The Forum has been Updated
The code has been upgraded to the latest .NET core version. Please check instructions in the Community Announcements about migrating your account.
Help
I need to put the following embedded code into an onload function within a forum page, and I am stuck
The embed code (edited for security reasons) is as follows:
Please could someone show me how?
I need to put the following embedded code into an onload function within a forum page, and I am stuck
The embed code (edited for security reasons) is as follows:
Code:
<script language='javascript' type='text/javascript' src='http://something.com/in.php?action=adserve&method=videopage&videoPageCode=video_player_page11&boxId=editAdDiv&syndicationTargetPageID=B-7070-4FA2'></script><div id='editAdDiv'></div>
Please could someone show me how?
Last edited by Webbo on 05 July 2011, 02:41
Posted
Why not put it in the header or footer of the forum? If you put it in the footer, the javascript will execute after the page is loaded.
Posted
The embed code is specific to one page Davio, hence the need to include it within that page's code
Posted
I think you could add this to the inc_header.asp page and it would then only load for the page you wanted it on:
Change the parts in red for your own page and code.
Code:
if request.servervariables("URL") = "/forum/yourpagehere.asp" then
%>
Content in here
<%
end if
Last edited by leatherlips on 04 July 2011, 21:11
Posted
The only problems I can see with that check is it will be made everytime a page is viewed that uses inc_header.asp and we get approx 11million page views a month, also I would not have any control where the resulting output is displayed
Here is a link to the page in question, the embedded code produces the video section, you can see the lag in the page rendering
http://www.maggotdrowning.com/forum/tv_channel.asp
Here is a link to the page in question, the embedded code produces the video section, you can see the lag in the page rendering
http://www.maggotdrowning.com/forum/tv_channel.asp
Last edited by Webbo on 05 July 2011, 02:38
Posted
that is not a forum page, we don't have any pages called tv_channel. can you post a text version of that page so we can take a look
Posted
Here is a thought. Since you made a special page maybe you could copy the inc_header.asp page and name it inc_header_tvchannel.asp. Add your code to it. Then in your tv_channel.asp page you could have it call inc_header_tvchannel.asp instead of the normal inc_header.asp page.
Posted
Originally posted by leatherlips
Here is a thought. Since you made a special page maybe you could copy the inc_header.asp page and name it inc_header_tvchannel.asp. Add your code to it. Then in your tv_channel.asp page you could have it call inc_header_tvchannel.asp instead of the normal inc_header.asp page.
The only problem with that is keeping updates synchronized between the two. If there's something that needs changing on both includes, you'll have to remember to make two sets of changes.
Not bad when you only have two sets of changes, but that mindset only leads to madness later on. Take it from someone who's maintained someone else's code designed like that...
Posted
This should work since you are just keeping up with the <body> tag for the onload function regarding edits. You could take your current inc_header.asp file (after editing and saving it) and then do a "Save As..." to save it as inc_header_tv_channel.asp (overwriting the old inc_header_tv_channel.asp file) as long as you remember to replace the needed onload function into the <body> tag once again after that save.
Posted
As AnonJnr said it would be a problem keeping the includes updated - there are four different tv_channel pages in total, each rendering different video content and with their own embed codes so I would need four versions of the inc_header_tvchannel.asp, not unless I could use a series of 'if's which checks the page being rendered and then loads the correct code - but that's just getting too complicated
Huwr, the page is a custom file and not an original Snitz file, a text version is available Here
Huwr, the page is a custom file and not an original Snitz file, a text version is available Here
Email Member
Message Member
Post Moderation
FileUpload
If you're having problems uploading, try choosing a smaller image.
Preview post
Send Topic
Loading...