KXStudio Website https://kx.studio/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

422 lines
15KB

  1. <?php
  2. $SHOW_NOTE = FALSE;
  3. $ROOT = "";
  4. if (file_exists("/home/falktx/.jackdrc") || file_exists("/home/daeavelwyn/public_html/kxstudio/"))
  5. {
  6. $ROOT = "/kxstudio";
  7. $SHOW_NOTE = FALSE;
  8. }
  9. if (false && $PAGE_TYPE != "PASTE" && $PAGE_TYPE != "DONATIONS" && $PAGE_TYPE != "NAMESPACE") {
  10. require "donate/config.php";
  11. require "donate/connect.php";
  12. $cur_amount = 0.0;
  13. $cur_percent = 0.0;
  14. if ($db_link) {
  15. $sql_donations = mysqli_query($db_link, "SELECT * FROM donations WHERE MONTH(dt) = MONTH(NOW()) AND YEAR(dt) = YEAR(NOW())");
  16. if (mysqli_num_rows($sql_donations)) {
  17. while ($sql_row = mysqli_fetch_assoc($sql_donations)) {
  18. $cur_amount += $sql_row["amount"];
  19. }
  20. }
  21. $cur_percent = $cur_amount / 500.0 * 100.0;
  22. $cur_amount = intval($cur_amount);
  23. if ($cur_percent > 100.0) {
  24. $cur_percent = 100.0;
  25. }
  26. }
  27. }
  28. function isMobile() {
  29. return preg_match("/(android|avantgo|blackberry|bolt|boost|cricket|docomo|fone|hiptop|mini|mobi|palm|phone|pie|tablet|up\.browser|up\.link|webos|wos)/i",
  30. $_SERVER["HTTP_USER_AGENT"]);
  31. }
  32. ?>
  33. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  34. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="ltr">
  35. <head>
  36. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  37. <!--[if lt IE 7]>
  38. <meta http-equiv="imagetoolbar" content="no" />
  39. <![endif]-->
  40. <title><?php echo $PAGE_TITLE; ?></title>
  41. <meta name="theme-color" content="#111111">
  42. <meta name="viewport" content="width=device-width">
  43. <link rel="copyright" href="https://creativecommons.org/publicdomain/zero/1.0/" />
  44. <link rel="stylesheet" href="<?php echo $ROOT; ?>/css/style.fluid.css" type="text/css" media="screen" />
  45. <link rel="stylesheet" href="<?php echo $ROOT; ?>/css/style.css" type="text/css" media="screen" />
  46. <link rel="icon" type="image/png" href="<?php echo $ROOT; ?>/images/ico_kxstudio.png" />
  47. <link rel="shortcut icon" href="<?php echo $ROOT; ?>/favicon.ico" />
  48. <?php if ($PAGE_TYPE == "BOARD") { ?>
  49. <!-- Special Board CSS -->
  50. <style type="text/css">
  51. #board-colors {
  52. display: flex;
  53. flex-direction: row;
  54. margin-bottom: 20px;
  55. }
  56. #board-colors p,
  57. #board-colors ul {
  58. line-height: unset;
  59. margin: 0;
  60. padding: 0;
  61. }
  62. #board-colors p,
  63. #board-colors span {
  64. margin: auto;
  65. }
  66. #board-colors p {
  67. margin-left: 8px;
  68. }
  69. #board-colors ul {
  70. display: inline-flex;
  71. flex: 1;
  72. list-style: none inside;
  73. margin-right: 8px;
  74. overflow: hidden;
  75. }
  76. #board-colors li {
  77. display: inline-flex;
  78. margin: 0px 4px;
  79. }
  80. .board-color > div {
  81. display: inline-block;
  82. width: 16px;
  83. height: 16px;
  84. margin: 4px;
  85. }
  86. @media only screen and (max-width: 1000px) {
  87. #board-colors p {
  88. display: none;
  89. }
  90. }
  91. @media only screen and (min-width: 1200px) {
  92. .omega {
  93. position: relative;
  94. }
  95. #board-colors {
  96. position: absolute;
  97. top: 0px;
  98. right: 0px;
  99. margin-bottom: 0px;
  100. }
  101. }
  102. </style>
  103. <?php } else if ($PAGE_TYPE == "DEVELOPMENT") { ?>
  104. <!-- Special Development CSS -->
  105. <style type="text/css">
  106. h3 > a {
  107. color: #F0F0F0 !important;
  108. }
  109. .changeset p {
  110. margin: 0.25em 15px !important;
  111. font-weight: lighter;
  112. }
  113. .changeset a {
  114. font-weight: normal;
  115. }
  116. .changeset b {
  117. font-weight: bold;
  118. }
  119. .changeset b > a {
  120. color: #F0F0F0 !important;
  121. }
  122. .changeset pre {
  123. font-size: 1.4em !important;
  124. background-color: unset;
  125. border: none;
  126. margin: 0.5em 1em;
  127. }
  128. </style>
  129. <?php } else if ($PAGE_TYPE == "DONATIONS") { ?>
  130. <style type="text/css">
  131. html > body .liberapay-btn {
  132. background-color: #f6c915;
  133. border-radius: 4px;
  134. color: #1a171b;
  135. display: inline-block;
  136. font-family: Helvetica Neue, Helvetica, sans-serif;
  137. font-size: 14px;
  138. font-weight: 700;
  139. line-height: 22px;
  140. padding: 5px 7px 3px;
  141. position: relative;
  142. text-decoration: none;
  143. }
  144. html > body .liberapay-btn:hover {
  145. background-color: #fbce1a;
  146. color: #444;
  147. }
  148. .liberapay-btn > svg {
  149. position: absolute;
  150. left: 7px;
  151. top: 7px;
  152. }
  153. .liberapay-btn > span {
  154. margin-left: 19px;
  155. }
  156. </style>
  157. <?php } else if ($PAGE_TYPE == "PASTE") { ?>
  158. <link rel="stylesheet" href="<?php echo $ROOT; ?>/paste/kxstudio.css" type="text/css" media="screen" />
  159. <!-- Special Paste CSS -->
  160. <style type="text/css">
  161. html, body {
  162. color: white;
  163. }
  164. .paste_textarea_border {
  165. height: 300px;
  166. border: 1px solid gray;
  167. }
  168. <?php if ($show_paste) { ?>
  169. div .paste_canvas_area {
  170. font-family: monospace;
  171. }
  172. <?php } ?>
  173. <?php if ($show_numbers) { ?>
  174. div .paste_canvas_area {
  175. padding-left: 10px;
  176. }
  177. <?php } ?>
  178. textarea {
  179. width: 100%;
  180. height: 100%;
  181. margin: 0;
  182. padding: 0;
  183. border-width: 0;
  184. resize: none;
  185. }
  186. </style>
  187. <?php } else if ($PAGE_TYPE == "REPOSITORY_PACKAGES") { ?>
  188. <!-- Special Repository Packages CSS -->
  189. <style type="text/css">
  190. .repository-package-list {
  191. display: flex;
  192. flex-direction: row;
  193. flex-wrap: wrap;
  194. }
  195. .repository-package {
  196. display: flex;
  197. flex-direction: row;
  198. margin: 15px;
  199. width: 485px;
  200. line-height: 1.25em;
  201. /* max-width: calc(92% / 3 - 32px); */
  202. }
  203. .repository-package > div:first-child {
  204. padding-top: calc(0.5em + 0.5px);
  205. }
  206. @media only screen and (max-width: 540px) {
  207. .repository-package {
  208. flex-direction: column;
  209. width: 100%;
  210. }
  211. .repository-package > div:first-child {
  212. padding-top: 0;
  213. text-align: center;
  214. }
  215. .repository-package table {
  216. width: 100%;
  217. margin-left: 10%;
  218. }
  219. .repository-package tr > td:first-child {
  220. width: 100px;
  221. }
  222. .img_clickable {
  223. margin-bottom: 5px;
  224. }
  225. }
  226. @media only screen and (max-width: 380px) {
  227. .repository-package table {
  228. margin-left: 5%;
  229. }
  230. }
  231. tr {
  232. vertical-align: top;
  233. }
  234. tr > td:first-child {
  235. font-weight: lighter;
  236. white-space: nowrap;
  237. }
  238. tbody > tr:first-child > td:last-child {
  239. font-weight: bold;
  240. }
  241. .img_clickable:hover {
  242. cursor: pointer;
  243. }
  244. .img_clickable:active > .img_clickable_overlay {
  245. display: block;
  246. }
  247. .img_clickable_overlay {
  248. position: fixed;
  249. top: 0px;
  250. left: 0px;
  251. width: 100%;
  252. min-height: 100%;
  253. background-color: black;
  254. background-color: rgba(11, 11, 11, 0.75);
  255. z-index: 1;
  256. display: none;
  257. }
  258. .img_clickable_overlay:active {
  259. display: none !important;
  260. }
  261. .img_clickable_overlay:hover {
  262. cursor: initial;
  263. display: block;
  264. }
  265. .img_clickable_overlay > img {
  266. /*
  267. display: block;
  268. margin: 0 auto;
  269. */
  270. margin: auto;
  271. position: absolute;
  272. top: 0;
  273. bottom: 0;
  274. left: 0;
  275. right: 0;
  276. max-width: 100%;
  277. max-height: 100%;
  278. }
  279. </style>
  280. <?php } ?>
  281. </head>
  282. <body class="mediawiki ltr ns-0 ns-subject skin-bentofluid">
  283. <!-- Top link -->
  284. <a name="Top" id="Top"></a>
  285. <!-- Start: Header -->
  286. <div id="header">
  287. <div id="header-content">
  288. <a id="header-logo" href="<?php echo $ROOT; ?>/">
  289. <img src="<?php echo $ROOT; ?>/images/header-logo_mod.png" width="46" height="26" alt="Header Logo"/>
  290. </a>
  291. <a id="header-home" href="<?php echo $ROOT; ?>/">Home</a>
  292. <ul id="global-navigation">
  293. <li id="item-news"><a href="<?php echo $ROOT; ?>/News">News</a></li>
  294. <li id="item-soft" class="item-menu">
  295. <?php if (isMobile()) { ?>
  296. <span>Software &#9660;</span>
  297. <?php } else { ?>
  298. <a href="<?php echo $ROOT; ?>/Applications">Software &#9660;</a>
  299. <?php } ?>
  300. <div class="item-menu-children">
  301. <p><a href="<?php echo $ROOT; ?>/Applications"><img src="<?php echo $ROOT; ?>/images/ico_cadence.png" alt=""/> &nbsp; Applications</a></p>
  302. <p><a href="<?php echo $ROOT; ?>/Plugins"><img src="<?php echo $ROOT; ?>/images/ico_distrho.png" alt=""/> &nbsp; Plugins</a></p>
  303. </div>
  304. </li>
  305. <li id="item-repos" class="item-menu">
  306. <?php if (isMobile()) { ?>
  307. <span>Repositories &#9660;</span>
  308. <?php } else { ?>
  309. <a href="<?php echo $ROOT; ?>/Repositories">Repositories &#9660;</a>
  310. <?php } ?>
  311. <div class="item-menu-children">
  312. <p><a href="<?php echo $ROOT; ?>/Repositories">About / How-to</a></p>
  313. <p><a href="<?php echo $ROOT; ?>/Repositories:Applications">Applications (in Repo)</a></p>
  314. <p><a href="<?php echo $ROOT; ?>/Repositories:Plugins">Plugins (in Repo)</a></p>
  315. <p><a href="<?php echo $ROOT; ?>/Repositories:FAQ">FAQ</a></p>
  316. <p><a href="<?php echo $ROOT; ?>/Repositories:Extras">Extras</a></p>
  317. </div>
  318. </li>
  319. <li id="item-board"><a href="<?php echo $ROOT; ?>/Board">Board</a></li>
  320. <li id="item-development"><a href="<?php echo $ROOT; ?>/Development">Development</a></li>
  321. <li id="item-documentation"><a href="<?php echo $ROOT; ?>/Documentation">Documentation</a></li>
  322. <li id="item-downloads"><a href="<?php echo $ROOT; ?>/Downloads">Downloads</a></li>
  323. <li id="item-donate"><a href="<?php echo $ROOT; ?>/Donations">Donations</a></li>
  324. </ul>
  325. </div>
  326. </div>
  327. <!-- End: Header -->
  328. <?php if (false && $PAGE_TYPE != "DONATIONS" && $db_link) { ?>
  329. <div id="donations_container" style="position:absolute; top:40px; right:5%; width: 250px; height: 10px; font-size: 0.8em;">
  330. <div id="donations_bar"><div style="width:<?php print_r($cur_percent); ?>%"></div></div>
  331. </div>
  332. <div style="position:absolute; top:44px; right:5%; width: 270px; height: 10px; font-size: 0.8em; text-align: center;">
  333. This month donations: <?php print_r($cur_amount); ?> / 500 &euro;
  334. </div>
  335. <?php } ?>
  336. <div id="subheader" class="container_16">
  337. <div id="breadcrump" class="grid_12 alpha">
  338. <a href="<?php echo $ROOT; ?>/" title="Home"><img src="<?php echo $ROOT; ?>/images/home_grey.png" width="16" height="16" alt="Home" /> KXStudio </a>
  339. <?php for ($i = 0; $i < count($PAGE_SOURCE_1); $i++) { ?>
  340. &gt; <a href="<?php echo $ROOT . $PAGE_SOURCE_1[$i]; ?>"><?php echo $PAGE_SOURCE_2[$i]; ?></a>
  341. <?php } ?>
  342. </div>
  343. </div>
  344. <!-- Start: Main Content Area -->
  345. <div id="content" class="container_16 content-wrapper">
  346. <div id="some-content" class="box box-shadow grid_77 clearfix">
  347. <!-- Start: Box header -->
  348. <div class="box-header header-tabs">
  349. <ul>
  350. <li><a href="#Top">Top</a></li>
  351. <?php /* */ if ($PAGE_TYPE == "APPLICATION") { ?>
  352. <li><a href="#Interface">Interface</a></li>
  353. <li><a href="#Usage">Usage</a></li>
  354. <li><a href="#Download">Download</a></li>
  355. <?php } else if ($PAGE_TYPE == "APPLICATION_NU") { ?>
  356. <li><a href="#Interface">Interface</a></li>
  357. <li><a href="#Download">Download</a></li>
  358. <?php } else if ($PAGE_TYPE == "DOWNLOADS") { ?>
  359. <li><a href="#Binaries">Binaries</a></li>
  360. <li><a href="#SourceCode">Source Code</a></li>
  361. <li><a href="#Artwork">Artwork</a></li>
  362. <?php } else if ($PAGE_TYPE == "PASTE") { ?>
  363. <li><a href="<?php echo $ROOT; ?>/Paste" title="Create new paste">New Paste</a></li>
  364. <?php if ($show_paste && ! $is_error) { ?>
  365. <li><a href="<?php echo $ROOT; ?>/Paste/raw/<?php echo $paste_id; ?>" target="blank" title="View RAW">View RAW</a></li>
  366. <li><a href="<?php echo $ROOT; ?>/Paste/download.php?id=<?php echo $paste_id; ?>" title="Download">Download</a></li>
  367. <?php } ?>
  368. <?php } ?>
  369. </ul>
  370. </div>
  371. <div id="contentSub"></div>
  372. <!-- End: Box header -->
  373. <div class="alpha omega paste_canvas_area">
  374. <?php /* */ if ($PAGE_TYPE == "HOME") { ?>
  375. <h1><span class="mw-headline"> About KXStudio </span></h1>
  376. <?php } else if ($PAGE_TYPE == "NEWS") { ?>
  377. <div style="float: right; padding-right: 16px;">
  378. <a href="/News/?action=feed"><img src="images/rss.png" alt="RSS"/></a>
  379. </div>
  380. <h1 style="margin-top: 0px"><span class="mw-headline"> KXStudio&nbsp;: News </span></h1>
  381. <?php } else if ($PAGE_TYPE != "PASTE") { ?>
  382. <h1><span class="mw-headline"> <?php
  383. for ($i = 0; $i < count($PAGE_SOURCE_2); $i++)
  384. {
  385. if ($i == 0)
  386. {
  387. if ($PAGE_TYPE == "NONKXSTUDIO")
  388. {
  389. echo $PAGE_SOURCE_2[$i];
  390. continue;
  391. }
  392. echo "KXStudio";
  393. }
  394. echo "&nbsp;: " . $PAGE_SOURCE_2[$i];
  395. }
  396. ?> </span></h1>
  397. <?php } ?>
  398. <?php if ($PAGE_TYPE != "PASTE" && $SHOW_NOTE) { ?>
  399. <p style="color:#fa3a3a;">
  400. NOTE: The KXStudio project is currently on a break, regular development is expected to return later in 2019.
  401. Thanks for understanding.
  402. </p>
  403. <?php } ?>
  404. <!-- - - - - - - - Begin Content Area - - - - - - - -->