Forum Moderators: open
I have a problem that many of my visitors are linking to my pictures and thats not the point I want them to download the pictures or set it as background, the other way it uses my server power + they dont see the ads which is the only income for this site.
Anybody know how to change this, maybe like like Tripod does.
zeus
If you don't meet those requirements, you could try this php solution [thesitewizard.com] instead.
The referer is from the previous page you would have to do a double load.
The real problem is once the image is load into the browser once ther you can just get the properties of the image.
one possible solution would be to use thumbnails with a javascript popup driven by a dynamic asp page.
with the JS you can call an asp page to look in the database for the image path and then throw it a popup(disable mouse buttons and menus)
DaveN
The HTTP_REFERER was only being sent by the browser when the user clicked on a link. I can't say for sure that this is the case but beware!
I can't find the post, sorry, I've trawled and used the search without any luck.
Open that, copy the code from the web page into it and then select 'save as...'. Save it as anything.txt unto your desktop.
Then go to your desktop, right-click the file and select 'rename'. Call it chimage.php.
But the principle is the same. If you have a .htaccess file on your server, download it and open it with the notepad. Then copy the code from the 'thesitewizard' page into that file, save it and upload it back to your server.
ASCII is just plain text. That is what the notepad produces.
1. Using a standard text editor (e.g. Microsoft's Notepad, or Mac's Simple Text (?)), create your file.
2. Save it as .htaccess. To make sure this works properly, you might want to set your PC to show file extensions. The name must be:
.htaccess
...i.e, nothing before the dot. Save it, then check using Windows Explorer that it is indeed .htaccess and not, say, .htaccess.txt (which can happen). Rename if necessary. Some text editors won't allow you to save anything without a file name; in that case, save it as x.htaccess and then rename it. If all else fails, you can upload it as x.htaccess and then use your FTP client to rename it on the server.
3. Upload. Now comes the ASCII bit.
Your FTP client can upload in either binary mode or ASCII mode. ASCII is used for text files, binary for images, Flash files, sound files etc. It uses the file extension to work out whether to use ASCII or binary. If your FTP client doesn't recognize .htaccess, it will most likely default to binary. This will probably mangle your .htaccess file; so your FTP client should have a menu somewhere that allows you to enter file extensions for upload in ASCII mode.
4. Most likely, you won't see your .htaccess file once it's uploaded. This is because file names beginning with a dot are usually "hidden". Your FTP client may have a box where you can enter a "mask" -- if you type -a into that box, you should see your .htaccess file.