I have a mysql table set up like this:
idsubjectbodyuseriddatetimetags1blog subjectblog body111|29|20099|30|AMblog,site news,tech
when displaying the data i want to be able to add "?id=blog&tags=blog,tech" to the url to search for multiple tags.
i'm pretty close with this:
Code: if (isset($_GET['tags'])) {
$tags = addslashes($_GET['tags']);
$srchinfo = "WHERE tags IN ('$tags')";
};
$result = mysql_query("SELECT * FROM blogs $srchinfo ORDER BY id DESC LIMIT $offset, $rowsPerPage");
but, when using the url, it will only show up posts that have one of the tags.
For example:
Post1: site news, blog
Post2: blog
Post3: blog,site news
"?id=blog&tags=blog" Only shows Post2
"?id=blog&tags=site news, blog" Only shows Post1
Anyone know what to do?
Thank you.
Change of partner analyse in sales orders
Hello,
Help with php code
Hello, can anyone tell me why this php word trap fails to work, and the trigger words get blow right past, and the comments get posted anyway?heres the php code im testing on a
cookie problem
I hv a website url In this site main menu functionality based on cookie when user click on particular menu the visited menu change its color and cookie is created for that menu and when user click on
[Need Help] php timing issues
I don't know what is going wrong. I need some help with being able to set an image at 9:00am Colorado time if my server is in California and it would be 8:00am. I tried to echo the image below, but
array empty
Hiya peeps,Ok here is the codes.order.phpCode: <?php if(!isset($_POST) OR empty($_POST)) { echo
PHP Multiples of 2, Show posts...not working (wordpress)
I have been using this code to show div.example with 6 li columns inside it, each li is a post with its info inside.Once it gets to the 6th li it closes the div.example and starts a new one. This to
Blank record injected into database
I always found several blank records inside my database, although $SESSION is required to insert the data into database.Why can this happen? how to prevent this?
mod_rewrite.c on windows ??
why it's not working on windows while it's working on other hosts??? this is the code i got from a tutorial :Code: [Select]<IfModule mod_rewrite.c>RewriteEngine OnRewriteBase
search function
HI guys,if anyone could point us in the right direction of how to do this, or provide some test code for a similar problem would be great!Basically, I have user profiles on my site, and I have a
SAP FICO learning materials
Hi all,