Output only links using wp_nav_menu()

This should add the drop class to all the li elements in the menu and also add your classes to the wrapping ul: function wpse_232637_add_menu_parent_class( $items ) { foreach ( $items as $item ) { $item->classes[] = ‘drop’; } return $items; } add_filter( ‘wp_nav_menu_objects’, ‘wp_232637_add_menu_parent_class’ ); $args = array( ‘menu’=>”, ‘menu_class’=>’nav navbar-nav navbar-right’, ‘menu_id’=>”, ‘container’=>false, … Read more

WordPress site with embedded menu – gives You don’t have permission to access /wp-content/themes/xxx/taxonomy-redirect.php on this server

The server is setup correctly, no one should be able to execute php which is not at the root directory of wordpress (if he cares about the site’s security). You can look into the htaccess or other server settings to figure out how it was done and remove it, but -10 for that option. The … Read more

Add the_post_thumbnail_url to a shortcode in function.php

I think you’re just printing your function as a string, try concatonating: add_action( ‘woocommerce_product_meta_end’, ‘childReview’ ); function childReview() { global $post; echo do_shortcode(‘[cl-popup size=”l” title=”Click!” btn_label=”Headline” btn_bgcolor=”#006982″ btn_color=”#ffffff” overlay_bgcolor=”rgba(0,105,130,0.75)” title_textcolor=”#006982″ content_textcolor=”#006982″]<img src=”https://wordpress.stackexchange.com/questions/235313/” . wp_get_attachment_url ( get_post_thumbnail_id( $post->ID ) ) . ‘”/> [/cl-popup]’); }

Unable to access WordPress functions from functions.php

check your header.php it should contain <?php wp_head(); ?> before the closing </head> tag. check your footer.php it should contain <?php wp_footer(); ?> before the closing </body> tag. You also need to hook your function to wp_enqueue_scripts action hook and then add wp_enqueue_script() and wp_enqueue_style() inside that function. e.g; function add_theme_scripts_styles() { wp_enqueue_style( ‘style-name’, ‘path_to_the_style.css’ … Read more

PHP Contact form

To access array values within a double quoted string use the form: $headers = “From: {$args[‘name’]} <{$args[’email’]}>” . “\r\n”; You are right: your function needs one more } to close it correctly.

Remove category from pagination

You are looking at the wrong line. $this_taxonomy is telling what taxonomy type (category, tag, custom tax, etc.) to look for, not what actual term in that taxonomy type. That being said, you should look at $previous and $next. More specifically, get_previous_post_link() and get_next_post_link(). The fourth parameter is $excluded_terms which is currently empty. The codex … Read more