Interact with webpage without buttons/textfields etc.

Discuss how to write good code, break bad code, your current pet projects, or the best way to approach novel problems

Interact with webpage without buttons/textfields etc.

Post by tiataman on Wed Aug 31, 2011 6:13 pm
([msg=61325]see Interact with webpage without buttons/textfields etc.[/msg])

Hello,
I want to write an application that will be able to automatically read text from a web page(and maybe compare it with something) , send to it the message that a button was pressed(without actually pressing it) or sending text info that you could send using the given forms but without using the actual form and so on . Which language should i learn to do this from my pc and where can i learn more about it ?
tiataman
New User
New User
 
Posts: 3
Joined: Wed Aug 31, 2011 5:56 pm
Blog: View Blog (0)


Re: Interact with webpage without buttons/textfields etc.

Post by mShred on Wed Aug 31, 2011 11:38 pm
([msg=61326]see Re: Interact with webpage without buttons/textfields etc.[/msg])

I'm not sure I understand.. But i'll give it a shot.
In PHP, you can do something like this. Say you have a script that grabs the IP of the visitor and sends it via the mail() function. The function is called on by a form. But as you said, you don't want to have to submit the form for it to activate the script. Well yes you can do this. But that means the function will be called every time the page is loaded, rather than every time the form is submitted. To achieve this, all you'd have to do is throw the function in the actual page file.
Image

For those about to rock.
User avatar
mShred
Administrator
Administrator
 
Posts: 1686
Joined: Tue Jun 22, 2010 4:22 pm
Blog: View Blog (2)


Re: Interact with webpage without buttons/textfields etc.

Post by tiataman on Thu Sep 01, 2011 6:17 am
([msg=61329]see Re: Interact with webpage without buttons/textfields etc.[/msg])

Here is an example to show you what i want to do, insteed of opening this topic by pressing newtopic and then typing in a subject and pressing submit to post it , i want to run the application and it would send to the site that i actually pressed the button(without it actually doing it) and after ariving to this page it would then send that i wrote a subject named"Interact with webpage without buttons/textfields etc." without actually typing anything and submiting it without pressing any buttons. I am not talking about recording keystrokes and mouse movements and i want to do this as a client having no server or control on it. I presume this is possible since no actual info is send until i press the submit the text i input here is only in my browser and not on the site until i send it . I dont know much so its just a presumption. Thank you .
tiataman
New User
New User
 
Posts: 3
Joined: Wed Aug 31, 2011 5:56 pm
Blog: View Blog (0)


Re: Interact with webpage without buttons/textfields etc.

Post by thetan on Fri Sep 02, 2011 1:08 am
([msg=61345]see Re: Interact with webpage without buttons/textfields etc.[/msg])

Sounds like a job for selenium IDE.
http://seleniumhq.org/projects/ide/

Selenium has saved my sanity countless times by automating front end tedious testing actions while developing.
"If art interprets our dreams, the computer executes them in the guise of programs!" - SICP

Image

“If at first, the idea is not absurd, then there is no hope for it” - Albert Einstein
User avatar
thetan
Contributor
Contributor
 
Posts: 657
Joined: Thu Dec 17, 2009 6:58 pm
Location: Various Bay Area Cities, California
Blog: View Blog (0)


Re: Interact with webpage without buttons/textfields etc.

Post by mShred on Fri Sep 02, 2011 1:21 am
([msg=61347]see Re: Interact with webpage without buttons/textfields etc.[/msg])

You can honestly do this with probably a few different languages.. But it could be very, very tedious. I didn't look into it, but what Thetan posted would probably help you out.
Image

For those about to rock.
User avatar
mShred
Administrator
Administrator
 
Posts: 1686
Joined: Tue Jun 22, 2010 4:22 pm
Blog: View Blog (2)


Re: Interact with webpage without buttons/textfields etc.

Post by tiataman on Sun Sep 04, 2011 8:28 am
([msg=61391]see Re: Interact with webpage without buttons/textfields etc.[/msg])

Thank you both, i will try it .
tiataman
New User
New User
 
Posts: 3
Joined: Wed Aug 31, 2011 5:56 pm
Blog: View Blog (0)



Return to Programming

Who is online

Users browsing this forum: No registered users and 0 guests