Raised This Month: $51 Target: $400
 12% 

Is it possible to query a website?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Kigen
BANNED
Join Date: Feb 2008
Old 03-18-2008 , 00:56   Is it possible to query a website?
Reply With Quote #1

Is it possible for SourceMod to query a website?

Like: new Handle:test = WebRead("http://www.example.com/test.php");
Kigen is offline
Kigen
BANNED
Join Date: Feb 2008
Old 03-18-2008 , 00:57   Re: Is it possible to query a website?
Reply With Quote #2

Or preferably do it similar to the SQL functions where there is a callback function.
Kigen is offline
Kigen
BANNED
Join Date: Feb 2008
Old 03-18-2008 , 00:58   Re: Is it possible to query a website?
Reply With Quote #3

Nevermind, found out it had to be an extension.

http://forums.alliedmods.net/showthread.php?t=54611
Kigen is offline
sfPlayer
Senior Member
Join Date: Dec 2007
Location: Germany
Old 03-18-2008 , 08:38   Re: Is it possible to query a website?
Reply With Quote #4

webdownloader doesn't comply with rfc 1945, i recommend to implement your own http client using the socket extension.
sfPlayer is offline
BAILOPAN
Join Date: Jan 2004
Old 03-18-2008 , 10:15   Re: Is it possible to query a website?
Reply With Quote #5

Uh, my guess is that most people would rather use a library than implement that.
__________________
egg
BAILOPAN is offline
sfPlayer
Senior Member
Join Date: Dec 2007
Location: Germany
Old 03-18-2008 , 10:35   Re: Is it possible to query a website?
Reply With Quote #6

.. which doesn't work with most webservers.

Webdownloader relies on getting a valid Content-Length header which won't be set by most webservers which choose closing the connection or chunked encoding (HTTP 1.1) to determine the end of the request.

Last edited by sfPlayer; 03-18-2008 at 10:40.
sfPlayer is offline
BAILOPAN
Join Date: Jan 2004
Old 03-18-2008 , 14:18   Re: Is it possible to query a website?
Reply With Quote #7

But there are libraries that accomplish this (assumedly, correctly).
__________________
egg
BAILOPAN is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 22:49.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode