I need to get a current value of SELECT tag. And for this I'm using $('select').val(), but this return only default value and it's don't changed. May be I can help me?
$('div#buy input').fancybox({
ajax : {
type : "POST",
data : {
id: $('input[name="id"]').val(),
count: $('#count').val()
}
}
});
<select id="count">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
</select>
fancyboxprobably runs on page load, so the value is read on page load and then it is of course the default one. You have to read the value when it is changed.$('div#buy input').fancybox(...)? Do you call it after the uses selects the value or before that ?