How to get the url that javascript is hidden on an external website?

How to get url hidden by javascript on external website?

ex: http://royaldesign.se/Att_Dricka.aspx This url is permanent due to page navigation, so the content of the page is loaded by javascript.

link location on the page:

javascript:__doPostBack('ctl00$masterContent$DataPager2$ctl00$ctl00','') javascript:__doPostBack('ctl00$masterContent$DataPager1$ctl00$ctl01','') javascript:__doPostBack('ctl00$masterContent$DataPager1$ctl00$ctl02','') 

.....

Is there a way to analyze (manually or using a PHP script) the __doPostBack function to find out about URLs?

thanks in advance

0
source share
3 answers

These values โ€‹โ€‹are not hidden, the __doPostBack method returns to itself. Those values โ€‹โ€‹passed to doPostBack represent the html identifier of the postback control.

The page you are looking at is written in ASP.NET, not PHP.

You can use browser debugging tools to find out what data is transferred to the server through javascript.

0
source

The javascript __doPostBack function is used to send data to an asp.net page.

The first parameter of the function is the purpose of the event. This is the ClientID of the control that the button is clicked on.

Asp.net uses this value to generate a Click event on the server when the page is submitted.

You can call this __doPostBack function with javascript yourself to get the same behavior as the user by clicking on it.

0
source

I gave some tips on โ€œscrapingโ€ ASP.net pages on this other issue: curl script just filled out the form without submitting it

The basics of modeling a POST request using CURL are discussed here: PHP + curl, HTTP POST sample code?

I would also add that if the site you โ€œscrapedโ€ belongs to someone, you are friends with (and not, for example, a competitor!), You can save a lot of time by asking the content or the static URL that gives content to you.

0
source

Source: https://habr.com/ru/post/1274275/


All Articles