=25) { if($a Copy text
Posts
Showing posts from April, 2021
datatype in php
- Get link
- X
- Other Apps
<?php $name = "Harry"; $income = 200; /* php data types 1. String 2. Integer 3. Float 4. Boolean 5. Object 6. Array 7. NULL */ // String - sequence of characters $name = "Harry"; $friend = 'Rohan'; echo "$name ka friend is $friend"; // Integer - Non decimal number $income = 455; $debts = -655; echo "<br>"; echo $income; echo "<br>"; echo $debts; echo "<br>"; // Float - Decimal point number $income = 344.5; $debts = -45.5; echo $income; echo "<br>"; echo $debts; echo "<br>"; // Boolean - Can be either true or false $x = true; $is_friend = false; echo var_dump($x); echo "<br>"; echo var_dump($is_friend); echo "<br>"; // Object - Instances of classes // Employee is a class ---> harry can be one object // Array - Used to store multiple values in a single variable $friends = array("rohan", "shubham", "skillf...
More On Php Variables
- Get link
- X
- Other Apps
This Is More On Php Variables Rules for creating variables in php Must Start with $ sign Can not start with a number Must Start with letter or underscore character can only contain alphanumaric charter or underscore Some eg of non alphanumaric characters are $,%,& etc. Variables in Php are case sensitive means($harry,$Harry and $harry are different)
Blank Template for Blogger
- Get link
- X
- Other Apps
<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE html> <html b:css='false' b:responsive='true' expr:dir='data:blog.languageDirection' lang='en-US' xmlns='http://www.w3.org/1999/xhtml' xmlns:b='http://www.google.com/2005/gml/b' xmlns:data='http://www.google.com/2005/gml/data' xmlns:expr='http://www.google.com/2005/gml/expr'> <head> <meta content='width=device-width, initial-scale=1' name='viewport'/> <b:include data='blog' name='all-head-content'/> <title><data:blog.pageTitle/></title> <b:skin><![CDATA[ body{background:#fff} ]]></b:skin> </head> <body> <b:section class='main' id='main' showaddelement='yes'/> </body> </html> DOWNLOAD
Varible In Php
- Get link
- X
- Other Apps
<?php //This is Tutorial 1 // Variable in php" // Variable are containers for storing information $name ="abhay"; //Variable are case sensitive $income=2000000000.8; echo "This guy is $name and his networth is Rs. $income<br>"; echo "$name is a good boy<br>"; echo "$name is the real gangsta <br>"; ?> output This guy is abhay and his networth is Rs. 2000000000.8 abhay is a good boy abhay is the real gangsta