Remove divs and spans from post content

Im not sure what you are actually doing here but I think you are looking to create a block of code from the post content then strip unnecessary tags. I would use strip tags: https://www.w3schools.com/php/func_string_strip_tags.asp <?php require “wp-config.php”; // Post Types to include $args = array( ‘posts_per_page’ => ’50’, ‘post_type’ => array( ‘product’, ‘product-variation’ ) … Read more

Problem with ms-thumb-frame-selected class in Master Slider

Seems you are simply overwriting #masterslider .ms-thumb-frame-selected with each loop. So in the end only the last iteration will take effect. You maybe need to add the post ID as class somewhere as well and then target #masterslider .ms-thumb-frame-selected .post-<?php echo $post->ID; ?> { } in your CSS. Adjust your markup inside The Loop to … Read more

Is there a visual editor specifically for page snippets/sections?

I found that this can be done simply by using WordPress’ Page editor. Nothing else is needed: Compose the content in WordPress’ Page editor Save (but don’t publish) In your code, retrieve the saved content By ID: $id=47; $post = get_post($id); $content = apply_filters(‘the_content’, $post->post_content); echo $content; Or by page title: $title=”page title”; $page = … Read more

Auto Sorting List Alphabetically

I was able to fix this by adjust my call slightly. instead of using jQuery(document).ready(function () { sortUL(“#sortList”); }); I used jQuery(window).on(“load”, function() { sortUL(“#sortList”); }); seems that either SHOULD have worked, but this worked for me nonetheless

Bulk edit for custom taxonomy

What you are looking for is custom taxonomy (which has been mentioned in the comments). Which you create with the register_taxonomy() function. There is a beginners guide here if you need it. You will need to pass in an array of arguments. The most important is probably hierarchical which is true for something like categories, … Read more