mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-12 10:10:30 +03:00
Changed latest apps from being rendered by update.py to wp-fdroid.php.
This also adds icons to the latest app widget listing.
This commit is contained in:
parent
9e77ebd899
commit
2f4d198589
2 changed files with 22 additions and 8 deletions
|
|
@ -722,7 +722,21 @@ function widget_fdroidlatest($args) {
|
|||
extract($args);
|
||||
echo $before_widget;
|
||||
echo $before_title . 'Latest Apps' . $after_title;
|
||||
readfile(getenv('DOCUMENT_ROOT').'/repo/latestapps.html');
|
||||
|
||||
$handle = fopen(getenv('DOCUMENT_ROOT').'/repo/latestapps.dat', 'r');
|
||||
if ($handle) {
|
||||
while (($buffer = fgets($handle, 4096)) !== false) {
|
||||
$app = explode("\t", $buffer);
|
||||
echo '<a href="/repository/browse/?fdid='.$app[0].'">';
|
||||
if(trim($app[2])) {
|
||||
echo '<img src="http://f-droid.org/repo/icons/'.$app[2].'" style="width:32px;border:none;float:right;" />';
|
||||
}
|
||||
echo $app[1].'<br />';
|
||||
echo '</a><br style="clear:both;" />';
|
||||
}
|
||||
fclose($handle);
|
||||
}
|
||||
|
||||
echo $after_widget;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue