Tag Info

New answers tagged

0

WP MVC (an MVC framework for WordPress) is the best plugin. We are using it now, maybe it will suit your needs.


2

Add a meta box to your custom post type edit screen to contain your markup. Check the $pagenow global to only show it on post.php, not post-new.php, and check $current_user global for administrator role to exclude other user roles. Also, if you aren't familiar, check out the $wpdb class for your queries, and read up on using AJAX in WordPress. EDIT use ...


1

You should place this function into your theme's functions.php. Never mess with the core WordPress files (anything in the wp-includes, wp-admin directory). An error can lead to a non functioning site, and the files get updated. WordPress never updates your custom themes, so this is the way to go. Of course, if you have a lot of functions, you can create a ...


0

You will have to use the Campaign Monitor Api: http://campaignmonitor.github.io/createsend-php/ Or if you only use it for newsletter sign up, you can use a plugin: https://wordpress.org/plugins/search.php?q=campaign+monitor


0

You can register a custom taxonomy (Country) to your custom post type (Country Pages) and are connected through their ids. Updating the name of a taxonomy will affect all Country Pages.


0

The CSS is coming from Owl Slider :- http://owlgraphic.com/owlcarousel/ You can create a Owl-Theme CSS and use the CSS to override default Owl CSS.You will need to enque your Owl CSS file after Owl Theme CSS is getting loaded.Hope that solves the problem. :)


2

I found a way to get it done but I am not very happy with this procedure. Please add your answer if you find better way. Mean while, this might be of help. add_action('admin_head-edit.php','addCustomImportButton')); I only need this on edit page, so I am using admin_head-edit.php action, but you can use admin_head or some other (not very specific ...


0

You can use get_terms. In your case, something like this ought to get you started: $term_list = get_terms( 'taxonomy_name', 'hide_empty=0&orderby=name' ); foreach( $term_list as $term ) { echo "<li>" . $term->name . $term->description . "</li>"; }


1

Something like this should point you in the right direction: function updateUser($newPassword = '', $newEmail = ''){ $update = array(); if(!empty($newPassword)) $update['user_pass'] = $newPassword; if(!empty($newEmail)) $update['user_email'] = $newEmail; if(!empty($update)){ $update['ID'] = wp_get_current_user_id(); ...


0

I did end up figuring this out and went with 2) To keep it simple for content creators I told them to make sure the name of the transcript the same name for the pdf. When a new song comes in a playlist, I grab the text from the current track playing, parse the string with Wordpress file name URL rewriting (such as " " reverts to "-" I believe; this is an ...


0

You do this with URL Rewriting. Locate your .htaccess file and add this line above # BEGIN WordPress RewriteEngine On RewriteRule ^author/(.*)$ /team/$1 [R=301,NC,L] Note, if you put this inside the wordpress block it will get rewritten next time your permalinks are regenerated.


0

Their archives will use archive-{post_type}.php 'has_archive' => true, has_archive (boolean or string) (optional) Enables post type archives. Will use $post_type as archive slug by default. Default: false


2

If you output the description with bloginfo(), you can use the filter bloginfo. add_filter( 'bloginfo', 'wpse183972_description_italic', 10, 2 ); function wpse183972_description_italic( $text, $show ) { if ('description' == $show) { $word = 'WordPress'; $text = preg_replace( '^(' . preg_quote( $word ) . ')^', '<em>$1</em>', ...


1

I packed everything together. Consider using wp_enqueue_script() to use the script. With this code, you will save all URLs as an array. See how I use get_post_meta() to retrieve the saved URLs. function save_custom_metabox($post_id){ if(!isset($_POST['source_post_metabox_nonce'])) : return; endif; if(!wp_verify_nonce( ...


0

Here you can read an article about how to deal with. You'll have some mandatory things to do such rewrite your taxonomy with the same name of the custom post type. http://someweblog.com/wordpress-custom-taxonomy-with-same-slug-as-custom-post-type/


1

<?php // Display Custom Field Value echo "<ul>"; echo "<li>License Type: ".get_post_meta( $post->ID, 'License Type', true )."</li>"; echo '<li><a href="' . get_post_meta( $post->ID, 'Download Comp', true ) . '">Download Comp</a></li>'; echo "</ul>"; ?>


0

There are quite a number of ways to achieve this and to optimize this to make it efficient as well. Here is just a basic idea to achieve this by using the offset parameter in WP_Query and using the php function date() to get the current week number. First, you should get the current week number with date( 'W' ). You can decide to take this as your ...


0

As Peter mentioned, Jetpack Stats would be a neat way to handle this. It has its own Popular Posts widget which you can take as a starting point, the API is fairly simple. An alternative is the Google Analytics API. I wrote a tutorial about this quite a while ago, it's probably somewhat outdated, but it can be a good reference at what you should be looking ...


0

You can try Jetpack by Wordpress Plugin It can display list of most viewed posts in the sidebar of last 24 hours Also it has detailed stats page


0

That is pretty easy to do with WP's login_redirect filter. A small snippet like this added to your functions.php file would do it: /** * Return the url you want to redirect to after login. * This example redirects the user to the main page. */ add_filter( 'login_redirect', 'my_login_redirect' ); function my_login_redirect( $redirect_to ) { return ...


1

It depends on the theme. Most themes provide a composer (like Visual Composer) to adjust page content. If your theme doesn't work with a composer, you have to change the server files. Take a look at the child theme workaround then.


0

If you have done the first part correctly in loop-home.php, you can just simply move that into the appropriate template used by your archive pages. Taken into account that you have not used custom queries to build your queries on the homepage or any of the archive pages, you can do the following which will work on any of the aforementioned pages Use the ...



Top 50 recent answers are included