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

Image resize
Hi again fellers

I managed to sort out the issues with the folder,

Final hurdle is th

array_map() probably obvious mistake
The code below is part of a class to escape strings, but should also accept an array, using array_ma

DataTable Help Required
Hi all I am creating an app that utilises and MS Access back end and queries it quite a bit at vario

string to currency format
Hi guys...

Actually I chunk out some data from txtfile and one of the data contains amount va

Insert data in Mysql and move to another page
I'm stuck with this simple problem. I need to insert data in Mysql and then hit submit and move to a

Do something every fifth time?
I'm trying to write a loop, but I want it to do something different after every fifth instance. Like

Question handling xml data
Hello,

I have sucessfull followed this tutorial
http://www.phpfreaks.com/tutorial/handlin

Web Host List
Here is a list of web hosts that offer PHP and MySQL. It is no where near a full list, but it is mos

PHP onsubmit in the form not going to the fuction.
I have a form through ‘onsubmit’ calling a function validation(). But not going to the

I got my hosting suspended XD
So I saw this challenge a day or so ago

http://www.programming-challenges.com/pg.php?page=dow

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