PDA

View Full Version : Php? Html?



Dapadipz
07-01-2003, 07:56 PM
What Is The Difference and is PHP hard to master.
What program do i need to create a php site. i dnt know if its me but i think most php sites look better

MetroStars
07-01-2003, 08:02 PM
Dreameaver MX let's u create PHP pages.... But is thier really a diffrence

Storm
07-02-2003, 09:21 AM
i think php gives u more options..... u can actually do things with it....... html is more static, really only a way of saying how ur text must look (from what ive heard, im no xpert on this)

Cl1mh4224rd
07-02-2003, 09:42 AM
PHP is server-side scripting language.

From PHP.net (http://www.php.net/):

What is PHP?

PHP is a widely-used general-purpose scripting language that is especially suited for Web development and can be embedded into HTML. If you are new to PHP and want to get some idea of how it works, try the introductory tutorial (http://www.php.net/tut.php).

An example function:

function filesize_r ($inFilesize) {
   $kb = 1024;
   $mb = 1024 * $kb;
   $gb = 1024 * $mb;
   $tb = 1024 * $gb;
   
   if ($inFilesize < $kb) {
       return( $inFilesize . ' Bytes' );
   }
   elseif ($inFilesize < $mb) {
       return( sprintf('%.2f', $inFilesize/$kb) . ' KB' );
   }
   elseif ($inFilesize < $gb) {
       return( sprintf('%.2f', $inFilesize/$mb) . ' MB' );
   }
   elseif ($inFilesize < $tb) {
       return( sprintf('%.2f', $inFilesize/$gb) . ' GB' );
   }
   else {
       return( sprintf('%.2f', $inFilesize/$tb) . ' TB' );
   }
}
This returns a number (a file's size in bytes) in a human-readable form.

Ynhockey
07-02-2003, 11:57 AM
Well, HTML isn't a programming language at all. It isn't dynamic. You can't do anything with it that depends on what the user does (except some really small things).

PHP isn't only dynamic, but just like any other programming language, it can process data and work with databases. Basically, everyone serious about website building should know PHP or ASP. ASP is worse and older, but it offers enough functionality for just about anything. I've never actually seen a site that was made in PHP that couldn't be made in ASP. However, PHP is still better. More efficient, to say the least.

However, before you start with PHP, you should probably learn JavaScript.

maddytherenegade
07-02-2003, 01:16 PM
Simply putting , php gets query from the browser, talks to the server and reply to u..U cannot see the source of all the links if u want to..
HTML talks directly with the server to the browser....u can see the source code..