LumberHack
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: User register with the roleHey Im not sure Im following this bit
My requirement is role based account confirmation approval.
A user registers on the site and is made Author by default. What exactly are we trying to achieve at this point ?
Hey Nafisa, I dont speak French but we have a dedicated forum for French support. It can be found here.
Please copy paste this there and someone will help you 🙂
Passez une bonne journée
Forum: Fixing WordPress
In reply to: display custom posts ‘movies’ with a custom taxonomy ‘drama’Hmm .. then can you try this code ? TBH I still cant understand how you’ve structured this on your site.
<?php args = array( 'post_type' => 'movie', 'tax_query' => array( array( 'taxonomy' => 'genre', 'field' => 'slug', 'terms' => 'drama', ), ), ); $loop = new WP_Query($args); if($loop->have_posts()) { echo '<h2>'. 'Drama' .'</h2>'; while($loop->have_posts()) : $loop->the_post(); echo '<a href="'.get_permalink().'">'.get_the_title().'</a>'; endwhile; } wp_reset_query(); ?>Forum: Fixing WordPress
In reply to: display custom posts ‘movies’ with a custom taxonomy ‘drama’Just to clarify is the post type
movieorgenre, I see you’ve got it different in your example and post.If its
moviethen re-write it as<?php $custom_terms = get_terms('drama'); foreach($custom_terms as $custom_term) { $args = array('post_type' => 'movie', 'tax_query' => array( array( 'taxonomy' => 'drama', 'field' => 'slug', 'terms' => $custom_term->slug, ), ), ); $loop = new WP_Query($args); if($loop->have_posts()) { echo '<h2>'.$custom_term->name.'</h2>'; while($loop->have_posts()) : $loop->the_post(); echo '<a href="'.get_permalink().'">'.get_the_title().'</a>'; endwhile; } wp_reset_query(); } ?>Forum: Networking WordPress
In reply to: Multi-site, error connection timed out. Tried everythingThis clearly points to something eating up more resources than it should or that you’ve outgrown your hosting package.
Can you install a plugin like this to see if any specific plugin is causing this ?
https://ww.wp.xz.cn/plugins/p3-profiler/
Next we’d want to check what’s slowing your database down. You’d want a plugin like this to identify any queries that take a longer than usual time to run.
https://ww.wp.xz.cn/plugins/query-monitor/
Turn off the culprits as identified above and your site should hopefully be back to normal.
Forum: Fixing WordPress
In reply to: Problems installing through bluehostHey Emma,
If you’ve done the changing name servers part correctly then it should take a short while before your site resolves to
www.yoursiteaddress.com/wp-admin, sometimes upto 72 hours. I’d say give it some time and if this still does not work then check your nameservers and see if they point to what BlueHost gave you.Forum: Fixing WordPress
In reply to: Installing Plugin Simple Lightbox does not workCan you first delete all copies of the plugin after logging into the site via FTP and then download a fresh copy from here
Install this too via FTP and activate it from the front end. Let me know if that fixes it.
https://codex.ww.wp.xz.cn/Managing_Plugins#Manual_Plugin_Installation
http://www.wpbeginner.com/how-to-install-wordpress/#installftp
Forum: Fixing WordPress
In reply to: Add post count to custom post type archive page title?What you’d want to do is add a filter to the title and call the
wp_count_postsmethod like this$count_posts = wp_count_posts('bicycles'); $total_posts = $count_posts->publish;Prepend the count to the title and you’re set !
https://codex.ww.wp.xz.cn/Function_Reference/wp_count_posts
https://core.trac.ww.wp.xz.cn/browser/tags/4.5.3/src/wp-includes/post.php#L0- This reply was modified 9 years, 6 months ago by LumberHack.
Forum: Fixing WordPress
In reply to: Native or Plugin?I’d reccomend you use pods or some other framework/plugin that allows custom post types. Create a post type called
Grounds( Don’t use pages ) add the various fields you mentioned as meta , enable comments on theGroundspost type and you should be good.If you want to take this a step further create a template for this post type and add the meta details there so you can view / sort / filter and do other cool stuff on the front end
Interesting links
Native
https://generatewp.com/post-type/
http://fooplugins.com/generators/wordpress-custom-post-types/Plugin
https://ww.wp.xz.cn/plugins/pods/
https://ww.wp.xz.cn/plugins/custom-post-type-ui/Templates
https://codex.ww.wp.xz.cn/Post_Type_Templates
http://blog.netgloo.com/2014/08/27/showing-single-posts-of-a-custom-post-type-in-wordpress/Cool stuff
https://ww.wp.xz.cn/plugins/search-filter/
https://wptavern.com/beautiful-taxonomy-filters-for-wordpress-custom-post-typesHave fun !
Forum: Fixing WordPress
In reply to: query_posts, sort post by cat_idSomething like this should help you !
https://github.com/birgire/wp-combine-queries
Simply add each sub category as a subquery and then assemble them in the main combined query either manually or with a function in the order you want the sorted sub cats to appear
Forum: Fixing WordPress
In reply to: Visual Editor blankCan you turn on WP_DEBUG and post the exact error messages you see here ?
https://codex.ww.wp.xz.cn/Debugging_in_WordPressAlso are you getting any errors on the console ?
https://codex.ww.wp.xz.cn/Using_Your_Browser_to_Diagnose_JavaScript_ErrorsForum: Hacks
In reply to: Hide children posts in loop with custom taxonomyCan you try by re writing your code as under ?
$exec_query = new WP_Query( array ( 'post_type' => 'cars', 'car_type' => 'large_cars', 'posts_per_page' => 100, 'order' => 'ASC', 'tax_query' => array( array( 'include_children' => false ) ), ) ); //* The Loop if ( $exec_query->have_posts() ) { ?> <?php while ( $exec_query->have_posts() ): $exec_query->the_post(); get_template_part( 'parts/loop', 'single-produkt' ); endwhile; ?> <?php //* Restore original Post Data wp_reset_postdata(); }- This reply was modified 9 years, 7 months ago by LumberHack.
Forum: Fixing WordPress
In reply to: ERROR: The password field is empty. – even when password is insertedHere is an excellent write up on what causes this and multiple ways of fixing it.
https://premium.wpmudev.org/blog/fixing-password-empty-wordpress-chrome-error/
Forum: Fixing WordPress
In reply to: Loses connection to offline site I’m building using MAMP on MacCan you check the logs in MAMP to see what exactly caused this ? I suspect something makes MAMP crash and the site goes offline. You can use the syslog viewer for this
http://blog-en.mamp.info/2009/09/how-to-show-your-mamp-logs-within.html
As for the files they should be safe in the folder where MAMP points to for this site.
More info here
https://www.mamp.info/en/documentation/Forum: Fixing WordPress
In reply to: How to get custom post type to display post meta on archive pages?Can you rewrite the the function to use output buffering and return a string and use
echoon the template file to display it instead and see if anything displays ?