What do you mean? Do you want to change the variable to $dwg1 then $dwg2 then $dwg3 or what? A variable is a place for holding information. If you want the same data under a different name then create a new variable equal to the old variable then unset the original. $dwg[0] = $dwg; unset($dwg); for ($i = 1; $i < $max; $i++) { $dwg[$i] = $dwg[$i - 1]; ... } Tim Ward Senior Systems Engineer Please refer to the following disclaimer in respect of this message: http://www.stivesdirect.com/e-mail-disclaimer.html > -----Original Message----- > From: Gary [mailto:[EMAIL PROTECTED]] > Sent: 19 March 2001 01:36 > To: [EMAIL PROTECTED] > Subject: dynamically change a variable name > > > Is there a way to dynamically change a variable name? For example: > I want to change the variable name $DWG to > $DWG1 > $DWG2 > $DWG3 > with a for loop. Is there a way to do this? > > Thanks, Gary > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]