I have this HTML
<div class="btn-group">
<input type="button" name="meat" class="btn btn-default active" value="Both">
<input type="button" name="meat" class="btn btn-default" value="Red">
<input type="button" name="meat" class="btn btn-default" value="White">
<input type="button" name="meat" class="btn btn-default" value="None">
</div>
This with addition os some css gives this resoult:
I use this code to only allow one active:
$(".btn-group > .btn").click(function(){
$(this).siblings().removeClass("active");
$(this).addClass("active");
});
But it is just visual, and when I try to input vía php POST (within a form) I don't get nothing.
If i change to type=radio, the PHP works fine, but it is uglier.
¿Any magical idea to make it work keeping it fancy?
The php code for testing is:
<html>
<body>
MegaUltraTest <?php echo ($_POST["meat"]); ?>
</body>
</html>
Thank you.