Count


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

Getting the same count everytime

Code:
$visitquery = mysql_query("SELECT COUNT(*) FROM visitors WHERE ownerkey = '$uuid' & region = '$selected' AND `date` < DATE_ADD(CURDATE(), INTERVAL +7 DAY)", $connect);
Did you know?Explore Trending and Topic pages for more stories like this.
$row9 = mysql_fetch_array($visitquery);
$visitoramount = $row9[0];
print "[$visitoramount] visits in the last 7 days!";
If $selected = "Blah" it gives the count as " 8"
if $selected = "Dumb" it gives the count as "8" ... Al though there is no "Dumb" in the db.

Sorry if my explaining is off. Just dont know another way to explain it easier.
No comments posted yet

Your Answer:

Login to answer
309 Like 18 Dislike
Previous forums Next forums
Other forums

Any help with my email script?
I have an email script, I have not tested it, although someone tested it for me and said it worked f

Javascript form submit and radio buttons?
When this form is submitted, it is automatically resubmitted using JS.

All my fields are carr

How to ... (FAQs)
... get e-mail notifications As several people asked how to get e-mail notifications when new posti

Is there a more efficient way to code this than what I have?
I have three associative arrays.

$combinedSettings
$userSettings
$defaultSettings

Displaying data from MySql a different way
Hi all,
I'm pretty new to php and MySql and have hit a problem.

I am able to display data

Add User script "Could not execute query"
This should be an easy script but I can't get it to run. Can someone please help me?

<

Upload Code Help
Hi everyone I need some help with a bit of code ive been working with for a while. I am completely s

Add trigger to UpdatePanel programmatically
Hi,I'm working on a website which uses AJAX and Masterpages. What I have is an AJAX UpdatePanel whi

How can I uploading Transactional Data from Legacy to New SAP system
Hell Gurus,

I am overwhelmed with questions on how to migrate huge volume of Sales Orders

Points for Wiki contribution
Hi everyone,

I want to know how long does it take for the moderator to award points for 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