Jump to content

Simple if Statement! Please Help.


jamjam

Recommended Posts

Hi

 

I am developing a page that has this PHP code <?php echo $row_Programme['status']; ?>

This code basically looks in a MySQL database table and echo’s the value of the status field.

 

The value of the Status field will only ever have 5 possible values.

I want to add an ‘if statement’ to the above code.

So for example if the value returned by the code was “Coming Soon”

I can add something like “Programme will be available soon”

 

A second example would be if the value returned by the code was “Not Available”

I can add something like “Sorry programme is not available”

 

This properly really basic PHP.

But am really new to this and will really appreciate the assistance.

 

Thanks in advance.

 

Link to comment
https://forums.phpfreaks.com/topic/209439-simple-if-statement-please-help/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.