Archive: Calling hosted PHP scripts from NSIS


Calling hosted PHP scripts from NSIS
I am fairly new to NSIS. I am in the process of creating an NSIS installer. All is going well so far but now I have a small problem which I cannot find the answer for. I have a custom NSIS page with user details and I want to call a hosted PHP script to check if the user is registered via the info given. e.g. of flow:

1) User clicks next and now on user info page
2) User enters info, clicks Next
3) NSIS script should connect to http://mywebsite.com/checkuser.php?<params>
4) PHP checks Database and outputs result (SUCCESS or FAIL)
5) NSIS reads the result and takes action accordingly.

How do I call a URL like this without starting a web browser? Is it possible and is it possible to read the result from the page too (results come back in plain text).

NSI code would be greatly appreciated.

Thanks very much for your time and help.

Riz


any of the http download plugins (including nsisdl that comes with NSIS; there's also Inetc and InetLoad; just google them) should do the trick.
Just have your web server respond to a regular http URL request, with the information required as GET parameters ( something.php?username=something&whatever=somethingelse ) and spit out a text or HTML document, then parse that once downloaded.

Inetc and Inetload also support the POST method, if that would be preferred.


cheers for that, much appreciated, will look into it.


Simular problem
I have a simular problem.

I want to call a php site with data in the link. So I looked at Inetc and InetLoad, but it works not with proxy and SSL.

All proxy data is accessible. Hmm and next problem is the certificate. The certificate on the server is not registered, so browser ask if the it should be trusted. But what does nsis? I have the certificate, in java I say that is the certificate, just use it, done.

Maybe some can help me. Thanks

Milbo