javascript - How to click on <a> tag using Curl -
how can click on tag , page content
i'm using script aliexpress page content fetch comments
$url = "some link"; $ch = curl_init(); curl_setopt( $ch, curlopt_useragent, "mozilla/5.0 (windows; u; windows nt 5.1; rv:1.7.3) gecko/20041001 firefox/0.10.1" ); curl_setopt( $ch, curlopt_url, $url ); curl_setopt( $ch, curlopt_followlocation, true ); curl_setopt( $ch, curlopt_encoding, "" ); curl_setopt( $ch, curlopt_returntransfer, true ); curl_setopt( $ch, curlopt_autoreferer, true ); curl_setopt( $ch, curlopt_ssl_verifypeer, false ); $content = curl_exec( $ch );
aliexpress feedback fetch comments using javascript after clinking on following tag
<li data-trigger="feedback" data-role="trigger" class="ui-switchable-trigger"> <a href="javascript:;" data-spm-anchor-id="2114.10010108.0.0">feedback (27)</a> </li>
can guide me if possible
the page trying fetch using javascript load content.
using file_get_contents javascript code will not run , cannot href data unless click triggered involves other dynamic requests.
selenium may out since it's kind of controlled web browser can read/fetch dynamic content.
Comments
Post a Comment