Results 1 to 7 of 7

Thread: Coloring text using shell scripting

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2002
    Location
    São Paulo
    Posts
    4

    Coloring text using shell scripting

    Hi,

    Is it possible to change text color in php when making it run as shell script?

    thanks in advance
    dOsgrAvE 2000©
    dead?!?... yup, you can say so...

  2. #2
    scoutt
    Guest
    like what do you have in mind?

  3. #3

    Thread Starter
    New Member
    Join Date
    Jan 2002
    Location
    São Paulo
    Posts
    4
    hi,

    i'm using php to fetch some webpages, and i'd like to send messages in red, when an error occurs, and green when it works fine.

    Another doubt is:

    everytime i try to fetch some webpages, it ends with a timeout error when fetching. Is it configurable? set_socket_timeout didn't work (isn't part of my installed build).

    thanks in advance
    dOsgrAvE 2000©
    dead?!?... yup, you can say so...

  4. #4
    scoutt
    Guest
    how would you know it worked? or for that matter failed (without looking at the screen)

    and
    how big are the pages you are fetching? that is the only cause I know that would bring up a timeout

  5. #5

    Thread Starter
    New Member
    Join Date
    Jan 2002
    Location
    São Paulo
    Posts
    4
    Hi,

    the timeout problem has been solved, changinc php.ini

    there's some error trapping routines, just want to make some color changing... how would i do to use ANSI Color codes in php?

    tia
    dOsgrAvE 2000©
    dead?!?... yup, you can say so...

  6. #6
    Addicted Member
    Join Date
    Nov 2001
    Location
    Yewston, Texis
    Posts
    240
    You can change the font color through HTML tags. For example <font color=#ff0000>This is red</font>

    and

    <font color=#00ff00>This is green</font>.

    BTW, do you listen to Cidade, Sao Paulo? I used to but now I listen to Cidade, Rio de Jeneiro. Both are great.

    cudabean

  7. #7
    scoutt
    Guest
    Originally posted by dosgrave2000
    Hi,

    the timeout problem has been solved, changinc php.ini

    there's some error trapping routines, just want to make some color changing... how would i do to use ANSI Color codes in php?

    tia
    lets see one of those error trapping routines?

Posting Permissions

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



Click Here to Expand Forum to Full Width