My friend has a website whereby once you have logged in on one page, you are redirected to another page, with a url similar to:
the random string changes each time you log in, however the login page has a static url
What i was attempting to do is run a script to get some data from the members page (after uve logged in) - however ive been having some trouble in how to do this, as the variable url with the random string will become invalid after a certain time, and i did not want to consantly change it.
While reading through some documentation i read that wget should be able to login to a form login website however ive had no luck, the command i was attempting to use was:
wget --user USERNAME -password PASSWORD "http://url.com"
similarly i also tried
wget --post-data "username=USERNAME&password=PASSWORD" "http://url.com"
and even both combined. However neither has worked as the html dl'd is simply the login page website.
I cannot post a direct link to the website as it is private, however ive looked at the source coding and ive extracted (what i think) is the relevant bit, which is:
<form action="/cgi-bin/sblogin/login.cgi" method="post" name="login" id="login"><br /><br />
<div class="user_text"><span class="text3">USERNAME:</span></div><div class="user_box"><input type="text" class="text" name="uname"></div>
<div class="pass_text"><span class="text3">PASSWORD:</span></div><div class="pass_box"><input type="password" class="text" name="pword"></div>
<div class="text3" style="padding-left: 40px;">Save My Password<input name="savepassword" type="checkbox" checked /></div>
any help would be greatly appreciated.