| | What is php? |
|
|
|
PHP is a server-side HTML embedded scripting language.
QUOTE PHP is a widely-used general-purpose scripting language that is especially suited for Web development and can be embedded into HTML.
and as many possible way to be used if you know who look at ipb forum nothing but php scripting and some minor html.
There are lots of other languages which do roughly the same things as php, such as JSP, ASP and PERL. Trap17 has all of these languages except ASP. The great thing about these languages is that they are server-sided which means that they run at the server so, unlike javascript, the user doesn't have to download any extra files to look at your php webpages. You may have seen urls in many webpages such as this ( http://example.com/file.php?id=1 ) Our good friend php helps us to construct these types of pages. HTML cannot do this: QUOTE(this is not a quote @ just doing this so i can use bbcode) <? if ($_REQUEST["id"] == "1") { echo "Hello"; } ?> Lets start with the basics. All PHP code must have <? ?> (shown in red) round it just like all html coding but have <html> </html> round it. This tells php that there is gonna be some php code coming. Now the part in blue and black basically says to php that if in the url id=1 can be found it must perform the following action. The very important parts you must notice are the brackets the two equal signs and the {. This may seem very compucated to someone who has not done php before (I know this) but I promise you you will get the hang of it. But, there's still more to come! The part in green tells us what php must do if id=1 is found in the url. This says echo "Hello";. Echo tells php it must write something. What it must write can be found in the speech marks. Notice ; is one the end. This is mandatory and echo will not work without this. Now we have the }. This tells php to stop performing the action if id=1 can be found in the url. Next is the red ?> and this tells php that there's no more php code till <? is found again, if it is found again. If you wish to learn more about php. Here are some good resources: http://www.w3schools.com/php/default.asp http://php.net/ Hope you understood it cmatcmextra
Well actually I have something to say to that. I am a noob at php but I know that it would example.com/file.php?view=id=1 or something like that. And also. I don't know if it would work with <? I learned it that you have to write it <?php and end it with ?>
QUOTE(Ao)K-General @ Jul 9 2005, 01:00 PM) Well actually I have something to say to that. I am a noob at php but I know that it would example.com/file.php?view=id=1 or something like that. And also. I don't know if it would work with <? I learned it that you have to write it <?php and end it with ?> Both <? <?php are acceptable ways of starting php. I don't know why but most people tend to start php like this { <?php } but I tend to start it the other way because it's faster to type. Your script will work using both of these methods. Butphp must always end with ?> never php?>
php most good lamguage to programming ur website
by it u can programe dynamic site as ipb forums and phpbb and vb etc.. and website phpnuke etc...
PHP is a wonderful and fast and easy to learn programming language.. and it's free... many website uses it so it's popular... and when they know that you use PHP, it means you are a powerful programmer...
|
|
![]() What Is Php? - what is php? |
| ADD REPLY / Got an Opinion! | a humble request :-) | RAPID SEARCH! | Free Hosting | [X] |
|
Express your Opinions, Thoughts or Contribute your information that might help someone here. Ask your Doubts & Queries to get answers.. "Together, We enlight each other!" |
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 |
|