Results 1 to 4 of 4
Hi guys, I am extremely new to linux, in fact i'm a total noob. I have a problem and i'm hoping someone here can help me. I am a member ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 04-18-2013 #1
- Join Date
- Feb 2009
Script to monitor web page and submit a form when it appears
I am extremely new to linux, in fact i'm a total noob.
I have a problem and i'm hoping someone here can help me.
I am a member of a meetup group on meetup[dot]com. On this site a new event is posted at a certain time in the week and everyone must click a 'RSVP' button to commit to the event. Only a limited number of places exist on an event.
However since I have no access to the site while in work I want to create an automatic signup script.
can this be done?
Basically here's an example of how the script would run;
- Login in to the meetup and download the html of the event page
- Search the code for the presence of the 'RSVP' button Code:
<div class="rsvp-box-section"><input id="rsvpSubmit" class="button primary" type="submit" value="RSVP"></input></div>
- if 'RSVP button is present the submit the button and stop script
- if 'RSVP' button is not present repeat the script in 5 minutes
I hope this makes sense.
I would love is this could happen - one thing that could stop things woul dbe the login
- 04-18-2013 #2
- Join Date
- May 2011
The downloading part could be done with a quick wget command.
if you can get those pieces working manually, then create an infinite bash while loop that does the RSVP check, and either does an exit, or does a sleep for 5 seconds.
- 04-19-2013 #3
perl - tiny runable www::Mechanize examples for the beginner - Stack Overflow
perlperlperlperlperlperlperlperlperlperlperl...oh, sorry again
Oh, and you should probably get a browser extension or use the chrome developer console to have a look at the web requests (GET's and POST's) that get generated whenever you manually interact with the site to do what you are trying to automate. It will give a lot of insight into what URLs you will output from whatever tool you use.
Last edited by nplusplus; 04-19-2013 at 02:55 AM. Reason: added advice
- 04-20-2013 #4
- Join Date
- Mar 2007
- Melbourne, Australia
I'd also suggest a randomized wait time as there are scripts on hosting sites that monitor for constant interval access and automatically inject source IP's in firewall rules. I know as I am a firewall and webserver admin who is tasked with doing just this!