From: Hans-Emil Skogh '.$name."";
- $out.=" ".$desc." License: ".$license." ";
- if(strlen($web)>0)
- $out.='Website: '.$web.' Version ".$apk['version']." - ";
- $out.='download ';
- $out.=$apk['size']." bytes";
- if($apk['srcname'])
- $out.=' Application not found ';
-
- $out.=' '.$name."";
+ $out.=" ".$desc." License: ".$license." ";
+ if(strlen($web)>0)
+ $out.='Website: '.$web.' Version ".$apk['version']." - ";
+ $out.='download ';
+ $out.=$apk['size']." bytes";
+ if($apk['srcname'])
+ $out.=' Application not found ';
- if($query_vars['fdpage']==1) {
- $out.="<<first ";
- $out.="<prev ";
- } else {
- $out.='<<first ';
- $out.='<<prev ';
- }
++
++ $out.='
".$summary."
';
- if(strlen($issues)>0)
- $out.='Issue Tracker: '.$issues.'
';
- if(strlen($source)>0)
- $out.='Source Code: '.$source.'
';
- if($donate && strlen($donate)>0)
- $out.='Donate: '.$donate.'
';
- $out.="Packages
";
- foreach($apks as $apk) {
- $out.="
source tarball';
- $out.="
';
-
- return $out;
- }
- }
- return "
';
- }
-
- if($numpages>0) {
- $out.=$matches;
-
- $out.='
".$summary."
';
+ if(strlen($issues)>0)
+ $out.='Issue Tracker: '.$issues.'
';
+ if(strlen($source)>0)
+ $out.='Source Code: '.$source.'
';
+ if($donate && strlen($donate)>0)
+ $out.='Donate: '.$donate.'
';
+ $out.="Packages
";
+ foreach($apks as $apk) {
+ $out.="
source tarball';
+ $out.="
';
+
+ return $out;
+ }
+ }
+ return "
';
+ }
+
+ if($numpages>0) {
+ $out.=$matches;
+
+ $out.='
No matches
'; - } - - return $out; - } - - - function show_search($query_vars) { - - $out=''; - $out.=''."\n"; - - return $out; - } - - - function show_apps($xml,$query_vars,&$numpages) { - - $skipped=0; - $got=0; - $total=0; - - if($query_vars['fdstyle']=='grid') { - $outputter = new FDOutGrid(); - } else { - $outputter = new FDOutList(); - } - - $out = ""; - - $out.=$outputter->outputStart(); - - foreach($xml->children() as $app) { - - if($app->getName() == 'repo') continue; - $appinfo['attrs']=$app->attributes(); - $appinfo['id']=$appinfo['attrs']['id']; - foreach($app->children() as $el) { - switch($el->getName()) { - case "name": - $appinfo['name']=$el; - break; - case "icon": - $appinfo['icon']=$el; - break; - case "summary": - $appinfo['summary']=$el; - break; - case "license": - $appinfo['license']=$el; - break; - } - } - - if($query_vars['fdfilter']===null || $query_vars['fdfilter']!='' && (stristr($appinfo['name'],$query_vars['fdfilter']) || stristr($appinfo['summary'],$query_vars['fdfilter']))) { - if($skipped<($query_vars['fdpage']-1)*$outputter->perpage) { - $skipped++; - } else if($got<$outputter->perpage) { - $out.=$outputter->outputEntry($query_vars, $appinfo); - $got++; - } - $total++; - } - - } - - $out.=$outputter->outputEnd(); - - $numpages = ceil((float)$total/$outputter->perpage); - - return $out; - } -} - -// Class to output app entries in a detailed list format -class FDOutList -{ - var $perpage=30; - - function FDOutList() { - } - - function outputStart() { - return ''; - } - - function outputEntry($query_vars, $appinfo) { - $out=""; - $out.="Details...'; - $out.="
"; - $out.="'.$appinfo['name']."";
- $out.="
".$appinfo['summary']."
';
- $out.=' '; - $out.=' ';
-
- $out.='';
- $out.=' ";
- $out.='';
- $out.="'; - $out.=$appinfo['name'].' '; - $out.=''; - - $out.=" | \n";
-
- $this->itemCount++;
- return $out;
- }
-
- function outputEnd() {
- return '
No matches
'; + } + + return $out; + } + + + function show_search($query_vars) { + + $out=''; + $out.=''."\n"; + + return $out; + } + + + function show_apps($xml,$query_vars,&$numpages) { + + $skipped=0; + $got=0; + $total=0; + + if($query_vars['fdstyle']=='grid') { + $outputter = new FDOutGrid(); + } else { + $outputter = new FDOutList(); + } + + $out = ""; + + $out.=$outputter->outputStart(); + + foreach($xml->children() as $app) { + + if($app->getName() == 'repo') continue; + $appinfo['attrs']=$app->attributes(); + $appinfo['id']=$appinfo['attrs']['id']; + foreach($app->children() as $el) { + switch($el->getName()) { + case "name": + $appinfo['name']=$el; + break; + case "icon": + $appinfo['icon']=$el; + break; + case "summary": + $appinfo['summary']=$el; + break; + case "description": + $appinfo['description']=$el; + break; + case "license": + $appinfo['license']=$el; + break; + } + } + + if($query_vars['fdfilter']===null || $query_vars['fdfilter']!='' && (stristr($appinfo['name'],$query_vars['fdfilter']) || stristr($appinfo['summary'],$query_vars['fdfilter']) || stristr($appinfo['description'],$query_vars['fdfilter']))) { + if($skipped<($query_vars['fdpage']-1)*$outputter->perpage) { + $skipped++; + } else if($got<$outputter->perpage) { + $out.=$outputter->outputEntry($query_vars, $appinfo); + $got++; + } + $total++; + } + + } + + $out.=$outputter->outputEnd(); + + $numpages = ceil((float)$total/$outputter->perpage); + + return $out; + } +} + +// Class to output app entries in a detailed list format +class FDOutList +{ + var $perpage=30; + + function FDOutList() { + } + + function outputStart() { + return ''; + } + + function outputEntry($query_vars, $appinfo) { + $out=""; + $out.="Details...'; + $out.="
"; + $out.="'.$appinfo['name']."";
+ $out.="
".$appinfo['summary']."
';
+ $out.=' '; + $out.=' ';
+
+ $out.='';
+ $out.=' ";
+ $out.='';
+ $out.="'; + $out.=$appinfo['name'].' '; + $out.=''; + + $out.=" | \n";
+
+ $this->itemCount++;
+ return $out;
+ }
+
+ function outputEnd() {
+ return '