• home
  • forum
  • my
  • kt
  • download
  • PHP Variables.

    Author: 2008-08-23 13:32:05 From:

    <>PHP is similar to ASP and other programming languages in that it allows you create variable to store values. PHP has serveral variable types with the most commonly used of these being the STRING variable.

    In PHP all strings begin with a $ statement. For example

    <?php
    	$address = "Kingswoods Heights, California";
    ?>
    



    Here we have created a variable called $address and assigned it the value Kingswoods Heights, California. As you can see everything inside the quotation marks will be assigned to the string $address.

    There are a few rules that you need to follow when choosing a name for your PHP variables.

    PHP variables must start with a letter or underscore "_".
    PHP variables may only be comprised of alpha-numeric characters and underscores. a-z, A-Z, 0-9, or _ .

    Variables with more than one word should be separated with underscores. $my_address Variables with more than one word can also be distinguished with capitalization. $myAddress

    discuss this topic to forum

    relation tutorial

    No relevant information

    Category

      Ad Management (4)
      Calendars (3)
      Chat Systems (7)
      Content Management (6)
      Cookies and Sessions (8)
      Counters (8)
      Database Related (8)
      Date and Time (9)
      Development (6)
      Discussion Boards (7)
      E Commerce (6)
      Email Systems (9)
      Error Handling (5)
      File Manipulation (10)
      Flash and PHP (4)
      Form Processing (7)
      Guestbooks (8)
      Image Manipulation (3)
      Installing PHP (5)
      Introduction to PHP (22)
      Link Indexing (8)
      Mailing List Management (9)
      Miscellaneous (54)
      Networking (8)
      News Publishing (9)
      OOP (24)
      PEAR (6)
      PHP vs Other Languages (2)
      Polls and Voting (6)
      Postcards (1)
      Randomizing (14)
      Redirection (11)
      Searching (9)
      Security (29)
      Site Navigation (16)
      User Authentication (14)
      WAP and WML (7)
      Web Fetching (8)
      Web Traffic Analysis (15)
      XML and PHP (16)

    New

    Hot