www.webdeveloper.com
Results 1 to 2 of 2

Thread: Log in script for ASP site

  1. #1
    Join Date
    Aug 2012
    Posts
    2

    Log in script for ASP site

    Greetings,

    I have encountered with a problem regarding my script done in PHP and is used for logging into a specific site
    which is written in ASP.

    I want to POST my user name and pass word to that form log-in but it seems like site is ignoring it.
    I eceive absolutely no errors.

    Anyone got an idea how to solve this?

    PS URL username and password in script are coreect and can be used for logging into site.

    I really hope someone could help me!

    Thank you!

    PHP Code:
    <?php
    $ch 
    curl_init();

    curl_setopt($chCURLOPT_URL'http://www.ajpes.si/login/login.asp?f=1&mdres=1');
    curl_setopt ($chCURLOPT_POST1);
    curl_setopt($chCURLOPT_SSL_VERIFYPEERfalse);
    curl_setopt($chCURLOPT_POSTFIELDS'uporabnik=test2012&geslo=test2012');
    curl_setopt ($chCURLOPT_COOKIEJAR'cookie.txt');
    curl_setopt ($chCURLOPT_RETURNTRANSFER1);
    curl_setopt($chCURLOPT_TIMEOUT60);

    $store curl_exec ($ch);

    $file fopen ("1234.txt""w");
    fwrite($file$store);
    fclose ($file);

    $content curl_exec ($ch);

    $content curl_exec($ch);
    if (
    $content === FALSE) {
        die(
    curl_error($ch));
    }
    echo 
    $content "<br />";

    curl_close ($ch); 

    ?>

  2. #2
    Join Date
    Aug 2012
    Posts
    2
    I have turned all possible forums upside down via google and couldn't find anything regarding my problem.

    So ... a) i am doing something completly wrong or
    b) it can not be done in PHP

    So if anyone has an idea how to pull this offf please do post about it!

    thank you!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles