fetch data from live website curl php
// Initialize Curl
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, "https://coinmarketcap.com/"); // set live website where data from
curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE); // default
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE); // default
$content = curl_exec($curl);
preg_match_all('!<p color="text3" class="sc-AxhUy bzeXdk coin-item-symbol" font-size="1">(.*?)</p>!', $content, $matches);
var_dump($matches);
Also in PHP:
- does array have key php
- create new project in laravel 7
- can i install php7.4 inside vagrant homestead
- check substring in string php
- SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; m ax key length is 767 bytes (SQL: alter table `users` add unique `users_email_unique`(`e mail`))
- Jul 29th, 2020 php format
- create symfony project
- convert lower to upper case php
- dateformat j/m/a php
- PHP string mask day-year
- display datetime in php
- How do you clear cache in Laravel?
- douzo definition
- delete cache manually laravel 5
- check if part of string php
- catch get error php
- dateTime current time in php
- encryption and decryption in php example
- array ket exists
- delete duplicates array php
- date remove 7 days php
- check substring php
- alert js in php
- factoring and seeding in laravel