corsasport.co.uk
 

Corsa Sport » Message Board » Off Day » Geek Day » php question - need more help :(


New Topic

New Poll
  Subscribe | Add to Favourites

You are not logged in and may not post or reply to messages. Please log in or create a new account or mail us about fixing an existing one - register@corsasport.co.uk

There are also many more features available when you are logged in such as private messages, buddy list, location services, post search and more.


Author php question - need more help :(
Dom
Member

Registered: 13th Sep 03
User status: Offline
   21st Jan 05 at 21:22   View User's Profile U2U Member Reply With Quote

if i had a php string, $html = "<font face=""arial"">$text</font>";, and i assinged hello to $text, would it get printed if i did an echo of $html?

i know this is basic, but i cant find anything by doing a google abit this

tar,
Dom

Edit - new question at bottom

[Edited on 22-01-2005 by Dom]
Smiffie
Member

Registered: 26th Feb 04
User status: Offline
21st Jan 05 at 21:24   View User's Profile U2U Member Reply With Quote

change from ur last question
Dom
Member

Registered: 13th Sep 03
User status: Offline
21st Jan 05 at 21:26   View User's Profile U2U Member Reply With Quote

quote:
Originally posted by Smiffie
change from ur last question

hahahaha...im tired and not thinking right mate

answer the question though
Smiffie
Member

Registered: 26th Feb 04
User status: Offline
21st Jan 05 at 21:27   View User's Profile U2U Member Reply With Quote

quote:
Originally posted by Dom
quote:
Originally posted by Smiffie
change from ur last question

hahahaha...im tired and not thinking right mate

answer the question though


sorry, i can't give u any kind of educated answer
Dom
Member

Registered: 13th Sep 03
User status: Offline
21st Jan 05 at 21:28   View User's Profile U2U Member Reply With Quote

quote:
Originally posted by Smiffie
quote:
Originally posted by Dom
quote:
Originally posted by Smiffie
change from ur last question

hahahaha...im tired and not thinking right mate

answer the question though


sorry, i can't give u any kind of educated answer


GTF then you dumbass biatch ...no really, you dont know?? its doing my head it and i cant be asked to try it out because i know my current script is gonna chuck out errors all over the place
Smiffie
Member

Registered: 26th Feb 04
User status: Offline
21st Jan 05 at 21:31   View User's Profile U2U Member Reply With Quote

i know SFA about scripting dude
Laney
Member

Registered: 6th May 03
Location: Leeds
User status: Offline
21st Jan 05 at 21:32   View User's Profile U2U Member Reply With Quote

quote:
Originally posted by Dom
if i had a php string, $html = "<font face=""arial"">$text</font>";, and i assinged hello to $text, would it get printed if i did an echo of $html?

i know this is basic, but i cant find anything by doing a google abit this

tar,
Dom


<font face="arial">$text</font> would be printed IIRC

Try making it $html = "<font face='arial'>".$text."</font>" ?
Dom
Member

Registered: 13th Sep 03
User status: Offline
21st Jan 05 at 21:33   View User's Profile U2U Member Reply With Quote

quote:
Originally posted by Laney
quote:
Originally posted by Dom
if i had a php string, $html = "<font face=""arial"">$text</font>";, and i assinged hello to $text, would it get printed if i did an echo of $html?

i know this is basic, but i cant find anything by doing a google abit this

tar,
Dom


<font face="arial">$text</font> would be printed IIRC

Try making it $html = "<font face='arial'>".$text."</font>" ?


nice one boss
Tim
Site Administrator

Avatar

Registered: 21st Apr 00
User status: Offline
21st Jan 05 at 21:33   View Garage View User's Profile U2U Member Reply With Quote

Yes... but you really should either escape the double quotes with a backslash, or just use single quotes (so it gets processed correctly and is a bit more readable)...

ie. $html = "<font face='Arial'>$text</font>";

or

$html = "<font face=\"Arial\">$text</font>";


[Edited on 21-01-2005 by Tim]
Dom
Member

Registered: 13th Sep 03
User status: Offline
21st Jan 05 at 22:09   View User's Profile U2U Member Reply With Quote

quote:
Originally posted by Tim
Yes... but you really should either escape the double quotes with a backslash, or just use single quotes (so it gets processed correctly and is a bit more readable)...

ie. $html = "<font face='Arial'>$text</font>";

or

$html = "<font face=\"Arial\">$text</font>";


[Edited on 21-01-2005 by Tim]


tar mate, that actually solved a load of errors that came up
Dom
Member

Registered: 13th Sep 03
User status: Offline
22nd Jan 05 at 00:02   View User's Profile U2U Member Reply With Quote

right have a string with html code in it (ie :$string = "<font face=\"$strFace"\>", have also tried "face="" . $strFace . "\ etc) and basically when i call it up later to change the the value of $strFace (ie: $strFace = "Arial";, echo $string, it doesnt seem to change the $strFace value in $string.

Anyone no how to solve this?

only solution i can think of is to split the $string into two and then wack the changing value inbetween the two split strings when outputed etc etc - but there must be another way

tar,
Dom

[Edited on 22-01-2005 by Dom]

 
New Topic

New Poll

  Related Threads Author Forum Replies Views Last Post
Forums! tiptoptim Help Zone, Modification and ICE Advice 6 1652
15th Jun 04 at 10:16
by tiptoptim
 
i need help to get car ready for summer N90ATH Help Zone, Modification and ICE Advice 3 1640
17th Jun 04 at 05:16
by LukeGSi
 
three quick questions red_12v Help Zone, Modification and ICE Advice 17 2072
31st Jul 04 at 18:24
by red_12v
 
Nitrous Q? blundey Help Zone, Modification and ICE Advice 8 1778
25th Aug 04 at 21:58
by blundey
 
Will this work? Calum1577 Help Zone, Modification and ICE Advice 1 1538
5th Dec 04 at 11:33
by Dom
 

Corsa Sport » Message Board » Off Day » Geek Day » php question - need more help :( 28 database queries in 0.0131152 seconds