develooper Front page | perl.libwww | Postings from September 2001

Problem getting past a java script

From:
gtilton2
Date:
September 5, 2001 08:29
Subject:
Problem getting past a java script
Message ID:
OFB6EC4CAA.EF2D004C-ON85256ABE.005259EE@com
I'm in trouble again.  I can't seem to get past a java script in order to
gain access to the files I need.  I have the authorization codes, but I
can't seem to negotiate with the java script.  I've tried calling the main
function of the script, but possibly don't know the syntax to do this or
whether it is even necessary.  I've tried to use the url that works with my
browser, but in the perl script this url doesn't return anything
meaningful.
Below is the main function of the java script.  When I try the "get"
function with useragent, I miss the main function altogether and get the
last section of the java script.  I've highlighted what I get in red.  Any
suggestions (besides getting out of programming) would be greatly
appreciated.
Thanks,
Greg

Java script with main function ShowFileList:
<html>
<head>
<meta NAME="GENERATOR" Content="Microsoft Visual InterDev 1.0">
<meta HTTP-EQUIV="Content-Type" content="text/html; charset=iso-8859-1">
<title>Downloads</title>
<!-- This include contains all Javascript functions for this asp file -->
<SCRIPT LANGUAGE="JavaScript">
<!--
function ShowFileList(UID,UCD,page) {
     var strTemp;
     var mktrno,mktname;
     var frm;

     frm = document.Downloads;

     strTemp=frm.MKTRACCT.options[frm.MKTRACCT.selectedIndex].text;
     mktrno=strTemp.substring(0,15);

     strTemp=frm.MKTRACCT.options[frm.MKTRACCT.selectedIndex].text;
     mktrname=strTemp.substring(19,45);

     if (mktrno.length < 15)
     {alert('Invalid Marketer selected.');}
     else
     {
          if (!isInteger(mktrno))
          {alert('Invalid Marketer selected.');}
          else
          { if (page == 'A')
               {location = '/retailaccess/dlFiles.asp?passUID=' + UID + '
&passUCD=' + UCD + '&mktr=' + mktrno + '&mn=' + ReplaceSpace(mktrname);}
            else
               {if (page == 'P')
                    {location = '/retailaccess/dlDaily.asp?passUID=' + UID
+ '&passUCD=' + UCD + '&proc=Profile&mktr=' + mktrno + '&mn=' +
ReplaceSpace(mktrname);}
                 else
                    { if (page == 'L')
                         {location = '/retailaccess/dlDaily.asp?passUID=' +
UID + '&passUCD=' + UCD + '&proc=Accts&mktr=' + mktrno + '&mn=' +
ReplaceSpace(mktrname);}
                      else
                         { if (page == 'R')
                              {location
= '/retailaccess/dlRates.asp?passUID=' + UID + '&passUCD=' + UCD + '&mktr='
+ mktrno;}
                           else
                              {if (page == 'U')
                                   {location
= '/retailaccess/dlDaily.asp?passUID=' + UID + '&passUCD=' + UCD + '
&proc=Notification&mktr=' + mktrno + '&mn=' + ReplaceSpace(mktrname);}
                                else
                                   {location
= '/retailaccess/dlDaily.asp?passUID=' + UID + '&passUCD=' + UCD + '
&proc=Cycle&mktr=' + mktrno + '&mn=' + ReplaceSpace(mktrname);}
                              }
                         }
                    }
               }
          }
     }
}
//-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!--
//-->
</SCRIPT>
//-->
</SCRIPT>
</head>
<body>

<!-- The include for the database connection object -->


<!-- This include contains a function for each database access required -->


<!-- This is a validation call to check for timeout -->

<!--this is the include for the timeout page-->
<BODY BACKGROUND="/retailaccess/images/page_bg.gif " LEFTMARGIN=10
TOPMARGIN=10 RIGHTMARGIN=10>
<CENTER>
<FONT FACE="ARIAL ROUNDED MT BOLD, ARIAL, HELVETICA" SIZE=5>
Retail Access Security Error</FONT>
<BR>
<BR CLEAR=ALL>
<FONT FACE="ARIAL ROUNDED MT BOLD, ARIAL, HELVETICA" SIZE=2>
You have timed out. Please restart the application</FONT>
<P>
<A HREF="/retailaccess" TARGET="_top"><IMG SRC="/webpics/restart.gif"
BORDER=0 HSPACE=5 VSPACE=10 ALT="Restart Application" ALIGN=ABSMIDDLE></A>
</CENTER>
</body>
</html>




nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About