PHP code example of alquran / tools
1. Go to this page and download the library: Download alquran/tools library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
alquran / tools example snippets
ser = new \AlQuranCloud\Tools\Parser\Tajweed();
$html = $parser->parse($text); // $text is the output text of a Verse from quran-tajweed edition. For example: http://api.alquran.cloud/ayah/24:35/quran-tajweed. Also see data/tajweed.json.
ser = new \AlQuranCloud\Tools\Parser\Buck();
$arabic = $parser->toArabic($text); // $text is the output text of a Verse from quran-buck edition. For example: http://api.alquran.cloud/ayah/24:35/quran-buck.