Our free HTML obfuscator can disable that, and you can find javascript snippets on the web to do it too, but for images, keep in mind that you can never stop someone taking a screen shot and then cropping that in m$osft paint to leach an image. I just can't figure a way to protect those themes with ioncube sorta fully.
Using the above features would still enable right click saves wouldn't it nick? I am running a theme site which only allows purchases through paypal. If you do want to encrypt the image files, then the readfile() can be replaced with ioncube_read_file() to read either an encrypted or non-encrypted image, but it's not clear whether this is useful. set by a GET parameter, rather than hardcoded. This is the kind of thing, although you would typically want to parameterise the script so that the image filename was dynamic, e.g. Header("Content-Transfer-Encoding: binary") Header("Content-Disposition: attachment filename=\"".basename($filename)."\" ") Header("Content-Type: application/octet-stream") Header("Cache-Control: must-revalidate, post-check=0, pre-check=0") I did some minor research on the subject and that's what I could come up with.Īs for an example of a wrapper, check out this snippet: I don't think the safest way for preventing direct links is through PHP, but instead in the Apache (or the webserver you are using) configuration. Just wanted to give my 2 cents worth of information, take it as you see fit p My question is now have an example of such an encoded PHP wrapper or a detailed description?
My aim is to avoid direct links from other websites to my pictures. Given that, it's not clear whether encrypting images would stop them being obtained via the webserver, but it would stop the images being used directly for sure. Whilst this will work very well, ultimately images will be received in their real form from the server, and there are several ways to take the image such as wget, or via the browser with right click, exploring the browser cache, or even taking a screen shot and mage cropping. An image tag might be something like Code: Your wrapper script may take the name of the image as a GET parameter, decrypt the corresponding file as a string, and echo the contents to the browser. The way to serve your encrypted image files is to use an encoded PHP wrapper, and for that to use the decryption feature built into the Loader API for restoring the image data and serving up the image. The encryption would in fact not be good if non-ionCube components could decrypt it! Once the files are encrypted, your browser of course caanot decrypt the images, and as images are normally served directly by the web server, they cannot be decrypted there either. Is it possible to encrypt this kind of php files in a way they are usable?Īs image files are not PHP, they cannot be encoded as PHP files, however you can encrypt them using the Encoder's unique non-PHP file encryption feature. But after I transfered this files to my server, the pictures weren't shown. I tried to encode non php files (*.gif, *.jpg. Posted: Sun 4:03 pm Post subject: encoding non php files (*.gif, *.jpg. Profile Log in to check your private messages Log inĮncoding non php files (*.gif, *.jpg. FAQ Search Memberlist Usergroups Register