| |
|
|
|
Search The Website |
|
|
|
|
|
PHP Personal Home Page PHP) is mainly focused on server-side scripting, so you can do anything any other Computer-Generated Imagery (CGI) program can do, such as collect form data, generate dynamic page content, or send and receive cookies. But PHP can do much more. There are three main areas where PHP scripts are used.
|
| The following
is PHP script to write the sentence:
Hello, World! <!DOCTYPE html>
|
| Note:
For quick results, you need a good PHP editor with a split view option to allow the user to code in Code view and preview in Design view without the
hassle of switching from the design and code view tabs for each review. By using such editor you will very quickly learn and familiarise your self with PHP
structure, statements and functions. I am using
Rapid PHP editor, it is fast, complete all-in-one software for coding PHP, HTML, CSS, JavaScript and other web
development languages with tools for debugging, validating, reusing, navigating and formatting your code. After developing and debugging your PHP
code, save it as PHP file, and upload the PHP and data files to your server. Can I combine PHP with HTML? yes, PHP is an HTML-embedded server-side scripting language. Much of its syntax is borrowed from
C, Java and
Perl with a couple of unique PHP-specific features thrown in. The goal of the language is to allow web
developers to write dynamically generated pages quickly. (Make sure that your hosting offers its clients PHP and HTML services). When building a
complex page, at some point you will be faced with the need to combine PHP and HTML to achieve your needed results. At first point, this can seem complicated,
since PHP and HTML are two separate languages, but this is not the case. PHP is designed to interact with HTML and PHP scripts can be included in an HTML
page without a problem. In an HTML page, PHP code is enclosed within special PHP tags. When a visitor opens the page, the server processes the PHP code and then
sends the output (not the PHP code itself) to the visitor's browser. Actually it is quite simple to integrate HTML and PHP. A PHP script can be
treated as an HTML page, with bits of PHP inserted here and there. Anything in a PHP script that is not contained within <?php ?> tags is ignored by the
PHP compiler and passed directly to the web browser. If you look at the example below you can see what a full PHP script might look like: The Standard
PHP Library (SPL): SPL provides
a standard set of interfaces for PHP.
The aim of SPL is to implement some
efficient data access interfaces and
classes for PHP. Functionally it is
designed to traverse aggregate
structures (anything you want to loop
over). These may include arrays,
database result sets, xml trees,
directory listings or any list at all.
Currently SPL deals with Iterators.
http://www.phpro.org/tutorials/Introduction-to-SPL.html To see all the classes available to SPL,
this simple snippet will show you. This will provide
you with a list something like this: � |
|
PHP Examples |
|
You may learn PHP by examples: (1) W3 School
, and
(2)
Code Academy both website have comprehensive list of
PHP examples in tutorial manner enjoy your
coding.
|
|
Useful Links |
| Learn PHP in 15 minutes
(You tupe 15 minutes video).
|
Web Development ResourcesCoding HelpDevelopment Tools |
Collection of some of the most useful web development resourcesHere you will find carefully picked links to thebest tutorials, most useful references and official specifications of the most important web programming languages. Browse |
| |