User Tools

Site Tools


courses:2009.05.06.web.programming

may 6: Web Programming

HTML

  • Basic structure of a HTML page
  • A very simple page
  • <html>
    <head>
    <title>Untitled Document</title>
    </head>
     
    <body>
    Hello World!
    </body>
    </html>
  • A simple page with basic declarations
  • <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title>Untitled Document</title>
    </head>
     
    <body>
    Hello World!
    </body>
    </html>
  • Some simple tags
  • <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title>Untitled Document</title>
    </head>
     
    <body>
    <h1>Hello World!</h1>
    <p>this is my first html page</p>
    <p>a second paragraph with some <em>italic</em> and <strong>bold</strong> text</p>
    <p>one impressive <a href="http://www.interactiondesign.se">hyperlink</a></p>
    <img src="http://www.interactiondesign.se/blog/wp-content/themes/myvigilance/images/masthead/masthead-on.gif" />
    </body>
    </html>

PHP

  • what is PHP
  • mixing PHP and HTML with <?php ?> tags
  • variables start with $, commenting with # and //
  • echo for output to the web document
  • basic control structures: if, for, foreach and more atphp.net
  • $_REQUEST variables
  • making a form and analysing the submitted data
courses/2009.05.06.web.programming.txt · Last modified: 2009/05/05 12:51 by camille