Problems encountered in crawling articles

encountered problems when fetching headline articles
Why are the content of articles obtained by various operations of getting pages different

I use curl crawl to save dom to file, use PHPSPIDER crawl to save dom to file, directly in the Google browser page right-click the audit element to see the dom, to check the source code to see the dom, these dom are unexpectedly different, the browser is easy to understand, it should be opened after the js run dom also changed.

for guidance, what I do is crawl the headline article of the user-specified link

Php
Nov.23,2021

should be generated dynamically through js. If you want to take the content, parse the string in the js script directly.

if you want to crawl based on dom, you can use Google's Headless Chromium

Headless Chromium

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e50ec3-45106.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e50ec3-45106.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?