so im trying to read json files that contain strings from MySQL that have been encoded to json for my quiz application.
<script>
$.ajax({
url: 'http://museumjn.neti.net/webservice/quiz.php',
dataType: 'json',
type: 'get',
cache: true,
success: function(data){
// Kuis 1
$('p#quiz1').append(data[1]['Quiz'] +'<br>')
$('form[name=quiz1').append('<input id="jawabana" type="radio" name="quiz1" value="a">' + data[1]['Jawabana'] + '<br>')
$('form[name=quiz1').append('<input id="jawabana" type="radio" name="quiz1" value="b">' + data[1]['Jawabanb'] + '<br>')
$('form[name=quiz1').append('<input id="jawabana" type="radio" name="quiz1" value="c">' + data[1]['Jawabanc'] + '<br>')
$('form[name=quiz1').append('<input id="jawabana" type="radio" name="quiz1" value="d">' + data[1]['Jawaband'] + '<br>')
}
});
</script>
and the data cannot be generated to fill in the quiz, but when i create post method to input something to the database it working perfectly.. Can somebody help me ?