PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
kevrelland
Forum Commoner
Posts: 73 Joined: Mon Jan 08, 2007 7:41 am
Post
by kevrelland » Wed Feb 11, 2009 6:56 am
can anyone help me the prod price is not showing inside my conditional region, and i can't think why?
Code: Select all
<?php if ($row_product_listing['prod_special'] == y)
{
echo ' <p class="price_special">Offer price £<?php echo $row_product_listing["prod_price"]; ?></p> ';
}
?>
Cheers
Kevin
papa
Forum Regular
Posts: 958 Joined: Wed Aug 27, 2008 3:36 am
Location: Sweden/Sthlm
Post
by papa » Wed Feb 11, 2009 7:29 am
Code: Select all
<?php
if($row_product_listing["prod_special"] == y) {
echo ' <p class="price_special">Offer price £'.$row_product_listing["prod_price"].'</p> ';
}
?>
Well you already have the php tags open so no need to open them again. And be consequent with your " " and ' '.
kevrelland
Forum Commoner
Posts: 73 Joined: Mon Jan 08, 2007 7:41 am
Post
by kevrelland » Wed Feb 11, 2009 7:37 am
Brilliant thanks
works a treat
kev
papa
Forum Regular
Posts: 958 Joined: Wed Aug 27, 2008 3:36 am
Location: Sweden/Sthlm
Post
by papa » Wed Feb 11, 2009 7:42 am
no probs!