Loading...

Follow PHP CORE LAB on Feedspot

Continue with Google
Continue with Facebook
or

Valid
What is Palindrome? Palindrome is a word, phrase, sentence, or number that reads the same from both backward or forward. If you reverse the ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 
$num= 20; // It print all prime number till 20 for($j=2;$j<=$num;$j++ ) { for($k=2;$k<$j;$k++ ) { if($j%$k==0) { break ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 
$num = 6; // Change to any number for($i=1 ; $i<=10 ; $i++) { echo $i*$num; // Multiply index to number echo '<br>'; // ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 
To get hostname we use PHP inbuilt function parse_url. $url = 'http://google.com/dhasjkdas/sadsdds/sdda/sdads.html'; $parse = parse_url($ ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 
In windows system you can not create a file without name it not allow you to create a .env file directly from the windows explorer. However ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 
If we want to get youtube video ID from any youtube video URL For this we need to parse youtube URL using PHP function $url = ‘https:// ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 
If we have table like below Table structure id name salary 1 Saurabh 20000 2 Arpit 15000 3 Navneet ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 
To enable DB query you need to add “use DB;” on top of the controller If you want to count row in table you can use count in your ..read more
  • Show original
  • .
  • Share
  • .
  • Favorite
  • .
  • Email
  • .
  • Add Tags 

Separate tags by commas
To access this feature, please upgrade your account.
Start your free month
Free Preview