can't get this script to work.

New to mod_rewrite? This is a good place to start.

can't get this script to work.

Postby darkman » Wed Jul 28, 2004 7:45 am

I have compiled mod_rewrite into my http daemon and have been trying to get this to work:
this is in my httpd.conf file:

#Image Snatchers
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_REFERER} !^http://slamomaha.com/ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.slamomaha.com/ [NC]
RewriteRule .*\.(jpe?g|gif|bmp|png)$ http://clicqx.com/images/bleu.jpg [R]
</IfModule>

I also did an httpd -l and here is what I get:
Compiled-in modules:
http_core.c
mod_mmap_static.c
mod_vhost_alias.c
mod_env.c
mod_log_config.c
mod_log_agent.c
mod_log_referer.c
mod_mime_magic.c
mod_mime.c
mod_negotiation.c
mod_status.c
mod_info.c
mod_include.c
mod_autoindex.c
mod_dir.c
mod_cgi.c
mod_asis.c
mod_imap.c
mod_actions.c
mod_speling.c
mod_userdir.c
mod_alias.c
mod_rewrite.c
mod_access.c
mod_auth.c
mod_auth_anon.c
mod_auth_dbm.c
mod_auth_db.c
mod_digest.c
mod_proxy.c
mod_cern_meta.c
mod_expires.c
mod_headers.c
mod_usertrack.c
mod_example.c
mod_unique_id.c
mod_so.c
mod_setenvif.c
but at the end I also get this:
suexec: disabled; invalid wrapper /usr/local/apache/bin/suexec<--- would this make a difference?

I am trying to make it hard for image and bandwidth snatchers to work....IE: hotlinking.....any ideas? thanks.
BTW I have tried several different ways to do this and none work. I have tried putting rewrite stuff in .htaccess files and it complains can't use rewrite here, but i have noticed that when I do use a rewrite in the htaccess file, it doesn't allow anyone to see my websites at all.....
TIA
darkman
 

Return to Beginner's Corner

Who is online

Users browsing this forum: No registered users and 34 guests

cron