Posts picking up old Permalinks, how to reset?
There seems to be a bug in the Yoast Plugin, which was fixed by switching on to the NavXT Plugin to do breadcrumbs instead.
There seems to be a bug in the Yoast Plugin, which was fixed by switching on to the NavXT Plugin to do breadcrumbs instead.
By default in WordPress if you create a new post, or custom post type based on post, and fill in the title but no body and press “Publish” it will save it as a draft instead of actually publishing it. If the post is saved as a draft it won’t show up in your list … Read more
I accidentally got the answer: <?php global $post; $the_post_parent = $post->post_parent; $the_post_ID = $post->ID; $cat_posts = get_posts(‘post_type=bbp_forum&posts_per_page=-1’); print_r($post_parent); ?> <?php foreach ( $cat_posts as $post ) : ?> <li <?php if ( $post->ID == $the_post_ID || $post->ID == $the_post_parent ) echo ‘class=”current”‘; ?>> <a href=”https://wordpress.stackexchange.com/questions/13966/<?php the_permalink(); ?>” title=”<?php printf( esc_attr__( ‘Permalink to %s’, ‘twentyten’ ), … Read more
There are two approaches to my question, that are both useful. They were provided by @goldenapples and @Bainternet. Custom Post Type Data in Sidebar widgets? How to quickly switch custom post type singular template?
The get_the_terms() returns a list of term objects. So first of all, you need to treat the output as a list rather than a single element. The name you’re looking for is stored in the name field. $artistnames = get_the_terms($post->ID, ‘artist’); if (!empty($artistnames)) : ?> foreach ($artistnames as $obj) { $name = $obj->name; // Do … Read more
you need a global $post; within that function before trying to access the contents of $post.
I wonder if adding ‘posts_per_page’ => XXX to your query would give the desired results? Just a thought. Good luck!
If you want to reach the “single” page of a custom post type (or even a regular post), you can do this by going to http://example.com?p=[post_id]&post_type=[post_type_name]. If you use Pretty permalinks WordPress will redirect you to the “canonical” link, which may look like http://example.com/my-post-type/my-post-name/. So by changing the target of your form and the post_id … Read more
Try re-generating the permalinks structure. And check that you have the correct urls in the general options (WPURL and URL)
You are missing the declaration of the HTML select tag which options are his children so just add something like this: function myplugin_inner_custom_box() { // Use nonce for verification wp_nonce_field( plugin_basename( __FILE__ ), ‘myplugin_noncename’ ); // The actual fields for data entry echo ‘<label for=”myplugin_new_field”>’; _e(“Description for this field”, ‘myplugin_textdomain’ ); echo ‘</label> ‘; echo … Read more