Re: PHP/HTML
- From: Geoff Berrow <blthecat@xxxxxxxxxxx>
- Date: Thu, 30 Mar 2006 13:07:35 +0100
Message-ID: <442bb9b7$0$10505$ba624c82@xxxxxxxxxxxxxxxxxxx> from Lau
Lauritzen contained the following:
<?php
if($form_errorlist): ?>
Please correct the following errors:<BR>
<UL>
<?php foreach($form_errors as $val): ?>
<LI><?=$val?> // Here is the problem
<?php endforeach; ?>
</UL>
<?php endif; ?>
You have coded assuming short tags are enabled and they may not be.
You have $form_errorlist and $form_errors. Are they two separate
variables?
Also I've never used that syntax so I will substitute what I normally
use.
Try:
<?php
if($form_errorlist){ ?>
Please correct the following errors:<BR>
<UL>
<?php foreach($form_errors as $val){ ?>
<LI><?php echo $val; ?> </LI>
<?php }?>
</UL>
<?php } ?>
<?php
if($form_errorlist){
echo ' Please correct the following errors:<BR>\n<UL>';
foreach($form_errors as $val){
echo "<LI>$val</LI>";
}
echo '</UL>';
}
?>
--
Geoff Berrow 0110001001101100010000000110
001101101011011001000110111101100111001011
100110001101101111001011100111010101101011
.
- Follow-Ups:
- Re: PHP/HTML
- From: robert
- Re: PHP/HTML
- From: Geoff Berrow
- Re: PHP/HTML
- References:
- PHP/HTML
- From: Lau Lauritzen
- PHP/HTML
- Prev by Date: Re: PHP/HTML
- Next by Date: Re: PHP/HTML
- Previous by thread: Re: PHP/HTML
- Next by thread: Re: PHP/HTML
- Index(es):
Relevant Pages
|