Has anyone been able to make an ASP ad rotator work?

Discussion in 'ASP.NET 2.0' started by Moselle, May 29, 2010.

  1. I've spent hours messing with this today. I've tried several different scripts, mostly ASP, one or two Java. None of them work.

    Here's one:


    <%
    'declare your variables
    dim varad, objAd
    'create an instance of the Rotator object and assign variable
    Set objAd = Server.CreateObject("MSWC.AdRotator")
    'make sure the page will open up in a new browser
    objAd.TargetFrame="TARGET=_BLANK"
    'call the GetAdvertisement method and assign all details to variable
    varAd = objAd.GetAdvertisement("text/ads.txt")
    'display the banner and its details
    Response.Write varAd
    %>


    Here's another:

    <%
    url=Request.QueryString("url")
    If url<>"" then Response.Redirect(url)
    %>
    <html>
    <body>

    <%
    DIM strBanners
    Set strBanners = Server.CreateObject("MSWC.AdRotator")
    Response.Write (strBanners.GetAdvertisement("/text/advertisements.txt"))
    %>

    And there's also the appropriate text files. Any help would be most appreciated.
     
  2. Bruce

    Bruce DiscountASP.NET Staff

    error?
     
  3. Is that Classic + VBScript? Since this question was posted in the ASP.NET forum, I'll pitch in with yes - the ASP.NET AdRotator web control that ships with VS2008/2010 works fine on the DASP web servers.
     
  4. I'm using the asp.net add rotator with xml, and it's working really fine, you can check it in http://www.dentiumcolombia.com . So are you using classic ASP?? or ASP.NET??
     
  5. Bruce

    Bruce DiscountASP.NET Staff

    note that this is only supported on iis6 server. If you are on IIS7, this component won't work.
     

Share This Page