Welcome to WebmasterWorld Guest from

Forum Moderators: incrediBILL

Message Too Old, No Replies

Possible To Run Multiple Scripts From An Iframe?



3:49 pm on Feb 11, 2010 (gmt 0)

10+ Year Member

Weird question here.

I have multiple clients in an industry that have 3rd party website providers. I need to install multiple scripts on their website including:

Analytics Scripts
Conversion Trackers
etc etc

The scripts are mostly pixels, iframes or javascript.

Is there a way that I can make one simple script that i host on and call from my server and then embed any additional scripts within that to use on the clients website?

Effectively this would mean giving the 3rd party web provider 1 script rather then several to install on all of their pages and allowing me to control the removal or implementation of any new pixels/scripts from my own server

I hope I explained that well. Thanks for any help.


5:10 pm on Feb 11, 2010 (gmt 0)

WebmasterWorld Administrator incredibill is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

That really won't work because iFrames load from separate HTML pages therefore your analytics would report the page of content in the iFrame itself, not the page that included the iFrame.

Basically, your analytics would only record a single page being loaded, the one in the iFrame, therefore completely useless.

Does that make any sense?


5:23 pm on Feb 11, 2010 (gmt 0)

10+ Year Member

makes sense...what if they were all javascript files...could i embed one js file on the client site, linked back to mine with many sub-scripts?


6:32 pm on Feb 11, 2010 (gmt 0)

WebmasterWorld Senior Member 5+ Year Member

i suppose you could put a load of different query strings onto the end of just one url -- the one that your hosting. and then you could call each script depending on which query strings are there.


1:10 am on Feb 12, 2010 (gmt 0)

WebmasterWorld Senior Member kaled is a WebmasterWorld Top Contributor of All Time 10+ Year Member

I'm sure I don't fully understand this question however...

Can you use window.location.hostname with a single script that does whatever it needs to do to change its actions depending on which site is calling it?


Featured Threads

Hot Threads This Week

Hot Threads This Month