2 $dockapps = parse_ini_file("dockapps.db", true);
5 $category = $_GET["category"];
6 $download = $_GET["download"];
8 function getCategory($dockapp) {
9 return $dockapp["category"];
13 $download=str_replace(" ", "+", $download);
14 preg_match("/([\w\-+.]+)-([\w+.]+).tar.gz/", $download, $matches);
15 header("Location: http://repo.or.cz/w/dockapps.git/snapshot/" .
16 $dockapps[$matches[1]]["version-$matches[2]"] . ".tar.gz");
20 <html xmlns
="http://www.w3.org/1999/xhtml">
22 <meta name
="generator" content
="HTML Tidy for Linux (vers 25 March 2009), see www.w3.org" />
24 <title
>Window Maker
: Dockapps
</title
>
25 <meta http
-equiv
="Content-Type" content
="text/html; charset=us-ascii" />
26 <link href
="../title.css" rel
="stylesheet" type
="text/css" />
30 include("../dock.php");
31 include("../header.php");?
>
33 <table
class="inner" border
="0" cellpadding
="1" cellspacing
="1">
35 <td content
="content" colspan
="2" valign
="top">
38 <h1
><a href
=".">Dockapps
</a
></h1
>
41 echo "<h2>$name</h2>\n";
42 echo "<b>Category:</b> <a href=\"?category=" .
43 $dockapps[$name]["category"] . "\">" .
44 $dockapps[$name]["category"] .
46 if ($dockapps[$name]["url"])
47 echo "<b>Website</b>: <a href=\"" . $dockapps[$name]["url"] .
48 "\">" . $dockapps[$name]["url"] . "</a><br/>\n";
49 echo "<b>Description:</b> " . nl2br($dockapps[$name]["description"]) .
51 $images = explode(",", $dockapps[$name]["image"]);
53 echo "<h3>Screenshots:</h3>\n";
54 foreach ($images as $image)
55 echo "<img src=\"img/$image\"/>\n";
57 echo "<h3>Available Versions:</h3>\n";
59 $info = $dockapps[$name];
60 foreach ($info as $key => $value) {
61 if (substr($key, 0, 8) == "version-")
63 substr($key, strrpos($key, "-")+
1));
65 foreach ($versions as $version) {
66 echo "<a href=\"?download=$name-$version.tar.gz\">" .
67 "$name-$version</a><br/>\n";
71 <i
>Note
:</i
> By
default, the above tarballs will save
as
72 dockapps
-$string.tar
.gz
, where
$string is a long
string of hexadecimal
73 characters
. You may wish to right click
and use the
<i
>Save Link
As...</i
>
77 } else if ($category) {
78 echo "<h2>$category</h2>\n";
80 foreach ($dockapps as $dockapp => $info)
81 if ($info["category"] == $category)
82 array_push($matches, $dockapp);
84 foreach ($matches as $dockapp)
85 echo "<a href=\"?name=" . urlencode($dockapp) .
86 "\">$dockapp</a><br/>\n";
89 Here you can download git snapshots of a number of Window Maker dockapps which
90 are no longer maintained by their original developers
and have been adopted by
91 the Window Maker Developers Team
. You can browse the repository itself at
92 <a href
="http://repo.or.cz/dockapps.git">http
://repo.or.cz/dockapps.git</a>.
94 If you would like to submit a patch to an existing dockapp
or add a
new dockapp
95 to the repository
, please follow
<a href
="http://repo.or.cz/w/wmaker-crm.git/blob/HEAD:/The-perfect-Window-Maker-patch.txt">these directions
</a
>.
99 $categories = array_unique(array_map("getCategory", $dockapps));
101 foreach ($categories as $category)
102 echo "<a href=\"?category=$category\">$category</a><br/>\n";
109 include("../footer.php");