Looking for a PHP Source viewer.

Discussion in 'Web Design and Development' started by Cabbit, Jun 29, 2010.

  1. Cabbit macrumors 68020

    Cabbit

    Joined:
    Jan 30, 2006
    Location:
    Scotland
    #1
    Hi hi folks i am trying to find a HMTL/CSS/Javascript PHP source code viewer something like the PHP tag used here.
    I am wanting to show code snippets on my site while i am developing my documentation for Cabbit(Soon to be rereleased faster and with some useful classes like pagination, cacheing, and well lots of stuff).

    Hopefully this is something that is floating around though google has not been my friend today, perhaps the search terms i have tried.

    Things like "Show code source in html" bring back loads of code editors.
     
  2. Mitthrawnuruodo Moderator emeritus

    Mitthrawnuruodo

    Joined:
    Mar 10, 2004
    Location:
    Bergen, Norway
    #2
    I cannot really think about anything but using <pre> tags (or the related <code> tags), off the top of my head.

    It won't add colour to your code, but should at least show the code as monospaced text, with indents.

    Here's someone combining <pre> tags with jQuery to prevent the <pre> boxes becoming too wide...
     
  3. angelwatt Moderator emeritus

    angelwatt

    Joined:
    Aug 16, 2005
    Location:
    USA
  4. Cabbit thread starter macrumors 68020

    Cabbit

    Joined:
    Jan 30, 2006
    Location:
    Scotland
    #4
    I've just tried this one out and it kept crashing safari no mater how complex or uncomplex the code example.
     
  5. angelwatt Moderator emeritus

    angelwatt

    Joined:
    Aug 16, 2005
    Location:
    USA
    #5

Share This Page