Php Starter Guide - Made By Me

free web hosting
Free Web Hosting > Computers & Tech > How-To's and Tutorials > Programming > PHP

Php Starter Guide - Made By Me

Lewisthemusician
Contents

Introduction

In this tutorial, you will learn about PHP, i will start with this and then make more parts to it until i have completed a few parts which will cover the whole range of PHP. I hope you will learn lots from this tutorial and when you finish you will know loads. I have benefited from learning this way and that's why i have written it out as a tutorial for others to learn from.

Start Off PHP

Now to start off create a page with any name, it doesn't really matter. However you need to make the page end it .php
When you are using PHP, you need to define it and tell the page you are using it, so this is kind of like :
CODE
<html>

and
CODE
</html>

However in PHP, to start off a PHP script you use:
CODE
<?

or
CODE
<?php

and to close it you use
CODE
?>

In this case we will be using the first choice so inside your page place this code.
CODE
<?

?>


Inside these brackets with question marks you can place any php stuff you like.

Echo

Then let's say you want to input some text, in PHP there are 4 ways
CODE
echo 'text';
print 'text';
return 'text';
die 'text';

(Note that die will shut down the rest of your script so nothing else below it will run, making it useful for errors and things.)
But for now you do not need to know them so we will be using echo.
So in between the brackets insert the echo which would look like this.
CODE
<?
echo "Hello";
?>

You can also change the quotations to single's eg
CODE
<?
echo 'Hello';
?>

These both would show up like this:
CODE
Hello

but don't worry about that for now.

Variables

In PHP there are such things called variables, these define a certain object.
To cut it down into baby language imagine you have a file in your "My Documents" folder, then, placing the variable into a echo is like making a shorcut on your desktop.
In This example we will be changing the "Hello" text into a variable then place the variable into the echo to show on the page, i have broken this down into steps to explain it.

Step 1: Open the PHP brackets
CODE
<?

Step 2: Make a variable called greeting
CODE
$greeting = "";

Step 3: Define whats happening in the variable so in this case we would say we want text to show up saying "Hello"
CODE
$greeting = "Hello";

Step 4: Echo this variable
CODE
echo $greeting;

Step 5: Close the PHP Brackets
CODE
?>


So, altogether that would look like this:
CODE
<?
$greeting = "Hello";
echo $greeting;
?>

This to would end up looking like this on a page
CODE
Hello


That's the end for part 1, look out for part 2 where i will more like the if command and if..else command as well as more in depth explanations of PHP.

Enjoy!

 

 

 


Reply

toby
You miss some things out, like where you can open and close, why you need <?php and ;, but otherwise good.

Reply

anakintyler
Very good tutorial for php very good and short even though I think it would have been better if it had more details using more codings.

Reply

vmkrightpoint
i gave this page to my friend and he likes it!


Reply


Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

(Maximum characters: 10,000)
You have characters left.
Confirm Code:

Similar Topics

