How to submit the custom form data in database in WordPress without plugin?

Finally, I got my solution, I added below code in function.php and using shortcode I am getting my form on webpage function st_contact_form(){ ob_start(); ?> <div class=”contact_form-wrapper popup-contact-form”> <form action=”” method=”post” name=”contact_form” id=”contact_form” autocomplete=”off”> <div class=”row”> <div class=”col-xl-6 col-lg-6 col-md-6 col-sm-12 col-xs-12 “> <div class=”form-group”> <input type=”text” name=”name” placeholder=”Name” class=”form-control” required> </div> </div> <div class=”col-xl-6 … Read more

How do I modify the with wp_nav_menu()

Welcome to WPSO. You need to modify the Walker_Nav_Menu Class. That class is responsible for rendering the HTML menu output in first place. The theme you are using is calling the WordPress menu class, which will then output your menu. As alexwc_ mentioned the alt attribute is for images, not for anchor tags. So in … Read more

custom form submission

You can’t use admin-post.php directly in your form, you need implement an ajax request. https://codex.wordpress.org/AJAX_in_Plugins To send your email have a function wp_mail https://developer.wordpress.org/reference/functions/wp_mail/ If you have problem to receive the POST params review this answer WordPress AJAX with Axios

WordPress Pagination with ajax – Dots

You can use “mid_size” to manage number of pages to display in paginate_links() function. Please check https://developer.wordpress.org/reference/functions/paginate_links/ for pagination options. Please see example below to use mid_size. $args = array( ‘mid_size’ => 3, ‘prev_next’ => true, ‘prev_text’ => ‘« Previous’, ‘next_text’ => ‘Next »’, ); $result = paginate_links($args);

Add custom version to an image

so you can do that in 2 different ways 1. modify directly on template-parts/content-single.php 2. you can plug it using the add_action(pre_get_post,func_with_your_staff ) inside this function func_with_your_staff( $query ) { global $wp ; if ( $query->is_single() && empty($query->post_type) $query->set(‘post_type’, ‘wherever_is_type’); // perhaps you have a custom_post_type ?> and then you can add your extra staff … Read more