daniel4ing
Forum Replies Created
Viewing 5 replies - 1 through 5 (of 5 total)
-
Forum: Fixing WordPress
In reply to: Multiple loops on frontpage with custom field queriesGot the result, took me long enough…heh
SELECT DISTINCT wposts.* FROM $wpdb->posts wposts, $wpdb->postmeta wpostmeta, $wpdb->postmeta wpostmeta2, $wpdb->postmeta wpostmeta3 WHERE wposts.ID = wpostmeta.post_id AND wposts.ID = wpostmeta2.post_id AND wposts.ID = wpostmeta3.post_id AND wpostmeta.meta_key = 'product_featured' AND wpostmeta.meta_value = '1' AND wpostmeta2.meta_key = 'product_start_date' AND wpostmeta2.meta_value < '" . date("Y-m-d") . "' AND wpostmeta3.meta_key = 'product_end_date' AND wpostmeta3.meta_value > '" . date("Y-m-d") . "' AND wposts.post_type = 'products' AND wposts.post_status = 'publish' GROUP BY IDThanks for the help Mac 🙂
Forum: Fixing WordPress
In reply to: Multiple loops on frontpage with custom field queriesThanks for the reply vtxyzzy
All 3 meta_key and meta_value queries work separately, just not combined…
Forum: Fixing WordPress
In reply to: Multiple loops on frontpage with custom field queriesI’ve adjusted the date format, but still the same result.
Forum: Fixing WordPress
In reply to: Multiple loops on frontpage with custom field queriesThe date format I’m using is d-m-Y though, why would I have to check it in the Y-m-d order?
Forum: Fixing WordPress
In reply to: tag plus tagAye, I might have not put it in the right section but I’m not sure this is the right section either… hehe
Viewing 5 replies - 1 through 5 (of 5 total)