diff --git a/credits.php b/credits.php index 5fdd5ae..ba540a1 100644 --- a/credits.php +++ b/credits.php @@ -5,9 +5,53 @@
Main: Znote.
+
Contributor: Kuzirashi.
Contributor: ninjalulz.
Contributor: att3.
+
+ Contributors:';
+
+ $curl = curl_init();
+ curl_setopt($curl, CURLOPT_URL, 'https://api.github.com/repos/Znote/ZnoteAAC/contributors');
+ curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
+ curl_setopt($curl, CURLOPT_USERAGENT, 'ZnoteAAC'); // GitHub requires user agent header.
+ $contributors = json_decode(curl_exec($curl), true); // Sorted by contributions.
+
+ $CONTRIBUTORS_PER_ROW = 7;
+
+ $i = 0;
+ $first_container = true;
+ $div_closed = true;
+ foreach($contributors as $contributor)
+ {
+ if($contributor['login'] != 'Znote') { // Exclude Znote as he is mentioned above as main developer.
+ $new_div = ctype_digit((String)($i / $CONTRIBUTORS_PER_ROW));
+
+ if($new_div) {
+ if(!$first_container)
+ echo '';
+
+ echo '