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

extract a file from zip file
hi,
i know how to unzip a zip file in php, but is there a way to just extract a certain file only

the problem with str_replace
$str="hahahahahahahahahahahahahaha";
$nn=1;
$str=str_replace('ha','MyGod',$str,$nn);

Xacute search within SQL results
I have a query that is pulling data, and I want to return a specific value from the results of that

how to make database item unique
Hey guys,

is it possible to do this:

I have the database item $title being pulled for

Breaking results into week blocks
I have a set of dates (and times), which are returned from a mySQL query.

These usually span

Got A Free Server :(
So I was given a free server

http://shopping.yahoo.com/p:Compaq%20ProLiant%201500%20Server:1

php/mysql problem
Hey all,

Problem: im trying to setup a shop where people can use a drop-down list to select t

Beginners syntax and loop questions - help please!
Hi everyone,

I have some problems with php code. I'm currently in the middle of learning php,

Database 'Validation'
Hi everyone,
I'm trying to validate the password entered by the user with the password in the dat

Forms Authentication and Refresh at Login page
Hello, When I try to press the Login button in my webapplication at my login.aspx page nothing h

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