Dropdown list in php

To display drowdown list in php we can use for-each loop . We have some data in our array so we cant display it using php array logic Output of code : Select one subjectHistoryGeographyMathsSanskritMarathiEnglish Submit strtolower    function is used to convert string to lower case . Array is a specail variable used to …

Insert form data into database using php-mysqli

It is very easy to insert data into database using php and i will you mysqli. I have used post method for data insertion. It is upto you & you can use post or get method for form handling . Your database table will look like this :- Only two coulmn needed user_name & user_comment …

How to use Loops in PHP

There are three types of loop in php : While loop , do while loop , for & for-each loop While Loop :- loops through a block of code unitl the specified condition become true

Now below is first example of while loop Output of code would be this : 4812162024283236404448525660 Now i will teach …

PHP – PDO Insert data into database using OOP Concept

I am using PDO – OOP concept for inserting data into database . If you are new to pdo then please learn basics of pdo . I have used simple OOP concept only class for connection and function for executing pdo query . This is table in db & coulmn names are : id , …

PHP logical programs for Interviews

1-How to get leap year in PHP using HTML form Leap year has 366 days .It adds extra day in calendar (Feb 29) , 2016 was a leap year and 2020 will be a leap year . Now we will see how to get leap year using php code . 2 – How to get …

PHP basic programs for interviews

PHP Program for factorial using HTML Form and this is formula for factorial : – n n! 1 – 1 1 12 – 2 × 1 = 2 × 1! = 23 – 3 × 2 × 1 = 3 × 2! = 64 – 4 × 3 × 2 × 1 = 4 × …

Where clause in php-mysql

Where cluase is used to only fetch those records that full fill a specified records This is our where clause query with select statement SELECT * FROM users WHERE name =”rahul” . Now this query will give all record of rahul Now this is our table in database and the database is test and the …

PHP mysqli ORDER BY clause

I will show you how to use ORDER BY clause in PHP . I have used select query to show database data on the table .The ORDER BY lets you define the field name in ascending or descending order . This is our ORDER BY Query :- SELECT * FROM  users  ORDER BY name DESC SELECT * FROM  users  ORDER BY name ASC …

CRUD Operation in PHP-PDO

Today i am giving you toturial on PDO-PHP .Here i will creat full CRUD system in PDO using PHP. So below is your connection in PDO so see carefully it looks tought but dont worry it is very easy compare to Mysqli. I didnt give file name here it is upto you what name you …

Prepositions क्या है –

What is Prepositions (संबंध सूचक अव्यय )  Prepositions की जरूरत वाक्य बोलते समय बार बार पड़ती है जैसे :- About यह एक संबंध सूचक अव्यय है .ऐसे ही कई सारे  संबंध सूचक अव्यय है :- about , after , across , above , along , alongside ,among ,at , from ,for ,by ,beyond  ऐसे ही कई और भी है हम …