-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

* and then Kunal Jhunjhunwala blurted....
> hey... im tryint to lay some conditions for the html output... example :
> if ($check  == 1) {
> <some html>
>                             }
> else {
>     <some other html>
>     }
> 
> The problem here is, I want the html in both cases to be customisable by the
> user... so I would have to make it a part of the template file... and if i
> do that, even if the conditions fail, the html will show up..any ideas on a
> fix for this?

I'm not 100% certain I understand your Q. but how about this:
I take it from the subject you are using a PHPLib template so if you
were to have a teplate var called {htmlOutput} you could do this, 

if($check=1) {
    $htmlOutput=<<<EOF
    <your html here>
    EOF;
} elseif($check=2) {  
    $htmlOutput=<<<EOF
    <your altenate html here>
    EOF;
} else { 
    $htmlOutput=<<<EOF
    <your default html here>
    EOF;
}

and then in your template code.....

$t->set_var("htmlOutput", $htmlOutput);

Hope that's what you mean
- -- 

Nick Wilson

Tel:    +45 3325 0688
Fax:    +45 3325 0677
Web:    www.explodingnet.com



-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)

iD8DBQE8UtA5HpvrrTa6L5oRAr/TAJ0RBC3OzWQashl7fFc0e9wcrow6LgCdFjY1
xjqg6qEwLRKI+R4g0NWYRoM=
=haum
-----END PGP SIGNATURE-----

-- 
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]

Reply via email to