sub199 sub199 - 1 year ago 193
Linux Question

Click button using curl

I need to fetch contact number from an URL, may be using curl.

Sample link-

Contact number button in on right hand side & value is hidden. Once you click on it, value shows up. There is no onclick event on button. Please let me know.

Answer Source

You can do it with combination of curl, sed and grep command outputs.

Here is an example:

wget -q -O - $(echo$(curl -s | grep link-phone | egrep -oh \'id\'\:\'\\S+\' | tail -n 1 | sed -e s/\'id\'\://g | sed -e s/\'//g))
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download