faqts : Computers : Programming : Languages : PHP : kms : General

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

5 of 10 people (50%) answered Yes
Recently 4 of 9 people (44%) answered Yes

Entry

How do I replace variables referenced within a string, when the string itself is also a variable?

Feb 8th, 2002 12:29
Michael Wales, Jim Lincoln,


<?
  $string = ereg_replace("$oldvar", "$newvar", $string);
?>