i want to display an qrcode after i’ve submit data to the DB
and this is my code of submitting :
$(document).ready(function(){
$("input#submitmap").click(function() {
var routedmap =
{
destination :destinationDB,
point: addressRoute
};
$.ajax({
type: 'POST',
url: 'addroutedmap.php',
data: routedmap,
success: function(data){
}
});
});
});
in the success function after submitted, i wanna display image of qrcode, here is the code of the image :
<img src="https://chart.googleapis.com/chart?
cht=qr&chs=200x200&chl=http://www.facebook.com"></img>
i’ve tried using .show .html (+data+ ) and it doesn’t work.
is there any idea or suggestion?
Have you tried this:
or:
where
#containeris some DOM element to harbor your image.or the way I prefer: