The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

How do you set up changing banners?

View previous topic View next topic Go down

How do you set up changing banners?

Post by NotoriousMcFleury on Wed Jul 18, 2012 11:59 pm

I need help setting up the ability for users when they refresh the page they see a different banner. We found codes for phpBB2 but we don't know if we put them in the CSS sheet or if it's a java script code.

Can someone help?

NotoriousMcFleury
New Member

Posts : 4
Reputation : 1
Language : English

Back to top Go down

Re: How do you set up changing banners?

Post by Shian on Thu Jul 19, 2012 12:07 am

Hello.

Could you please post the code so I can see?

Shian
Forumember

Male Posts : 240
Reputation : 15
Language : English, French

http://overflowforum.com

Back to top Go down

Re: How do you set up changing banners?

Post by NotoriousMcFleury on Thu Jul 19, 2012 12:26 am

Well I figured out where the codes are supposed to go, but when I paste them in "overall_headers" it doesn't work.

Code:
<a href="FORUMURL">
                   
<center><div style="width: 900px;"><script type="text/javascript">
/*
Rotating Ads per Page Load
by iFusion - http://forum.ifcode.com
*/
//Define the ads' URL and Image below
var ad = []
ad[0]=["FORUMURL" , "BANNERURL"]
ad[1]=["FORUMURL" , "BANNERURL"]
ad[2]=["FORUMURL" , "BANNERURL"]
ad[3]=["FORUMURL" , "BANNERURL"]
//Do not edit anything below this line
x = Math.floor(Math.random()*ad.length)
document.write("<center>")
document.write("<a href='" + ad[x][0] + "'>")
document.write("<img src='" + ad[x][1] + "' />")
document.write("</a>")
document.write("</center>")
</script></div> </center></a>
              </tr>     

That is the code I am using, I didn't edit anything below, are the images not showing up because I'm hosting them on imgur? I also didn't put anything in "var ad = []"

NotoriousMcFleury
New Member

Posts : 4
Reputation : 1
Language : English

Back to top Go down

Re: How do you set up changing banners?

Post by Shian on Thu Jul 19, 2012 12:28 am

Is it posted under Java Script Management?

Shian
Forumember

Male Posts : 240
Reputation : 15
Language : English, French

http://overflowforum.com

Back to top Go down

Re: How do you set up changing banners?

Post by NotoriousMcFleury on Thu Jul 19, 2012 12:30 am

No it's pasted in overall_headers in Templates

NotoriousMcFleury
New Member

Posts : 4
Reputation : 1
Language : English

Back to top Go down

Re: How do you set up changing banners?

Post by Shian on Thu Jul 19, 2012 1:07 am

Well, just like Rideem said, Javascript goes in JavaScript Codes Management, so try posting it there.

Shian
Forumember

Male Posts : 240
Reputation : 15
Language : English, French

http://overflowforum.com

Back to top Go down

Re: How do you set up changing banners?

Post by NotoriousMcFleury on Thu Jul 19, 2012 8:03 pm

I put it in Javascript Managment and still nothing, I put it in overall_headers and still nothing.

Does anyone have an alternative code or something that is known to work?

NotoriousMcFleury
New Member

Posts : 4
Reputation : 1
Language : English

Back to top Go down

Re: How do you set up changing banners?

Post by nathanadhitya on Sun Jul 22, 2012 4:06 am

can you please provide your forum link please Hello
and your code it's a basic html the picture will auto shuffle and change so you only need to change the FORUMURL To Your forum url
then change the BANNERURL To be the direct image link
then if you wanna see the demo you can see by putting this code to html
Code:
<center><div style="width: 900px;"><script type="text/javascript">
/*
Rotating Ads per Page Load
by iFusion - http://forum.ifcode.com
*/
//Define the ads' URL and Image below
var ad = []
ad[0]=["FORUMURL1" , "http://i48.servimg.com/u/f48/17/48/49/15/clear10.gif"]
ad[1]=["FORUMURL2" , "http://www.programminglanguageforums.freehostingcloud.com/styles/prosilverbrownversion/imageset/site_logo.gif"]
ad[2]=["FORUMURL3" , "http://i48.servimg.com/u/f48/17/48/49/15/defaul11.png"]
ad[3]=["FORUMURL4" , "http://illiweb.com/fa/fdf_en3/repond12.png"]
//Do not edit anything below this line
x = Math.floor(Math.random()*ad.length)
document.write("<center>")
document.write("<a href='" + ad[x][0] + "'>")
document.write("<img src='" + ad[x][1] + "' />")
document.write("</a>")
document.write("</center>")
</script></div> </center></a>
              </tr>

nathanadhitya
Forumember

Male Posts : 98
Reputation : 2
Language : English And Indonesia

http://tr-teamwork.mydiscussionboard.com

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum