I am looking for a simple javascript that will switch an image on a
homepage when that page is reloaded. I would like a new image to
appear on the homepage each time it is accessed, either randomly or in
an order. Nothing fancy or heavy. |
Request for Question Clarification by
serenata-ga
on
14 Jan 2004 10:35 PST
Hi Roseyman ~
Do you really need javascript? I know of a dynamite cgi script that
will accomplish what you want without having to worry about whether or
not your visitor has javascript disabled.
Thanks,
Serenata
|
Clarification of Question by
roseyman-ga
on
14 Jan 2004 11:27 PST
As long as it works i am happy. Will that work on all servers?
DR
|
Request for Question Clarification by
serenata-ga
on
14 Jan 2004 11:31 PST
What server are you on? Unix or Windows?
Serenata
|
Clarification of Question by
roseyman-ga
on
14 Jan 2004 13:37 PST
Windows NT
|
Request for Question Clarification by
serenata-ga
on
14 Jan 2004 16:13 PST
Hi again Roseyman ~
Here's two scripts which should be pretty easy to install and use on
your servers ... the cgi script had a really easy interface, and cgi
*can* run on a Windows server, but only if it's set up to run cgi. And
if your server isn't it wouldn't do you much good.
I've asked the script's author if he has a version for your server,
but haven't heard from him yet.
In the mean time, here are a couple which should serve your purposes:
1. From The Javascript Source:
- http://javascript.internet.com/miscellaneous/random-image-rotator.html
and
2. From Dynamic Web Coding - Random Image Rotation
- http://www.dyn-web.com/javascript/rotate-img/rotate-rand.html
Do these look like the type you can work with easily enough?
Thanks,
Serenata
|
Clarification of Question by
roseyman-ga
on
14 Jan 2004 20:36 PST
Nope, I need it to change images when the page is refreshed only, not
randomly while the page is loaded.
Do you know of that code?
Thanks,
DR
|
Request for Question Clarification by
serenata-ga
on
14 Jan 2004 21:03 PST
That's the cgi. code .... every time you load the page you get a new
image (or content, you can decide).
Let me see what I can find.
Serenata
|
Request for Question Clarification by
serenata-ga
on
14 Jan 2004 22:18 PST
I'm sorry Roseyman ...
All the javascript codes I found were not based on cookies, although I
did find some which were built on time sequences, etc.
But that means every time your visitor comes back, he'd see the same
sequences. The script I had in mind was a marvelous little two lines
of script with a Perl5, cgi-bin interface to add your content. And it
just loops through the content every time anyone accesses the page.
Perhaps some other researcher can find or write what you need.
Sorry about that.
Serenata
|
Clarification of Question by
roseyman-ga
on
15 Jan 2004 15:59 PST
Will the cgi script work on Windows NT? I would use it if it would,
otherwise I'm in trouble. Let me know this last answer and I'll pay
you for your time.
Thanks,
DR
|
Request for Question Clarification by
serenata-ga
on
15 Jan 2004 16:37 PST
Hi Roseyman ~
The cgi script would work on your Windows NT server, but only if you
have Perl5 installed.
However, the script is free, the author of the script is a very
well-known and highly respected cgi script writer, Will Bontrager.
Their website is at www.willmaster.com ... The script I'm talking
about (which I have used on a lot of sites) is MasterMerryGoRound.
Here's my suggestion ...
Their contact information is on this page:
- http://willmaster.com/contact.shtml
Go ahead and ask him if his script can work on your server ... because
it may very well be able to work with some slight adjustment - I
really don't know.
You can tell him that I suggested his script (yes, they know who I am,
I use their scripts on all the sites I design) ... I don't get
anything from recommending them, except the satisfaction of knowing
I've recommended a relatively easy and genuinely good script to
someone.
If he can help you, he'll tell you ... if not, perhaps he can
recommend something that can help accomplish what you want.
I can't post this as an answer, because I haven't really helped you
solve your problem, but thanks so much for your generous offer!
Good luck,
Serenata
|
Clarification of Question by
roseyman-ga
on
16 Jan 2004 22:21 PST
Ok, talked to the server guy (design guy lingo) and PHP and cgi and
perl are out. I need a javascript or .asp solution. There has to be a
simple javascript code for this. All I want to do is have a different
image show up each time the page is loaded. HELP! Does anyone know a
smart javescript person who can solve this? I'll up the ante to $10,
with a tip to boot!
|