Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Looking for a fast way to update content on multiple sites
Old 01-05-2008, 09:34 AM Looking for a fast way to update content on multiple sites
Novice Talker

Posts: 8
Trades: 0
Hi,

I design websites in HTML and I've got a following problem:

I want to run advertisements on my site. Is there any way
to use some script, so all the spaces where ads will be placed
through the site will refer to only one file, so after editing that file
all ads will change on all of the pages at once?

I'm not sure if I stated myself clear


I tried to insert a JavaScript call


<SCRIPT LANGUAGE="JavaScript" SRC="my-file-with-ads.js">
<!--
/-->
</SCRIPT>


into every page on my site but for example etology.com has their ad
code also in the JavaScript format and when I put their JavaScript code into my *.js file that is called on every page on my site, Internet Explorer crash and doesn't display site layout properly (Firefox for example displays everything ok)

It looks like that:

I've got this

<SCRIPT LANGUAGE="JavaScript" SRC="my-file-with-ads.js">
<!--
/-->
</SCRIPT>

in source code of every page, and the file "my-file-with-ads.js" contains:

document.write("<div id='ad-up'><script language='javascript' type='text/javascript' charset='utf-8' src='http://pages.etology.com/gtbjs/3244543510.php'></script></div>")

I tried to break the </script> and it still doesn't work in IE


Is there any other way to put JavaScript format ads into every page on the website that will be easy to edit?

Thanks
przechwyt is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 01-05-2008, 10:18 AM Re: Looking for a fast way to update content on multiple sites
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
Server-side includes would likely do the trick.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 01-05-2008, 03:38 PM Re: Looking for a fast way to update content on multiple sites
Connie's Avatar
Junior Talker

Posts: 2
Name: Connie Shelton
Trades: 0
I agree that SSI would do what you want to do. You will have to add something like this on all your pages where you want the adds to show.
<!--#include virtual="/folder/page.inc" -->

You also need to create the file that contains the add or graphic. I use an extension .inc, but I think you can use any extension for that page. I keep my main .inc files in one folder.

By default a server will only parse a shtml file. You will probably need to add this to a .htaccess file "AddHandler server-parsed .htm .html" without the quotes.
Connie is offline
Reply With Quote
View Public Profile Visit Connie's homepage!
 
Old 01-06-2008, 01:41 AM Re: Looking for a fast way to update content on multiple sites
Novice Talker

Posts: 8
Trades: 0
Thanks guys, everything works fine !
przechwyt is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Looking for a fast way to update content on multiple sites
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.22687 seconds with 12 queries