in reply to Re: Correct Syntax
in thread Need help getting correct syntax for "if" statement

You'll probably laugh but
How do I embed that in the form
if ($ag eq "*********") {print " <form action=FormMail.pl method=post name=accept_estimate_cost target= +_self id=accept_estimate_cost> <input type=hidden name=job_number value= > {print qq[<input type="hidden" name="phone_number" value="$ph">]; <input type=hidden name=phone_number value= $ph >

Replies are listed 'Best First'.
Re: Re: Re: Correct Syntax
by Juerd (Abbot) on Aug 09, 2002 at 08:02 UTC

    You're *guessing* syntax again. That will not work. Not today, not ever. If you have to ask for help for things like this, stop asking and start *learning*. You do not learn a language only by trying something, hoping the receiving end will be able to decrypt your illogical grammar. You will have to read documentation *before* you start programming. perlintro is a good start, but don't stop there.

    Sane programming cannot be done with the copy/paste function.

    If you're not willing to learn basic syntax rules, just please stop asking these stupid questions.

    - Yes, I reinvent wheels.
    - Spam: Visit eurotraQ.
    

Re^3: Correct Syntax
by tadman (Prior) on Aug 09, 2002 at 00:23 UTC
    If you mean "in the form" in the "right in the HTML" sense, you may need to use something like Text::Template to put this kind of functionality in there.

    If you mean in the context of CGI, then the idea is simply to output bits of HTML, one after the other. In this case, you're merely printing a part conditionally.