-
{{ title }}{% if not viewPost %}{% endif %}
- {% if newsPosts|length %}
+
{{ title }}{% if not (viewPost and postExists) %}{% endif %}
+ {% if (viewPost ? postExists : newsPosts|length) %}
{% for post in newsPosts %}
{% include 'elements/newsPost.tpl' %}
{% endfor %}
- {% if not viewPost and news.getPosts(postsPerPage)|length > 1 %}
+ {% if not (viewPost and postExists) and news.getPosts(postsPerPage)|length > 1 %}
{% include 'elements/pagination.tpl' %}
{% endif %}
+ {% include 'elements/comments.tpl' %}
{% else %}
The requested news post does not exist!
diff --git a/_sakura/templates/yuuno/settings/general.home.tpl b/_sakura/templates/yuuno/settings/general.home.tpl
index 97485a5..acd4de2 100644
--- a/_sakura/templates/yuuno/settings/general.home.tpl
+++ b/_sakura/templates/yuuno/settings/general.home.tpl
@@ -30,7 +30,7 @@
Online
{% if user.getFriends(true, true, true).online %}
{% for key,friend in user.getFriends(true, true, true).online %}
-
{{ friend.user.username }}{% if key + 1 != settings.friends.online|length %},{% endif %}
+
{{ friend.user.username }}{% if key + 1 != user.getFriends(true, true, true).online|length %},{% endif %}
{% endfor %}
{% else %}
No friends are online.
@@ -38,7 +38,7 @@
Offline
{% if user.getFriends(true, true, true).offline %}
{% for key,friend in user.getFriends(true, true, true).offline %}
-
{{ friend.user.username }}{% if key + 1 != settings.friends.offline|length %},{% endif %}
+
{{ friend.user.username }}{% if key + 1 != user.getFriends(true, true, true).offline|length %},{% endif %}
{% endfor %}
{% else %}
No friends are offline.
diff --git a/public/.htaccess b/public/.htaccess
index 6a02080..4560faa 100644
--- a/public/.htaccess
+++ b/public/.htaccess
@@ -30,9 +30,9 @@ RewriteRule ^p/([a-z]+)/?$ index.php?p=$1 [L,QSA]
RewriteRule ^news/?$ news.php [L,QSA]
RewriteRule ^news/p([0-9]+)/?$ news.php?page=$1 [L,QSA]
RewriteRule ^news/([0-9]+)/?$ news.php?id=$1 [L,QSA]
-RewriteRule ^news/([a-z]+)/?$ news.php?cat=$1 [L,QSA]
-RewriteRule ^news/([a-z]+)/p([0-9]+)/?$ news.php?cat=$1&page=$2 [L,QSA]
-RewriteRule ^news/([a-z]+)/([0-9]+)/?$ news.php?cat=$1&id=$2 [L,QSA]
+RewriteRule ^news/([a-z\-]+)/?$ news.php?cat=$1 [L,QSA]
+RewriteRule ^news/([a-z\-]+)/p([0-9]+)/?$ news.php?cat=$1&page=$2 [L,QSA]
+RewriteRule ^news/([a-z\-]+)/([0-9]+)/?$ news.php?cat=$1&id=$2 [L,QSA]
RewriteRule ^news.xml$ news.php?xml [L,QSA]
# Settings
diff --git a/public/content/data/yuuno/css/yuuno.css b/public/content/data/yuuno/css/yuuno.css
index e4cc7d2..183f24c 100644
--- a/public/content/data/yuuno/css/yuuno.css
+++ b/public/content/data/yuuno/css/yuuno.css
@@ -181,7 +181,7 @@ img {
max-height: 100%;
}
-img.default-avatar-setting {
+.default-avatar-setting {
max-width: 200px;
max-height: 200px;
border: 3px solid #EEE;
@@ -591,7 +591,7 @@ a.default:active {
#chatUserList > div > .avatar {
width: 50px;
height: 50px;
- background: transparent url("/pixel.png") no-repeat scroll left center / contain;
+ background: transparent url("/content/pixel.png") no-repeat scroll left center / contain;
border-radius: 5px;
}
@@ -2094,3 +2094,80 @@ textarea.inputStyling {
padding: 6px 10px;
border-radius: 3px;
}
+
+/*
+ * Comments
+ */
+.comments {
+}
+
+.comments .comment-input-section {
+ border-top: 1px solid #9475B2;
+ border-bottom: 1px solid #9475B2;
+}
+
+.comments .comment {
+ display: flex;
+ align-items: stretch;
+ margin: 2px 0;
+}
+
+.comments .comment > .comment-avatar {
+ height: 58px;
+ width: 58px;
+ background: url("/content/pixel.png") no-repeat scroll left center / contain;
+ flex-shrink: 0;
+ margin-right: 2px;
+ border-radius: 4px;
+ border: 1px solid #9475B2;
+}
+
+.comments .comment > .comment-pointer {
+ width: 0px;
+ height: 0px;
+ border-style: solid;
+ border-width: 0px 15px 15px 0px;
+ border-color: transparent #FFF transparent transparent;
+}
+
+.comments .comment > .comment-text {
+ border-radius: 0 5px 5px 5px;
+ border: 0;
+ min-height: 50px;
+ height: 50px;
+ flex-grow: 2;
+ padding: 5px;
+ font: 12px/20px "SegoeUI", "Segoe UI", sans-serif;
+ background: #FFF;
+}
+
+.comments .comment > .comment-submit {
+ flex-shrink: 0;
+ font-family: FontAwesome;
+ height: 60px;
+ width: 60px;
+ border-radius: 4px;
+ margin-left: 2px;
+ border: 0;
+ background: #9475B2;
+ color: #FFF;
+ font-size: 2em;
+}
+
+.comments ul {
+ list-style: none;
+}
+
+.comments ul > li > ul {
+ margin-left: 40px;
+}
+
+.comments ul > li > ul .comment > .comment-avatar {
+ height: 48px;
+ width: 48px;
+}
+
+.comments ul > li > ul .comment > .comment-text {
+ min-height: 40px;
+ height: 40px;
+}
Log in to comment!
+ {% endif %} +