PHP PROGRAMS

PHP Programs Link ::-- 


Q1) Define an interface which has methods area( ), volume( ). Define constant PI. Create a class cylinder  which implements this interface and calculate area and volume.

Q2) Write a PHP script to demonstrate the introspection for examining class .(use functionget_declared_classes() ,get_class_methods() and get_class_vars()

Q3) Write PHP script to display GATEWAY INTERFACE, Server Address, Server Name,server software, server protocol.

Q4) Write PHP program to accept user details such as user-id, name, Address, email, andmobile no. Display same information on next page.

Q5) Write a PHP program that takes name and age from an HTML page. If the age is less than 18, it should send a page with “hello ,and u are not authorized to visit this site” otherwise it should send “welcome to this site” message where name should be replaced with the entered name otherwise it should send welcome to the site message.

Q6) Write a PHP Program to display all Server information in table format.

Q7)  Write a PHP script to accept user preference like background color, text font, login message. On the next page display login message using the preferences.

Q8) Write a PHP program to create a simple distance calculator that can accept distance in meters from user. Convert it into centimeter or kilometer according to user preference(use radio buttons and Self Processing form).

Q9) Write a PHP script for the following: Design a form to accept a number from the user. Perform the operations and show the results.  Check whether number is palindrome or not.  Reverse the number using recursions. (Use the concept of self processing page.)

Q10) Write a PHP script to accept an Indian currency and then convert it in dollar or pounds (radio buttons) according to user’s preference. (use concept of self processing form).

Q11)Write a PHP script to accept a weight in kg and Height in meter of person and then calculate BMI.

Q12) Write a PHP program to accept two strings from user and check whether entered strings are matching or not. (Use sticky form concept).

Q13)Write PHP program to create student registration form and display student information. (Use sticky form concept).

Q14)Write PHP program accept name, select your cities you would like to visit (Use multi-valued parameter), and display selected information on page.

Q15)Write PHP program to select list of subjects from list box and display selected subject on information. (Use sticky multi-valued parameter).

Q16)How to fetch single data without using get method in PHP.

Q17)Write a PHP program to accept user-id and password and check whether it is valid or not.

Q18)Write a Program to make login page using PHP.

Q19)PHP program to display bio data of a person by reading the person details.

Q20)Create a Web Page in PHP to find person is Adult or not.

Q21)How to select gender in PHP.

Q22)Write a PHP Script to change background color using Switch Statement.

Q23)PHP script to find length of the String "this is my first program".

Comments