inviting people to blog and editing roles

By the below code you can give contributor to upload image. function rwc_allow_contributor_uploads() { $contributor = get_role(‘contributor’); $contributor->add_cap(‘upload_files’); } add_action(‘admin_init’, ‘rwc_allow_contributor_uploads’);` And admin will review the post and then publish it.

Custom Pagination is Broken

Chances are your pager is getting the count of all posts, regardless of whether they are published. In your query, you should add a filter for only published posts. $query_args = array( ‘post_type’ => ‘post’, ‘posts_per_page’ => 4, ‘paged’ => $paged, ‘post_status’ = ‘publish’, ); Then the results count and number of pager links should … Read more

How to replace website?

You can install the All-in-One WP Migration to make a backup of the new test site. Then install the plugin in your old site as well and upload the backup there. Then update the permalinks and change Site URL in Setting > General if needed. Here’s the URL for the Plugin: https://wordpress.org/plugins/all-in-one-wp-migration/

Add Date and Author to Posts

Use the following code in file template single.php (https://developer.wordpress.org/reference/functions/get_day_link/#user-contributed-notes ) : <?php $archive_year = get_the_time( ‘Y’ ); $archive_month = get_the_time( ‘m’ ); $archive_day = get_the_time( ‘d’ ); $month= get_the_date(‘M’); ?> <div class=”custom_archives”> <p> Posted on: <a href=”https://wordpress.stackexchange.com/questions/310792/<?php echo esc_url( get_day_link( $archive_year, $archive_month, $archive_day ) ); ?>”><?php echo $month. ” “.$archive_day.”, ” .$archive_year; ?> </a> </p> … Read more

What is the “pub” theme? [closed]

There is no pub theme, that’s a quirk of how WordPress.com the premium 3rd party service ran by Automattic is internally structured. It’s non-standard. To be more specific WP.com doesn’t use the normal theme folder structure, and instead of searching wp-content/themes for theme folders, it searches wp-content/themes/pub and several others for themes, but mostly pub. … Read more

Blog has an infinite redirect loop

Is WordPress configured to use www or without www? Your server seems to be listening only for the www version and tries to redirect non-www requests to the www version. Considering that you provided a link to the non-www version of the domain above, my guess is that WordPress is trying to hook on to … Read more