how to make my website secured

It may possible that he is trying to hack. I am sure you are storing form data after escaping/sanitizing the content which eliminate the risk of Sql injection and since user can submit empty form it mean you haven done the server side validation. what you need to check is First check that weather field … Read more

My custom get_the_excerpt() can’t get excerpt by ID

Try this one /* Change Excerpt length */ function excerpt($num, $post_id) { // removed empty default value $limit = $num+1; $excerpt = apply_filters(‘the_excerpt’, get_post_field(‘post_excerpt’, $post_id)); $excerpt = explode(‘ ‘, $excerpt, $limit); array_pop($excerpt); $excerpt = implode(” “,$excerpt).”&#8230”; echo $excerpt; } Another solution – using setup_postdata($post); and wp_reset_postdata(); function custom_get_the_excerpt($post_id) { global $post; $save_post = $post; $post … Read more

Archives shortcode displaying above widget title

Either use output buffering: // Email Archives Shortcode function email_archives_shortcode() { ob_start(); ?> <select name=”archive-dropdown” onchange=”document.location.href=this.options[this.selectedIndex].value;”> <option value=””><?php echo esc_attr( __( ‘Select Month’ ) ); ?></option> <?php wp_get_archives( array( ‘type’ => ‘monthly’, ‘format’ => ‘option’, ‘show_post_count’ => 1, ‘post_type’ => ’emails’ ) ); ?> </select> <?php return ob_get_clean(); } add_shortcode(’email-archives’, ’email_archives_shortcode’); Or a string function … Read more

How can I modify footer when footer.php calls to another file?

You can remove_action and add_action with your own action. (https://codex.wordpress.org/Function_Reference/remove_action) In your child theme functions.php you can add this code for example : add_action(‘init’, ‘remove_talon_footer’); // Remove your parent theme actions function remove_talon_footer() { remove_action(‘talon_footer’, ‘talon_footer_sidebar’, 7); // Use same priority remove_action(‘talon_footer’, ‘talon_footer_credits’, 8); remove_action(‘talon_footer’, ‘talon_footer_menu’, 9); } /** * Footer sidebar */ function my_talon_footer_menu() … Read more

How to change menu labels

In order to change the menu labels you will have to go to add this code into your functions.php: add_filter( ‘gettext’, ‘change_woocommerce_text’ ); function change_woocommerce_text( $translated ) { $translated = str_replace( ‘WooCommerce’, ‘Store’, $translated ); return $translated; } Tested.