I found this code somewhere, sorry I don't remember where, but it works great for a rotating banner.  

Below is the code, you will need to replace:

your website

your image file

description

Then paste it all in a text box on your ning site.

 

You need to setup your images the exact size you want and store them somewhere so you can add the href address to the code.

Copy the line of code down and change the info for however many images you want in rotation.

 

See it in action here:  http://network.girlriders.net  Its the top left text box. Hit refresh to see it change.  I add more images whenever I have time to make them.

 

The code below is for 3 images.  ENJOY :)

 

 

<SCRIPT LANGUAGE="Javascript">
function banner() { } ; b = new banner() ; n = 0
b[n++]= "<A HREF='your website'><IMG name=randimg SRC='your image file' border='0' ALT='description'></A>"
b[n++]= "<A HREF='your website'><IMG name=randimg SRC='your image file' border='0' ALT='description'></A>"
b[n++]= "<A HREF='your website'><IMG name=randimg SRC='your image file' border='0' ALT='description'></A>"
i=Math.floor(Math.random() * n) ;
document.write( b[i] )
</SCRIPT>

 

 

Views: 956

Replies to This Discussion

Great tip, thank you for sharing!

=)

thanks for the tip
Thanks for this little tip!
You're welcome, all!

Great tip, but, how can I put the image into NING system ? , I mean in which directory do I have to put the SRC='your image file' ?... thanks for your helps

Since I don't use that for these images, I'm not positive.  But I think if you have Pro, you can load them into the file manager.  If you don't you may be able to load them like photos and use that address.   Someone else here may know for sure.

RSS

Members

© 2024   Created by JenSocial.   Powered by

Badges  |  Report an Issue  |  Terms of Service

Home
VIP Ning Tips