Jump to content

[Curl] Trying to optimize it!


 Share

Recommended Posts

Hello guys,

Few weeks ago, someone [i don't remember the name, sorry] told me to use Curl to get HTML Source Code because my _InetGet function DOESN'T WORK on my computer with this webpage.

I don't have any choice, I must use it to be able to test my software.

If you don't have it, place those 3 files in your Script dir or Download and launch my software (see following links).

_______________________________________________

Ok now:

Posted Image

I'm using this function in THIS program: http://rsgetpoints.pureweb.fr.

If you want to try it : http://rsgetpoints.pureweb.fr/RsGetPoints1_3.rar

This function is used to Get The source Code of a Webpage which require Login/Pass. (Im getting account info with StringBetween after this).

_______________________________________________

FOR THIS EXAMPLE, i created a Useless account [Free]:

Collector account [Free one, uploader account]

Username: Au3Acc

Password: test

________________________________________________

So you are able to test my prog/and the following script. AS you can see, the Curl function is called every 10sec in my prog. I disabled every buttons during this function because you can't use them.. my whole UI doesn't work during this function call. I don't think I can do anything to change it...

The problem is: This function take a lot of time : 1s! I wonder if there is any way to Optimize it.

$wLogin='Au3Acc'                                                        ;;Username
$wPass='test'                                                           ;;Password
Global $url='https://ssl.rapidshare.com/cgi-bin/collectorszone.cgi'     ;;Account type change Url

$timer=TimerInit()

Dim $iPidCurl = Run(@ComSpec & " /c " & 'curl -k -d username=' & $wLogin & ' -d password=' & $wPass & ' '& $url, @ScriptDir, @SW_Hide,2+4)  ;;Curl function.
$source=StdoutRead($iPidCurl) ;;Getting source code from Curl.

MsgBox(0,'done', TimerDiff($timer))
MsgBox(0, '', $source) ;;Displaying the code.

Thanks a lot if you have any idea. I though to Use cookies, and just refresh the webpage when you are logged in.. But I don't know how to do that.

THANKS FOR YOUR TIME

Edited by eHrgo
Sorry for my Bad English.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...