SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast abercrombie's Avatar
    Join Date
    Jul 2008
    Posts
    57
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How to add <instructional> code to page?

    i need to add this code to a page for instructional guidance. easy here with the code command but how do you perform such in HTML? i tried pre and also code tags but nothing within the brackets show up.

    Code:
    <sample_list> : <sample_list> [: example <a_command>

  2. #2
    SitePoint Enthusiast abercrombie's Avatar
    Join Date
    Jul 2008
    Posts
    57
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i figured it out using &lt; (open bracket) and &gt (close bracket).

  3. #3
    SitePoint Author silver trophybronze trophy

    Join Date
    Nov 2004
    Location
    Ankh-Morpork
    Posts
    12,158
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yes, the '<' and '>' characters have special meaning in HTML, indicating the beginning and end of a tag, respectively. In SGML parlance they're known as the STAGO and TAGC delimiters.

    If you want to represent them literally you must escape them using character entity references (&lt; and &gt;) or numeric character references (&#38;#60; and &#38;#62;).

    This applies in all HTML element types that allow character data as content, except style and script. XHTML doesn't have that exception.
    Birnam wood is come to Dunsinane


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •