Adding color to text

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

LTLhawk
New php-forum User
New php-forum User
Posts: 29
Joined: Fri Mar 07, 2003 4:17 pm

Adding color to text

Postby LTLhawk » Mon Mar 10, 2003 11:28 am

I guys,

I know this is probably a basic question for you peeps, but I am just starting with php so I have a lot to learn.

I want to print some text to the screen, but I want to change the color (anything but black..lol)... how do I do this.

print "level0.Load.Count=$NewCount";

thanks
Last edited by LTLhawk on Mon Mar 10, 2003 1:31 pm, edited 1 time in total.

User avatar
Redcircle
Moderator
Moderator
Posts: 830
Joined: Tue Jan 21, 2003 10:42 pm
Location: Michigan USA
Contact:

Postby Redcircle » Mon Mar 10, 2003 12:07 pm

That really has nothing to do with php. It is standard html.

LTLhawk
New php-forum User
New php-forum User
Posts: 29
Joined: Fri Mar 07, 2003 4:17 pm

Postby LTLhawk » Mon Mar 10, 2003 1:35 pm

well ok.. i understand that. I just dont know how to mix the php and the html together for this..

thanks for the reply

SmartAssDan
New php-forum User
New php-forum User
Posts: 5
Joined: Sun Mar 09, 2003 4:33 pm

Postby SmartAssDan » Mon Mar 10, 2003 2:19 pm

think of it this way:

php is a "behind the scenes" thing.

html is "the show"...


so, you can use php to print out your html... in other words:

Code: Select all

print "<html><body>hello world</body></html>";


will work for you...


php is just a very useful way to "generate" your html. say you want to read a file from somewhere, and put that in your website. you can't do that with html. but you can with php.


you need to learn some html, there is no substitute.


(btw, the html that you wanted would be something like

Code: Select all

<font color=red>text</font>
(where 'red' can be replaced with whatever color you chose [which must be recognized by html], and 'text' can be replaced with any text you want.)

LTLhawk
New php-forum User
New php-forum User
Posts: 29
Joined: Fri Mar 07, 2003 4:17 pm

Postby LTLhawk » Mon Mar 10, 2003 3:21 pm

thanks smartass....nice name by the way...I like it..lol

thats the iunfo I was looking for..this is all new so I have a lot of learning to do


Return to “PHP coding => General”

Who is online

Users browsing this forum: Bing [Bot] and 2 guests