PDA

View Full Version : Getting info from the web page



Destroyer
08-27-2007, 03:35 PM
I need to do such thing: when user press the button, information (html text of the page) from the given link is taken, then this information is given to server to work with it using php.
An Ajax Includes Script is good for me, but it doesn't allow to access to other domain's pages. Please, help me to solve this problem.

Twey
08-27-2007, 03:42 PM
Nothing in Javascript is capable of doing cross-domain requests. Pass the URL to PHP and download it server-side.

boogyman
08-27-2007, 05:55 PM
get_file_contents("absolute-url") i believe is the php function to use

Destroyer
08-27-2007, 06:45 PM
get_file_contents("absolute-url") i believe is the php function to use

yes, but I need to do the same from userside. Because every user in my local network has got a unique parameter and it is avaliable only from userside.
Need more ideas.

Twey
08-27-2007, 07:04 PM
Send the "unique parameter" to the PHP script?

Destroyer
08-27-2007, 10:01 PM
Send the "unique parameter" to the PHP script?

Yes, thats what I need. I need to open a web page from userside and send this "unique parameter" to serverside php script. The problem is that this parameter looks like:
<input type="hidden" name="anticode" value="c14518adb3cebfe91d3c52eb3d11a73f">...

I need to get this "value". I can get it using php, but it can't get userside "value", because php opens it from serverside. That is why I need to open this web page on userside and send it's contents to the serverside php script. Please help me to do it.

Twey
08-28-2007, 08:11 AM
It's the same on both sides. You cannot open the page from the client side.