Difference between revisions of "Template:Quran Sura InfoBox"
From HodHood
P.Astakhov (talk | contribs) (Undo revision 54934 by P.Astakhov (talk)) |
P.Astakhov (talk | contribs) (global $suraIndexOfSubjects;) |
||
(8 intermediate revisions by the same user not shown) | |||
Line 231: | Line 231: | ||
<phptag> | <phptag> | ||
+ | global $suraIndexOfSubjects; | ||
+ | |||
if ( !isset( $argv['sura-index-of-subjects'] ) ) { | if ( !isset( $argv['sura-index-of-subjects'] ) ) { | ||
+ | $suraIndexOfSubjects = false; | ||
break; | break; | ||
} | } | ||
− | + | $a = explode( ', ', $argv['sura-index-of-subjects'] ); | |
− | + | asort( $a ); | |
− | + | ||
− | + | $suraIndexOfSubjects = []; | |
− | + | foreach ( $a as $value ) { | |
− | + | $fl = $value[0]; // $fl = strtolower( $value[0] ); | |
− | + | $suraIndexOfSubjects[$fl][] = "[[Has Sura Index of Subjects::$value]]"; | |
+ | } | ||
</phptag> | </phptag> |
Latest revision as of 16:13, 2 April 2018