Line 1: | Line 1: | ||
+ | [[Category:Data]] | ||
= Page = | = Page = | ||
Fetchs the quran data page by page. This method we use on GlobalQuran.com 3.0
Url: [http://api.globalquran.com/page/getPage/quranID http://api.globalquran.com/page/getPage/quranID]
attribute | Value | Description |
---|---|---|
getPage | page number, verse number or surah:ayah number | Identify here what page number you want to pull |
quranID | quran id | list of quran id seperated by | (pipe) |
Url Examples By:
JSON Response: [http://api.globalquran.com/page/604/quran-simple http://api.globalquran.com/page/604/quran-simple]
{ "quran": { "quran-simple": { "6222": { "surah": 112, "ayah": 1, "verse": "بِسْمِ اللَّهِ الرَّحْمَٰنِ الرَّحِيمِ قُلْ هُوَ اللَّهُ أَحَدٌ" }, "6223": { "surah": 112, "ayah": 2, "verse": "اللَّهُ الصَّمَدُ" }, "6224": { "surah": 112, "ayah": 3, "verse": "لَمْ يَلِدْ وَلَمْ يُولَدْ" }, "6225": { "surah": 112, "ayah": 4, "verse": "وَلَمْ يَكُنْ لَهُ كُفُوًا أَحَدٌ" }, "6226": { "surah": 113, "ayah": 1, "verse": "بِسْمِ اللَّهِ الرَّحْمَٰنِ الرَّحِيمِ قُلْ أَعُوذُ بِرَبِّ الْفَلَقِ" }, "6227": { "surah": 113, "ayah": 2, "verse": "مِنْ شَرِّ مَا خَلَقَ" }, "6228": { "surah": 113, "ayah": 3, "verse": "وَمِنْ شَرِّ غَاسِقٍ إِذَا وَقَبَ" }, "6229": { "surah": 113, "ayah": 4, "verse": "وَمِنْ شَرِّ النَّفَّاثَاتِ فِي الْعُقَدِ" }, "6230": { "surah": 113, "ayah": 5, "verse": "وَمِنْ شَرِّ حَاسِدٍ إِذَا حَسَدَ" }, "6231": { "surah": 114, "ayah": 1, "verse": "بِسْمِ اللَّهِ الرَّحْمَٰنِ الرَّحِيمِ قُلْ أَعُوذُ بِرَبِّ النَّاسِ" }, "6232": { "surah": 114, "ayah": 2, "verse": "مَلِكِ النَّاسِ" }, "6233": { "surah": 114, "ayah": 3, "verse": "إِلَٰهِ النَّاسِ" }, "6234": { "surah": 114, "ayah": 4, "verse": "مِنْ شَرِّ الْوَسْوَاسِ الْخَنَّاسِ" }, "6235": { "surah": 114, "ayah": 5, "verse": "الَّذِي يُوَسْوِسُ فِي صُدُورِ النَّاسِ" }, "6236": { "surah": 114, "ayah": 6, "verse": "مِنَ الْجِنَّةِ وَالنَّاسِ" } } } }
Example: Loads the last quran page 604.
<!DOCTYPE html> <html> <head> <style>#demo-1{ color:lightBlue; }</style> <script src="http://code.jquery.com/jquery-latest.js"></script> </head> <body> <div id="demo-1"> </div> <script> $.ajaxSetup({ cache: true, jsonpCallback: 'quranData' }); // define ajax setup $.getJSON("http://api.globalquran.com/page/604/quran-simple?jsoncallback=?", { format : "jsonp" }, function(data) { $.each(data.quran, function(i, by) { $.each(by, function (verseNo, line) { $("<p>").html(line.surah+':'+line.ayah+' '+line.verse).appendTo("#demo-1"); }); }); }); </script> </body> </html>
Demo:
.