Current location: Hot Scripts Forums » General Web Coding » JavaScript » Best way to link images and swf for banner tracking


Best way to link images and swf for banner tracking

Reply
  #1 (permalink)  
Old 12-03-03, 12:27 AM
Xtremist Xtremist is offline
Newbie Coder
 
Join Date: Aug 2003
Location: Pensacola, FL
Posts: 99
Thanks: 0
Thanked 0 Times in 0 Posts
Best way to link images and swf for banner tracking

Hello,

I'm building a banner/ad managment script and I want to be able to track all clicks on images and swf files. I've got it working fine with images but am having a problem when it comes to swf files. I know I can put a link in the swf file but I want a way to link and track without having to use a link in the swf file.

I've tried layers, linking tables, wraping the swf code in a href tags and so on with no results.

Here is the code I use to display the image / swf file.

<% dim thefile, theextension
thefile = (getbanners.Fields.Item("fbannerimageurl").Value)
theextension = right (thefile,3) %>


<% if theextension = "swf" then %>
<object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="468" height="60">
<param name="movie" value="/bannertrackerasp/banners/<%=thefile%>">
<param name="quality" value="high"> <param name="PLAY" value="<% if (getbanners.Fields.Item("fbannerautoplay").Value) = 1 then
Response.Write "true"
else Response.Write "False"
end if %>"><param name="LOOP" value="<% if (getbanners.Fields.Item("fbannerloop").Value) = 1 then
Response.Write "true"
else Response.Write "False"
end if %>">
<embed src="/bannertrackerasp/banners/<%=thefile%>" width="468" height="60" loop="false" play="false" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed>
</object>
<% else %>
<a href="click.asp?id=<%=(getbanners.Fields.Item("fba nnerid").Value)%>&count=<%=dcount%>" <% if (getbanners.Fields.Item("fbannerwindow").Value) = 1 then%> target="_blank" <% Else%> target="_top" <% End IF %>><img src="/bannertrackerasp/banners/<%=thefile%>" alt="<%=(getbanners.Fields.Item("fbanneralttext"). Value)%>" border="0"></a>
<% end if %>

It's is using ASP and a access database....

If anyone can offer some assistance, I'd be thankful!

TIA,

Chris
__________________
Chris
http://www.pensacolawebdesigns.com
I know it's not much but I never find time to work on my own site
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #2 (permalink)  
Old 12-14-03, 12:46 PM
psyon psyon is offline
Newbie Coder
 
Join Date: Dec 2003
Posts: 16
Thanks: 0
Thanked 0 Times in 0 Posts
www.phpadsnew.com

PHPAdsnew does something like that, its a free project, you might be able to get ideas from. I think they actually modify the SWF file, using built in functions of php. Perl also has SWF libraries.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #3 (permalink)  
Old 12-14-03, 01:00 PM
Xtremist Xtremist is offline
Newbie Coder
 
Join Date: Aug 2003
Location: Pensacola, FL
Posts: 99
Thanks: 0
Thanked 0 Times in 0 Posts
Thanks for the reply! I will look into that.
__________________
Chris
http://www.pensacolawebdesigns.com
I know it's not much but I never find time to work on my own site
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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 Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump


All times are GMT -5. The time now is 01:36 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.