On Mon, 17 Jan 2005 16:11:54 +0530, Anish Kumar K.
<[EMAIL PROTECTED]> wrote:
> Hi I need help regarding substituion of varaibles with values
> 
> Say I have a txt file (a.txt)
> 
> which has only one line:
> Hi $name

Don't think of $name as a perl variable, but as a placeholder. It
looks better if you use something like __NAME__. ie
Hi __NAME__

For substition, you simply use:
s/__NAME__/$var/;

Tor

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to