grabbing data and displaying an image
i am attempting to grab roughly 40 pieces of data that is a combination of 0 and 1 flags from mysql. based off of the 0 or 1... either pictA or pictB will be displayed.
can someone please assist me in evaluating my code? i believe the logic is incorrect. PHP Code:
|
Ummm ... w/ the square brackets in the if and the condition
tacked onto the else I'm wondering why it would produce anything at all; that doesn't look like valid PHP. Cheers, Tink |
apologies, the code is actually written in bash.
Code:
$status = `mysql -u username -ppassword -h x.x.x.x -e 'SELECT help FROM table' database`; |
What is declare? is that a bash statement
|
Quote:
Second you try to assign a index variable using $status. $status is not an integer. it will be a series of strings. First set returned are the column names of the table. next comes the rows of the table. |
All times are GMT -5. The time now is 05:41 PM. |