Keywords : php, starter, guide, made

  1. The Worst Singer That Made It Big
    (5)
  2. Barebone Kit Completion- Need Second Opinions
    made barebone kit - is it compatible? (3)
    hers what i came up with let me know if its okay- ricker Case ( Xion Dazl Gaming Tower Case w/420W
    Power Supply ) Case Lighting ( None ) Power Supply ( 750 Watt -- Corsair CMPSU-750TX Power Supply
    Quad SLI Ready ) Processor ( Intel Core 2 Quad Processor Q6600 (4x 2.4GHz/8MB L2 Cache/1066FSB) )
    Free Software/Game ( Free Game - must purchase with Microsoft Windows Vista operation system )
    Processor Cooling ( Thermaltake V1 CPU Cooling Fan System Kit Silent & Overclocking Proof =
    Maximum cooling efficiency for quietness and performance ) Motherboard ( eVGA Nvidi....
  3. An Absolute Basic Guide To Algorithms For Dummies
    (0)
    I really want to learn about algorithms but i dont know how it works at all. Can anyone suggest a
    site, or more preferably a book that can introduce me to algorithms?....
  4. C++ Meters To Feet And Feet To Meters Program
    I made it (0)
    Here's a useful program I made today that converts meters to feet or feet to meters: Exe:
    Source: 100% C++. /rolleyes.gif" style="vertical-align:middle" emoid=":rolleyes:" border="0"
    alt="rolleyes.gif" /> Play with it if you like. Maybe add more to it. /tongue.gif"
    style="vertical-align:middle" emoid=":P" border="0" alt="tongue.gif" /> ~ Snake....
  5. Login Made Easy
    (0)
    i found a company a while back that does easy to use login stuff it is auth pro they do a free
    version but it only alows 10 members but they have very advanced admin area with member time out
    login log with ip address, they do paid member subsciption i used them and they were good note if
    you go for free version login page has ads....
  6. Website Navigation Hover Buttons Stick So Made Css Today
    need further help with tutorial from this site (7)
    Hi I made hover buttons to go into my friends website because frontpage didn't allow the text on
    their buttons to be left aligned. Anyway, I think they stick a lot and i'm not happy with them.
    I have read a lot of people don't like the time it takes for java applets to load either so
    thought I should try doing the navigation buttons with the CSS shown on this site. I was so happy
    when after following the instruction my buttons turned out fine but the probem is that they have a
    solid border around each button and i want my nav bar to look like it's under....
  7. My Guide On Runescape Making Millions
    guide (4)
    Alright so you want to make millions in 2 hours. First you need to work yourself up to get the
    millions, What you do is with about 60+ str kill flesh crawlers and start fishing. Once you have 300
    k cash start tanning Green d hide; Which after tanned will be called green leather. Math: 300 000
    spent on supplies. Around 500 green d hides can be tanned every 15 mins. Buy green d hide at med,
    Which would cost 1698 ea. Which will get you about 177 which you can do in like 2 mins. You sell the
    green d hide back for 1850 ea, A little below med price. Which is 327 000 thats ....
  8. The Ultimate Businness Man Online Game Guide
    A guide for the Ultimate Businness Man (2)
    Theubm (The Ultimate Businness Man) is a free Text Based online game. You are able to win over 1,500
    dollars of prizes each week. Here is a guide I made for the UBM the game itself, and for you
    guys! http://theubm.com is the link for the game A fast start for the ubm 1 - Go to
    the Recruit section to recruit some producers (engineers and scientists) and collectors (managers
    and investors). DO NOT recruit a lot until you know for sure how to make them happy! On average,
    you get 2 scientists, 3 engineers, 3 investors and 5 managers per turn. Managers and ....
  9. Help Me Make A Guide To Website Making!
    HELP! (0)
    I been wanting for a time now to make a guide to website making, i now i have have decided im going
    to, i will need colleagues, if anyone has medium knowledge in this area it would be nice if they
    could be the co-author (or probably the main as i am 10). CSS would be a VERY good thing to know as
    i am only reasonable in HTML/XHTML. all credit will be shared. P.S. you are probably thinking "this
    idiot is a newbie and hes only ten" please do not, i have been doing html for a while now and i
    really beleive i can do this, if you want i could even give you FULL credit for ALL ....
  10. Which Os Would Be First To Respond With ....
    an OS to use a new computer system made by a third manufacturing compa (4)
    and which do you think would be best for this? reason I ask is that I have plans to build a device
    that will need a Parallel port that would have thousands of hard wired pins if not millions and
    nothing exists today that could handle that. so the idea is if a brand new style of computing were
    devised requiring all levels of programming to be done from scratch who do you think would be the
    best candidate to make a user friendly OS for it? remember BRAD NEW like using trianary or
    quadrinary as opposed to binary with multi sensitive transistors that would have 4 or more ....
  11. Guide For Beginner Convert Video To Psp
    Video convert iPod iPhone (2)
    Guide for beginner how to convert WMV, ASF, WMA, AVI, RMVB, RM, RA, MOV ect to psp PSP Video Format
    The video codec supported by the PSP is a proprietary variant of the H.264 codec closely related to
    DivX. The format is also referred to as the Memory Stick Video Format. The audio codec used is AAC.
    Before loading video onto your PSP it needs to be transcoded using one of the tools listed below.
    Some compatible (Sony) devices may be able to produce video in the correct format, and therefore may
    not require transcoding. The PSP manual states that the maximum supported ....
  12. A Guide To Using Ftp
    (2)
    Here is a small guide QUOTE What is FTP? FTP (File Transfer Protocol) is the simplest and most
    secure way to exchange files over the Internet. Whether you know it or not, you most likely use FTP
    all the time. The most common use for FTP is to download files from the Internet. Because of this,
    FTP is the backbone of the MP3 music craze, and vital to most online auction and game enthusiasts.
    In addition, the ability to transfer files back-and-forth makes FTP essential for anyone creating a
    Web page, amateurs and professionals alike. When downloading a file from ....
  13. Attack Script In Php
    This is a funny attack script that i made (5)
    Hey! I am going to share an attack script that i made for some time ago. I made it, as a test
    for my game.. And ofc, you can use it for your game to. It is still version 1.0. But I want you to
    learn something from it /wink.gif" style="vertical-align:middle" emoid=";)" border="0"
    alt="wink.gif" /> This is my second tutorial here, and I will try to make it better than my first
    one /smile.gif" style="vertical-align:middle" emoid=":)" border="0" alt="smile.gif" /> Here is
    the SQL File. CODE CREATE TABLE `characterss` (   `health` int(2....
  14. My Sigs
    My best sigs that I've made so far (5)
    I'm still a bit new to this signature thing. I use Macromedia flash (YES I DO!)
    because I'm too lazy to learn Photoshop.....
  15. Like My New Banner?
    Made in Photoshop (8)
    How do you like this baby? i wanna put it up on the website. ....
  16. Rags To Riches Iv - My Best Guide
    another awesome runescape guide (10)
    Rags To Riches IV- The Final Chapter The best money making guide EVER! Introductions From
    Rags to Riches IV- The Final Chapter ~ Rags to Riches Iv- The final chapter ~ Has all the money
    making ideas that the high levels don’t want you to know. They have been trying to keep the secrets
    away from you for years. They don’t want you to know how they make all the money. But guess what?
    Mobil and I do want you to know. ~ In Runescape money = power. If you don’t have a lot of money
    even if you’re a high level people just don’t respect you. Well, that’s all about to c....
  17. Runescape Multi Logon Guide
    how to multi logon (7)
    Hi i was told by one of my school friends how to login on multiple account so u never have to drop
    trade items and risk getting banned. All u need is ure computer thats it!!!! lol,
    well heres the steps: 1) Go to the runescape home page. 2) Click "Play runescape" (Existing user).
    3) When the detail selection comes up scroll down and there should be a grey box which says "Signed
    Applet Using Defult Java(Recommended). Leave this and as it is and click low detail. 4) Choose a
    world. 5) Open another windows explorer and do steps 1 and 2. 6) Now when u ge....
  18. Run A Webserver From Usb-stick On Windows Guide
    (2)
    Run a webserver from USB-stick on windows guide Introduction A few weeks ago we got a
    256MB USB-stick from school (yes I didn’t have one yet!), and I haven’t played with it since I
    got it till my computer broke and I had to use my moms laptop. Since I didn’t want to break up my
    moms laptop, I thought about my USB-stick and wanted to install a webserver on it. Though it can
    also be used if you want to demonstrate a project of yours to your clients or friends
    whatsoever! It can even be used as a real webserver! But please keep in mind that a USB-st....
  19. Pre Loader Tutorial For Flash
    Made by: Jordain (6)
    Simple pre loader tutorial with play button by: Jordain Joyce First of all open up flash then
    Create 4 Layers and in order name them: Actions
    Loader outline
    Loader Bar Content Then create 3
    frames for each layer. Lets start in the actions layer, for the first frame make it blank and the
    second frame make it blank also. Press F9 to open the actions panel (make sure you ....
  20. What Made You Switch To Linux?
    (60)
    I first tried Linux a few years ago, not because I was completely against Windows or anything like
    that, but just because I had some free time on my hands. I started off with Mandrake 9.0 which was
    very user friendly and Windows-like. After reading through a bunch of message boards and learning
    which distros are good for what, I soon realized my current distro was great for Linux noobs. So
    then I decided to try something a little more advanced like Slackware which I knew had a steep
    learning curve. Since then I've been using Slackware as my main OS and couldn'....
  21. Apache Tutorial: Enable mod_rewrite In Windows
    A brief action guide to enable mod_rewrite in Windows (2)
    Hi everybody, If you are using Windows OS and want to enable mod_rewrite module here is how to do
    it. This is the general configuration guideline both for Windows and Linux server: QUOTE 1. Find
    the httpd.conf file (usually you will find it in a folder called conf, config or something along
    those lines) 2. Inside the httpd.conf file uncomment the line LoadModule rewrite_module
    modules/mod_rewrite.so (remove the pound '#' sign from in front of the line) 3. Also find
    the line ClearModuleList is uncommented then find and make sure that the line AddModule mod_....
  22. Banner Made For A Friend
    (9)
    a banner i made for a friend and his rp. ....
  23. Add A Forum To Your Site
    A guide to adding discussion forums to your site (23)
    QUOTE When you’re setting up a site using CSS, it’s a good idea to do a little planning ahead
    and think how you’ll be using your styles, otherwise you could end up spending much more time later.
    As a case in point – for a site I’ve recently built, a basic style sheet was put together, with
    entries for matters like headlines, section headings, item headings and so on. When it came to forms
    on the site that needed headings next to the data entry boxes, the logical choice was the item
    headings style. It helped maintain a consistent look across the site, but it came bac....
  24. Runescape Money Guide
    A must (50)
    My runescape money guide. The following are some tips to earn some easy money: (1) Through mining
    -PART 1- Get your mining level to lv115 1st, If your going for the easy way, Get your mining level
    to 60 (mine only irons) You'll have about 7822 iron ores You can sell your iron ores for 100gp
    each and that'll earn you around 770k-800k -PART 2- If you're going for the tougher task,
    Like in part 1,get your mining to 15 but after 30 start to mine coals From my calculation: The iron
    ores between level 15-30 + coals between lv30-60 will let u make this amount : ....
  25. How To Connect Dual/triple Monitor + Advantages
    Guide on how to install mult. monitors (21)
    I'm sure 95 % of you are running your system with one monitor. Primarily because that is the
    default for any computer. What if i told you that running your system with dual monitors or even
    triple monitors will increase your user performance extensively? Ways it helps: - can play some
    games while instant messaging, writing emails, watching movie on other screen, looking up something
    online, etc... - Helps with working on websites or other programming, because code can be on one
    side, while the preview image is on the other monitor. - Spreads the space out so you h....
  26. Imho, You'll Be Rotfl!
    A guide to understanding Email stupidity (12)
    IMHO, you'll be ROTFL! A guide to understanding Email stupidity
    ----------------------------------------------------------------------------------------------- By:
    Cube Domain Created: October 22, 2005 Licensed To: Astahost The Internet is, in the most general
    sense, quite stupid actually. Inhibitions are unknown, ignorance could not be more prevalent, and
    idiocy is the language of the majority of Internet users. They’ve even gone as far as inventing
    their own acronyms. You may use this guide to comprehend the language found mainly in email and
    message boards....
  27. Just Made This Cd Cover For A Friend
    tell me what you think about it! (3)
    nothing spectacular, I have alot of friends into music and when they drop cds they ask for my help
    in the covers, ive done a few this is 1 of my favorites, I dunno why probably because Ali is in it.
    But tell me what you think about it? tips? questions? blah go for it. ....
  28. (Nearly) Ultimate Music Posting Guide
    Making your music available online (11)
    The (Nearly) Ultimate Music Posting Guide For several years, indie and established musicians
    relied on MP3.com as their primary off-site music host. While there were a small number of other
    similar sites, and MP3.com had its share of problems, it was still THE place to get your music
    posted. It also allowed artists and music fans to create "Stations" where customized playlists could
    be created and shared with the world. Vivendi Universal eventually bought MP3.com and ultimately
    shut it down only to rebuild it as a site for "established" artists, leaving all of the in....
  29. Do You Program/code Your Own Games
    What games have you made? (11)
    Hey all! I was wondering what kinds of games you all have made or are working on right now.
    I'm also interested in what languages/software you used to make them. The most recent game
    I've made is Cannon Wars. It is a 3-D artillery game, similar to Scorched 3D . You control
    the angle and power of your gun and try to blow the other players up. After a lot of work I was
    able to add network support so you can play with people over a LAN. It also has a primitive Ai so
    that you can play against computer players. I wrote it in C++ and used Directx for the g....
  30. Character Modeling For 3ds Max
    Actually, modeling the character I made (4)
    Thanks to ImageShack for Free Image Hosting I’m putting the images that I rendered on my
    account because I'm using hyperlink to link to them, which would require less traffic than
    hotlinking them. I'm hyperlinking them because I have too many images anyway, so I can't
    hotlink them all. I’m working on a 3d animation with 3ds max, and have created a model called Neo.
    This tutorial will tell you how I modeled it. It might not be the best way, but it worked for me.
    First, I used Flash to draw my model. I did a front and side view. These images will serve ....

    1. Looking for php, starter, guide, made

Searching Video's for php, starter, guide, made
Similar
The Worst
Singer That
Made It Big
Barebone Kit
Completion-
Need Second
Opinions -
made
barebone kit
- is it
compatible?
An Absolute
Basic Guide
To
Algorithms
For Dummies
C++ Meters
To Feet And
Feet To
Meters
Program - I
made it
Login Made
Easy
Website
Navigation
Hover
Buttons
Stick So
Made Css
Today - need
further help
with
tutorial
from this
site
My Guide On
Runescape
Making
Millions -
guide
The Ultimate
Businness
Man Online
Game Guide -
A guide for
the Ultimate
Businness
Man
Help Me Make
A Guide To
Website
Making!
- HELP!
Which Os
Would Be
First To
Respond With
.... - an OS
to use a new
computer
system made
by a third
manufacturin
g compa
Guide For
Beginner
Convert
Video To Psp
- Video
convert iPod
iPhone
A Guide To
Using Ftp
Attack
Script In
Php - This
is a funny
attack
script that
i made
My Sigs - My
best sigs
that
I've
made so far
Like My New
Banner? -
Made in
Photoshop
Rags To
Riches Iv -
My Best
Guide -
another
awesome
runescape
guide
Runescape
Multi Logon
Guide - how
to multi
logon
Run A
Webserver
From
Usb-stick On
Windows
Guide
Pre Loader
Tutorial For
Flash - Made
by: Jordain
What Made
You Switch
To Linux?
Apache
Tutorial:
Enable
mod_rewrite
In Windows -
A brief
action guide
to enable
mod_rewrite
in Windows
Banner Made
For A Friend
Add A Forum
To Your Site
- A guide to
adding
discussion
forums to
your site
Runescape
Money Guide
- A must
How To
Connect
Dual/triple
Monitor +
Advantages -
Guide on how
to install
mult.
monitors
Imho,
You'll
Be
Rotfl! -
A guide to
understandin
g Email
stupidity
Just Made
This Cd
Cover For A
Friend -
tell me what
you think
about
it!
(Nearly)
Ultimate
Music
Posting
Guide -
Making your
music
available
online
Do You
Program/code
Your Own
Games - What
games have
you made?
Character
Modeling For
3ds Max -
Actually,
modeling the
character I
made
advertisement




Php Starter Guide - Made By Me



 

 

 

 

ADD REPLY / Got an Opinion! a humble request :-) RAPID SEARCH! Free Hosting [X]
Express your Opinions, Thoughts or Contribute more info. to help others.
Ask your Doubts & Queries to get answers, So that "Together We can help others!"
Register FREE for AD-FREE forum, Create your own topics, Ask Questions, track topics, setup subscriptions & notifications and Get a Free Website w/ Email and FTP.
500MB Space *No Ads*, CPanel, FTP, PHP, MySQL, EMails - 100% FREE