I can't find any tutorial for jQuery + web.py. So I've got basic question on POST method.
I've got jQuery script:
<script>
jQuery('#continue').click(function() {
var command = jQuery('#continue').attr('value');
jQuery.ajax({
type: "POST",
data: {signal : command},
});
});
</script>
A simple form:
<form>
<button type="submit">Cancel</button>
<button type="submit" id="continue" value="next">Continue</button>
</form>
and python script:
def POST (self):
s = signal
print s
return
I expect to see string "next" in console. But it doesn't happen.
I have a strong feeling that selectors somehow do not work. Any way to check it?