main
side
curve
  1. In Memory of LAJ_FETT: Please share your remembrances and condolences HERE

Weekly Web Workshop #1 -- Choosing A Coding Standard

Discussion in 'Archive: Fan Sites' started by Grimby , Aug 5, 2003.

Thread Status:
Not open for further replies.
  1. Grimby

    Grimby Technical Consultant & Former Head Admin star 7 Staff Member Administrator

    Registered:
    Apr 22, 2000
    Welcome to the first of hopefully many WWW's for this forum. My intent here is basically to provide a place that we, the site builders, can learn something new, share our experiences on specific topics, and help each other out. Feel free to ask questions and/or contribute any relevant information. :)


    [b][i][color=azure][hl=black]Weekly Web Workshop[/hl][/color][/i][/b]
    [b][hl=darkgray][color=navy]Volume 1: Choosing A Coding Standard[/color][/hl][/b]



    [b][u]Why conform to a web standard?[/u][/b]
    The internet has come a long way in the past few years. There are a lot of different web browsers in use today. We see browsers like Internet Explorer, Netscape Navigator, Mozilla, and Opera on our pc's. We also see browsers built into our mobile phone or pda. With so many different ways to access information, it is important that we specify the way the information is presented. This is important not only for what we use today to view the web, but also for what we may use tomarrow. Web standards are the key to making this happen. Conforming to a specific web standard will ensure that your web site is viewable by anyone in your target audience on the medium(s) you intend it for.



    [b][u]What are my choices of coding standards?[/u][/b]
    You have three basic choices when choosing a coding standard for you web site: Standard [b]HTML[/b], HTML using Cascading Style Sheets ([b]CSS[/b]), or [b]XHTML[/b]. Choosing the standard that's best for you will depend on your target audience, the content of your site, and your web building skill.
    [ul]
    [u]Standard HTML[/u]
    This is the most basic of languages used to build web pages. HTML has been around since the early 1990's and has changed quite a bit since then. The latest (and last) version of standard HTML is HTML 4.01, released in December 1999. HTML uses a series of tags to define the content of a web page.

    [li]Example:
    [color=darkred]<html>
    <body>
    HTML is teh cool!
    </body>
    </html>[/color][/li]

    Use Standard HTML if you are new to building web pages and want to keep things simple.
    |[i]Reference: [link=http://www.w3schools.com/html/html_reference.asp]html 4.01 tags[/link][/i]|

    [u]Cascading Style Sheets (CSS)[/u]
    CSS is a companion to HTML that enables you to specify the way a page looks. Using style sheets, it is much easier to maintain and change the look of your web site than using standard <font> tags and color attributes. Basically, using CSS you can define the way each tag in your html document looks when viewed in a browser. Anything from text color and background color to specifying where an image is placed on the page can be done using style sheets.

    [li]Example:
    With CSS we can make a string of ordinary text: Typical Mod
    ...look any way we want: [hl=black][b][u][color=mediumvioletred]Typical Mod[/color][/b][/u][/hl]
    ...anywhere on the page. This is especialy helpful because we only have to specify the way something looks once, regardless of how many times it may show up on the page.[/li]

    Most web pages on the net use CSS and it doesn't take a rocket scientist to figure out how to use it. Look for a more in-depth look at CSS in the next WWW.
    |[i]Reference: [link=http://www.w3schools.com/css/default.asp]CSS tutorial[/link][/i]|

    [u]XHTML[/u]
    The new HTML. XHTML is the standard of tomarrow, which enables us to specify how our pages will look on any browser. We've all noticed that sometimes when we look at a web page in Netscape, it may not look the same as when we view it in Internet Explorer. Writing a page that conforms to XHTML standards will ensure that this doesn't happen, and we know exactly what our target audience sees. XHTML coding does this by conforming to strict syntax guidelings, such as only allowing tags written in lowercase and putting all attribute values in quotes.

    [li]Example:
    Use [color=darkred]<body bgcolor="lightgrey">[/color] instead of [color=darkred]<BODY bgcolor=lightgrey>[/color][/li]

    In addition, there are three types of XHTML: [b]Strict[/b], [b]Transitiona
     
  2. Aanix_Durray

    Aanix_Durray Jedi Padawan star 4

    Registered:
    Dec 29, 2001
    You have no idea how helpful that is, since I've been coding two websites, both of which I'm having trouble getting to work in all browsers. I'm hoping this'll get the job done :)

    ~Aanix
     
  3. Grimby

    Grimby Technical Consultant & Former Head Admin star 7 Staff Member Administrator

    Registered:
    Apr 22, 2000
    glad i could help! if you have any questions, don't be afraid to ask. :)
     
  4. Ardens_Furore

    Ardens_Furore Jedi Padawan star 4

    Registered:
    May 14, 2001
    Good stuff, Grimby!

    Let me just add a bit about XHTML. To really take advantage of the standard, you should take out all the layout and visual formatting elements and put it into a CSS2 style sheet. That's really the big difference between XHTML and HTML 4: use the markup for structure and use stylesheets for formatting. There is an advantage to this, too. You can change the colour scheme/background image and even layout of your whole site by manipulating the stylesheet.

    Now, this takes some learning, and the browsers don't quite agree on the standard (but they mostly agree). So you can start learning now, and when the browsers mature and support all of it, then you're good to go.
     
  5. DarthGrimby

    DarthGrimby Assistant to the Assistant to the Head Admin star 2

    Registered:
    Jul 1, 2003
    great post A_F!

    i love the whole concept of style sheets in that you can have one file to manage the layout of any or every page on your web site. it makes changing things up that much easier. :D
     
  6. Raef_Wolfe

    Raef_Wolfe Jedi Padawan star 4

    Registered:
    Jul 12, 2003
    Do you have any examples of HTML, XHTML, CSS, ect pages? It might help a little...after all, a picure is worth a thousand words.
     
  7. DarthGrimby

    DarthGrimby Assistant to the Assistant to the Head Admin star 2

    Registered:
    Jul 1, 2003
    great suggestion. there are a lot of examples in the references i listed for each one above :)

    i'll take that into consideration for the next WWW, as i know that css will definitely benefit. ;)
     
Thread Status:
Not open for further replies.