Browse Source

tes1

pull/298/head
aulhaq 9 years ago
parent
commit
e965079d7c
52 changed files with 1981 additions and 391 deletions
  1. +1
    -0
      .gitignore
  2. +14
    -16
      README.md
  3. +7
    -10
      composer.json
  4. +8
    -65
      composer.lock
  5. +1
    -1
      config/config.ini
  6. +9
    -0
      config/users/noxymon.ini
  7. +7
    -0
      nbproject/project.properties
  8. +9
    -0
      nbproject/project.xml
  9. +1
    -1
      system/admin/admin.php
  10. +2
    -2
      system/admin/views/edit-content.html.php
  11. +62
    -0
      system/admin/views/layout.html.old.php
  12. +53
    -46
      system/admin/views/layout.html.php
  13. +44
    -24
      system/admin/views/login.html.php
  14. +29
    -0
      system/admin/views/login_old.html.php
  15. +153
    -0
      system/admin/views/main-admin.html
  16. +8
    -18
      system/htmly.php
  17. +2
    -2
      system/includes/dispatch.php
  18. +56
    -8
      system/includes/functions.php
  19. +3
    -0
      system/plugins/urlify/.gitignore
  20. +15
    -0
      system/plugins/urlify/.travis.yml
  21. +10
    -0
      system/plugins/urlify/INSTALL
  22. +27
    -0
      system/plugins/urlify/LICENSE
  23. +94
    -0
      system/plugins/urlify/README.md
  24. +268
    -0
      system/plugins/urlify/URLify.php
  25. +26
    -0
      system/plugins/urlify/composer.json
  26. +8
    -0
      system/plugins/urlify/phpunit.xml
  27. +20
    -0
      system/plugins/urlify/scripts/downcode.php
  28. +20
    -0
      system/plugins/urlify/scripts/filter.php
  29. +20
    -0
      system/plugins/urlify/scripts/transliterate.php
  30. +54
    -0
      system/plugins/urlify/tests/URLifyTest.php
  31. +9
    -0
      system/plugins/urlify/tests/bootstrap.php
  32. +587
    -0
      system/resources/css/bootstrap-theme.css
  33. +6
    -0
      system/resources/css/bootstrap.min.css
  34. +105
    -0
      system/resources/css/dashboard.css
  35. +13
    -0
      system/resources/css/ie10-viewport-bug-workaround.css
  36. +40
    -0
      system/resources/css/signin.css
  37. +7
    -0
      system/resources/js/bootstrap.min.js
  38. +12
    -0
      system/resources/js/holder.min.js
  39. +51
    -0
      system/resources/js/ie-emulation-modes-warning.js
  40. +23
    -0
      system/resources/js/ie10-viewport-bug-workaround.js
  41. +13
    -0
      system/resources/js/ie8-responsive-file-warning.js
  42. +5
    -5
      system/resources/js/jquery.min.js
  43. +1
    -1
      system/vendor/autoload.php
  44. +4
    -4
      system/vendor/composer/ClassLoader.php
  45. +1
    -1
      system/vendor/composer/LICENSE
  46. +0
    -2
      system/vendor/composer/autoload_classmap.php
  47. +7
    -6
      system/vendor/composer/autoload_files.php
  48. +0
    -1
      system/vendor/composer/autoload_namespaces.php
  49. +17
    -28
      system/vendor/composer/autoload_real.php
  50. +46
    -102
      system/vendor/composer/installed.json
  51. +1
    -46
      system/vendor/suin/php-rss-writer/Tests/Suin/RSSWriter/ItemTest.php
  52. +2
    -2
      system/vendor/suin/php-rss-writer/src/Suin/RSSWriter/Item.php

+ 1
- 0
.gitignore View File

@ -0,0 +1 @@
/nbproject/private/

+ 14
- 16
README.md View File

