php - Action Form not work -
<form action="/en2/maps-<?php echo $id; ?>/?=. ($_get['textsearchterms']).&=. ($_get['locationsearchterms'])."><!--relative url page map on--> distination: <select name="textsearchterms" class="selectpicker" data-live-search="true"> <option value="alfamart">alfamart</option> <option value="bca">bca</option> </select> location: <input type="text" name="locationsearchterms"> <input type="submit" value="search"> </form>
<form action="/en2/maps-<?php echo $id; ?>
not work... idea?
i want link form action:
http://indonesia.com/en2/maps-alfamart/?textsearchterms=alfamart&locationsearchterms=denpasar
thanks
use this
<?php $id="alfamart"; $textsearchterms = isset($_get['textsearchterms']) ? $_get['textsearchterms'] : ""; $locationsearchterms = isset($_get['locationsearchterms']) ? $_get['locationsearchterms'] : ""; $url = "/en2/maps-".$id."/?textsearchterms=".$textsearchterms."&locationsearchterms=".$locationsearchterms; ?> <form action="<?php echo $url; ?>" method="get"> distination: <select name="textsearchterms" class="selectpicker" data-live-search="true"> <option value="alfamart">alfamart</option> <option value="bca">bca</option> </select> location: <input type="text" name="locationsearchterms"> <input type="submit" value="search"> </form>
added form method , php variable in php tag
Comments
Post a Comment