ASP
  Home arrow ASP arrow Page 2 - New Technologies and What They Mean To You...
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
ASP

New Technologies and What They Mean To You: Part 2
By: Jeremy Wright
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 2
    2002-10-09

    Table of Contents:
  • New Technologies and What They Mean To You: Part 2
  • PHP
  • ASP
  • ColdFusion
  • Conclusion

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    New Technologies and What They Mean To You: Part 2 - PHP


    (Page 2 of 5 )

    Definition
    PHP (PHP Hypertext Processor) is an HTML-embedded, server-side, cross-platform scripting language used to create dynamic web pages. PHP is open source software.

    PHP is a server side language designed to be able to handle web-based applications and processing. When a PHP script is requested from the server, it is parsed (read) for instructions that are then executed. The resulting HTML code is then sent to the browser.

    As PHP is open source, it can be ran on many different types of servers, such as Apache, IIS etc. This fact has lead to the rapid adoption of PHP by the web development community, and it is now one of the most popular server side languages.

    The latest version of PHP -- version 4 -- is built upon the Zend parsing engine, which was written by Andi Gutmans and Zeev Suraski. Andi and Zeev adopted the PHP language after version 2 and have been responsible for all major releases since (including a complete overhaul).

    PHP4 now includes support for many more web servers, HTTP sessions, output buffering, more secure ways of handling user input and several new language constructs.

    What It Really Is
    So that's what PHP is on paper, but what does it really do? Two things that are instantly attractive are that it's open source, and so it has a low development cost and support and assistance are readily available through the active and helpful PHP community.

    For experienced developers in Java, C, C++ or even JavaScript, the syntax of PHP is both logical and familiar. The developers have taken care to ensure that the language is not overly complicated by, for example, naming functions logically ie: strtoupper() and arraypop(). This makes PHP a solid language for anyone looking to take the leap from static HTML pages to dynamic web sites.

    The most common application of PHP is, undoubtedly, web-based applications which utilize a MySQL database, which means that developers can effectively create fast web applications. PHP provides support for many other databases as well, including Microsoft SQL Server, Oracle and Microsoft Access.

    It has proven to be a viable and stable solution for everything from personal to corporate to eCommerce web sites. It also comes with a wide range of other features such as, XML support, Java servlet support, native session handling and IMAP functions amongst others.

    Overall PHP is a strong option for those looking to graduate from the basics of web design. As well as being easy to pick up, it offers many advanced functions that experienced developers will appreciate.

    Advantages
    • Strong support community
    • Ease of use for experienced developers
    • Installed on nearly all web hosts
    • Cross-platform
    • Open Source
    Disadvantages
    • Strong learning curve for inexperienced developers
    • Security risks for new developers, due to the power PHP is given
    Examples
    For examples of PHP usage, as well as the full manual, go to http://www.php.net/manual. Here are some basic PHP examples:

    PHP Start & End Tags:

    <?php ... ?> or <? ... ?>

    Display Configuration Information:

    <? phpinfo(); ?>

    Comparison Operators:

    $a == $b
    Checks if the value held in $a is the same as that held in $b

    $a === $b
    Same as before but also checks if they are the same type (string, number)

    $a != $b
    Checks if the value held in $a is not equal to that held in $b

    $a < $b
    Returns true if the value held in $a is LESS THAN that held in $b

    $a > $b
    Returns true if the value held in $a is GREATER THAN that held in

    MySQL Database Connection:

    If(!$link = mysql_connect("mysql_host", "mysql_login", "mysql_password")) {
    echo("Error connecting to the database host: " . mysql_error());
    }

    if(!mysql_select_db("devarticles")) {
    echo("Couldnt connect to the database because " . mysql_error());
    }

    echo("WOOHOO! Ready to start executing querys on the database.");


    Similar Technologies
    Really, any web based scripting language is "similar" to PHP, in that it fulfills the same goals. We will look at most of these during the rest of this article series:
    • ASP: By far the most hated rival of the PHP community. ASP is Microsoft's proprietary scripting language. While it does run on Linux under interpreter’s such as Sun’s ASP ONE, it shines on Windows NT and Windows 2000 machines.
    • ColdFusion: ColdFusion is Macromedia's offering for web-based dynamic content. While it isn’t technically "scripting", as it is based on an HTML-like tag structure, it does fulfill the same goal of providing dynamic web pages.
    Links
    There are many places to find out information about PHP, and there are literally thousands of sites that will help you on your way. Some of the best for both of these are:

    DevArticles PHP section

    Hotscripts list of tutorials

    Official PHP manual

    More ASP Articles
    More By Jeremy Wright


     

    ASP ARTICLES

    - Central Scoreboard with Flash and ASP
    - Calorie Counter Using WAP and ASP
    - Creating PGP-Encrypted E-Mails Using ASP
    - Be My Guest in ASP
    - Session Replacement in ASP
    - Securing ASP Data Access Credentials Using t...
    - The Not So Ordinary Address Book
    - Adding and Displaying Data Easily via ASP an...
    - Sending Email From a Form in ASP
    - Adding Member Services in ASP
    - Removing Unconfirmed Members
    - Trapping HTTP 500.100 - Internal Server Error
    - So Many Rows, So Little Time! - Case Study
    - XDO: An XML Engine Class for Classic ASP
    - Credit Card Fraud Prevention Using ASP and C...







    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 1 Hosted by Hostway
    For more Enterprise Application Development news, visit eWeek