Backend – Categories and Menus conflicts
Backend – Categories and Menus conflicts
Backend – Categories and Menus conflicts
You could try $slidercategories_array = array(3,5,6,9,10,11,12,23,24,27); $in = implode( ‘,’, array_map( ‘absint’, $slidercategories_array ) ); global $wpdb; $sql = $wpdb->prepare( ‘SELECT tt.term_id, MAX(p.post_date) AS max_date FROM ‘ . $wpdb->term_taxonomy . ‘ AS tt ‘ . ‘ JOIN ‘ . $wpdb->term_relationships . ‘ AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id’ . ‘ LEFT JOIN ‘ . $wpdb->posts … Read more
Some of your resources are not loading properly, even on your main domain. Using Google Chrome, load your main page, open the Elements Panel by hitting the F12 key. In the panel that opens, look in the upper right corner. There will be a red X with a number next to it. That shows you … Read more
I presume there is an open option html element before that code provided. After that select tag is opened and before you run through that loop echo out a blank option with value=””
I bet you have a page named “Blog” with a slug “blog” in your system too? You can’t have that with the permalink structure you have created because the permalink for this page would also be /blog/ and therefore cause a conflict. Try changing the slug of the page “blog” to something else.
Did you try: function exclude_category($query) { if ( is_page(‘slug-of-page’) && isset($query) ) { $query->set(‘cat’, ‘-3’); } return $query; } add_filter(‘pre_get_posts’, ‘exclude_category’);
The way you’re appending a foreach loop to a variable is not possible. Try this: $form_fields[“custom4”][“html”] = “<select name=”attachments[{$post->ID}][custom4]” id=’attachments[{$post->ID}][custom4]’>”; foreach ($categories as $category) { $form_fields[“custom4”][“html”] .= ‘<option value=”$category”>’ . $category . ‘</option>’; } $form_fields[“custom4”][“html”] .= “</select>”;
ok folks, i did it anothere way.. here’s how i did it: add_filter( ‘pre_get_posts’, function( $query ) { if( ! is_main_query() || ! is_post_type_archive() || ! $query->get( ‘section’, false ) ) return $query; global $wpdb; $section = $query->get( ‘section’ ); unset( $query->query[‘section’] ); unset( $query->query_vars[‘section’] ); $query->tax_query = false; $query->set( ‘tax_query’, false ); $cateroties = … Read more
You should create a taxonomy template, not a category. I suspect that you have misunderstanding about categories, terms and custom taxonomies. I would suggest that you read my post on this particular subject here Study the taxonomy template hierarchy in the linked page in your question As for the 404 page, you most probably haven’t … Read more
WordPress has a pretty good inbuilt bulk editing system. Just select all the products/post for each category and select bulk edit from the menu where you’d normally see more to trash.