coloring various syntax

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Ruthless

    coloring various syntax

    hello.

    I've got a simple question.

    I've searched on google for PHP scripts coloring syntax e.g. asm, c, c++,
    bash etc.

    I've only found some CGI, apps, modules for Apache - but i can't use them
    on my server
    (due to my restricted permissions - i can use only PHP and MySQL).

    Are there any PHP scripts for coloring syntax?

    thanx in advance

    greetings R


    ---
    Outgoing mail is certified Virus Free.
    Checked by AVG anti-virus system (http://www.grisoft.com).
    Version: 6.0.554 / Virus Database: 346 - Release Date: 03-12-20


  • CountScubula

    #2
    Re: coloring various syntax

    "Ruthless" <ruthless@NO_SP AM.poczta.onet. pl> wrote in message
    news:bt60k7$lhj $1@nemesis.news .tpi.pl...[color=blue]
    > hello.
    >
    > I've got a simple question.
    >
    > I've searched on google for PHP scripts coloring syntax e.g. asm, c, c++,
    > bash etc.
    >
    > I've only found some CGI, apps, modules for Apache - but i can't use them
    > on my server
    > (due to my restricted permissions - i can use only PHP and MySQL).
    >
    > Are there any PHP scripts for coloring syntax?
    >
    > thanx in advance
    >
    > greetings R
    >
    >
    > ---
    > Outgoing mail is certified Virus Free.
    > Checked by AVG anti-virus system (http://www.grisoft.com).
    > Version: 6.0.554 / Virus Database: 346 - Release Date: 03-12-20
    >
    >[/color]

    if you want to color a php script run it through php with the -s option

    like this

    $coloredText = `php -s $someFileName`;

    if you look at my site, that is how the colored snippets are done.

    --
    Mike Bradley
    http://gzen.myhq.info -- free online php tools


    Comment

    • Tim Tyler

      #3
      Re: coloring various syntax

      Ruthless <ruthless@no_sp am.poczta.onet. pl> wrote or quoted:
      [color=blue]
      > I've searched on google for PHP scripts coloring syntax e.g. asm, c, c++,
      > bash etc. [...][/color]
      [color=blue]
      > Are there any PHP scripts for coloring syntax?[/color]

      http://mandala.co.uk/syntax_highlighting/ has a script which highlights
      HTML and PHP.
      --
      __________
      |im |yler http://timtyler.org/ tim@tt1lock.org Remove lock to reply.

      Comment

      • Agelmar

        #4
        Re: coloring various syntax

        Ruthless wrote:
        <snip>[color=blue]
        > Are there any PHP scripts for coloring syntax?
        >
        > thanx in advance
        >
        > greetings R[/color]

        Why not just use highlight_file( )?


        Comment

        • Ruthless

          #5
          Re: coloring various syntax

          yeah but i know how to color PHP syntax ;-)

          i was asking for asm,c, c++ etc. syntax

          any way... i'll try google once more

          greetings R

          U¿ytkownik "Ruthless" <ruthless@NO_SP AM.poczta.onet. pl> napisa³ w wiadomo¶ci
          news:bt60k7$lhj $1@nemesis.news .tpi.pl...[color=blue]
          > hello.
          >
          > I've got a simple question.
          >
          > I've searched on google for PHP scripts coloring syntax e.g. asm, c, c++,
          > bash etc.
          >
          > I've only found some CGI, apps, modules for Apache - but i can't use them
          > on my server
          > (due to my restricted permissions - i can use only PHP and MySQL).
          >
          > Are there any PHP scripts for coloring syntax?
          >
          > thanx in advance
          >
          > greetings R
          >
          >
          > ---
          > Outgoing mail is certified Virus Free.
          > Checked by AVG anti-virus system (http://www.grisoft.com).
          > Version: 6.0.554 / Virus Database: 346 - Release Date: 03-12-20
          >
          >[/color]


          ---
          Outgoing mail is certified Virus Free.
          Checked by AVG anti-virus system (http://www.grisoft.com).
          Version: 6.0.557 / Virus Database: 349 - Release Date: 03-12-30


          Comment

          • Ruthless

            #6
            Re: coloring various syntax

            thanks Tim

            at least sth more then coloring PHP ;D

            i'll search once again for asm, c, c++ maybe i'll hunt sth on google

            greetings R

            U¿ytkownik "Tim Tyler" <tim@tt1lock.or g> napisa³ w wiadomo¶ci
            news:Hqx2nE.3Cn @bath.ac.uk...[color=blue]
            > Ruthless <ruthless@no_sp am.poczta.onet. pl> wrote or quoted:
            >[color=green]
            > > I've searched on google for PHP scripts coloring syntax e.g. asm, c,[/color][/color]
            c++,[color=blue][color=green]
            > > bash etc. [...][/color]
            >[color=green]
            > > Are there any PHP scripts for coloring syntax?[/color]
            >
            > http://mandala.co.uk/syntax_highlighting/ has a script which highlights
            > HTML and PHP.
            > --
            > __________
            > |im |yler http://timtyler.org/ tim@tt1lock.org Remove lock to reply.[/color]


            ---
            Outgoing mail is certified Virus Free.
            Checked by AVG anti-virus system (http://www.grisoft.com).
            Version: 6.0.557 / Virus Database: 349 - Release Date: 03-12-30


            Comment

            • Tim Van Wassenhove

              #7
              Re: coloring various syntax

              On 2004-01-03, Ruthless <ruthless@NO_SP AM.poczta.onet. pl> wrote:[color=blue]
              > thanks Tim
              >
              > at least sth more then coloring PHP ;D
              >
              > i'll search once again for asm, c, c++ maybe i'll hunt sth on google[/color]


              Meaby you find more/better is u use "highlight" instead of "coloring"
              as a keyword ;)


              --
              verum ipsum factum

              Comment

              • Tim Tyler

                #8
                Re: coloring various syntax

                Ruthless <ruthless@no_sp am.poczta.onet. pl> wrote or quoted:

                Re: http://mandala.co.uk/syntax_highlighting/
                [color=blue]
                > at least sth more then coloring PHP ;D
                >
                > i'll search once again for asm, c, c++ maybe i'll hunt sth on google[/color]

                I'd rather like one that does Java source code.

                I might write one based on my current HTML highlighter someday...
                --
                __________
                |im |yler http://timtyler.org/ tim@tt1lock.org Remove lock to reply.

                Comment

                Working...