Информация об изменениях

Сообщение Re[15]: Как распарсить https://apnews.com/ от 16.12.2024 18:20

Изменено 16.12.2024 18:22 kov_serg

Re[15]: Как распарсить https://apnews.com/
Здравствуйте, Passerby, Вы писали:

P>>При этом запрос https://www.cryptocompare.com/news/list/latest/ нормально отрабатывается в коде, указанном https://rsdn.org/forum/dotnet/8847491.1
Автор: Serginio1
Дата: 05.11 13:16


Постораюсь еще раз намекнуть. Там нет проверки cloudflare

Вот что у вас пишет: curl https://data-api.cryptocompare.com/news/v1/article/list?sortOrder=latest

Или такой код:
<?php
$json=json_decode( file_get_contents("https://data-api.cryptocompare.com/news/v1/article/list?sortOrder=latest") ); 
//print(json_encode($json,JSON_PRETTY_PRINT|JSON_INVALID_UTF8_SUBSTITUTE));
$i=0; foreach($json->Data as $k=>$v) printf("%02d. %s\n",++$i,$v->TITLE);
  у меня пишет следующее
01. Coinbase To Add Support For Parcl (PRCL) On Solana Network
02. Chainlink and Hedera Unite To Revolutionize DeFi and Real-World Asset Tokenization
03. Trump’s Bitcoin Reserve (TRUMPRES) Solana Memecoin to Rally 17,000% Before Exchange Listing, As SHIB and DOGE Lag
04. UK FCA FUDs Retardio meme coin
05. UK FCA FUDs Retardio meme coin
06. FTX Plans to Start Customer Repayments by Early 2025 as Bankruptcy Process Advances
07. 4 Ethereum Rivals Altcoins That Could Double Before January 2025
08. Crypto Funds Attract Record $20.3 Billion in Inflows Over 10 Weeks
09. FTX Will Repay Customers in Early 2025 via Kraken and BitGo
10. UK FCA Flags Retardio Solana For Unregulated Financial Services Promotion
11. Surge in Xaman User Activity Suggests Renewed Interest in XRP and Anticipation for RLUSD Stablecoin Launch
12. Bitcoin’s DeFi TVL Surges Over Sixfold Amid Growing Restaking Demand and Institutional Interest
13. Nasdaq-Listed Crypto Firm Expands with Liberty Road Capital Acquisition and Xapo Bank Partnership
14. Bitcoin DeFi TVL hits record highs, flips BNB – Good news for BTC?
15. Pendle price prediction 2024-2030: Is PENDLE a good investment?
16. XRP rally and RLUSD anticipation fuel activity on Xaman Wallet
17. Singapore Leading World in Crypto Adoption, With 40% of Investors Holding Digital Assets: Report
18. 21Shares XRP Trust Officially Registered in Delaware | XRP Price Reaches $2.52
19. FCA releases discussion paper on crypto market transparency, abuse
20. Ethereum Price Today As 92% ETH Holders Are Profitable
21. XRP Price Eyes Rally To $7 As Whales Shuffle $283M
22. BREAKING: Here are Date and Details on FTX Refunds That May Affect the Cryptocurrency Market
23. Coinbase Lists Parcl (PRCL) for Trading
24. Kraken chosen as distribution partner by the FTX Debtors
25. FTX Set to Resume Operations on January 3, 2025: Latest Cryptocurrency News
26. ‘Prepare your exit strategy,’ warns crypto trader as ‘we are close to the top’
27. Bitcoin Hits New All-Time High, Sparking Speculation of Possible Rally Toward $113,000
28. Bitcoin Breaks $107,000 Amid Fed Rate Cut Expectations and Trump’s Crypto Reserve Plans
29. PENGU: Everything You Need to Know About the Pudgy Penguins Solana Token and Airdrop
30. Top Ripple (XRP) Price Predictions as of Late
31. Bitcoin hits new record high with surge to $107k
32. Bitcoin hits new record high with surge to $107k
33. Quiet Powerhouses: Are Ethereum and Cardano Ready for Big Upswings?
34. Ripple’s RLUSD scheduled for Dec. 17 launch
35. Ripple’s RLUSD scheduled for Dec. 17 launch
36. Price analysis 12/16: SPX, DXY, BTC, ETH, XRP, SOL, BNB, DOGE, ADA, AVAX
37. Chainlink price rallies as hopes of an 80% surge rise
38. Chainlink price rallies as hopes of an 80% surge rise
39. Pepe And Mog See Overnight Declines, Analysts Highlight This Project As A High ROI Alternative
40. From Crypto Genius to Centi-Billionaire: Satoshi Nakamoto’s Wealth Soars
41. Time To Sell XRP? Price Completes Head And Shoulder Pattern, Suggesting Crash To $2.2 Is Imminent
42. Pepe Coin Millionaire Identifies the ‘Next PEPE’ That Could Turn $300 Into $30,000 in Just 8 Weeks
43. Semler Scientific buys more Bitcoin, now holds 2,084 BTC
44. Semler Scientific buys more Bitcoin, now holds 2,084 BTC
45. Ripple Launches RLUSD Stablecoin Amid XRP Price Surge and Growing Institutional Interest
46. Arbitrum price prediction 2024 – 2030: ARB breaks key barrier
47. Lido sunsets staking on Polygon network
48. Lido sunsets staking on Polygon network
49. Here’s when Chainlink (LINK) will reach $40, according to analyst
50. UK to Ban Public Crypto Offers in Incisive New Regulatory Climate
Re[15]: Как распарсить https://apnews.com/
Здравствуйте, Passerby, Вы писали:

