Simple AND question


Posted on 16th Feb 2014 07:03 pm by admin

Hello,

I've got following code:

Code: if(strpos($row[13],"http://")!==false) $info['results'][$num]['player']="PREVIEW";
else $info['results'][$num]['player']="NO PREVIEW";
and would like to add following AND statement
Code: AND ($media=="mp3")
Can someone advice me how to do please?

I'm getting following error: "unexpected T_LOGICAL_AND" in my code below.

Code: if(strpos($row[13],"http://")!==false) AND ($media=="mp3") $info['results'][$num]['player']="PREVIEW";
else $info['results'][$num]['player']="NO PREVIEW";
Thank you

No comments posted yet

Your Answer:

Login to answer
345 Like 43 Dislike
Previous forums Next forums
Other forums

How to use Ajax to verify data on a DB ?
Hello everyone, well i want to know how to check a value if it exists or not on a Data base and capt

Dynamically allocating the number of rows in a table based on a variable value
Hi,
I have situation here which i cannot resolve, I have a variable temp which stores the num

Email Processor
I have a few questions so this post will be a larger one! Sorry, but I'm a bit of a PHP newbie so be

FROM_UNIXTIME($phpdate);
Hello,

I tried to use this :

$date = FROM_UNIXTIME($phpdate);

ANd I was t

Lining up columns nicely.
Hello everyone, I'm having problems with making columns line up properly. Here is my code:

MySQL issue
I am taking sentences through a form on page. Then checking some condition and trying to insert them

First root of a number
Hi,

I can't find any function in php to give me the first root of a number.
Is there any

Javascript using window.location seems to lose state
Not sure what forum so let me know if I'm in the wrong place. I have a main window with a ajax grid

Filename like the user name
I am creating a form and storing the values in file. Could anyone please tell me how to write a code

Help with form post data and arrays
Hi all,

I am new to this forum... It has been awhile since i have worked with arrays, and i a

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash