Pages

File Uploading in PHP

Hello Readers!
File Uploading is now a requirement of almost every web application. Uploading means tranferring a file from user computer (Client) to the server. While uploading a file, many aspects like file size,file type etc should be considered to make it a secure process.
Like other Server side scripting languages, PHP is also equipped with a very handy file uploading mechanism. The PHP File Uploading system is a combination of setting some directives in PHP.ini file, creating a web form and creating a PHP script.

1 comments  

How to make a Hit Counter using PHP

Hello all! in this post i m going to show you how to make a web hit counter using PHP.It is a very easy and useful hit counter which can display the total number of visits made to your website.In this post you will also learn the file handling capabilities of PHP.Following is the complete code of counter.The file counter.dat is already created on the server, than this file is read and incremented everytime your webpage is requested by a browser.

0 comments  

Simple PHP Gridview

If someone is migrating from ASP.Net to PHP than he must be searching for Gridview kind of funtionality in PHP.Basically this kind of job is accomplished in PHP by populating an HTML table at runtime i.e extracting each row from the database one by one and than build a table dynamically.Following code is doing the same...

0 comments  

Creating a Database from within PHP

Creating a database from the PHP code on runtime is very simple by using a combination of Structured Query Language and the PHP mysql_query() function.

0 comments  

Steps to communicate with MySql database using PHP

If your PHP web application is dealing with a database most commonly MySql,The knowledge about the following functions and their order as described is better.

  1. mysql_connect(hostname,databaseUserName,databasePassword):This is the first function which will establish a connection with the database.It returns false on connection failure.
  2. mysql_select_db("databaseName","connectionName"):This function selects the database.It takes database name and connection name as parameter, Note that connection name is optional.This function can also return false in case of any error.

0 comments  

MySql Connect : The mysql_connect() function.

MySql is the database mostly paired with PHP to provide robust functionality of Interactive webpages.To establish any communication with database in MySql, it is necessary to connect with the database.

0 comments  

PHP inlude() Function

If some lines of code are to be included in every page of the website, The PHP include() funciotn works perfect.If you have been working in ASP.Net or in Dreamweaver than you must be familiar with the role of masterpages and frames in ASP.net and Dreamweaver respectively.Suppose if the look and feel of the website has to be kept similar than we can include the navigation and header files on every page using PHP include() function.

0 comments