P>>При этом запрос https://www.cryptocompare.com/news/list/latest/ нормально отрабатывается в коде, указанном https://rsdn.org/forum/dotnet/8847491.1
Автор: Serginio1
Дата: 05.11 13:16


Постораюсь еще раз намекнуть. Там нет проверки cloudflare

Вот что у вас пишет: curl https://data-api.cryptocompare.com/news/v1/article/list?sortOrder=latest

Или такой код:
<?php
$json=json_decode( file_get_contents("https://data-api.cryptocompare.com/news/v1/article/list?sortOrder=latest") ); 
//print(json_encode($json,JSON_PRETTY_PRINT|JSON_UNESCAPED_UNICODE));
$i=0; foreach($json->Data as $k=>$v) printf("%02d. %s\n",++$i,$v->TITLE);
  у меня пишет следующее
01. Coinbase To Add Support For Parcl (PRCL) On Solana Network
02. Chainlink and Hedera Unite To Revolutionize DeFi and Real-World Asset Tokenization
03. Trump’s Bitcoin Reserve (TRUMPRES) Solana Memecoin to Rally 17,000% Before Exchange Listing, As SHIB and DOGE Lag
04. UK FCA FUDs Retardio meme coin
05. UK FCA FUDs Retardio meme coin
06. FTX Plans to Start Customer Repayments by Early 2025 as Bankruptcy Process Advances
07. 4 Ethereum Rivals Altcoins That Could Double Before January 2025
08. Crypto Funds Attract Record $20.3 Billion in Inflows Over 10 Weeks
09. FTX Will Repay Customers in Early 2025 via Kraken and BitGo
10. UK FCA Flags Retardio Solana For Unregulated Financial Services Promotion
11. Surge in Xaman User Activity Suggests Renewed Interest in XRP and Anticipation for RLUSD Stablecoin Launch
12. Bitcoin’s DeFi TVL Surges Over Sixfold Amid Growing Restaking Demand and Institutional Interest
13. Nasdaq-Listed Crypto Firm Expands with Liberty Road Capital Acquisition and Xapo Bank Partnership
14. Bitcoin DeFi TVL hits record highs, flips BNB – Good news for BTC?
15. Pendle price prediction 2024-2030: Is PENDLE a good investment?
16. XRP rally and RLUSD anticipation fuel activity on Xaman Wallet
17. Singapore Leading World in Crypto Adoption, With 40% of Investors Holding Digital Assets: Report
18. 21Shares XRP Trust Officially Registered in Delaware | XRP Price Reaches $2.52
19. FCA releases discussion paper on crypto market transparency, abuse
20. Ethereum Price Today As 92% ETH Holders Are Profitable
21. XRP Price Eyes Rally To $7 As Whales Shuffle $283M
22. BREAKING: Here are Date and Details on FTX Refunds That May Affect the Cryptocurrency Market
23. Coinbase Lists Parcl (PRCL) for Trading
24. Kraken chosen as distribution partner by the FTX Debtors
25. FTX Set to Resume Operations on January 3, 2025: Latest Cryptocurrency News
26. ‘Prepare your exit strategy,’ warns crypto trader as ‘we are close to the top’
27. Bitcoin Hits New All-Time High, Sparking Speculation of Possible Rally Toward $113,000
28. Bitcoin Breaks $107,000 Amid Fed Rate Cut Expectations and Trump’s Crypto Reserve Plans
29. PENGU: Everything You Need to Know About the Pudgy Penguins Solana Token and Airdrop
30. Top Ripple (XRP) Price Predictions as of Late
31. Bitcoin hits new record high with surge to $107k
32. Bitcoin hits new record high with surge to $107k
33. Quiet Powerhouses: Are Ethereum and Cardano Ready for Big Upswings?
34. Ripple’s RLUSD scheduled for Dec. 17 launch
35. Ripple’s RLUSD scheduled for Dec. 17 launch
36. Price analysis 12/16: SPX, DXY, BTC, ETH, XRP, SOL, BNB, DOGE, ADA, AVAX
37. Chainlink price rallies as hopes of an 80% surge rise
38. Chainlink price rallies as hopes of an 80% surge rise
39. Pepe And Mog See Overnight Declines, Analysts Highlight This Project As A High ROI Alternative
40. From Crypto Genius to Centi-Billionaire: Satoshi Nakamoto’s Wealth Soars
41. Time To Sell XRP? Price Completes Head And Shoulder Pattern, Suggesting Crash To $2.2 Is Imminent
42. Pepe Coin Millionaire Identifies the ‘Next PEPE’ That Could Turn $300 Into $30,000 in Just 8 Weeks
43. Semler Scientific buys more Bitcoin, now holds 2,084 BTC
44. Semler Scientific buys more Bitcoin, now holds 2,084 BTC
45. Ripple Launches RLUSD Stablecoin Amid XRP Price Surge and Growing Institutional Interest
46. Arbitrum price prediction 2024 – 2030: ARB breaks key barrier
47. Lido sunsets staking on Polygon network
48. Lido sunsets staking on Polygon network
49. Here’s when Chainlink (LINK) will reach $40, according to analyst
50. UK to Ban Public Crypto Offers in Incisive New Regulatory Climate