dbugger
Forum Replies Created
-
Forum: Plugins
In reply to: [Custom Block Builder - Lazy Blocks] Define blocks just with codeWhat I want is to have the definition of my custom blocks linked to the code of my theme directly, so that if the theme gets activated/installed, the blocks will be available, without having to import anything.
I will try again the screenshot: https://bit.ly/3h1qPiZ
Forum: Plugins
In reply to: [Custom Block Builder - Lazy Blocks] Define blocks just with codeYes, they can be exported to PHP, but that only is useful to import them back into another system, no?
Can I do it, even if I am using a free version?
Forum: Plugins
In reply to: [WordPress Popular Posts] All the links point to the same postThanks! I did not know that!
Forum: Plugins
In reply to: [WordPress Popular Posts] All the links point to the same postThis is the function for building the custom HTML in functions.php:
function my_custom_popular_posts_html_list( $mostpopular, $instance ){ ?> <div class="popular-pages"> <?php // loop the array of popular posts objects foreach( $mostpopular as $popular ) { $author = get_the_author_meta('display_name', $popular->uid); $date = date_i18n($instance['stats_tag']['date']['format'], strtotime($popular->date)); $excerpt = get_excerpt_by_id( $popular->id ); ?> <div class="popular-page"> <h2 class="title"> <a href="<?php the_permalink( $popular->id ) ?>"> <?php echo $popular->title; ?> </a> </h2> <div><?php echo $date; ?> | <?php echo $author; ?></div> <?php echo $excerpt; ?> <a class="more-link" href="<?php the_permalink( $popular->id ) ?>"> > Mehr erfahren </a> </div> <?php } ?> </div> <?php }
Forum: Plugins
In reply to: [WordPress Popular Posts] All the links point to the same postMay I send it to you through a more private channel? It is rather big customer. My twitter is @enriquemoreno. I will give you other contact data if you need it.
Sadly I did not find a solution. I proposed to add this functionality to Types in their forum, and they told me they would add it to their TO DO, but I haven’t heard back from them yet ??
Forum: Plugins
In reply to: [Media Library Categories] New images aren't automatically in "Uncategorized"+1
Forum: Plugins
In reply to: [Media Library Categories] New images aren't automatically in "Uncategorized"I have fixed this issue here:
// Handle default category of attachments without category add_action('add_attachment', 'emt_set_attachment_category'); add_action('edit_attachment', 'emt_set_attachment_category'); function emt_set_attachment_category( $post_ID ) { // if attachment already have categories, stop here if( wp_get_object_terms( $post_ID, 'category' ) ) return; // no, then get the default one $post_category = array( get_option('default_category') ); // then set category if default category is set on writting page if( $post_category ) wp_set_post_categories( $post_ID, $post_category ); }
Jeffrey, could you add this code to the plugin?
Forum: Fixing WordPress
In reply to: MultisiteThey are multiple separate installs of WP
Forum: Fixing WordPress
In reply to: comment_form outputThanks!