![]() |
For fucks sake... someone write this script
Let's say I have an image http://mysite.com/image.jpg
I want a script that will scan the image and make a copy of it somewhere else, like... http://MyOtherSite.com/scanned.jpg The script needs to scan the image twice daily, and replace the image it makes on the other site... since the original image will be changed twice daily. Lemme know if you can so I can give you contact info. Thanks |
Uhm, maybe I dont get what you're asking after but how about just crontabing a
"cd /www/myotherhost.com; rm -f image.jpg; wget http://mysite.com/image.jpg" on the box that hosts myothersite.com? |
traffictrader perhaps? It's all template run. So basically you can set it up like this, (I think)
http://mysite.com/image.jpg runs template a http://MyOtherSite.com/image.jpg runs template b They both run through traffic trader, and can be updated every 15 minutes if you wish, or everyday, every other day, once a week... It's up to you. Not so sure if it would scan. But you can set your file structure up to display "numbered images" and just have the templates run those numbers with each update. Traffic trader will automatically run those templates for you. You could basically set up a years worth of updates, turn on traffic trader, and walk away. :) |
Hmm, well see... sometimes the site that has the original image is down, and I want to display that image on a different site... so the whole purpose of the script is to NOT have a broken image on my site.
|
Quote:
Why would you think it's easier to run two seperate domains and copy image from server to another (automatically) than to get a more reliabe host is out of the question? |
to just grab the image from somewhere else and write it to your server this should do it with a cronjob..
lynx -dump http://yourdomain.com/image.jpg > image.jpg |
You can use symlinks to link to the picture. You can always do that and link the picture from anywhere on the server.
or use this script: ---- use File::Copy; $sour == "path/to/orig/image"; $dest == "path/to/copy/image/to"; copy("$sour", "$dest"); ----- |
Quote:
Reliable host? Im good on hosting and I have yet to find anyone to handle my traffic at my cost, but we wont get into that. |
All times are GMT -7. The time now is 03:26 AM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123