html - On form submit link to a url including the input value -
i link straight url such index/link/product-name, value inputted value on form. don't want go index/link.php?product-name=value. there way that?
<form id="search" class="header_form" action=""> <input id="product-name" class="header_search" type="text" placeholder="what looking for?" required> <span> <input type="button" value="search"> </span> </form>
every time type goin t in textfield going update action of form:
$("#product-name").keyup(function(){ $("#search").attr('action',"index/link/"+$(this).val());
});
html .htaccess mod-rewrite
No comments:
Post a Comment