how can I login the web

Ask a Question related to PERL Modules, Design and Development.

  1. #1

    Default how can I login the web

    my code,and i don't know how to get the value of "PHPSEEid"??
    who can tell me how to do ?thank you very much!
    =============
    use HTTP::Request::Common qw(POST);
    use LWP::UserAgent;

    my
    $url='http://192.168.110.129/security/login/login.php?selectedLanguage=eng';
    $ua=LWP::UserAgent->new();
    $req1= POST
    $url,[userName=>'manager',userPwd=>'manager',PHPSEEID=>" $PHPSESSID"];
    $content=$ua->request($req1)->as_string;
    print $content;
    =====================
    but i received the message:
    ==================
    HTTP/1.1 200 OK
    Cache-Control: no-cache, must-revalidate
    Connection: close
    Date: Mon, 07 Aug 2006 08:02:36 GMT
    Pragma: no-cache
    Server: Apache/1.3.27 (Unix) PHP/4.2.3
    Content-Type: text/html
    Expires: Mon, 26 Jul 1997 05:00:00 GMT
    Last-Modified: Mon, 07 Aug 2006 08:02:36GMT
    Client-Date: Thu, 06 Jul 2006 07:37:15 GMT
    Client-Peer: 192.168.110.129:80
    Client-Response-Num: 1
    Client-Transfer-Encoding: chunked
    Set-Cookie: PHPSESSID=72e0a426f9363f7ba4b17f19826c5989; path=/
    X-Powered-By: PHP/4.2.3

    <html>
    <style type="text/css">
    <!--
    body { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    8pt}
    th { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    8pt; font-weight: bold; background-color: #D3DCE3;}
    td { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    8pt;}
    form { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    8pt}
    textarea{font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 8pt; BACKGROUND-COLOR: white; BORDER-BOTTOM: #000000 1px
    solid; BORDER-LEFT: #000000 1px solid; BORDER-RIGHT: #000000 1px solid;
    BORDER-TOP: #000000 1px solid;}
    input.text {font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 8pt; BACKGROUND-COLOR: white; BORDER-BOTTOM: #000000 1px
    solid; BORDER-LEFT: #000000 1px solid; BORDER-RIGHT: #000000 1px solid;
    BORDER-TOP: #000000 1px solid;}
    input.button {font-family: Verdana; font-size: 8pt}
    select { font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 8pt; BACKGROUND-COLOR: white; BORDER-BOTTOM: #000000 1px
    solid; BORDER-LEFT: #000000 1px solid; BORDER-RIGHT: #000000 1px solid;
    BORDER-TOP: #000000 1px solid;}
    h1 { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    16pt; font-weight: bold}
    A:link { font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 8pt; text-decoration: none; color: #0000FF}
    A:visited { font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 8pt; text-decoration: none; color: #0000FF}
    A:hover { font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 8pt; text-decoration: underline; color: #FF0000}
    A:link.nav { font-family: Verdana, Arial, Helvetica, sans-serif;
    color: #0000FF}
    A:visited.nav { font-family: Verdana, Arial, Helvetica, sans-serif;
    color: #0000FF}
    A:hover.nav { font-family: Verdana, Arial, Helvetica, sans-serif;
    color: #FF0000}
    .nav { font-family: Verdana, Arial, Helvetica, sans-serif; color:
    #000000}
    -->
    </style>
    <script LANGUAGE="JavaScript">
    function openHelp(helpId){
    URL="../../omcHelp/index.php?helpId="+helpId;
    var
    baseSetting='toolbar=no,directories=no,menubar=no, scrollbars=yes,resizable=yes,left=0,top=0';
    var size800=',width=790,height=560';
    var size1024=',width=1010,height=710';

    if (window.screen.width==800 && window.screen.height==600){
    pageSetting = baseSetting + size800;
    }else{
    pageSetting = baseSetting + size1024;
    }

    msgWindow = window.open(URL,'helpWin',pageSetting);
    msgWindow.focus();
    }
    </script>
    <SCRIPT LANGUAGE="JAVASCRIPT">
    <!--
    function loadset(){
    document.loginForm.userName.value='';
    document.loginForm.userPwd.value='';
    document.loginForm.userName.focus();
    }

    function Check(theform){
    var username=theform.userName.value;
    var password=theform.userPwd.value;
    if (username.length < 1){
    alert("User ID error!");
    theform.userName.focus();
    return (false);
    }
    if (password.length < 6){
    alert("password length must >= 6");
    theform.userPwd.focus();
    theform.userPwd.select();
    return (false);
    }
    return (true);
    }

    function selectEng(){
    window.location.href="/security/login/login.php?selectedLanguage=eng";
    }

    function selectChn(){
    window.location.href="/security/login/login.php?selectedLanguage=chn";
    }

    //-->
    </script>

    <body bgcolor="#FFFFFF" onload="loadset()">
    <br><br><br><br><br><br>
    <form method="POST" name="loginForm"
    action="/security/login/login.php?selectedLanguage=eng"
    onsubmit="return Check(this)" ><input type="hidden" name="PHPSESSID"
    value="72e0a426f9363f7ba4b17f19826c5989" />
    <table border="0" width="100%" height="75%" valign="center">
    <tr>
    <td width="100%" align="center" height="25%" valign="bottom">
    <img border="0" src="../../images/alvr_300.gif">
    <br><br><br>
    </td>
    </tr>
    <tr>
    <td width="100%" align="center" height="10">
    <table border="1" width="280" bordercolordark="#FFFFFF"
    bordercolor="#808080" cellspacing="0" height="120">
    <tr>
    <td width="100%" colspan="2" bgcolor="#E6E6E6" height="20"
    align="center">
    <b><font size="2">
    Logon WXC2 Management Console </font></b>
    </td>
    </tr>
    <tr>
    <td>
    <img border="0" src="../../images/loginUser.gif" > User: </td>
    <td align="center">
    <input type="text" name="userName" size="20" class="text">
    </td>
    </tr>
    <tr>
    <td>
    <img border="0" src="../../images/loginPwd.gif" > Password: </td>

    <td align="center">
    <input type="password" name="userPwd" size="20" class="text">
    </td>
    </tr>
    <tr>
    <td colspan="2" align="center">
    <input type="submit" value="Login" name="login"
    class="button">&nbsp;&nbsp;&nbsp;<input type="reset" value="Cancel"
    class="button"> </td>
    </tr>
    </table>
    </td>
    </tr>
    <tr><td align="center">
    <a style="Cursor:hand" onclick="javascript:selectChn()"><image
    src="../../images/chinese.gif"></td></tr>
    <tr><td align="center"><b><font
    size=6>R8.0(V8.02.10)</font></b></td></tr>
    </table>
    </form>
    </body>
    </html>

    warhua@gmail.com Guest

  2. Similar Questions and Discussions

    1. Strange problem with Forms authentication: After successfull login, login page is still displayed
      Hi there I have a quite strange problem with my ASP.NET-Application. The application has being deployed one year ago and worked fine till last...
    2. user and admin login on same login page
      Hello, I have a user login page which also doubles as my administrator login. Currently, my method of logging in doesnt seem to be working...
    3. Login to admin system through login screen only
      Hi there, I have an issue relating to login to my asp.net application. Basically i have built the standard login page which compares against the...
    4. session problem - login screen continually reloads after pressing the login button
      I am trying to get sessions to work on a log in screen to give certain users access to certain pages/directories. The problem is that when the...
    5. LOGIN: ERROR- Failed to initialize policy manager. (IFOR_PM_FATAL) Login sessions denied.
      Verify that you haven't set the system date by mistake to a far away future. All the licenses then become expired! Restoring the system to the...
  3. #2

    Default Re: how can I login the web

    looks ok to me (apart from lack of documtent-type declaration!)
    what's your problem?

    On Sun, 06 Aug 2006 00:40:55 -0700, [email]warhua@gmail.com[/email]
    wrote:
    > my code,and i don't know how to get the value of "PHPSEEid"??
    > who can tell me how to do ?thank you very much!
    > =============
    > use HTTP::Request::Common qw(POST);
    > use LWP::UserAgent;
    >
    > my
    > $url='http://192.168.110.129/security/login/login.php?selectedLanguage=eng';
    > $ua=LWP::UserAgent->new();
    > $req1= POST
    > $url,[userName=>'manager',userPwd=>'manager',PHPSEEID=>" $PHPSESSID"];
    > $content=$ua->request($req1)->as_string;
    > print $content;
    > =====================
    > but i received the message:
    > ==================
    > HTTP/1.1 200 OK
    > Cache-Control: no-cache, must-revalidate
    > Connection: close
    > Date: Mon, 07 Aug 2006 08:02:36 GMT
    > Pragma: no-cache
    > Server: Apache/1.3.27 (Unix) PHP/4.2.3
    > Content-Type: text/html
    > Expires: Mon, 26 Jul 1997 05:00:00 GMT
    > Last-Modified: Mon, 07 Aug 2006 08:02:36GMT
    > Client-Date: Thu, 06 Jul 2006 07:37:15 GMT
    > Client-Peer: 192.168.110.129:80
    > Client-Response-Num: 1
    > Client-Transfer-Encoding: chunked
    > Set-Cookie: PHPSESSID=72e0a426f9363f7ba4b17f19826c5989; path=/
    > X-Powered-By: PHP/4.2.3
    >
    > <html>
    > <style type="text/css">
    > <!--
    > body { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    > 8pt}
    > th { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    > 8pt; font-weight: bold; background-color: #D3DCE3;}
    > td { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    > 8pt;}
    > form { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    > 8pt}
    > textarea{font-family: Verdana, Arial, Helvetica, sans-serif;
    > font-size: 8pt; BACKGROUND-COLOR: white; BORDER-BOTTOM: #000000 1px
    > solid; BORDER-LEFT: #000000 1px solid; BORDER-RIGHT: #000000 1px solid;
    > BORDER-TOP: #000000 1px solid;}
    > input.text {font-family: Verdana, Arial, Helvetica, sans-serif;
    > font-size: 8pt; BACKGROUND-COLOR: white; BORDER-BOTTOM: #000000 1px
    > solid; BORDER-LEFT: #000000 1px solid; BORDER-RIGHT: #000000 1px solid;
    > BORDER-TOP: #000000 1px solid;}
    > input.button {font-family: Verdana; font-size: 8pt}
    > select { font-family: Verdana, Arial, Helvetica, sans-serif;
    > font-size: 8pt; BACKGROUND-COLOR: white; BORDER-BOTTOM: #000000 1px
    > solid; BORDER-LEFT: #000000 1px solid; BORDER-RIGHT: #000000 1px solid;
    > BORDER-TOP: #000000 1px solid;}
    > h1 { font-family: Verdana, Arial, Helvetica, sans-serif; font-size:
    > 16pt; font-weight: bold}
    > A:link { font-family: Verdana, Arial, Helvetica, sans-serif;
    > font-size: 8pt; text-decoration: none; color: #0000FF}
    > A:visited { font-family: Verdana, Arial, Helvetica, sans-serif;
    > font-size: 8pt; text-decoration: none; color: #0000FF}
    > A:hover { font-family: Verdana, Arial, Helvetica, sans-serif;
    > font-size: 8pt; text-decoration: underline; color: #FF0000}
    > A:link.nav { font-family: Verdana, Arial, Helvetica, sans-serif;
    > color: #0000FF}
    > A:visited.nav { font-family: Verdana, Arial, Helvetica, sans-serif;
    > color: #0000FF}
    > A:hover.nav { font-family: Verdana, Arial, Helvetica, sans-serif;
    > color: #FF0000}
    > .nav { font-family: Verdana, Arial, Helvetica, sans-serif; color:
    > #000000}
    > -->
    > </style>
    > <script LANGUAGE="JavaScript">
    > function openHelp(helpId){
    > URL="../../omcHelp/index.php?helpId="+helpId;
    > var
    > baseSetting='toolbar=no,directories=no,menubar=no, scrollbars=yes,resizable=yes,left=0,top=0';
    > var size800=',width=790,height=560';
    > var size1024=',width=1010,height=710';
    >
    > if (window.screen.width==800 && window.screen.height==600){
    > pageSetting = baseSetting + size800;
    > }else{
    > pageSetting = baseSetting + size1024;
    > }
    >
    > msgWindow = window.open(URL,'helpWin',pageSetting);
    > msgWindow.focus();
    > }
    > </script>
    > <SCRIPT LANGUAGE="JAVASCRIPT">
    > <!--
    > function loadset(){
    > document.loginForm.userName.value='';
    > document.loginForm.userPwd.value='';
    > document.loginForm.userName.focus();
    > }
    >
    > function Check(theform){
    > var username=theform.userName.value;
    > var password=theform.userPwd.value;
    > if (username.length < 1){
    > alert("User ID error!");
    > theform.userName.focus();
    > return (false);
    > }
    > if (password.length < 6){
    > alert("password length must >= 6");
    > theform.userPwd.focus();
    > theform.userPwd.select();
    > return (false);
    > }
    > return (true);
    > }
    >
    > function selectEng(){
    > window.location.href="/security/login/login.php?selectedLanguage=eng";
    > }
    >
    > function selectChn(){
    > window.location.href="/security/login/login.php?selectedLanguage=chn";
    > }
    >
    > //-->
    > </script>
    >
    > <body bgcolor="#FFFFFF" onload="loadset()">
    > <br><br><br><br><br><br>
    > <form method="POST" name="loginForm"
    > action="/security/login/login.php?selectedLanguage=eng"
    > onsubmit="return Check(this)" ><input type="hidden" name="PHPSESSID"
    > value="72e0a426f9363f7ba4b17f19826c5989" />
    > <table border="0" width="100%" height="75%" valign="center">
    > <tr>
    > <td width="100%" align="center" height="25%" valign="bottom">
    > <img border="0" src="../../images/alvr_300.gif">
    > <br><br><br>
    > </td>
    > </tr>
    > <tr>
    > <td width="100%" align="center" height="10">
    > <table border="1" width="280" bordercolordark="#FFFFFF"
    > bordercolor="#808080" cellspacing="0" height="120">
    > <tr>
    > <td width="100%" colspan="2" bgcolor="#E6E6E6" height="20"
    > align="center">
    > <b><font size="2">
    > Logon WXC2 Management Console </font></b>
    > </td>
    > </tr>
    > <tr>
    > <td>
    > <img border="0" src="../../images/loginUser.gif" > User: </td>
    > <td align="center">
    > <input type="text" name="userName" size="20" class="text">
    > </td>
    > </tr>
    > <tr>
    > <td>
    > <img border="0" src="../../images/loginPwd.gif" > Password: </td>
    >
    > <td align="center">
    > <input type="password" name="userPwd" size="20" class="text">
    > </td>
    > </tr>
    > <tr>
    > <td colspan="2" align="center">
    > <input type="submit" value="Login" name="login"
    > class="button">&nbsp;&nbsp;&nbsp;<input type="reset" value="Cancel"
    > class="button"> </td>
    > </tr>
    > </table>
    > </td>
    > </tr>
    > <tr><td align="center">
    > <a style="Cursor:hand" onclick="javascript:selectChn()"><image
    > src="../../images/chinese.gif"></td></tr>
    > <tr><td align="center"><b><font
    > size=6>R8.0(V8.02.10)</font></b></td></tr>
    > </table>
    > </form>
    > </body>
    > </html>
    Jimi-Carlo Bukowski-Wills Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139