Articles of customization

Custom login and registration forms

I want to create a custom register / login form for a specific user role in the WordPress system. The visitor should be able to register (to assign the right role immediately) and login to gain access to a specific page (which is only available for this specific role). I’ve found some articles, where they […]

website with pretty permalinks except pagination

I use friendly URLs on my wordpress page so I have for example shop/page/2 I would like to have It like shop/?paged=2. Is there anything like rewriterules but opossite to it 😉 ? Which converts pretty permalinks into “ugly” one?

How can i change what one category displays?

I want to do this with WooCommerce product categories, but I guess it should be the same for post categories. I want all categories to display their products, but then i want one category “For free” to display products from all other categories where price is zero. How can I change it? Should i create […]

WordPress custom dropdown listings

I have a site with a database of repair shops, by; Manufacturer – Venue I want 2 dropdown lists at the home page. In the first dropdown, when i select the “Apple” the second list appears in the places where they are “Apple” repair shops, and when i press the “Submit” button, it redirects me […]

post_content is stripping HTML when adding a new post?

I have the following in my functions.php file: $post_content = ” Image: <img src=’$featured_image’ /> Address: $event_address Zip: $event_zip Region: $event_region Country: $date_country “; This works fine… But I need something like this: <div class=’activity-listing-content’> <div class=’activity-listing-item’> $image <div class=’activity-listing-item-details’> <span class=’address’>$event_address, $event_region, $event_zip</span> </div></div> </div> Whenever I create the post, all the HTML above […]

After disabling WPML multi currency, the currency is still handled by the WPML

I have used WPML multi currency for a while, but recently I turned it off and use the other currency plugin. Most of the amount have converted correctly, but for some amount still remain at the default currency even after I changed to another one: 1) Booking cost from Woocommerce Booking plugin 2) Extra option […]

How to customize work area / admin area in a custom post type without plugins?

Strangely I don’t find much sources on the web talking about my desires. So I hope it is a trivial thing I’m asking (although I fear it’s not and WordPress is just..). Naturally I need custom fields in my custom post types. WordPress’ native way of handling custom fields is very inconvenient and I can’t […]

Can 'edit_form_after_editor' messages be varied for specific pages?

I use edit-screen hooks ( display messages on the new/edit admin page for posts and pages. Example: function add_screen_message() { $screen = get_current_screen(); if($screen->post_type==’page’ && $screen->id==’page’) { echo “<p class=\”edit-message\”>Custom message here.</p>”;} add_action(‘edit_form_after_editor’, ‘add_screen_message’); Can this be modified to display a specific message according to page id/name/slug, and if so, how?

Customizer image control default value showing in customizer but not on frontend

I use the WP_Customize_Image_Control to add the image. But, The default value is accessible in Customizer only!!! On front-end It return empty. How to reproduce? Copy below code snippet and paste in your themes functions.php. Visit URL http://YOUR_SITE/wp-admin/customize.php?autofocus[section]=section-test_option to open section Test Section add_action( ‘customize_register’, ‘test_1234_customize_register’ ); add_action( ‘wp_head’, ‘test_1234_customizer_ouput_debug’ ); function test_1234_customizer_ouput_debug() { // […]

get_theme_mod outputs number when using WP_Customize_Cropped_Image_Control

I have added a few sections to the customizer but am having trouble when trying to call the image I have defined. The back end works great but when I call it using get_theme_mod it echos a two digit number, like 23. I have several sections in the theme customizer (non-images) and don’t have any […]