@ -1,6 +1,6 @@
<a href="https://www.htmly.com" target="_blank">![Logo](https://raw.githubusercontent.com/danpros/htmly/master/system/resources/images/logo-big.png)</a>
HTMLy is an open source Databaseless Blogging Platform or Flat-File Blog prioritizes simplicity and speed written in PHP. HTMLy can be referred to as Flat-File CMS either since it will also manage your content.
HTMLy is an open source databaseless web publishing platform that prioritizes simplicity and speed. HTMLy can be referred to as a Flat-File Blog or Flat-File CMS, since it will also manage your content.
You do not need to use a VPS to run HTMLy, shared hosting or even [free hosting](https://github.com/danpros/htmly#openshift) should work as long as the host supports at least PHP 5.3.
@ -49,12 +49,10 @@ HTMLy requires PHP 5.3 or greater and php-xml package.
Installations
-------------
If you have an OpenSSL enabled server (usually enabled by default), use the [installer.php](https://github.com/danpros/htmly/releases/latest) and read the following [instructions](https://docs.htmly.com/basics/installations) to get started. If you don't have OpenSSL, please download the latest version, extract it, then upload the extracted files to your server. Also, make sure the installation folder is writeable by your server.
If you have an OpenSSL enabled server (usually enabled by default), use the [installer](https://github.com/Kanti/htmly-installer/releases/latest) and read the following [instructions](https://github.com/Kanti/htmly-installer/blob/master/README.md#htmly-installerphp) to get started. If you don't have OpenSSL, please download the latest version, extract it, then upload the extracted files to your server. Also, make sure the installation folder is writeable by your server.
Configurations
--------------
Set written permission for the `cache` and `content` directories.
Rename `config.ini.example` inside the `config` folder to `config.ini` (or you can create a new `config/config.ini` file) then change the site settings there.
Create `YourUsername.ini` inside the `config/users` folder or simply rename the `username.ini.example` file and write down your password there:
@ -131,7 +129,7 @@ server {
OpenShift
---------
Need a free server to test HTMLy? try [OpenShift](https://www.openshift.com) using the [HTMLy OpenShift QuickStart](https://hub.openshift.com/quickstarts/219-htmly) for easy deployment.
Need a free server to test HTMLy? try [OpenShift](https://www.openshift.com) using the [HTMLy OpenShift QuickStart](https://github.com/danpros/htmly-openshift) for easy deployment.
**Quick install:**
@ -166,8 +164,8 @@ The default category is `Uncategorized` with slug `uncategorized` and you do not
<!--t New category title t-->
<!--d New category meta description d-->
New category info etc.
````
New category info etc.
````
The slug for the new category is `new-category` (htmly removing the file extension). And for full file directory:
````
content/username/new-category/post/file.md
@ -186,7 +184,7 @@ Here's the explanation (separated by an underscore):
- `2014-01-31-12-56-40` is the published date. The date format is `yyyy-mm-dd-hh-mm-ss`
- `tag1,tag2,tag3` are the tags, separated by commas
- `databaseless-blogging-platform-flat-file-blog` is the URL
For static pages, use the following format:
````
@ -212,54 +210,54 @@ If you are writing offline, you need specify the content tags below:
**Title**
```html
<!--t Title t-->
````
````
**Meta description**
```html
<!--d The meta description d-->
````
````
**Tags**
This is just the tags display and for the slug is in the filename.
```html
<!--tag Tag1,Tag2 tag-->
````
````
**Featured image**
Post with featured image.
```html
<!--image http://www.example.com/image-url/image.jpg image-->
````
````
**Featured youtube video**
Post with featured youtube video.
```html
<!--video https://www.youtube.com/watch?v=xxxxxxx video-->
````
````
**Featured soundcloud audio**
Post with featured soundcloud audio.
```html
<!--audio https://soundcloud.com/xxxx/audio-url audio-->
````
````
**Featured link**
Post with featured link.
```html
<!--link https://github.com/danpros/htmly link-->
````
````
**Featured quote**
Post with featured quote.
```html
<!--quote Premature Optimization is The Root of All Evil quote-->
````
````
**Example**


+ 7
- 10
composer.json View File

@ -1,17 +1,13 @@
{
"config": {
"vendor-dir": "system/vendor/",
"optimize-autoloader": true,
"platform": {
"php": "5.3"
}
"optimize-autoloader": true
},
"require": {
"ircmaxell/password-compat": "1.*",
"michelf/php-markdown": "1.*",
"suin/php-rss-writer": "1.*",
"kanti/hub-updater": "0.*",
"jbroadway/urlify": "^1.0"
"ircmaxell/password-compat": "^1.0",
"michelf/php-markdown": "^1.5",
"suin/php-rss-writer": "^1.3",
"kanti/hub-updater": "^0.4.0"
},
"autoload": {
"files": [
@ -19,7 +15,8 @@
"system/includes/functions.php",
"system/admin/admin.php",
"system/includes/session.php",
"system/includes/opml.php"
"system/includes/opml.php",
"system/plugins/urlify/URLify.php"
]
}
}

+ 8
- 65
composer.lock View File

@ -4,8 +4,8 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"hash": "4b4af0298a863441fda250d818d3fc4b",
"content-hash": "250bd035a1d26dd3e3e01e504833c798",
"hash": "5bdfc8dcf4f971b8f61fd8439dd9cbdb",
"content-hash": "e98ae62bcc711211dfb7c7c70e7fdfc7",
"packages": [
{
"name": "ircmaxell/password-compat",
@ -49,60 +49,6 @@
],
"time": "2014-11-20 16:49:30"
},
{
"name": "jbroadway/urlify",
"version": "1.0.8-stable",
"source": {
"type": "git",
"url": "https://github.com/jbroadway/urlify.git",
"reference": "984c991881501098eafdc41053b243237191cff8"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/jbroadway/urlify/zipball/984c991881501098eafdc41053b243237191cff8",
"reference": "984c991881501098eafdc41053b243237191cff8",
"shasum": ""
},
"require": {
"php": ">=5.3.0"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.0-dev"
}
},
"autoload": {
"psr-0": {
"URLify": ""
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD"
],
"authors": [
{
"name": "Johnny Broadway",
"email": "johnny@johnnybroadway.com",
"homepage": "http://www.johnnybroadway.com/"
}
],
"description": "PHP port of URLify.js from the Django project. Transliterates non-ascii characters for use in URLs.",
"homepage": "https://github.com/jbroadway/urlify",
"keywords": [
"encode",
"iconv",
"link",
"slug",
"translit",
"transliterate",
"transliteration",
"url",
"urlify"
],
"time": "2016-07-27 15:26:43"
},
{
"name": "kanti/hub-updater",
"version": "v0.4.1",
@ -200,16 +146,16 @@
},
{
"name": "suin/php-rss-writer",
"version": "1.3.2",
"version": "1.3.1",
"source": {
"type": "git",
"url": "https://github.com/suin/php-rss-writer.git",
"reference": "51840d2fad4087a4bdd93fb6937aa4b324b5c94f"
"reference": "96ff59575442dbe23e15fe7ff56d0bf27486cff9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/suin/php-rss-writer/zipball/51840d2fad4087a4bdd93fb6937aa4b324b5c94f",
"reference": "51840d2fad4087a4bdd93fb6937aa4b324b5c94f",
"url": "https://api.github.com/repos/suin/php-rss-writer/zipball/96ff59575442dbe23e15fe7ff56d0bf27486cff9",
"reference": "96ff59575442dbe23e15fe7ff56d0bf27486cff9",
"shasum": ""
},
"require": {
@ -240,7 +186,7 @@
"rss",
"writer"
],
"time": "2016-03-01 12:09:17"
"time": "2015-08-21 06:24:39"
}
],
"packages-dev": [],
@ -250,8 +196,5 @@
"prefer-stable": false,
"prefer-lowest": false,
"platform": [],
"platform-dev": [],
"platform-overrides": {
"php": "5.3"
}
"platform-dev": []
}

+ 1
- 1
config/config.ini View File

@ -1,5 +1,5 @@
; The URL of your blog. Include the http or https if you are using Facebook or Disqus comment.
site.url = ""
site.url = "http://localhost/htmlx"
; Your timezone
timezone = "Asia/Jakarta"


+ 9
- 0
config/users/noxymon.ini View File

@ -0,0 +1,9 @@
;Password
password = admin
encryption = clear
; encryption: not set, leave blank or set to clear or none to use plain text password for the user,
; else set to encryption algoritm supported by hash function of php to use the selected
; encryption
;Role
role = admin

+ 7
- 0
nbproject/project.properties View File

@ -0,0 +1,7 @@
include.path=${php.global.include.path}
php.version=PHP_70
source.encoding=UTF-8
src.dir=.
tags.asp=false
tags.short=false
web.root=.

+ 9
- 0
nbproject/project.xml View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://www.netbeans.org/ns/project/1">
<type>org.netbeans.modules.php.project</type>
<configuration>
<data xmlns="http://www.netbeans.org/ns/php-project/1">
<name>htmly</name>
</data>
</configuration>
</project>

+ 1
- 1
system/admin/admin.php View File

@ -43,7 +43,7 @@ function session($user, $pass)
{
$user_file = 'config/users/' . $user . '.ini';
if (!file_exists($user_file)) {
return $str = '<li>Username not found in our record.</li>';
return $str = 'Username not found in our record.';
}
$user_enc = user('encryption', $user);


+ 2
- 2
system/admin/views/edit-content.html.php View File

@ -95,7 +95,7 @@ if (config('permalink.type') == 'post') {
<input type="date" name="date" class="text" value="<?php echo date('Y-m-d', $postdate); ?>">
<br>
Hour, Minute, Second<br>
<input step="1" type="time" name="time" class="text" value="<?php echo $time->format('H:i:s'); ?>">
<input type="time" name="time" class="text" value="<?php echo $time->format('H:i:s'); ?>">
<br><br>
Meta Description (optional)<br>
<textarea name="description" rows="3" cols="20"><?php if (isset($p->description)) { echo $p->description; } else { echo $olddescription;} ?></textarea>
@ -170,4 +170,4 @@ if (config('permalink.type') == 'post') {
<div id="wmd-preview" class="wmd-panel wmd-preview"></div>
<!-- Declare the base path. Important -->
<script type="text/javascript">var base_path = '<?php echo site_url() ?>';</script>
<script type="text/javascript" src="<?php echo site_url() ?>system/admin/editor/js/editor.js"></script>
<script type="text/javascript" src="<?php echo site_url() ?>system/admin/editor/js/editor.js"></script>

+ 62
- 0
system/admin/views/layout.html.old.php View File

@ -0,0 +1,62 @@
<!DOCTYPE html>
<html>
<anuan></anuan>
<head>
<?php echo head_contents() ?>
<title><?php echo $title;?></title>
<meta name="description" content="<?php echo $description; ?>"/>
<?php if($canonical): ?>
<link rel="canonical" href="<?php echo $canonical; ?>" />
<?php endif; ?>
<link href="<?php echo site_url() ?>system/resources/css/admin.css" rel="stylesheet"/>
<link href="//fonts.googleapis.com/css?family=Open+Sans:400,700" rel="stylesheet" type="text/css">
<?php if (publisher()): ?>
<link href="<?php echo publisher() ?>" rel="publisher" /><?php endif; ?>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body class="admin <?php echo $bodyclass; ?>" itemscope="itemscope" itemtype="http://schema.org/Blog">
<div class="hide">
<meta content="<?php echo blog_title() ?>" itemprop="name"/>
<meta content="<?php echo blog_description() ?>" itemprop="description"/>
</div>
<?php if (login()) {
toolbar();
} ?>
<div id="outer-wrapper">
<div id="menu-wrapper">
<div class="container">
<nav id="menu">
<?php echo search() ?>
</nav>
</div>
</div>
<div id="header-wrapper">
<div class="container">
<header id="header">
<section id="branding">
<h1 class="blog-title"><a href="<?php echo site_url() ?>"><?php echo blog_title() ?></a></h1>
<div class="blog-tagline"><p><?php echo blog_tagline() ?></p></div>
</section>
</header>
</div>
</div>
<div id="content-wrapper">
<div class="container">
<section id="content">
<?php echo content() ?>
</section>
</div>
</div>
<div id="footer-wrapper">
<div class="container">
<footer id="footer">
<div class="copyright"><?php echo copyright() ?></div>
</footer>
</div>
</div>
</div>
<?php if (analytics()): ?><?php echo analytics() ?><?php endif; ?>
</body>
</html>

+ 53
- 46
system/admin/views/layout.html.php View File

@ -1,62 +1,69 @@
<!DOCTYPE html>
<html>
<head>
<html lang="en">
<head>
<?php echo head_contents() ?>
<title><?php echo $title;?></title>
<meta name="description" content="<?php echo $description; ?>"/>
<?php if($canonical): ?>
<link rel="canonical" href="<?php echo $canonical; ?>" />
<?php endif; ?>
<link href="<?php echo site_url() ?>system/resources/css/admin.css" rel="stylesheet"/>
<link href="//fonts.googleapis.com/css?family=Open+Sans:400,700" rel="stylesheet" type="text/css">
<link href="<?php echo site_url() ?>system/resources/css/bootstrap.min.css" rel="stylesheet">
<link href="<?php echo site_url() ?>system/resources/css/ie10-viewport-bug-workaround.css" rel="stylesheet">
<link href="<?php echo site_url() ?>system/resources/css/dashboard.css" rel="stylesheet">
<!--[if lt IE 9]><script src="<?php echo site_url() ?>system/resources/js/ie8-responsive-file-warning.js"></script><![endif]-->
<script src="<?php echo site_url() ?>system/resources/js/ie-emulation-modes-warning.js"></script>
<?php if (publisher()): ?>
<link href="<?php echo publisher() ?>" rel="publisher" /><?php endif; ?>
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<body class="admin <?php echo $bodyclass; ?>" itemscope="itemscope" itemtype="http://schema.org/Blog">
<div class="hide">
<meta content="<?php echo blog_title() ?>" itemprop="name"/>
<meta content="<?php echo blog_description() ?>" itemprop="description"/>
</div>
<?php if (login()) {
toolbar();
} ?>
<div id="outer-wrapper">
<div id="menu-wrapper">
<div class="container">
<nav id="menu">
<?php echo menu() ?>
<?php echo search() ?>
</nav>
</head>
<body>
<nav class="navbar navbar-inverse navbar-fixed-top">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="<?php echo site_url() ?>admin">Dashboard</a>
</div>
</div>
<div id="header-wrapper">
<div class="container">
<header id="header">
<section id="branding">
<h1 class="blog-title"><a href="<?php echo site_url() ?>"><?php echo blog_title() ?></a></h1>
<div class="blog-tagline"><p><?php echo blog_tagline() ?></p></div>
</section>
</header>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav navbar-right">
<?php
if (login()) {
newToolBar();
}
?>
</ul>
<?php echo search() ?>
</div>
</div>
<div id="content-wrapper">
<div class="container">
<section id="content">
<?php echo content() ?>
</section>
</div>
</nav>
<div class="container-fluid">
<div class="row">
<div class="col-sm-3 col-md-2 sidebar list-group">
<?php echo sideBar(); ?>
</div>
</div>
<div id="footer-wrapper">
<div class="container">
<footer id="footer">
<div class="copyright"><?php echo copyright() ?></div>
</footer>
<div class="col-sm-9 col-sm-offset-3 col-md-10 col-md-offset-2 main">
<?php echo content() ?>
</div>
</div>
</div>
</div>
<?php if (analytics()): ?><?php echo analytics() ?><?php endif; ?>
</body>
</html>
<!-- Bootstrap core JavaScript
================================================== -->
<!-- Placed at the end of the document so the pages load faster -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<script>window.jQuery || document.write('<script src="<?php echo site_url() ?>system/resources/js/jquery.min.js"><\/script>')</script>
<script src="<?php echo site_url() ?>system/resources/js/bootstrap.min.js"></script>
<script src="<?php echo site_url() ?>system/resources/js/holder.min.js"></script>
<script src="<?php echo site_url() ?>system/resources/js/ie10-viewport-bug-workaround.js"></script>
</body>
</html>

+ 44
- 24
system/admin/views/login.html.php View File

@ -1,29 +1,49 @@
<?php if (isset($error)) { ?>
<div class="error-message"><?php echo $error ?></div>
<?php } ?>
<?php if (!login()) { ?>
<h1>Login</h1>
<form method="POST" action="login">
User <span class="required">*</span> <br>
<input type="text" class="<?php if (isset($username)) {
if (empty($username)) {
echo 'error';
}
} ?>" name="user"/><br><br>
Password <span class="required">*</span> <br>
<input type="password" class="<?php if (isset($password)) {
if (empty($password)) {
echo 'error';
}
} ?>" name="password"/><br><br>
<input type="hidden" name="csrf_token" value="<?php echo get_csrf() ?>">
<?php if (config('google.reCaptcha') === 'true'): ?>
<script src='https://www.google.com/recaptcha/api.js'></script>
<div class="g-recaptcha" data-sitekey="<?php echo config("google.reCaptcha.public"); ?>"></div>
<br/>
<!DOCTYPE html>
<html lang="en">
<head>
<?php echo head_contents() ?>
<meta name="description" content="">
<?php if($canonical): ?>
<link rel="canonical" href="<?php echo $canonical; ?>" />
<?php endif; ?>
<input type="submit" name="submit" value="Login"/>
</form>
<link href="<?php echo site_url() ?>system/resources/css/bootstrap.min.css" rel="stylesheet">
<link href="<?php echo site_url() ?>system/resources/css/ie10-viewport-bug-workaround.css" rel="stylesheet">
<link href="<?php echo site_url() ?>system/resources/css/signin.css" rel="stylesheet">
<!--[if lt IE 9]><script src="<?php echo site_url() ?>system/resources/js/ie8-responsive-file-warning.js"></script><![endif]-->
<script src="<?php echo site_url() ?>system/resources/js/ie-emulation-modes-warning.js"></script>
<script src="<?php echo site_url() ?>system/resources/js/ie-emulation-modes-warning.js"></script>
<?php if (publisher()): ?>
<link href="<?php echo publisher() ?>" rel="publisher" /><?php endif; ?>
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<body>
<div class="container">
<?php if (isset($error)) { ?>
<div class="alert alert-danger alert-dismissible" role="alert">
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<strong>ERROR!</strong> <?php echo $error ?>
</div>
<?php } ?>
<form class="form-signin" method="POST" action="login">
<h2 class="form-signin-heading">Please sign in</h2>
<label for="inputUsername" class="sr-only">Username</label>
<input name="user" type="username" id="inputUsername" class="form-control" placeholder="your username ..." required autofocus>
<label for="inputPassword" class="sr-only">Password</label>
<input name="password" type="password" id="inputPassword" class="form-control" placeholder="your password" required>
<input type="hidden" name="csrf_token" value="<?php echo get_csrf() ?>">
<button class="btn btn-lg btn-primary btn-block" type="submit" value="login">Sign in</button>
<br/>
<a type="button" href="<?php echo site_url() ?>"><< Return to Blog</a>
</form>
</div>
<script src="<?php echo site_url() ?>system/resources/js/ie10-viewport-bug-workaround.js"></script>
</body>
</html>
<?php } else {
header('location: admin');
} ?>

+ 29
- 0
system/admin/views/login_old.html.php View File

@ -0,0 +1,29 @@
<?php if (isset($error)) { ?>
<div class="error-message"><?php echo $error ?></div>
<?php } ?>
<?php if (!login()) { ?>
<h1>Login</h1>
<form method="POST" action="login">
User <span class="required">*</span> <br>
<input type="text" class="<?php if (isset($username)) {
if (empty($username)) {
echo 'error';
}
} ?>" name="user"/><br><br>
Password <span class="required">*</span> <br>
<input type="password" class="<?php if (isset($password)) {
if (empty($password)) {
echo 'error';
}
} ?>" name="password"/><br><br>
<input type="hidden" name="csrf_token" value="<?php echo get_csrf() ?>">
<?php if (config('google.reCaptcha') === 'true'): ?>
<script src='https://www.google.com/recaptcha/api.js'></script>
<div class="g-recaptcha" data-sitekey="<?php echo config("google.reCaptcha.public"); ?>"></div>
<br/>
<?php endif; ?>
<input type="submit" name="submit" value="Login"/>
</form>
<?php } else {
header('location: admin');
} ?>

+ 153
- 0
system/admin/views/main-admin.html View File

@ -0,0 +1,153 @@
<h1 class="page-header">Dashboard</h1>
<div class="row placeholders">
<div class="col-xs-6 col-sm-3 placeholder">
<img src="data:image/gif;base64,R0lGODlhAQABAIAAAHd3dwAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw==" width="200" height="200" class="img-responsive" alt="Generic placeholder thumbnail">
<h4>Label</h4>
<span class="text-muted">Something else</span>
</div>
<div class="col-xs-6 col-sm-3 placeholder">
<img src="data:image/gif;base64,R0lGODlhAQABAIAAAHd3dwAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw==" width="200" height="200" class="img-responsive" alt="Generic placeholder thumbnail">
<h4>Label</h4>
<span class="text-muted">Something else</span>
</div>
<div class="col-xs-6 col-sm-3 placeholder">
<img src="data:image/gif;base64,R0lGODlhAQABAIAAAHd3dwAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw==" width="200" height="200" class="img-responsive" alt="Generic placeholder thumbnail">
<h4>Label</h4>
<span class="text-muted">Something else</span>
</div>
<div class="col-xs-6 col-sm-3 placeholder">
<img src="data:image/gif;base64,R0lGODlhAQABAIAAAHd3dwAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw==" width="200" height="200" class="img-responsive" alt="Generic placeholder thumbnail">
<h4>Label</h4>
<span class="text-muted">Something else</span>
</div>
</div>
<h2 class="sub-header">Section title</h2>
<div class="table-responsive">
<table class="table table-striped">
<thead>
<tr>
<th>#</th>
<th>Header</th>
<th>Header</th>
<th>Header</th>
<th>Header</th>
</tr>
</thead>
<tbody>
<tr>
<td>1,001</td>
<td>Lorem</td>
<td>ipsum</td>
<td>dolor</td>
<td>sit</td>
</tr>
<tr>
<td>1,002</td>
<td>amet</td>
<td>consectetur</td>
<td>adipiscing</td>
<td>elit</td>
</tr>
<tr>
<td>1,003</td>
<td>Integer</td>
<td>nec</td>
<td>odio</td>
<td>Praesent</td>
</tr>
<tr>
<td>1,003</td>
<td>libero</td>
<td>Sed</td>
<td>cursus</td>
<td>ante</td>
</tr>
<tr>
<td>1,004</td>
<td>dapibus</td>
<td>diam</td>
<td>Sed</td>
<td>nisi</td>
</tr>
<tr>
<td>1,005</td>
<td>Nulla</td>
<td>quis</td>
<td>sem</td>
<td>at</td>
</tr>
<tr>
<td>1,006</td>
<td>nibh</td>
<td>elementum</td>
<td>imperdiet</td>
<td>Duis</td>
</tr>
<tr>
<td>1,007</td>
<td>sagittis</td>
<td>ipsum</td>
<td>Praesent</td>
<td>mauris</td>
</tr>
<tr>
<td>1,008</td>
<td>Fusce</td>
<td>nec</td>
<td>tellus</td>
<td>sed</td>
</tr>
<tr>
<td>1,009</td>
<td>augue</td>
<td>semper</td>
<td>porta</td>
<td>Mauris</td>
</tr>
<tr>
<td>1,010</td>
<td>massa</td>
<td>Vestibulum</td>
<td>lacinia</td>
<td>arcu</td>
</tr>
<tr>
<td>1,011</td>
<td>eget</td>
<td>nulla</td>
<td>Class</td>
<td>aptent</td>
</tr>
<tr>
<td>1,012</td>
<td>taciti</td>
<td>sociosqu</td>
<td>ad</td>
<td>litora</td>
</tr>
<tr>
<td>1,013</td>
<td>torquent</td>
<td>per</td>
<td>conubia</td>
<td>nostra</td>
</tr>
<tr>
<td>1,014</td>
<td>per</td>
<td>inceptos</td>
<td>himenaeos</td>
<td>Curabitur</td>
</tr>
<tr>
<td>1,015</td>
<td>sodales</td>
<td>ligula</td>
<td>in</td>
<td>libero</td>
</tr>
</tbody>
</table>
</div>

+ 8
- 18
system/htmly.php View File

@ -121,7 +121,7 @@ get('/index', function () {
// Get submitted login data
post('/login', function () {
$proper = (is_csrf_proper(from($_REQUEST, 'csrf_token')));
$captcha = isCaptcha(from($_REQUEST, 'g-recaptcha-response'));
@ -131,21 +131,17 @@ post('/login', function () {
session($user, $pass);
$log = session($user, $pass);
if (!empty($log)) {
config('views.root', 'system/admin/views');
render('login', array(
'title' => 'Login - ' . blog_title(),
'description' => 'Login page on ' . blog_title(),
'canonical' => site_url(),
'error' => '<ul>' . $log . '</ul>',
'error' => $log,
'type' => 'is_login',
'is_login' => true,
'bodyclass' => 'in-login',
'breadcrumb' => '<a href="' . site_url() . '">' . config('breadcrumb.home') . '</a> &#187; Login'
));
), FALSE);
}
} else {
$message['error'] = '';
@ -163,12 +159,12 @@ post('/login', function () {
}
config('views.root', 'system/admin/views');
render('login', array(
'title' => 'Login - ' . blog_title(),
'description' => 'Login page on ' . blog_title(),
'canonical' => site_url(),
'error' => '<ul>' . $message['error'] . '</ul>',
'error' => $message['error'],
'username' => $user,
'password' => $pass,
'type' => 'is_login',
@ -1386,7 +1382,7 @@ get('/admin/categories', function () {
'is_admin' => true,
'bodyclass' => 'admin-categories',
'breadcrumb' => '<a href="' . site_url() . '">' . config('breadcrumb.home') . '</a> &#187; Categories'
));
), 'layout');
} else {
$login = site_url() . 'login';
header("location: $login");
@ -2332,13 +2328,7 @@ get('/:static', function ($static) {
die;
} elseif ($static === 'login') {
config('views.root', 'system/admin/views');
render('login', array(
'title' => 'Login - ' . blog_title(),
'description' => 'Login page from ' . blog_title() . '.',
'canonical' => site_url() . '/login',
'bodyclass' => 'in-login',
'breadcrumb' => '<a href="' . site_url() . '">' . config('breadcrumb.home') . '</a> &#187; Login'
));
render('login',NULL, FALSE);
die;
} elseif ($static === 'logout') {
if (login()) {


+ 2
- 2
system/includes/dispatch.php View File

@ -314,7 +314,7 @@ function render($view, $locals = null, $layout = null)
mkdir($dir, 0775, true);
}
}
if (is_array($locals) && count($locals)) {
extract($locals, EXTR_SKIP);
}
@ -325,7 +325,7 @@ function render($view, $locals = null, $layout = null)
ob_start();
include "{$view_root}/{$view}.html.php";
content(trim(ob_get_clean()));
if ($layout !== false) {
if ($layout == null) {
$layout = config('views.layout');


+ 56
- 8
system/includes/functions.php View File

@ -2140,20 +2140,18 @@ function get_menu($custom)
}
// Search form
function search($text = null)
function search()
{
if(!empty($text)) {
echo <<<EOF
<form id="search-form" method="get">
<input type="text" class="search-input" name="search" value="{$text}" onfocus="if (this.value == '{$text}') {this.value = '';}" onblur="if (this.value == '') {this.value = '{$text}';}">
<input type="submit" value="{$text}" class="search-button">
<form id="search-form" class="navbar-form navbar-right" method="get">
<input type="text" class="search-input form-control" name="search" value="{$text}" onfocus="if (this.value == '{$text}') {this.value = '';}" onblur="if (this.value == '') {this.value = '{$text}';}">
</form>
EOF;
} else {
echo <<<EOF
<form id="search-form" method="get">
<input type="text" class="search-input" name="search" value="Search" onfocus="if (this.value == 'Search') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Search';}">
<input type="submit" value="Search" class="search-button">
<form id="search-form" class="navbar-form navbar-right" method="get">
<input type="text" class="search-input form-control" name="search" value="Search" onfocus="if (this.value == 'Search') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Search';}">
</form>
EOF;
}
@ -2749,6 +2747,56 @@ function head_contents()
return $output;
}
function newToolBar(){
$user = $_SESSION[config("site.url")]['user'];
$role = user('role', $user);
$base = site_url();
if ($role === 'admin') {
echo "<li class='dropdown'>
<a type='button' class='dropdown-toggle' data-toggle='dropdown' href='#'>
System
<span class='caret'></span>
</a>
<ul class='dropdown-menu'>
<li><a href={$base}admin/config>Config</a></li>
<li><a href={$base}admin/update>Update</a></li>
<li role='separator' class='divider'></li>
<li><a href={$base}admin/clear-cache>Clear Cache</a></li>
</ul>
</li>";
}
echo "<li class='dropdown'>
<a type='button' class='dropdown-toggle' data-toggle='dropdown' href='#'>
Profile
<span class='caret'></span>
</a>
<ul class='dropdown-menu'>
<li><a href={$base}edit/profile>Edit Profile</a></li>
<li role='separator' class='divider'></li>
<li><a href={$base}logout>Logout</a></li>
</ul>
</li>";
}
function sideBar(){
$base = site_url();
echo <<<EOF
<ul class="nav nav-sidebar">
<li class=""><a href="{$base}admin">Overview <span class="sr-only">(current)</span></a></li>
<li>
<a data-toggle="collapse" href="#collapsePost" aria-expanded="true">Post <span class="caret"></span></a>
<div id="collapsePost" class="collapse">
<ul style="list-style-type: none">
<li style="padding: 5px 0px 5px 0px"><a href="{$base}admin/posts">All Post</a></li>
<li style="padding: 5px 0px 5px 0px"><a href="{$base}admin/content">Add New</a></li>
</ul>
</div>
</li>
<li><a href="{$base}admin/categories">Categories</a></li>
</ul>
EOF;
}
// Return toolbar
function toolbar()
{
@ -2777,7 +2825,7 @@ EOF;
echo '<li><a href="' . $base . 'admin/import">Import</a></li>';
echo '<li><a href="' . $base . 'admin/backup">Backup</a></li>';
if ($role === 'admin') {
echo '<li><a href="' . $base . 'admin/config">Config</a></li>';
echo '<li><a href="' . $base . 'admin/config">Config</a></li>';
}
echo '<li><a href="' . $base . 'admin/clear-cache">Clear cache</a></li>';
echo '<li><a href="' . $base . 'admin/update">Update</a></li>';


+ 3
- 0
system/plugins/urlify/.gitignore View File

@ -0,0 +1,3 @@
vendor
composer.phar
composer.lock

+ 15
- 0
system/plugins/urlify/.travis.yml View File

@ -0,0 +1,15 @@
language: php
php:
- 5.3
- 5.4
- 5.5
- 5.6
- 7.0
- hhvm
before_script:
- composer install --no-interaction --prefer-source
script:
- phpunit --coverage-text --verbose

+ 10
- 0
system/plugins/urlify/INSTALL View File

@ -0,0 +1,10 @@
To install URLify, you can add it as a dependency ar by downloading the composer.phar executable.
$ curl -s http://getcomposer.org/installer | php
and run install
$ php composer.phar install
For more details, see http://getcomposer.org.

+ 27
- 0
system/plugins/urlify/LICENSE View File

@ -0,0 +1,27 @@
Copyright (c) Django Software Foundation and individual contributors.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. Neither the name of Django nor the names of its contributors may be used
to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

+ 94
- 0
system/plugins/urlify/README.md View File

@ -0,0 +1,94 @@
# URLify for PHP
A PHP port of [URLify.js](https://github.com/django/django/blob/master/django/contrib/admin/static/admin/js/urlify.js)
from the Django project. Handles symbols from Latin languages as well as Arabic, Azerbaijani, Czech, German, Greek,
Latvian, Lithuanian, Polish, Romanian, Bulgarian, Russian, Serbian, Turkish, Ukrainian and Vietnamese. Symbols it cannot
transliterate it will simply omit.
## Usage:
To generate slugs for URLs:
```php
<?php
echo URLify::filter (' J\'étudie le français ');
// "jetudie-le-francais"
echo URLify::filter ('Lo siento, no hablo español.');
// "lo-siento-no-hablo-espanol"
?>
```
To generate slugs for file names:
```php
<?php
echo URLify::filter ('фото.jpg', 60, "", true);
// "foto.jpg"
?>
```
To simply transliterate characters:
```php
<?php
echo URLify::downcode ('J\'étudie le français');
// "J'etudie le francais"
echo URLify::downcode ('Lo siento, no hablo español.');
// "Lo siento, no hablo espanol."
/* Or use transliterate() alias: */
echo URLify::transliterate ('Lo siento, no hablo español.');
// "Lo siento, no hablo espanol."
?>
```
To extend the character list:
```php
<?php
URLify::add_chars (array (
'¿' => '?', '®' => '(r)', '¼' => '1/4',
'½' => '1/2', '¾' => '3/4', '¶' => 'P'
));
echo URLify::downcode ('¿ ® ¼ ¼ ¾ ¶');
// "? (r) 1/2 1/2 3/4 P"
?>
```
To extend the list of words to remove:
```php
<?php
URLify::remove_words (array ('remove', 'these', 'too'));
?>
```
To prioritize a certain language map:
```php
<?php
echo URLify::filter (' Ägypten und Österreich besitzen wie üblich ein Übermaß an ähnlich öligen Attachés ',60,"de");
// "aegypten-und-oesterreich-besitzen-wie-ueblich-ein-uebermass-aehnlich-oeligen-attaches"
echo URLify::filter ('Cağaloğlu, çalıştığı, müjde, lazım, mahkûm',60,"tr");
// "cagaloglu-calistigi-mujde-lazim-mahkum"
?>
```
Please note that the "ü" is transliterated to "ue" in the first case, whereas it results in a simple "u" in the latter.

+ 268
- 0
system/plugins/urlify/URLify.php View File

@ -0,0 +1,268 @@
<?php
/**
* A PHP port of URLify.js from the Django project
* (https://github.com/django/django/blob/master/django/contrib/admin/static/admin/js/urlify.js).
* Handles symbols from Latin languages, Greek, Turkish, Bulgarian, Russian,
* Ukrainian, Czech, Polish, Romanian, Latvian, Lithuanian, Vietnamese, Arabic,
* Serbian, Azerbaijani, and Slovakian. Symbols it cannot transliterate
* it will simply omit.
*
* Usage:
*
* echo URLify::filter (' J\'étudie le français ');
* // "jetudie-le-francais"
*
* echo URLify::filter ('Lo siento, no hablo español.');
* // "lo-siento-no-hablo-espanol"
*/
class URLify {
public static $maps = array (
'de' => array ( /* German */
'Ä' => 'Ae', 'Ö' => 'Oe', 'Ü' => 'Ue', 'ä' => 'ae', 'ö' => 'oe', 'ü' => 'ue', 'ß' => 'ss',
'ẞ' => 'SS'
),
'latin' => array (
'À' => 'A', 'Á' => 'A', 'Â' => 'A', 'Ã' => 'A', 'Ä' => 'A', 'Å' => 'A','Ă' => 'A', 'Æ' => 'AE', 'Ç' =>
'C', 'È' => 'E', 'É' => 'E', 'Ê' => 'E', 'Ë' => 'E', 'Ì' => 'I', 'Í' => 'I', 'Î' => 'I',
'Ï' => 'I', 'Ð' => 'D', 'Ñ' => 'N', 'Ò' => 'O', 'Ó' => 'O', 'Ô' => 'O', 'Õ' => 'O', 'Ö' =>
'O', 'Ő' => 'O', 'Ø' => 'O','Ș' => 'S','Ț' => 'T', 'Ù' => 'U', 'Ú' => 'U', 'Û' => 'U', 'Ü' => 'U', 'Ű' => 'U',
'Ý' => 'Y', 'Þ' => 'TH', 'ß' => 'ss', 'à' => 'a', 'á' => 'a', 'â' => 'a', 'ã' => 'a', 'ä' =>
'a', 'å' => 'a', 'ă' => 'a', 'æ' => 'ae', 'ç' => 'c', 'è' => 'e', 'é' => 'e', 'ê' => 'e', 'ë' => 'e',
'ì' => 'i', 'í' => 'i', 'î' => 'i', 'ï' => 'i', 'ð' => 'd', 'ñ' => 'n', 'ò' => 'o', 'ó' =>
'o', 'ô' => 'o', 'õ' => 'o', 'ö' => 'o', 'ő' => 'o', 'ø' => 'o', 'ș' => 's', 'ț' => 't', 'ù' => 'u', 'ú' => 'u',
'û' => 'u', 'ü' => 'u', 'ű' => 'u', 'ý' => 'y', 'þ' => 'th', 'ÿ' => 'y'
),
'latin_symbols' => array (
'©' => '(c)'
),
'el' => array ( /* Greek */
'α' => 'a', 'β' => 'b', 'γ' => 'g', 'δ' => 'd', 'ε' => 'e', 'ζ' => 'z', 'η' => 'h', 'θ' => '8',
'ι' => 'i', 'κ' => 'k', 'λ' => 'l', 'μ' => 'm', 'ν' => 'n', 'ξ' => '3', 'ο' => 'o', 'π' => 'p',
'ρ' => 'r', 'σ' => 's', 'τ' => 't', 'υ' => 'y', 'φ' => 'f', 'χ' => 'x', 'ψ' => 'ps', 'ω' => 'w',
'ά' => 'a', 'έ' => 'e', 'ί' => 'i', 'ό' => 'o', 'ύ' => 'y', 'ή' => 'h', 'ώ' => 'w', 'ς' => 's',
'ϊ' => 'i', 'ΰ' => 'y', 'ϋ' => 'y', 'ΐ' => 'i',
'Α' => 'A', 'Β' => 'B', 'Γ' => 'G', 'Δ' => 'D', 'Ε' => 'E', 'Ζ' => 'Z', 'Η' => 'H', 'Θ' => '8',
'Ι' => 'I', 'Κ' => 'K', 'Λ' => 'L', 'Μ' => 'M', 'Ν' => 'N', 'Ξ' => '3', 'Ο' => 'O', 'Π' => 'P',
'Ρ' => 'R', 'Σ' => 'S', 'Τ' => 'T', 'Υ' => 'Y', 'Φ' => 'F', 'Χ' => 'X', 'Ψ' => 'PS', 'Ω' => 'W',
'Ά' => 'A', 'Έ' => 'E', 'Ί' => 'I', 'Ό' => 'O', 'Ύ' => 'Y', 'Ή' => 'H', 'Ώ' => 'W', 'Ϊ' => 'I',
'Ϋ' => 'Y'
),
'tr' => array ( /* Turkish */
'ş' => 's', 'Ş' => 'S', 'ı' => 'i', 'İ' => 'I', 'ç' => 'c', 'Ç' => 'C', 'ü' => 'u', 'Ü' => 'U',
'ö' => 'o', 'Ö' => 'O', 'ğ' => 'g', 'Ğ' => 'G'
),
'bg' => array( /* Bulgarian */
"Щ" => 'Sht', "Ш" => 'Sh', "Ч" => 'Ch', "Ц" => 'C', "Ю" => 'Yu', "Я" => 'Ya',
"Ж" => 'J', "А" => 'A', "Б" => 'B', "В" => 'V', "Г" => 'G', "Д" => 'D',
"Е" => 'E', "З" => 'Z', "И" => 'I', "Й" => 'Y', "К" => 'K', "Л" => 'L',
"М" => 'M', "Н" => 'N', "О" => 'O', "П" => 'P', "Р" => 'R', "С" => 'S',
"Т" => 'T', "У" => 'U', "Ф" => 'F', "Х" => 'H', "Ь" => '', "Ъ" => 'A',
"щ" => 'sht', "ш" => 'sh', "ч" => 'ch', "ц" => 'c', "ю" => 'yu', "я" => 'ya',
"ж" => 'j', "а" => 'a', "б" => 'b', "в" => 'v', "г" => 'g', "д" => 'd',
"е" => 'e', "з" => 'z', "и" => 'i', "й" => 'y', "к" => 'k', "л" => 'l',
"м" => 'm', "н" => 'n', "о" => 'o', "п" => 'p', "р" => 'r', "с" => 's',
"т" => 't', "у" => 'u', "ф" => 'f', "х" => 'h', "ь" => '', "ъ" => 'a'
),
'ru' => array ( /* Russian */
'а' => 'a', 'б' => 'b', 'в' => 'v', 'г' => 'g', 'д' => 'd', 'е' => 'e', 'ё' => 'yo', 'ж' => 'zh',
'з' => 'z', 'и' => 'i', 'й' => 'j', 'к' => 'k', 'л' => 'l', 'м' => 'm', 'н' => 'n', 'о' => 'o',
'п' => 'p', 'р' => 'r', 'с' => 's', 'т' => 't', 'у' => 'u', 'ф' => 'f', 'х' => 'h', 'ц' => 'c',
'ч' => 'ch', 'ш' => 'sh', 'щ' => 'sh', 'ъ' => '', 'ы' => 'y', 'ь' => '', 'э' => 'e', 'ю' => 'yu',
'я' => 'ya',
'А' => 'A', 'Б' => 'B', 'В' => 'V', 'Г' => 'G', 'Д' => 'D', 'Е' => 'E', 'Ё' => 'Yo', 'Ж' => 'Zh',
'З' => 'Z', 'И' => 'I', 'Й' => 'J', 'К' => 'K', 'Л' => 'L', 'М' => 'M', 'Н' => 'N', 'О' => 'O',
'П' => 'P', 'Р' => 'R', 'С' => 'S', 'Т' => 'T', 'У' => 'U', 'Ф' => 'F', 'Х' => 'H', 'Ц' => 'C',
'Ч' => 'Ch', 'Ш' => 'Sh', 'Щ' => 'Sh', 'Ъ' => '', 'Ы' => 'Y', 'Ь' => '', 'Э' => 'E', 'Ю' => 'Yu',
'Я' => 'Ya',
'№' => 'No'
),
'uk' => array ( /* Ukrainian */
'Є' => 'Ye', 'І' => 'I', 'Ї' => 'Yi', 'Ґ' => 'G', 'є' => 'ye', 'і' => 'i', 'ї' => 'yi', 'ґ' => 'g'
),
'cs' => array ( /* Czech */
'č' => 'c', 'ď' => 'd', 'ě' => 'e', 'ň' => 'n', 'ř' => 'r', 'š' => 's', 'ť' => 't', 'ů' => 'u',
'ž' => 'z', 'Č' => 'C', 'Ď' => 'D', 'Ě' => 'E', 'Ň' => 'N', 'Ř' => 'R', 'Š' => 'S', 'Ť' => 'T',
'Ů' => 'U', 'Ž' => 'Z'
),
'pl' => array ( /* Polish */
'ą' => 'a', 'ć' => 'c', 'ę' => 'e', 'ł' => 'l', 'ń' => 'n', 'ó' => 'o', 'ś' => 's', 'ź' => 'z',
'ż' => 'z', 'Ą' => 'A', 'Ć' => 'C', 'Ę' => 'e', 'Ł' => 'L', 'Ń' => 'N', 'Ó' => 'O', 'Ś' => 'S',
'Ź' => 'Z', 'Ż' => 'Z'
),
'ro' => array ( /* Romanian */
'ă' => 'a', 'â' => 'a', 'î' => 'i', 'ș' => 's', 'ț' => 't', 'Ţ' => 'T', 'ţ' => 't'
),
'lv' => array ( /* Latvian */
'ā' => 'a', 'č' => 'c', 'ē' => 'e', 'ģ' => 'g', 'ī' => 'i', 'ķ' => 'k', 'ļ' => 'l', 'ņ' => 'n',
'š' => 's', 'ū' => 'u', 'ž' => 'z', 'Ā' => 'A', 'Č' => 'C', 'Ē' => 'E', 'Ģ' => 'G', 'Ī' => 'i',
'Ķ' => 'k', 'Ļ' => 'L', 'Ņ' => 'N', 'Š' => 'S', 'Ū' => 'u', 'Ž' => 'Z'
),
'lt' => array ( /* Lithuanian */
'ą' => 'a', 'č' => 'c', 'ę' => 'e', 'ė' => 'e', 'į' => 'i', 'š' => 's', 'ų' => 'u', 'ū' => 'u', 'ž' => 'z',
'Ą' => 'A', 'Č' => 'C', 'Ę' => 'E', 'Ė' => 'E', 'Į' => 'I', 'Š' => 'S', 'Ų' => 'U', 'Ū' => 'U', 'Ž' => 'Z'
),
'vn' => array ( /* Vietnamese */
'Á' => 'A', 'À' => 'A', 'Ả' => 'A', 'Ã' => 'A', 'Ạ' => 'A', 'Ă' => 'A', 'Ắ' => 'A', 'Ằ' => 'A', 'Ẳ' => 'A', 'Ẵ' => 'A', 'Ặ' => 'A', 'Â' => 'A', 'Ấ' => 'A', 'Ầ' => 'A', 'Ẩ' => 'A', 'Ẫ' => 'A', 'Ậ' => 'A',
'á' => 'a', 'à' => 'a', 'ả' => 'a', 'ã' => 'a', 'ạ' => 'a', 'ă' => 'a', 'ắ' => 'a', 'ằ' => 'a', 'ẳ' => 'a', 'ẵ' => 'a', 'ặ' => 'a', 'â' => 'a', 'ấ' => 'a', 'ầ' => 'a', 'ẩ' => 'a', 'ẫ' => 'a', 'ậ' => 'a',
'É' => 'E', 'È' => 'E', 'Ẻ' => 'E', 'Ẽ' => 'E', 'Ẹ' => 'E', 'Ê' => 'E', 'Ế' => 'E', 'Ề' => 'E', 'Ể' => 'E', 'Ễ' => 'E', 'Ệ' => 'E',
'é' => 'e', 'è' => 'e', 'ẻ' => 'e', 'ẽ' => 'e', 'ẹ' => 'e', 'ê' => 'e', 'ế' => 'e', 'ề' => 'e', 'ể' => 'e', 'ễ' => 'e', 'ệ' => 'e',
'Í' => 'I', 'Ì' => 'I', 'Ỉ' => 'I', 'Ĩ' => 'I', 'Ị' => 'I', 'í' => 'i', 'ì' => 'i', 'ỉ' => 'i', 'ĩ' => 'i', 'ị' => 'i',
'Ó' => 'O', 'Ò' => 'O', 'Ỏ' => 'O', 'Õ' => 'O', 'Ọ' => 'O', 'Ô' => 'O', 'Ố' => 'O', 'Ồ' => 'O', 'Ổ' => 'O', 'Ỗ' => 'O', 'Ộ' => 'O', 'Ơ' => 'O', 'Ớ' => 'O', 'Ờ' => 'O', 'Ở' => 'O', 'Ỡ' => 'O', 'Ợ' => 'O',
'ó' => 'o', 'ò' => 'o', 'ỏ' => 'o', 'õ' => 'o', 'ọ' => 'o', 'ô' => 'o', 'ố' => 'o', 'ồ' => 'o', 'ổ' => 'o', 'ỗ' => 'o', 'ộ' => 'o', 'ơ' => 'o', 'ớ' => 'o', 'ờ' => 'o', 'ở' => 'o', 'ỡ' => 'o', 'ợ' => 'o',
'Ú' => 'U', 'Ù' => 'U', 'Ủ' => 'U', 'Ũ' => 'U', 'Ụ' => 'U', 'Ư' => 'U', 'Ứ' => 'U', 'Ừ' => 'U', 'Ử' => 'U', 'Ữ' => 'U', 'Ự' => 'U',
'ú' => 'u', 'ù' => 'u', 'ủ' => 'u', 'ũ' => 'u', 'ụ' => 'u', 'ư' => 'u', 'ứ' => 'u', 'ừ' => 'u', 'ử' => 'u', 'ữ' => 'u', 'ự' => 'u',
'Ý' => 'Y', 'Ỳ' => 'Y', 'Ỷ' => 'Y', 'Ỹ' => 'Y', 'Ỵ' => 'Y', 'ý' => 'y', 'ỳ' => 'y', 'ỷ' => 'y', 'ỹ' => 'y', 'ỵ' => 'y',
'Đ' => 'D', 'đ' => 'd'
),
'sr' => array ( /* Serbian */
'ђ' => 'dj', 'ј' => 'j', 'љ' => 'lj', 'њ' => 'nj', 'ћ' => 'c', 'џ' => 'dz', 'đ' => 'd',
'Ђ' => 'Dj', 'Ј' => 'j', 'Љ' => 'Lj', 'Њ' => 'Nj', 'Ћ' => 'C', 'Џ' => 'Dz', 'Đ' => 'D'
),
'az' => array ( /* Azerbaijani */
'ç' => 'c', 'ə' => 'e', 'ğ' => 'g', 'ı' => 'i', 'ö' => 'o', 'ş' => 's', 'ü' => 'u',
'Ç' => 'C', 'Ə' => 'E', 'Ğ' => 'G', 'İ' => 'I', 'Ö' => 'O', 'Ş' => 'S', 'Ü' => 'U'
),
'slo' => array ( /* Slovakian */
'DZ' => 'DZ', 'dz' => 'dz', 'DŽ' => 'DZ', 'dž' => 'dz', 'CH' => 'CH', 'Ĺ' => 'L', 'ĺ' => 'l', 'Ľ' => 'L',
'ľ' => 'l', 'Ŕ' => 'R', 'ŕ' => 'r'
),
'cus' => array ( /* Custom */
'Ĉ' => 'C', 'ĉ' => 'c', 'Ċ' => 'C', 'ċ' => 'c', 'Ď' => 'D', 'ď' => 'd', 'Ĕ' => 'E', 'ĕ' => 'e', 'Ĝ' => 'G', 'ĝ' => 'g',
'Ġ' => 'G', 'ġ' => 'g', 'Ĥ' => 'H', 'ĥ' => 'h', 'Ħ' => 'H', 'ħ' => 'h', 'Ĭ' => 'I', 'ĭ' => 'i', 'IJ' => 'J', 'ij' => 'j',
'Ĵ' => 'J', 'ĵ' => 'j', 'Ŀ' => 'L', 'ŀ' => 'l', 'ʼn' => 'n', 'Ō' => 'O', 'ō' => 'o', 'Ŏ' => 'O', 'ŏ' => 'o', 'Œ' => 'OE',
'œ' => 'oe', 'Ŗ' => 'R', 'ŗ' => 'r', 'Ŝ' => 'S', 'ŝ' => 's', 'Ŧ' => 'T', 'ŧ' => 't', 'Ŭ' => 'U', 'ŭ' => 'u', 'Ŵ' => 'W',
'ŵ' => 'w', 'Ŷ' => 'Y', 'ŷ' => 'y', 'Ÿ' => 'Y', 'ſ' => 'S', 'Ƒ' => 'F', 'ƒ' => 'f', 'Ǎ' => 'A', 'ǎ' => 'a', 'Ǐ' => 'I',
'ǐ' => 'i', 'Ǒ' => 'O', 'ǒ' => 'o', 'Ǔ' => 'U', 'ǔ' => 'u', 'Ǖ' => 'U', 'ǖ' => 'u', 'Ǘ' => 'U', 'ǘ' => 'u', 'Ǚ' => 'U',
'ǚ' => 'u', 'Ǜ' => 'U', 'ǜ' => 'u', 'Ǻ' => 'A', 'ǻ' => 'a', 'Ǽ' => 'AE', 'ǽ' => 'ae', 'Ǿ' => 'O', 'ǿ' => 'o'
)
);
/**
* List of words to remove from URLs.
*/
public static $remove_list = array (
'a', 'an', 'as', 'at', 'before', 'but', 'by', 'for', 'from',
'is', 'in', 'into', 'like', 'of', 'off', 'on', 'onto', 'per',
'since', 'than', 'the', 'this', 'that', 'to', 'up', 'via',
'with'
);
/**
* The character map.
*/
private static $map = array ();
/**
* The character list as a string.
*/
private static $chars = '';
/**
* The character list as a regular expression.
*/
private static $regex = '';
/**
* The current language
*/
private static $language = '';
/**
* Initializes the character map.
*/
private static function init ($language = "") {
if (count (self::$map) > 0 && (($language == "") || ($language == self::$language))) {
return;
}
/* Is a specific map associated with $language ? */
if (isset(self::$maps[$language]) && is_array(self::$maps[$language])) {
/* Move this map to end. This means it will have priority over others */
$m = self::$maps[$language];
unset(self::$maps[$language]);
self::$maps[$language] = $m;
}
/* Reset static vars */
self::$language = $language;
self::$map = array();
self::$chars = '';
foreach (self::$maps as $map) {
foreach ($map as $orig => $conv) {
self::$map[$orig] = $conv;
self::$chars .= $orig;
}
}
self::$regex = '/[' . self::$chars . ']/u';
}
/**
* Add new characters to the list. `$map` should be a hash.
*/
public static function add_chars ($map) {
if (! is_array ($map)) {
throw new LogicException ('$map must be an associative array.');
}
self::$maps[] = $map;
self::$map = array ();
self::$chars = '';
}
/**
* Append words to the remove list. Accepts either single words
* or an array of words.
*/
public static function remove_words ($words) {
$words = is_array ($words) ? $words : array ($words);
self::$remove_list = array_merge (self::$remove_list, $words);
}
/**
* Transliterates characters to their ASCII equivalents.
* $language specifies a priority for a specific language.
* The latter is useful if languages have different rules for the same character.
*/
public static function downcode ($text, $language = "") {
self::init ($language);
if (preg_match_all (self::$regex, $text, $matches)) {
for ($i = 0; $i < count ($matches[0]); $i++) {
$char = $matches[0][$i];
if (isset (self::$map[$char])) {
$text = str_replace ($char, self::$map[$char], $text);
}
}
}
return $text;
}
/**
* Filters a string, e.g., "Petty theft" to "petty-theft"
*/
public static function filter ($text, $length = 60, $language = "", $file_name = false, $use_remove_list = true) {
$text = self::downcode ($text,$language);
if ($use_remove_list) {
// remove all these words from the string before urlifying
$text = preg_replace ('/\b(' . join ('|', self::$remove_list) . ')\b/i', '', $text);
}
// if downcode doesn't hit, the char will be stripped here
$remove_pattern = ($file_name) ? '/[^_\-.\-a-zA-Z0-9\s]/u' : '/[^\s_\-a-zA-Z0-9]/u';
$text = preg_replace ($remove_pattern, '', $text); // remove unneeded chars
$text = str_replace ('_', ' ', $text); // treat underscores as spaces
$text = preg_replace ('/^\s+|\s+$/u', '', $text); // trim leading/trailing spaces
$text = preg_replace ('/[-\s]+/u', '-', $text); // convert spaces to hyphens
$text = strtolower ($text); // convert to lowercase
return trim (substr ($text, 0, $length), '-'); // trim to first $length chars
}
/**
* Alias of `URLify::downcode()`.
*/
public static function transliterate ($text) {
return self::downcode ($text);
}
}

+ 26
- 0
system/plugins/urlify/composer.json View File

@ -0,0 +1,26 @@
{
"name": "jbroadway/urlify",
"type": "library",
"description": "PHP port of URLify.js from the Django project. Transliterates non-ascii characters for use in URLs.",
"keywords": ["urlify","transliterate","translit","transliteration","url","encode","slug","link","iconv"],
"homepage": "https://github.com/jbroadway/urlify",
"license": "BSD",
"authors": [
{
"name": "Johnny Broadway",
"email": "johnny@johnnybroadway.com",
"homepage": "http://www.johnnybroadway.com/"
}
],
"require": {
"php": ">=5.3.0"
},
"autoload": {
"psr-0": { "URLify": "" }
},
"extra": {
"branch-alias": {
"dev-master": "1.0-dev"
}
}
}

+ 8
- 0
system/plugins/urlify/phpunit.xml View File

@ -0,0 +1,8 @@
<phpunit bootstrap="tests/bootstrap.php">
<testsuite name="URLify Test Suite">
<directory>tests</directory>
</testsuite>
<logging>
<log type="coverage-text" target="php://stdout" showUncoveredFiles="false"/>
</logging>
</phpunit>

+ 20
- 0
system/plugins/urlify/scripts/downcode.php View File

@ -0,0 +1,20 @@
<?php
//Downcode the provided argument or stdin if the argument was not present
require_once dirname (__DIR__) . '/URLify.php';
//Print usage and exit if arguments are invalid
if($argc < 1 || $argc > 2) {
die ("Usage (argument): php " . basename(__FILE__) . " \"<text to downcode>\"\nUsage (pipe): <Arbitrary command> | php " . basename(__FILE__) . "\n");
}
//Process the provided argument
if($argc === 2) {
$s = $argv[1];
//Or read from stdin if the argument wasn't present
} else {
$piped = true;
$s = file_get_contents("php://stdin");
}
echo URLify::downcode ($s) . ($piped ? "\n" : "");

+ 20
- 0
system/plugins/urlify/scripts/filter.php View File

@ -0,0 +1,20 @@
<?php
//Filter the provided argument or stdin if the argument was not present
require_once dirname (__DIR__) . '/URLify.php';
//Print usage and exit if arguments are invalid
if($argc < 1 || $argc > 2) {
die ("Usage (argument): php " . basename(__FILE__) . " \"<text to filter>\"\nUsage (pipe): <Arbitrary command> | php " . basename(__FILE__) . "\n");
}
//Process the provided argument
if($argc === 2) {
$s = $argv[1];
//Or read from stdin if the argument wasn't present
} else {
$piped = true;
$s = file_get_contents("php://stdin");
}
echo URLify::filter ($s) . ($piped ? "\n" : "");

+ 20
- 0
system/plugins/urlify/scripts/transliterate.php View File

@ -0,0 +1,20 @@
<?php
//Transliterate the provided argument or stdin if the argument was not present
require_once dirname (__DIR__) . '/URLify.php';
//Print usage and exit if arguments are invalid
if($argc < 1 || $argc > 2) {
die ("Usage (argument): php " . basename(__FILE__) . " \"<text to transliterate>\"\nUsage (pipe): <Arbitrary command> | php " . basename(__FILE__) . "\n");
}
//Process the provided argument
if($argc === 2) {
$s = $argv[1];
//Or read from stdin if the argument wasn't present
} else {
$piped = true;
$s = file_get_contents("php://stdin");
}
echo URLify::transliterate($s) . ($piped ? "\n" : "");

+ 54
- 0
system/plugins/urlify/tests/URLifyTest.php View File

@ -0,0 +1,54 @@
<?php
class URLifyTest extends PHPUnit_Framework_TestCase {
function test_downcode () {
$this->assertEquals (' J\'etudie le francais ', URLify::downcode (' J\'étudie le français '));
$this->assertEquals ('Lo siento, no hablo espanol.', URLify::downcode ('Lo siento, no hablo español.'));
$this->assertEquals ('F3PWS', URLify::downcode ('ΦΞΠΏΣ'));
$this->assertEquals ('foo-bar', URLify::filter ('_foo_bar_'));
}
function test_filter () {
$this->assertEquals ('jetudie-le-francais', URLify::filter (' J\'étudie le français '));
$this->assertEquals ('lo-siento-no-hablo-espanol', URLify::filter ('Lo siento, no hablo español.'));
$this->assertEquals ('f3pws', URLify::filter ('ΦΞΠΏΣ'));
$this->assertEquals ('', URLify::filter('大般若經'));
$this->assertEquals ('test-.txt', URLify::filter('test-大般若經.txt', 60, "", $file_name = true));
$this->assertEquals ('ykrhy-ltoytr', URLify::filter('ياكرهي لتويتر'));
$this->assertEquals ('foto.jpg', URLify::filter ('фото.jpg', 60, "", $file_name = true));
// priorization of language-specific maps
$this->assertEquals ('aouaou', URLify::filter ('ÄÖÜäöü',60,"tr"));
$this->assertEquals ('aeoeueaeoeue', URLify::filter ('ÄÖÜäöü',60,"de"));
$this->assertEquals ('bobby-mcferrin-dont-worry-be-happy', URLify::filter ("Bobby McFerrin — Don't worry be happy",600,"en"));
// test stripping and conversion of UTF-8 spaces
$this->assertEquals ('test-mahito-mukai', URLify::filter('向井 真人test (Mahito Mukai)'));
}
function test_add_chars () {
$this->assertEquals ('¿ ® ¼ ¼ ¾ ¶', URLify::downcode ('¿ ® ¼ ¼ ¾ ¶'));
URLify::add_chars (array (
'¿' => '?', '®' => '(r)', '¼' => '1/4',
'¼' => '1/2', '¾' => '3/4', '¶' => 'P'
));
$this->assertEquals ('? (r) 1/2 1/2 3/4 P', URLify::downcode ('¿ ® ¼ ¼ ¾ ¶'));
}
function test_remove_words () {
$this->assertEquals ('foo-bar', URLify::filter ('foo bar'));
URLify::remove_words (array ('foo', 'bar'));
$this->assertEquals ('', URLify::filter ('foo bar'));
}
function test_many_rounds_with_unknown_language_code () {
for ($i = 0; $i < 1000; $i++) {
URLify::downcode ('Lo siento, no hablo español.',-1);
}
}
function test_remove_words_disable () {
URLify::remove_words (array ('foo', 'bar'));
$this->assertEquals ('foo-bar', URLify::filter ('foo bar', 60, '', false, false));
}
}
?>

+ 9
- 0
system/plugins/urlify/tests/bootstrap.php View File

@ -0,0 +1,9 @@
<?php
set_error_handler(function () {
echo file_get_contents(dirname(__DIR__).'/INSTALL');
exit(1);
}, E_ALL);
require_once dirname(__DIR__) . '/vendor/autoload.php';
restore_error_handler();

+ 587
- 0
system/resources/css/bootstrap-theme.css View File

@ -0,0 +1,587 @@
/*!
* Bootstrap v3.3.7 (http://getbootstrap.com)
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
.btn-default,
.btn-primary,
.btn-success,
.btn-info,
.btn-warning,
.btn-danger {
text-shadow: 0 -1px 0 rgba(0, 0, 0, .2);
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
}
.btn-default:active,
.btn-primary:active,
.btn-success:active,
.btn-info:active,
.btn-warning:active,
.btn-danger:active,
.btn-default.active,
.btn-primary.active,
.btn-success.active,
.btn-info.active,
.btn-warning.active,
.btn-danger.active {
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-default.disabled,
.btn-primary.disabled,
.btn-success.disabled,
.btn-info.disabled,
.btn-warning.disabled,
.btn-danger.disabled,
.btn-default[disabled],
.btn-primary[disabled],
.btn-success[disabled],
.btn-info[disabled],
.btn-warning[disabled],
.btn-danger[disabled],
fieldset[disabled] .btn-default,
fieldset[disabled] .btn-primary,
fieldset[disabled] .btn-success,
fieldset[disabled] .btn-info,
fieldset[disabled] .btn-warning,
fieldset[disabled] .btn-danger {
-webkit-box-shadow: none;
box-shadow: none;
}
.btn-default .badge,
.btn-primary .badge,
.btn-success .badge,
.btn-info .badge,
.btn-warning .badge,
.btn-danger .badge {
text-shadow: none;
}
.btn:active,
.btn.active {
background-image: none;
}
.btn-default {
text-shadow: 0 1px 0 #fff;
background-image: -webkit-linear-gradient(top, #fff 0%, #e0e0e0 100%);
background-image: -o-linear-gradient(top, #fff 0%, #e0e0e0 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#e0e0e0));
background-image: linear-gradient(to bottom, #fff 0%, #e0e0e0 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #dbdbdb;
border-color: #ccc;
}
.btn-default:hover,
.btn-default:focus {
background-color: #e0e0e0;
background-position: 0 -15px;
}
.btn-default:active,
.btn-default.active {
background-color: #e0e0e0;
border-color: #dbdbdb;
}
.btn-default.disabled,
.btn-default[disabled],
fieldset[disabled] .btn-default,
.btn-default.disabled:hover,
.btn-default[disabled]:hover,
fieldset[disabled] .btn-default:hover,
.btn-default.disabled:focus,
.btn-default[disabled]:focus,
fieldset[disabled] .btn-default:focus,
.btn-default.disabled.focus,
.btn-default[disabled].focus,
fieldset[disabled] .btn-default.focus,
.btn-default.disabled:active,
.btn-default[disabled]:active,
fieldset[disabled] .btn-default:active,
.btn-default.disabled.active,
.btn-default[disabled].active,
fieldset[disabled] .btn-default.active {
background-color: #e0e0e0;
background-image: none;
}
.btn-primary {
background-image: -webkit-linear-gradient(top, #337ab7 0%, #265a88 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #265a88 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#265a88));
background-image: linear-gradient(to bottom, #337ab7 0%, #265a88 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff265a88', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #245580;
}
.btn-primary:hover,
.btn-primary:focus {
background-color: #265a88;
background-position: 0 -15px;
}
.btn-primary:active,
.btn-primary.active {
background-color: #265a88;
border-color: #245580;
}
.btn-primary.disabled,
.btn-primary[disabled],
fieldset[disabled] .btn-primary,
.btn-primary.disabled:hover,
.btn-primary[disabled]:hover,
fieldset[disabled] .btn-primary:hover,
.btn-primary.disabled:focus,
.btn-primary[disabled]:focus,
fieldset[disabled] .btn-primary:focus,
.btn-primary.disabled.focus,
.btn-primary[disabled].focus,
fieldset[disabled] .btn-primary.focus,
.btn-primary.disabled:active,
.btn-primary[disabled]:active,
fieldset[disabled] .btn-primary:active,
.btn-primary.disabled.active,
.btn-primary[disabled].active,
fieldset[disabled] .btn-primary.active {
background-color: #265a88;
background-image: none;
}
.btn-success {
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #419641 100%);
background-image: -o-linear-gradient(top, #5cb85c 0%, #419641 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#419641));
background-image: linear-gradient(to bottom, #5cb85c 0%, #419641 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #3e8f3e;
}
.btn-success:hover,
.btn-success:focus {
background-color: #419641;
background-position: 0 -15px;
}
.btn-success:active,
.btn-success.active {
background-color: #419641;
border-color: #3e8f3e;
}
.btn-success.disabled,
.btn-success[disabled],
fieldset[disabled] .btn-success,
.btn-success.disabled:hover,
.btn-success[disabled]:hover,
fieldset[disabled] .btn-success:hover,
.btn-success.disabled:focus,
.btn-success[disabled]:focus,
fieldset[disabled] .btn-success:focus,
.btn-success.disabled.focus,
.btn-success[disabled].focus,
fieldset[disabled] .btn-success.focus,
.btn-success.disabled:active,
.btn-success[disabled]:active,
fieldset[disabled] .btn-success:active,
.btn-success.disabled.active,
.btn-success[disabled].active,
fieldset[disabled] .btn-success.active {
background-color: #419641;
background-image: none;
}
.btn-info {
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
background-image: -o-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#2aabd2));
background-image: linear-gradient(to bottom, #5bc0de 0%, #2aabd2 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #28a4c9;
}
.btn-info:hover,
.btn-info:focus {
background-color: #2aabd2;
background-position: 0 -15px;
}
.btn-info:active,
.btn-info.active {
background-color: #2aabd2;
border-color: #28a4c9;
}
.btn-info.disabled,
.btn-info[disabled],
fieldset[disabled] .btn-info,
.btn-info.disabled:hover,
.btn-info[disabled]:hover,
fieldset[disabled] .btn-info:hover,
.btn-info.disabled:focus,
.btn-info[disabled]:focus,
fieldset[disabled] .btn-info:focus,
.btn-info.disabled.focus,
.btn-info[disabled].focus,
fieldset[disabled] .btn-info.focus,
.btn-info.disabled:active,
.btn-info[disabled]:active,
fieldset[disabled] .btn-info:active,
.btn-info.disabled.active,
.btn-info[disabled].active,
fieldset[disabled] .btn-info.active {
background-color: #2aabd2;
background-image: none;
}
.btn-warning {
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
background-image: -o-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#eb9316));
background-image: linear-gradient(to bottom, #f0ad4e 0%, #eb9316 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #e38d13;
}
.btn-warning:hover,
.btn-warning:focus {
background-color: #eb9316;
background-position: 0 -15px;
}
.btn-warning:active,
.btn-warning.active {
background-color: #eb9316;
border-color: #e38d13;
}
.btn-warning.disabled,
.btn-warning[disabled],
fieldset[disabled] .btn-warning,
.btn-warning.disabled:hover,
.btn-warning[disabled]:hover,
fieldset[disabled] .btn-warning:hover,
.btn-warning.disabled:focus,
.btn-warning[disabled]:focus,
fieldset[disabled] .btn-warning:focus,
.btn-warning.disabled.focus,
.btn-warning[disabled].focus,
fieldset[disabled] .btn-warning.focus,
.btn-warning.disabled:active,
.btn-warning[disabled]:active,
fieldset[disabled] .btn-warning:active,
.btn-warning.disabled.active,
.btn-warning[disabled].active,
fieldset[disabled] .btn-warning.active {
background-color: #eb9316;
background-image: none;
}
.btn-danger {
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
background-image: -o-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c12e2a));
background-image: linear-gradient(to bottom, #d9534f 0%, #c12e2a 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #b92c28;
}
.btn-danger:hover,
.btn-danger:focus {
background-color: #c12e2a;
background-position: 0 -15px;
}
.btn-danger:active,
.btn-danger.active {
background-color: #c12e2a;
border-color: #b92c28;
}
.btn-danger.disabled,
.btn-danger[disabled],
fieldset[disabled] .btn-danger,
.btn-danger.disabled:hover,
.btn-danger[disabled]:hover,
fieldset[disabled] .btn-danger:hover,
.btn-danger.disabled:focus,
.btn-danger[disabled]:focus,
fieldset[disabled] .btn-danger:focus,
.btn-danger.disabled.focus,
.btn-danger[disabled].focus,
fieldset[disabled] .btn-danger.focus,
.btn-danger.disabled:active,
.btn-danger[disabled]:active,
fieldset[disabled] .btn-danger:active,
.btn-danger.disabled.active,
.btn-danger[disabled].active,
fieldset[disabled] .btn-danger.active {
background-color: #c12e2a;
background-image: none;
}
.thumbnail,
.img-thumbnail {
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
}
.dropdown-menu > li > a:hover,
.dropdown-menu > li > a:focus {
background-color: #e8e8e8;
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
background-repeat: repeat-x;
}
.dropdown-menu > .active > a,
.dropdown-menu > .active > a:hover,
.dropdown-menu > .active > a:focus {
background-color: #2e6da4;
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
background-repeat: repeat-x;
}
.navbar-default {
background-image: -webkit-linear-gradient(top, #fff 0%, #f8f8f8 100%);
background-image: -o-linear-gradient(top, #fff 0%, #f8f8f8 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#f8f8f8));
background-image: linear-gradient(to bottom, #fff 0%, #f8f8f8 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-radius: 4px;
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
}
.navbar-default .navbar-nav > .open > a,
.navbar-default .navbar-nav > .active > a {
background-image: -webkit-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
background-image: -o-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#dbdbdb), to(#e2e2e2));
background-image: linear-gradient(to bottom, #dbdbdb 0%, #e2e2e2 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdbdbdb', endColorstr='#ffe2e2e2', GradientType=0);
background-repeat: repeat-x;
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
}
.navbar-brand,
.navbar-nav > li > a {
text-shadow: 0 1px 0 rgba(255, 255, 255, .25);
}
.navbar-inverse {
background-image: -webkit-linear-gradient(top, #3c3c3c 0%, #222 100%);
background-image: -o-linear-gradient(top, #3c3c3c 0%, #222 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#3c3c3c), to(#222));
background-image: linear-gradient(to bottom, #3c3c3c 0%, #222 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-radius: 4px;
}
.navbar-inverse .navbar-nav > .open > a,
.navbar-inverse .navbar-nav > .active > a {
background-image: -webkit-linear-gradient(top, #080808 0%, #0f0f0f 100%);
background-image: -o-linear-gradient(top, #080808 0%, #0f0f0f 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#080808), to(#0f0f0f));
background-image: linear-gradient(to bottom, #080808 0%, #0f0f0f 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff080808', endColorstr='#ff0f0f0f', GradientType=0);
background-repeat: repeat-x;
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
}
.navbar-inverse .navbar-brand,
.navbar-inverse .navbar-nav > li > a {
text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
}
.navbar-static-top,
.navbar-fixed-top,
.navbar-fixed-bottom {
border-radius: 0;
}
@media (max-width: 767px) {
.navbar .navbar-nav .open .dropdown-menu > .active > a,
.navbar .navbar-nav .open .dropdown-menu > .active > a:hover,
.navbar .navbar-nav .open .dropdown-menu > .active > a:focus {
color: #fff;
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
background-repeat: repeat-x;
}
}
.alert {
text-shadow: 0 1px 0 rgba(255, 255, 255, .2);
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
}
.alert-success {
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
background-image: -o-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#c8e5bc));
background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);
background-repeat: repeat-x;
border-color: #b2dba1;
}
.alert-info {
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
background-image: -o-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#b9def0));
background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);
background-repeat: repeat-x;
border-color: #9acfea;
}
.alert-warning {
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
background-image: -o-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#f8efc0));
background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);
background-repeat: repeat-x;
border-color: #f5e79e;
}
.alert-danger {
background-image: -webkit-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
background-image: -o-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#e7c3c3));
background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);
background-repeat: repeat-x;
border-color: #dca7a7;
}
.progress {
background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
background-image: -o-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#f5f5f5));
background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar {
background-image: -webkit-linear-gradient(top, #337ab7 0%, #286090 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #286090 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#286090));
background-image: linear-gradient(to bottom, #337ab7 0%, #286090 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff286090', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-success {
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #449d44 100%);
background-image: -o-linear-gradient(top, #5cb85c 0%, #449d44 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#449d44));
background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-info {
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
background-image: -o-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#31b0d5));
background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-warning {
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
background-image: -o-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#ec971f));
background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-danger {
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c9302c 100%);
background-image: -o-linear-gradient(top, #d9534f 0%, #c9302c 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c9302c));
background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-striped {
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
}
.list-group {
border-radius: 4px;
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
}
.list-group-item.active,
.list-group-item.active:hover,
.list-group-item.active:focus {
text-shadow: 0 -1px 0 #286090;
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2b669a 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2b669a 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2b669a));
background-image: linear-gradient(to bottom, #337ab7 0%, #2b669a 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2b669a', GradientType=0);
background-repeat: repeat-x;
border-color: #2b669a;
}
.list-group-item.active .badge,
.list-group-item.active:hover .badge,
.list-group-item.active:focus .badge {
text-shadow: none;
}
.panel {
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
}
.panel-default > .panel-heading {
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
background-repeat: repeat-x;
}
.panel-primary > .panel-heading {
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
background-repeat: repeat-x;
}
.panel-success > .panel-heading {
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
background-image: -o-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#d0e9c6));
background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);
background-repeat: repeat-x;
}
.panel-info > .panel-heading {
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
background-image: -o-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#c4e3f3));
background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);
background-repeat: repeat-x;
}
.panel-warning > .panel-heading {
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
background-image: -o-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#faf2cc));
background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);
background-repeat: repeat-x;
}
.panel-danger > .panel-heading {
background-image: -webkit-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
background-image: -o-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#ebcccc));
background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);
background-repeat: repeat-x;
}
.well {
background-image: -webkit-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
background-image: -o-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#e8e8e8), to(#f5f5f5));
background-image: linear-gradient(to bottom, #e8e8e8 0%, #f5f5f5 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);
background-repeat: repeat-x;
border-color: #dcdcdc;
-webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
}
/*# sourceMappingURL=bootstrap-theme.css.map */

+ 6
- 0
system/resources/css/bootstrap.min.css
File diff suppressed because it is too large
View File


+ 105
- 0
system/resources/css/dashboard.css View File

@ -0,0 +1,105 @@
/*
* Base structure
*/
/* Move down content because we have a fixed navbar that is 50px tall */
body {
padding-top: 50px;
}
/*
* Global add-ons
*/
.sub-header {
padding-bottom: 10px;
border-bottom: 1px solid #eee;
}
/*
* Top navigation
* Hide default border to remove 1px line.
*/
.navbar-fixed-top {
border: 0;
}
/*
* Sidebar
*/
/* Hide for mobile, show later */
.sidebar {
display: none;
}
@media (min-width: 768px) {
.sidebar {
position: fixed;
top: 51px;
bottom: 0;
left: 0;
z-index: 1000;
display: block;
padding: 20px;
overflow-x: hidden;
overflow-y: auto; /* Scrollable contents if viewport is shorter than content. */
background-color: #f5f5f5;
border-right: 1px solid #eee;
}
}
/* Sidebar navigation */
.nav-sidebar {
margin-right: -21px; /* 20px padding + 1px border */
margin-bottom: 20px;
margin-left: -20px;
}
.nav-sidebar > li > a {
padding-right: 20px;
padding-left: 20px;
}
.nav-sidebar > .active > a,
.nav-sidebar > .active > a:hover,
.nav-sidebar > .active > a:focus {
color: #fff;
background-color: #428bca;
}
/*
* Main content
*/
.main {
padding: 20px;
}
@media (min-width: 768px) {
.main {
padding-right: 40px;
padding-left: 40px;
}
}
.main .page-header {
margin-top: 0;
}
/*
* Placeholder dashboard ideas
*/
.placeholders {
margin-bottom: 30px;
text-align: center;
}
.placeholders h4 {
margin-bottom: 0;
}
.placeholder {
margin-bottom: 20px;
}
.placeholder img {
display: inline-block;
border-radius: 50%;
}

+ 13
- 0
system/resources/css/ie10-viewport-bug-workaround.css View File

@ -0,0 +1,13 @@
/*!
* IE10 viewport hack for Surface/desktop Windows 8 bug
* Copyright 2014-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
/*
* See the Getting Started docs for more information:
* http://getbootstrap.com/getting-started/#support-ie10-width
*/
@-ms-viewport { width: device-width; }
@-o-viewport { width: device-width; }
@viewport { width: device-width; }

+ 40
- 0
system/resources/css/signin.css View File

@ -0,0 +1,40 @@
body {
padding-top: 40px;
padding-bottom: 40px;
background-color: #eee;
}
.form-signin {
max-width: 330px;
padding: 15px;
margin: 0 auto;
}
.form-signin .form-signin-heading,
.form-signin .checkbox {
margin-bottom: 10px;
}
.form-signin .checkbox {
font-weight: normal;
}
.form-signin .form-control {
position: relative;
height: auto;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
padding: 10px;
font-size: 16px;
}
.form-signin .form-control:focus {
z-index: 2;
}
.form-signin input[type="email"] {
margin-bottom: -1px;
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
}
.form-signin input[type="password"] {
margin-bottom: 10px;
border-top-left-radius: 0;
border-top-right-radius: 0;
}

+ 7
- 0
system/resources/js/bootstrap.min.js
File diff suppressed because it is too large
View File


+ 12
- 0
system/resources/js/holder.min.js
File diff suppressed because it is too large
View File


+ 51
- 0
system/resources/js/ie-emulation-modes-warning.js View File

@ -0,0 +1,51 @@
// NOTICE!! DO NOT USE ANY OF THIS JAVASCRIPT
// IT'S JUST JUNK FOR OUR DOCS!
// ++++++++++++++++++++++++++++++++++++++++++
/*!
* Copyright 2014-2015 Twitter, Inc.
*
* Licensed under the Creative Commons Attribution 3.0 Unported License. For
* details, see https://creativecommons.org/licenses/by/3.0/.
*/
// Intended to prevent false-positive bug reports about Bootstrap not working properly in old versions of IE due to folks testing using IE's unreliable emulation modes.
(function () {
'use strict';
function emulatedIEMajorVersion() {
var groups = /MSIE ([0-9.]+)/.exec(window.navigator.userAgent)
if (groups === null) {
return null
}
var ieVersionNum = parseInt(groups[1], 10)
var ieMajorVersion = Math.floor(ieVersionNum)
return ieMajorVersion
}
function actualNonEmulatedIEMajorVersion() {
// Detects the actual version of IE in use, even if it's in an older-IE emulation mode.
// IE JavaScript conditional compilation docs: https://msdn.microsoft.com/library/121hztk3%28v=vs.94%29.aspx
// @cc_on docs: https://msdn.microsoft.com/library/8ka90k2e%28v=vs.94%29.aspx
var jscriptVersion = new Function('/*@cc_on return @_jscript_version; @*/')() // jshint ignore:line
if (jscriptVersion === undefined) {
return 11 // IE11+ not in emulation mode
}
if (jscriptVersion < 9) {
return 8 // IE8 (or lower; haven't tested on IE<8)
}
return jscriptVersion // IE9 or IE10 in any mode, or IE11 in non-IE11 mode
}
var ua = window.navigator.userAgent
if (ua.indexOf('Opera') > -1 || ua.indexOf('Presto') > -1) {
return // Opera, which might pretend to be IE
}
var emulated = emulatedIEMajorVersion()
if (emulated === null) {
return // Not IE
}
var nonEmulated = actualNonEmulatedIEMajorVersion()
if (emulated !== nonEmulated) {
window.alert('WARNING: You appear to be using IE' + nonEmulated + ' in IE' + emulated + ' emulation mode.\nIE emulation modes can behave significantly differently from ACTUAL older versions of IE.\nPLEASE DON\'T FILE BOOTSTRAP BUGS based on testing in IE emulation modes!')
}
})();

+ 23
- 0
system/resources/js/ie10-viewport-bug-workaround.js View File

@ -0,0 +1,23 @@
/*!
* IE10 viewport hack for Surface/desktop Windows 8 bug
* Copyright 2014-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
// See the Getting Started docs for more information:
// http://getbootstrap.com/getting-started/#support-ie10-width
(function () {
'use strict';
if (navigator.userAgent.match(/IEMobile\/10\.0/)) {
var msViewportStyle = document.createElement('style')
msViewportStyle.appendChild(
document.createTextNode(
'@-ms-viewport{width:auto!important}'
)
)
document.querySelector('head').appendChild(msViewportStyle)
}
})();

+ 13
- 0
system/resources/js/ie8-responsive-file-warning.js View File

@ -0,0 +1,13 @@
// NOTICE!! DO NOT USE ANY OF THIS JAVASCRIPT
// IT'S JUST JUNK FOR OUR DOCS!
// ++++++++++++++++++++++++++++++++++++++++++
/*!
* Copyright 2011-2015 Twitter, Inc.
*
* Licensed under the Creative Commons Attribution 3.0 Unported License. For
* details, see https://creativecommons.org/licenses/by/3.0/.
*/
// Intended to prevent false-positive bug reports about responsive styling supposedly not working in IE8.
if (window.location.protocol == 'file:') {
window.alert('ERROR: Bootstrap\'s responsive CSS is disabled!\nSee getbootstrap.com/getting-started/#respond-file-proto for details.')
}

+ 5
- 5
system/resources/js/jquery.min.js
File diff suppressed because it is too large
View File


+ 1
- 1
system/vendor/autoload.php View File

@ -4,4 +4,4 @@
require_once __DIR__ . '/composer' . '/autoload_real.php';
return ComposerAutoloaderInitd88c6c25320034df85dd42f1462fbda7::getLoader();
return ComposerAutoloaderInit202d771b98d07410d9e52c5a90cbc9e1::getLoader();

+ 4
- 4
system/vendor/composer/ClassLoader.php View File

@ -13,7 +13,9 @@
namespace Composer\Autoload;
/**
* ClassLoader implements a PSR-0, PSR-4 and classmap class loader.
* ClassLoader implements a PSR-0 class loader
*
* See https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-0.md
*
* $loader = new \Composer\Autoload\ClassLoader();
*
@ -37,8 +39,6 @@ namespace Composer\Autoload;
*
* @author Fabien Potencier <fabien@symfony.com>
* @author Jordi Boggiano <j.boggiano@seld.be>
* @see http://www.php-fig.org/psr/psr-0/
* @see http://www.php-fig.org/psr/psr-4/
*/
class ClassLoader
{
@ -147,7 +147,7 @@ class ClassLoader
* appending or prepending to the ones previously set for this namespace.
*
* @param string $prefix The prefix/namespace, with trailing '\\'
* @param array|string $paths The PSR-4 base directories
* @param array|string $paths The PSR-0 base directories
* @param bool $prepend Whether to prepend the directories
*
* @throws \InvalidArgumentException


+ 1
- 1
system/vendor/composer/LICENSE View File

@ -1,5 +1,5 @@
Copyright (c) 2016 Nils Adermann, Jordi Boggiano
Copyright (c) 2015 Nils Adermann, Jordi Boggiano
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal


+ 0
- 2
system/vendor/composer/autoload_classmap.php View File

@ -19,6 +19,4 @@ return array(
'Suin\\RSSWriter\\Item' => $vendorDir . '/suin/php-rss-writer/src/Suin/RSSWriter/Item.php',
'Suin\\RSSWriter\\ItemInterface' => $vendorDir . '/suin/php-rss-writer/src/Suin/RSSWriter/ItemInterface.php',
'Suin\\RSSWriter\\SimpleXMLElement' => $vendorDir . '/suin/php-rss-writer/src/Suin/RSSWriter/SimpleXMLElement.php',
'URLify' => $vendorDir . '/jbroadway/urlify/URLify.php',
'URLifyTest' => $vendorDir . '/jbroadway/urlify/tests/URLifyTest.php',
);

+ 7
- 6
system/vendor/composer/autoload_files.php View File

@ -6,10 +6,11 @@ $vendorDir = dirname(dirname(__FILE__));
$baseDir = dirname(dirname($vendorDir));
return array(
'e40631d46120a9c38ea139981f8dab26' => $vendorDir . '/ircmaxell/password-compat/lib/password.php',
'3abd73be56f01e9aafc62d31c7e15d91' => $baseDir . '/system/includes/dispatch.php',
'f770a6f41af7b4285303bdcc4ff87ba7' => $baseDir . '/system/includes/functions.php',
'8432047aca7938f88a2098a2f7770228' => $baseDir . '/system/admin/admin.php',
'1b9bf2d9d029f1364c3d7262b5375c41' => $baseDir . '/system/includes/session.php',
'62f038defb1b29aab3998eb437e01df9' => $baseDir . '/system/includes/opml.php',
'05669301f06448944ce5eb260126f84e' => $vendorDir . '/ircmaxell/password-compat/lib/password.php',
'd662bbf785a887e687f7fa6bdd9aa881' => $baseDir . '/system/includes/dispatch.php',
'fb0ea7d90f78e44562b8d920c0121d2e' => $baseDir . '/system/includes/functions.php',
'e007dd6c75e8015538ebb6eebefb736e' => $baseDir . '/system/admin/admin.php',
'372406877c969643fd5d4bdc28f7a64a' => $baseDir . '/system/includes/session.php',
'46286444bb46675598ca39831bb66c52' => $baseDir . '/system/includes/opml.php',
'7487caa065ba62094dc29560a54a535d' => $baseDir . '/system/plugins/urlify/URLify.php',
);

+ 0
- 1
system/vendor/composer/autoload_namespaces.php View File

@ -6,7 +6,6 @@ $vendorDir = dirname(dirname(__FILE__));
$baseDir = dirname(dirname($vendorDir));
return array(
'URLify' => array($vendorDir . '/jbroadway/urlify'),
'Suin\\RSSWriter' => array($vendorDir . '/suin/php-rss-writer/src'),
'Michelf' => array($vendorDir . '/michelf/php-markdown'),
);

+ 17
- 28
system/vendor/composer/autoload_real.php View File

@ -2,7 +2,7 @@
// autoload_real.php @generated by Composer
class ComposerAutoloaderInitd88c6c25320034df85dd42f1462fbda7
class ComposerAutoloaderInit202d771b98d07410d9e52c5a90cbc9e1
{
private static $loader;
@ -19,48 +19,37 @@ class ComposerAutoloaderInitd88c6c25320034df85dd42f1462fbda7
return self::$loader;
}
spl_autoload_register(array('ComposerAutoloaderInitd88c6c25320034df85dd42f1462fbda7', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInit202d771b98d07410d9e52c5a90cbc9e1', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
spl_autoload_unregister(array('ComposerAutoloaderInitd88c6c25320034df85dd42f1462fbda7', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInit202d771b98d07410d9e52c5a90cbc9e1', 'loadClassLoader'));
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION');
if ($useStaticLoader) {
require_once __DIR__ . '/autoload_static.php';
call_user_func(\Composer\Autoload\ComposerStaticInitd88c6c25320034df85dd42f1462fbda7::getInitializer($loader));
} else {
$map = require __DIR__ . '/autoload_namespaces.php';
foreach ($map as $namespace => $path) {
$loader->set($namespace, $path);
}
$map = require __DIR__ . '/autoload_namespaces.php';
foreach ($map as $namespace => $path) {
$loader->set($namespace, $path);
}
$map = require __DIR__ . '/autoload_psr4.php';
foreach ($map as $namespace => $path) {
$loader->setPsr4($namespace, $path);
}
$map = require __DIR__ . '/autoload_psr4.php';
foreach ($map as $namespace => $path) {
$loader->setPsr4($namespace, $path);
}
$classMap = require __DIR__ . '/autoload_classmap.php';
if ($classMap) {
$loader->addClassMap($classMap);
}
$classMap = require __DIR__ . '/autoload_classmap.php';
if ($classMap) {
$loader->addClassMap($classMap);
}
$loader->register(true);
if ($useStaticLoader) {
$includeFiles = Composer\Autoload\ComposerStaticInitd88c6c25320034df85dd42f1462fbda7::$files;
} else {
$includeFiles = require __DIR__ . '/autoload_files.php';
}
$includeFiles = require __DIR__ . '/autoload_files.php';
foreach ($includeFiles as $fileIdentifier => $file) {
composerRequired88c6c25320034df85dd42f1462fbda7($fileIdentifier, $file);
composerRequire202d771b98d07410d9e52c5a90cbc9e1($fileIdentifier, $file);
}
return $loader;
}
}
function composerRequired88c6c25320034df85dd42f1462fbda7($fileIdentifier, $file)
function composerRequire202d771b98d07410d9e52c5a90cbc9e1($fileIdentifier, $file)
{
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
require $file;


+ 46
- 102
system/vendor/composer/installed.json View File

@ -43,6 +43,52 @@
"password"
]
},
{
"name": "suin/php-rss-writer",
"version": "1.3.1",
"version_normalized": "1.3.1.0",
"source": {
"type": "git",
"url": "https://github.com/suin/php-rss-writer.git",
"reference": "96ff59575442dbe23e15fe7ff56d0bf27486cff9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/suin/php-rss-writer/zipball/96ff59575442dbe23e15fe7ff56d0bf27486cff9",
"reference": "96ff59575442dbe23e15fe7ff56d0bf27486cff9",
"shasum": ""
},
"require": {
"php": ">=5.3.0"
},
"time": "2015-08-21 06:24:39",
"type": "library",
"installation-source": "dist",
"autoload": {
"psr-0": {
"Suin\\RSSWriter": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Hidehito Nozawa aka Suin",
"email": "suinyeze@gmail.com"
}
],
"description": "Yet another simple RSS writer library for PHP 5.3 or later.",
"homepage": "https://github.com/suin/php-rss-writer",
"keywords": [
"feed",
"generator",
"php",
"rss",
"writer"
]
},
{
"name": "michelf/php-markdown",
"version": "1.6.0",
@ -141,107 +187,5 @@
}
],
"description": "Simple Github Updater for Web Projects"
},
{
"name": "suin/php-rss-writer",
"version": "1.3.2",
"version_normalized": "1.3.2.0",
"source": {
"type": "git",
"url": "https://github.com/suin/php-rss-writer.git",
"reference": "51840d2fad4087a4bdd93fb6937aa4b324b5c94f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/suin/php-rss-writer/zipball/51840d2fad4087a4bdd93fb6937aa4b324b5c94f",
"reference": "51840d2fad4087a4bdd93fb6937aa4b324b5c94f",
"shasum": ""
},
"require": {
"php": ">=5.3.0"
},
"time": "2016-03-01 12:09:17",
"type": "library",
"installation-source": "dist",
"autoload": {
"psr-0": {
"Suin\\RSSWriter": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Hidehito Nozawa aka Suin",
"email": "suinyeze@gmail.com"
}
],
"description": "Yet another simple RSS writer library for PHP 5.3 or later.",
"homepage": "https://github.com/suin/php-rss-writer",
"keywords": [
"feed",
"generator",
"php",
"rss",
"writer"
]
},
{
"name": "jbroadway/urlify",
"version": "1.0.8-stable",
"version_normalized": "1.0.8.0",
"source": {
"type": "git",
"url": "https://github.com/jbroadway/urlify.git",
"reference": "984c991881501098eafdc41053b243237191cff8"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/jbroadway/urlify/zipball/984c991881501098eafdc41053b243237191cff8",
"reference": "984c991881501098eafdc41053b243237191cff8",
"shasum": ""
},
"require": {
"php": ">=5.3.0"
},
"time": "2016-07-27 15:26:43",
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.0-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-0": {
"URLify": ""
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD"
],
"authors": [
{
"name": "Johnny Broadway",
"email": "johnny@johnnybroadway.com",
"homepage": "http://www.johnnybroadway.com/"
}
],
"description": "PHP port of URLify.js from the Django project. Transliterates non-ascii characters for use in URLs.",
"homepage": "https://github.com/jbroadway/urlify",
"keywords": [
"encode",
"iconv",
"link",
"slug",
"translit",
"transliterate",
"transliteration",
"url",
"urlify"
]
}
]

+ 1
- 46
system/vendor/suin/php-rss-writer/Tests/Suin/RSSWriter/ItemTest.php View File

@ -143,52 +143,7 @@ class ItemTest extends TestCase
<description>{$data['description']}</description>
<category>{$data['categories'][0][0]}</category>
<category domain=\"{$data['categories'][1][1]}\">{$data['categories'][1][0]}</category>
<guid>{$data['guid']}</guid>
<pubDate>{$nowString}</pubDate>
<enclosure url=\"{$data['enclosure']['url']}\" type=\"{$data['enclosure']['type']}\" length=\"{$data['enclosure']['length']}\"/>
<author>{$data['author']}</author>
</item>
";
$this->assertXmlStringEqualsXmlString($expect, $item->asXML()->asXML());
}
public function testAsXML_false_permalink()
{
$now = time();
$nowString = date(DATE_RSS, $now);
$data = array(
'title' => "Venice Film Festival Tries to Quit Sinking",
'url' => 'http://nytimes.com/2004/12/07FEST.html',
'description' => "Some of the most heated chatter at the Venice Film Festival this week was about the way that the arrival of the stars at the Palazzo del Cinema was being staged.",
'categories' => array(
array("Grateful Dead", null),
array("MSFT", 'http://www.fool.com/cusips'),
),
'guid' => "http://inessential.com/2002/09/01.php#a2",
'isPermalink' => false,
'pubDate' => $now,
'enclosure' => array(
'url' => 'http://link-to-audio-file.com/test.mp3',
'length' => 4992,
'type' => 'audio/mpeg'),
'author' => 'Hidehito Nozawa aka Suin'
);
$item = new Item();
foreach ($data as $key => $value) {
$this->reveal($item)->attr($key, $value);
}
$expect = "
<item>
<title>{$data['title']}</title>
<link>{$data['url']}</link>
<description>{$data['description']}</description>
<category>{$data['categories'][0][0]}</category>
<category domain=\"{$data['categories'][1][1]}\">{$data['categories'][1][0]}</category>
<guid isPermaLink=\"false\">{$data['guid']}</guid>
<guid isPermaLink=\"true\">{$data['guid']}</guid>
<pubDate>{$nowString}</pubDate>
<enclosure url=\"{$data['enclosure']['url']}\" type=\"{$data['enclosure']['type']}\" length=\"{$data['enclosure']['length']}\"/>
<author>{$data['author']}</author>


+ 2
- 2
system/vendor/suin/php-rss-writer/src/Suin/RSSWriter/Item.php View File

@ -108,8 +108,8 @@ class Item implements ItemInterface
if ($this->guid) {
$guid = $xml->addChild('guid', $this->guid);
if ($this->isPermalink === false) {
$guid->addAttribute('isPermaLink', 'false');
if ($this->isPermalink) {
$guid->addAttribute('isPermaLink', 'true');
}
}


Loading…
Cancel
Save