bootstrap-dark-page.php 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358
  1. <?php
  2. use PrivateBin\I18n;
  3. ?><!DOCTYPE html>
  4. <html lang="en">
  5. <head>
  6. <meta charset="utf-8" />
  7. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  8. <meta name="viewport" content="width=device-width, initial-scale=1">
  9. <meta name="robots" content="noindex" />
  10. <meta name="referrer" content="no-referrer">
  11. <title><?php echo I18n::_('PrivateBin'); ?></title>
  12. <link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-theme-3.3.5.css" />
  13. <link type="text/css" rel="stylesheet" href="css/bootstrap/darkstrap-0.9.3.css" />
  14. <link type="text/css" rel="stylesheet" href="css/bootstrap/privatebin.css?<?php echo rawurlencode($VERSION); ?>" />
  15. <?php
  16. if ($SYNTAXHIGHLIGHTING):
  17. ?>
  18. <link type="text/css" rel="stylesheet" href="css/prettify/prettify.css?<?php echo rawurlencode($VERSION); ?>" />
  19. <?php
  20. if (strlen($SYNTAXHIGHLIGHTINGTHEME)):
  21. ?>
  22. <link type="text/css" rel="stylesheet" href="css/prettify/<?php echo rawurlencode($SYNTAXHIGHLIGHTINGTHEME); ?>.css?<?php echo rawurlencode($VERSION); ?>" />
  23. <?php
  24. endif;
  25. endif;
  26. ?>
  27. <script type="text/javascript" src="js/jquery-3.1.1.js" integrity="sha512-U6K1YLIFUWcvuw5ucmMtT9HH4t0uz3M366qrF5y4vnyH6dgDzndlcGvH/Lz5k8NFh80SN95aJ5rqGZEdaQZ7ZQ==" crossorigin="anonymous"></script>
  28. <script type="text/javascript" src="js/sjcl-1.0.4.js" integrity="sha512-BqVQ8GgWfMCcdsDuP6Ggm1BV7+mmoWH3PC4UqcYpEKSdEq1rthy6NUsa6gu5sydewbi/ilI3E3ohdCxlPPF9ww==" crossorigin="anonymous"></script>
  29. <?php
  30. if ($ZEROBINCOMPATIBILITY):
  31. ?>
  32. <script type="text/javascript" src="js/base64-1.7.js" integrity="sha512-JdwsSP3GyHR+jaCkns9CL9NTt4JUJqm/BsODGmYhBcj5EAPKcHYh+OiMfyHbcDLECe17TL0hjXADFkusAqiYgA==" crossorigin="anonymous"></script>
  33. <?php
  34. else:
  35. ?>
  36. <script type="text/javascript" src="js/base64-2.1.9.js" integrity="sha512-rbqAby7hObftbEoGQzkhUbEh5YkUn2MtekTLs4btvo2oly4CZ3DxhJzEh0u/rNzS54tcJdqi5Ug1ruugEd2U1g==" crossorigin="anonymous"></script>
  37. <?php
  38. endif;
  39. ?>
  40. <script type="text/javascript" src="js/rawdeflate-0.5.js" integrity="sha512-tTdZ7qMr7tt5VQy4iCHu6/aGB12eRwbUy+AEI5rXntfsjcRfBeeqJloMsBU9FrGk1bIYLiuND/FhU42LO1bi0g==" crossorigin="anonymous"></script>
  41. <script type="text/javascript" src="js/rawinflate-0.3.js" integrity="sha512-g8uelGgJW9A/Z1tB6Izxab++oj5kdD7B4qC7DHwZkB6DGMXKyzx7v5mvap2HXueI2IIn08YlRYM56jwWdm2ucQ==" crossorigin="anonymous"></script>
  42. <script type="text/javascript" src="js/bootstrap-3.3.5.js" integrity="sha512-/W33QnLmSAP1fwINS9iXgB6s/VOIG9GVdIuIYaUtbSvKPMv5S08PtT3PqnT2WjwBgB8DFeDN2nqJroqQYF7SwQ==" crossorigin="anonymous"></script>
  43. <?php
  44. if ($SYNTAXHIGHLIGHTING):
  45. ?>
  46. <script type="text/javascript" src="js/prettify.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-m8iHxoN+Fe12xxFwWNdY/TS4KoFntHp29qY0xUzBnPd0bkKMOR/dFhEdTWydpt0b/fIXyhB+znGYUvgjfJ2RzQ==" crossorigin="anonymous"></script>
  47. <?php
  48. endif;
  49. if ($MARKDOWN):
  50. ?>
  51. <script type="text/javascript" src="js/showdown-1.4.1.js" integrity="sha512-Kbz1FIlDnqUJu/3yW8H8USzURA3JuUqSKRwz13lM4kWt6C0n6s4tjl81PCfnWtE4gBIzyj5uGePcfUyotk/icw==" crossorigin="anonymous"></script>
  52. <?php
  53. endif;
  54. ?>
  55. <script type="text/javascript" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-aKd7/5EFMPmeZTmL0Iyttt6sbukO9E40bUink8A/IJmrncCh1upGLlkhti7ygO+hq/ocgLJ0kKoxZETzTgNEww==" crossorigin="anonymous"></script>
  56. <!--[if lt IE 10]>
  57. <style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
  58. <![endif]-->
  59. <link rel="apple-touch-icon" href="apple-touch-icon.png?<?php echo rawurlencode($VERSION); ?>" sizes="180x180" />
  60. <link rel="icon" type="image/png" href="favicon-32x32.png?<?php echo rawurlencode($VERSION); ?>" sizes="32x32" />
  61. <link rel="icon" type="image/png" href="favicon-16x16.png?<?php echo rawurlencode($VERSION); ?>" sizes="16x16" />
  62. <link rel="manifest" href="manifest.json?<?php echo rawurlencode($VERSION); ?>" />
  63. <link rel="mask-icon" href="safari-pinned-tab.svg?<?php echo rawurlencode($VERSION); ?>" color="#ffcc00" />
  64. <link rel="shortcut icon" href="favicon.ico">
  65. <meta name="msapplication-config" content="browserconfig.xml">
  66. <meta name="theme-color" content="#ffe57e" />
  67. </head>
  68. <body role="document">
  69. <div id="passwordmodal" class="modal fade" role="dialog">
  70. <div class="modal-dialog">
  71. <div class="modal-content">
  72. <div class="modal-body">
  73. <form id="passwordform" role="form">
  74. <div class="form-group">
  75. <label for="passworddecrypt"><span class="glyphicon glyphicon-eye-open"></span> <?php echo I18n::_('Please enter the password for this paste:') ?></label>
  76. <input id="passworddecrypt" type="password" class="form-control" placeholder="<?php echo I18n::_('Enter password') ?>" autofocus>
  77. </div>
  78. <button type="submit" class="btn btn-success btn-block"><span class="glyphicon glyphicon-off"></span> <?php echo I18n::_('Decrypt') ?></button>
  79. </form>
  80. </div>
  81. </div>
  82. </div>
  83. </div>
  84. <nav class="navbar navbar-inverse navbar-static-top">
  85. <div class="navbar-header">
  86. <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
  87. <span class="sr-only"><?php echo I18n::_('Toggle navigation'); ?></span>
  88. <span class="icon-bar"></span>
  89. <span class="icon-bar"></span>
  90. <span class="icon-bar"></span>
  91. </button>
  92. <a class="reloadlink navbar-brand" href="">
  93. <img alt="<?php echo I18n::_('PrivateBin'); ?>" src="img/icon.svg" width="38" />
  94. </a>
  95. </div>
  96. <div id="navbar" class="navbar-collapse collapse">
  97. <ul class="nav navbar-nav">
  98. <li>
  99. <button id="sendbutton" type="button" class="hidden btn btn-warning navbar-btn">
  100. <span class="glyphicon glyphicon-upload" aria-hidden="true"></span> <?php echo I18n::_('Send'), PHP_EOL; ?>
  101. </button>
  102. <?php
  103. if ($EXPIRECLONE):
  104. ?>
  105. <button id="clonebutton" type="button" class="hidden btn btn-warning navbar-btn">
  106. <span class="glyphicon glyphicon-duplicate" aria-hidden="true"></span> <?php echo I18n::_('Clone'), PHP_EOL; ?>
  107. </button>
  108. <?php
  109. endif;
  110. ?>
  111. <button id="rawtextbutton" type="button" class="hidden btn btn-warning navbar-btn">
  112. <span class="glyphicon glyphicon-text-background" aria-hidden="true"></span> <?php echo I18n::_('Raw text'), PHP_EOL; ?>
  113. </button>
  114. </li>
  115. <li class="dropdown">
  116. <select id="pasteExpiration" name="pasteExpiration" class="hidden">
  117. <?php
  118. foreach ($EXPIRE as $key => $value):
  119. ?>
  120. <option value="<?php echo $key; ?>"<?php
  121. if ($key == $EXPIREDEFAULT):
  122. ?> selected="selected"<?php
  123. endif;
  124. ?>><?php echo $value; ?></option>
  125. <?php
  126. endforeach;
  127. ?>
  128. </select>
  129. <a id="expiration" href="#" class="hidden dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><?php echo I18n::_('Expires'); ?>: <span id="pasteExpirationDisplay"><?php echo $EXPIRE[$EXPIREDEFAULT]; ?></span> <span class="caret"></span></a>
  130. <ul class="dropdown-menu">
  131. <?php
  132. foreach ($EXPIRE as $key => $value):
  133. ?>
  134. <li>
  135. <a href="#" data-expiration="<?php echo $key; ?>">
  136. <?php echo $value, PHP_EOL; ?>
  137. </a>
  138. </li>
  139. <?php
  140. endforeach;
  141. ?>
  142. </ul>
  143. </li>
  144. <li>
  145. <div id="burnafterreadingoption" class="navbar-text checkbox hidden">
  146. <label>
  147. <input type="checkbox" id="burnafterreading" name="burnafterreading"<?php
  148. if ($BURNAFTERREADINGSELECTED):
  149. ?> checked="checked"<?php
  150. endif;
  151. ?> />
  152. <?php echo I18n::_('Burn after reading'), PHP_EOL; ?>
  153. </label>
  154. </div>
  155. </li>
  156. <?php
  157. if ($DISCUSSION):
  158. ?>
  159. <li>
  160. <div id="opendisc" class="navbar-text checkbox hidden">
  161. <label>
  162. <input type="checkbox" id="opendiscussion" name="opendiscussion"<?php
  163. if ($OPENDISCUSSION):
  164. ?> checked="checked"<?php
  165. endif;
  166. ?> />
  167. <?php echo I18n::_('Open discussion'), PHP_EOL; ?>
  168. </label>
  169. </div>
  170. </li>
  171. <?php
  172. endif;
  173. if ($PASSWORD):
  174. ?>
  175. <li>
  176. <div id="password" class="navbar-form hidden">
  177. <input type="password" id="passwordinput" placeholder="<?php echo I18n::_('Password (recommended)'); ?>" class="form-control" size="19" />
  178. </div>
  179. </li>
  180. <?php
  181. endif;
  182. if ($FILEUPLOAD):
  183. ?>
  184. <li id="attach" class="hidden dropdown">
  185. <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><?php echo I18n::_('Attach a file'); ?> <span class="caret"></span></a>
  186. <ul class="dropdown-menu">
  187. <li id="filewrap">
  188. <div>
  189. <input type="file" id="file" name="file" />
  190. </div>
  191. </li>
  192. <li>
  193. <a id="fileremovebutton" href="#">
  194. <?php echo I18n::_('Remove attachment'), PHP_EOL; ?>
  195. </a>
  196. </li>
  197. </ul>
  198. </li>
  199. <?php
  200. endif;
  201. ?>
  202. <li class="dropdown">
  203. <select id="pasteFormatter" name="pasteFormatter" class="hidden">
  204. <?php
  205. foreach ($FORMATTER as $key => $value):
  206. ?>
  207. <option value="<?php echo $key; ?>"<?php
  208. if ($key == $FORMATTERDEFAULT):
  209. ?> selected="selected"<?php
  210. endif;
  211. ?>><?php echo $value; ?></option>
  212. <?php
  213. endforeach;
  214. ?>
  215. </select>
  216. <a id="formatter" href="#" class="hidden dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><?php echo I18n::_('Format'); ?>: <span id="pasteFormatterDisplay"><?php echo $FORMATTER[$FORMATTERDEFAULT]; ?></span> <span class="caret"></span></a>
  217. <ul class="dropdown-menu">
  218. <?php
  219. foreach ($FORMATTER as $key => $value):
  220. ?>
  221. <li>
  222. <a href="#" data-format="<?php echo $key; ?>">
  223. <?php echo $value, PHP_EOL; ?>
  224. </a>
  225. </li>
  226. <?php
  227. endforeach;
  228. ?>
  229. </ul>
  230. </li>
  231. </ul>
  232. <ul class="nav navbar-nav pull-right">
  233. <?php
  234. if (strlen($LANGUAGESELECTION)):
  235. ?>
  236. <li id="language" class="dropdown">
  237. <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><span class="glyphicon glyphicon-flag" aria-hidden="true"></span> <?php echo $LANGUAGES[$LANGUAGESELECTION][0]; ?> <span class="caret"></span></a>
  238. <ul class="dropdown-menu">
  239. <?php
  240. foreach ($LANGUAGES as $key => $value):
  241. ?>
  242. <li>
  243. <a href="#" data-lang="<?php echo $key; ?>">
  244. <?php echo $value[0]; ?> (<?php echo $value[1]; ?>)
  245. </a>
  246. </li>
  247. <?php
  248. endforeach;
  249. ?>
  250. </ul>
  251. </li>
  252. <?php
  253. endif;
  254. ?>
  255. <li>
  256. <button id="newbutton" type="button" class="reloadlink hidden btn btn-warning navbar-btn">
  257. <span class="glyphicon glyphicon-file" aria-hidden="true"></span> <?php echo I18n::_('New'), PHP_EOL; ?>
  258. </button>
  259. </li>
  260. </ul>
  261. </div>
  262. </nav>
  263. <header class="container">
  264. <?php
  265. if (strlen($NOTICE)):
  266. ?>
  267. <div role="alert" class="alert alert-info">
  268. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span> <?php echo htmlspecialchars($NOTICE), PHP_EOL; ?>
  269. </div>
  270. <?php
  271. endif;
  272. ?>
  273. <div id="remainingtime" role="alert" class="hidden alert alert-info">
  274. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  275. </div>
  276. <?php
  277. if ($FILEUPLOAD):
  278. ?>
  279. <div id="attachment" role="alert" class="hidden alert alert-info">
  280. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span> <a><?php echo I18n::_('Download attachment'); ?></a> <span id="clonedfile" class="hidden"><?php echo I18n::_('Cloned file attached.'); ?></span>
  281. </div>
  282. <?php
  283. endif;
  284. if (strlen($STATUS)):
  285. ?>
  286. <div id="status" role="alert" class="alert alert-success">
  287. <span class="glyphicon glyphicon-ok" aria-hidden="true"></span> <?php echo htmlspecialchars($STATUS), PHP_EOL; ?>
  288. </div>
  289. <?php
  290. endif;
  291. ?>
  292. <div id="errormessage" role="alert" class="<?php
  293. if (!strlen($ERROR)):
  294. ?>hidden <?php
  295. endif;
  296. ?>alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> <?php echo htmlspecialchars($ERROR); ?></div>
  297. <noscript><div id="noscript" role="alert" class="nonworking alert alert-error"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> <?php echo I18n::_('Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.'); ?></div></noscript>
  298. <div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> <?php echo I18n::_('PrivateBin requires a modern browser to work.'); ?></div>
  299. <div id="ienotice" role="alert" class="hidden alert alert-error"><span class="glyphicon glyphicon-question-sign" aria-hidden="true"></span> <?php echo I18n::_('Still using Internet Explorer? Do yourself a favor, switch to a modern browser:'), PHP_EOL; ?>
  300. <a href="https://www.mozilla.org/firefox/">Firefox</a>,
  301. <a href="https://www.opera.com/">Opera</a>,
  302. <a href="https://www.google.com/chrome">Chrome</a>,
  303. <a href="https://www.apple.com/safari">Safari</a>...
  304. </div>
  305. <div id="pasteresult" role="alert" class="hidden alert alert-success">
  306. <span class="glyphicon glyphicon-ok" aria-hidden="true"></span>
  307. <div id="deletelink"></div>
  308. <div id="pastelink">
  309. <?php
  310. if (strlen($URLSHORTENER)):
  311. ?>
  312. <button id="shortenbutton" data-shortener="<?php echo htmlspecialchars($URLSHORTENER); ?>" type="button" class="btn btn-warning">
  313. <span class="glyphicon glyphicon-send" aria-hidden="true"></span> <?php echo I18n::_('Shorten URL'), PHP_EOL; ?>
  314. </button>
  315. <?php
  316. endif;
  317. ?>
  318. </div>
  319. </div>
  320. <ul id="preview" class="nav nav-tabs hidden">
  321. <li role="presentation" class="active"><a id="messageedit" href="#"><?php echo I18n::_('Editor'); ?></a></li>
  322. <li role="presentation"><a id="messagepreview" href="#"><?php echo I18n::_('Preview'); ?></a></li>
  323. </ul>
  324. </header>
  325. <section class="container">
  326. <article class="row">
  327. <div id="image" class="col-md-12 text-center hidden"></div>
  328. <div id="prettymessage" class="col-md-12 hidden">
  329. <pre id="prettyprint" class="col-md-12 prettyprint linenums:1"></pre>
  330. </div>
  331. <div id="cleartext" class="col-md-12 hidden"></div>
  332. <p class="col-md-12"><textarea id="message" name="message" cols="80" rows="25" class="form-control hidden"></textarea></p>
  333. </article>
  334. </section>
  335. <section class="container">
  336. <div id="discussion" class="hidden">
  337. <h4><?php echo I18n::_('Discussion'); ?></h4>
  338. <div id="comments"></div>
  339. </div>
  340. </section>
  341. <section class="container">
  342. <div id="noscript" role="alert" class="nonworking alert alert-info noscript-hide"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true">
  343. <span> <?php echo I18n::_('Loading…'); ?></span><br>
  344. <span class="small"><?php echo I18n::_('In case this message never disappears please have a look at <a href="https://github.com/PrivateBin/PrivateBin/wiki/FAQ#why-does-not-the-loading-message-go-away">this FAQ for information to troubleshoot</a>.'); ?></span>
  345. </div>
  346. </section>
  347. <footer class="container">
  348. <div class="row">
  349. <h4 class="col-md-5 col-xs-8"><?php echo I18n::_('PrivateBin'); ?> <small>- <?php echo I18n::_('Because ignorance is bliss'); ?></small></h4>
  350. <p class="col-md-1 col-xs-4 text-center"><?php echo $VERSION; ?></p>
  351. <p id="aboutbox" class="col-md-6 col-xs-12">
  352. <?php echo I18n::_('PrivateBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://privatebin.info/">project page</a>.'), PHP_EOL; ?>
  353. </p>
  354. </div>
  355. </footer>
  356. <div id="cipherdata" class="hidden"><?php echo htmlspecialchars($CIPHERDATA, ENT_NOQUOTES); ?></div>
  357. </body>
  358. </html>