As far as I can see, the code on the 1st link is written in Perl, not PHP. And the second one is for use within a web page, not between [img] tags on a message board.
Trying to pull off a random image generator something like the ones explained on these pages I found:
http://www.scriptarchive.com/rand_image.html
http://www.davelozinski.com/scripts/...1265#download2
I want to get a random image to use for things like forum sigs, etc. so it would have to be at one stable. No javascript or anything. I tried pulling off some of the codes on the sites I looked at, but either:
A)Host dosen't accept PHP codes
B)I'm doing it wrong.
I tired using a free host called awardspace.com that said they were compatable with php, but I couldn't get the random image stuff working correctly.
So if anyone knows of any good hosts to try this on (free, if any) and maybe some experience with something like this (it seems simple enough, but maybe I'm missing something) I'd be thankful.
Hey guys.
As far as I can see, the code on the 1st link is written in Perl, not PHP. And the second one is for use within a web page, not between [img] tags on a message board.
Annual Unown Awards: Kind (2007), Friendly, Queen (2008), Dedicated (2009), She found Kevin! (2009),
Everyone wins (2011), Tea, World traveler (2012), Busy, Patient (2013),
Durga, Firefox, Twenty Thousand Hidden Posts (2014), Helpful (2015),
Active, Discord, Letter, Unown Awards 2019 (2019).
Don't forget to visit the Dragon's Guild and Dragon Tamers site.
✭Ask me about AC/CC. Adopt a pokemon and Join!✭
Well, regardless of it being php or not- I want any method of random off-site images on a free host. If anyone knows of any way to do that...
Hey guys.
Award space is good. I have some PHP scripts running with them. Yeah there good, I'd stick with them. But for the script. Currently my web design doesn't go past (x)html, css and javascript. Can't help you there.
Pokemon Pearl FC: 3479 9091 3139
Hmm... I'm not too familiar with PHP, myself. However, I found a script here that might help you. If that isn't what you need, then I'd recommend running a Google search and just sifting through the results.
It still works.Originally Posted by Lady Vulpix
I guess it depends on the forum board, but for the most part, it works. (It works in vB too)
http://www.davelozinski.com/scripts/...image1.php.txt
That's from your second link. All you do is upload that script to your server then make an "images" directory and upload your images into that directory. And of course, make sure it has .php extension, not .txt.
So your directory tree should be like:
/
random_image.php
/images
/images
picture1.jpeg
pikachu.jpg
etc.gif
(btw, your images can only be .jpg, .jpeg, and .gif)
and then you add it to your sig:
[ img ]http://yoursite.com/random_image.php[ /img ]
If it doesn't work, try changing this line in the script: $IMAGE_DIRECTORY = "../images/";
to: $IMAGE_DIRECTORY = "./images/"; (remove first period)
Good luck!