100 Web Space
http://forum.100webspace.com/

Include file on every page
http://forum.100webspace.com/viewtopic.php?f=4&t=10517
Page 1 of 1

Author:  reallyfunny [ Wed Jul 02, 2008 2:34 am ]
Post subject:  Include file on every page

Do you know how with 100webspace free accounts display ads/banner on every frame? How do you do that automatically?

I want 2 lines of code to be displayed on every webpage I have without have to edit them all to put the two lines in.

Thanks

Author:  leohom [ Wed Jul 02, 2008 3:35 pm ]
Post subject: 

I would suggest you use php's "include" for this. Depending on what exactly you want to do, you could probably also use a database for it.

But regardless of how you do it, you will have to make a change to all your pages initially so that they all point to the "include" file. After the initial dirty work is done, all you need to do is to change the file to which the "include" refers to and all the pages update automatically from there.

Author:  reallyfunny [ Thu Jul 03, 2008 11:49 am ]
Post subject: 

but how does 100webspace do it, and other webhosts for that matter. How do you force content on every single page desired? With my site here, i don't add code to my site to display ads, so there must be a way. use .htaccess or something?

Author:  sohel2009 [ Sun Mar 14, 2010 4:40 am ]
Post subject: 

I've used .htaccess redirects before. You can also just always make it link to mywebsite/schedual.html and update that page.


Thanbks

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/