Skip to content

Commit

Permalink
added relative_path to templates
Browse files Browse the repository at this point in the history
  • Loading branch information
barisusakli committed Jan 5, 2014
1 parent 02e550d commit 9da165c
Show file tree
Hide file tree
Showing 21 changed files with 71 additions and 73 deletions.
2 changes: 1 addition & 1 deletion public/templates/account.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

<div class="account-username-box" data-userslug="{userslug}">
<span class="account-username">
<a href="/user/{userslug}">{username}</a>
<a href="{relative_path}/user/{userslug}">{username}</a>
</span>
</div>

Expand Down
4 changes: 2 additions & 2 deletions public/templates/accountedit.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@

<div class="account-username-box" data-userslug="{userslug}">
<span class="account-username">
<a href="/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="/user/{userslug}/edit">[[user:edit]]</a>
<a href="{relative_path}/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="{relative_path}/user/{userslug}/edit">[[user:edit]]</a>
</span>
</div>

Expand Down
4 changes: 2 additions & 2 deletions public/templates/accountsettings.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

<div class="account-username-box" data-userslug="{userslug}">
<span class="account-username">
<a href="/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="/user/{userslug}/settings">[[user:settings]]</a>
<a href="{relative_path}/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="{relative_path}/user/{userslug}/settings">[[user:settings]]</a>
</span>
</div>

Expand Down
11 changes: 5 additions & 6 deletions public/templates/category.tpl
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">{category_name} <a target="_blank" href="../{category_id}.rss"><i class="fa fa-rss-square"></i></a></span>
</li>
<div id="category_active_users"></div>
</ol>

<div>
Expand Down Expand Up @@ -56,7 +55,7 @@
</span>
|
<span>
<a href="/user/{topics.userslug}">
<a href="../../user/{topics.userslug}">
<img class="teaser-pic" src="{topics.picture}" title="{topics.username}"/>
</a>
[[category:posted]] <span class="timeago" title="{topics.relativeTime}"></span>
Expand All @@ -66,7 +65,7 @@
<!-- IF topics.unreplied -->
[[category:no_replies]]
<!-- ELSE -->
<a href="/user/{topics.teaser_userslug}">
<a href="../../user/{topics.teaser_userslug}">
<img class="teaser-pic" src="{topics.teaser_userpicture}" title="{topics.teaser_username}"/>
</a>
<a href="../../topic/{topics.slug}#{topics.teaser_pid}">
Expand Down Expand Up @@ -95,7 +94,7 @@
<div class="panel-heading">[[category:sidebar.active_participants]]</div>
<div class="panel-body active-users">
<!-- BEGIN active_users -->
<a data-uid="{active_users.uid}" href="/user/{active_users.userslug}"><img title="{active_users.username}" src="{active_users.picture}" class="img-rounded user-img" /></a>
<a data-uid="{active_users.uid}" href="../../user/{active_users.userslug}"><img title="{active_users.username}" src="{active_users.picture}" class="img-rounded user-img" /></a>
<!-- END active_users -->
</div>
</div>
Expand All @@ -104,7 +103,7 @@
<div class="panel-heading">[[category:sidebar.moderators]]</div>
<div class="panel-body moderators">
<!-- BEGIN moderators -->
<a href="/user/{moderators.userslug}"><img title="{moderators.username}" src="{moderators.picture}" class="img-rounded" /></a>
<a href="../../user/{moderators.userslug}"><img title="{moderators.username}" src="{moderators.picture}" class="img-rounded" /></a>
<!-- END moderators -->
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion public/templates/confirm.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
<strong>{title}</strong>
<p>{text}</p>
<p>
<a href="/">[[notifications:back_to_home]]</a>
<a href="{relative_path}/">[[notifications:back_to_home]]</a>
</p>
</div>
6 changes: 3 additions & 3 deletions public/templates/favourites.tpl
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<div class="well favourites">
<div class="account-username-box" data-userslug="{userslug}">
<span class="account-username">
<a href="/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="/user/{userslug}/favourites">[[topic:favourites]]</a>
<a href="{relative_path}/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="{relative_path}/user/{userslug}/favourites">[[topic:favourites]]</a>
</span>
</div>

<!-- IF show_nofavourites -->
<div id="no-favourites-notice" class="alert alert-warning">[[topic:has_no_favourites]]</div>
<div id="no-favourites-notice" class="alert alert-warning">[[topic:favourites.has_no_favourites]]</div>
<!-- ENDIF show_nofavourites -->

<div class="row">
Expand Down
8 changes: 4 additions & 4 deletions public/templates/followers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@

<div class="account-username-box" data-userslug="{userslug}">
<span class="account-username">
<a href="/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="/user/{userslug}/followers">[[user:followers]]</a>
<a href="../../user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="../../user/{userslug}/followers">[[user:followers]]</a>
</span>
</div>

<div>
<!-- BEGIN followers -->
<div class="users-box">
<a href="/user/{followers.userslug}">
<a href="../../user/{followers.userslug}">
<img src="{followers.picture}" class="img-thumbnail"/>
</a>
<br/>
<div class="user-info">
<a href="/user/{followers.userslug}">{followers.username}</a>
<a href="../../user/{followers.userslug}">{followers.username}</a>
<br/>
<div title="reputation" class="reputation">
<i class='fa fa-star'></i>
Expand Down
8 changes: 4 additions & 4 deletions public/templates/following.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@

<div class="account-username-box" data-userslug="{userslug}">
<span class="account-username">
<a href="/user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="/user/{userslug}/following">[[user:following]]</a>
<a href="../../user/{userslug}">{username}</a> <i class="fa fa-chevron-right"></i>
<a href="../../user/{userslug}/following">[[user:following]]</a>
</span>
</div>

<div>
<!-- BEGIN following -->
<div class="users-box">
<a href="/user/{following.userslug}">
<a href="../../user/{following.userslug}">
<img src="{following.picture}" class="img-thumbnail"/>
</a>
<br/>
<div class="user-info">
<a href="/user/{following.userslug}">{following.username}</a>
<a href="../../user/{following.userslug}">{following.username}</a>
<br/>
<div title="reputation" class="reputation">
<span class='formatted-number'>{following.reputation}</span>
Expand Down
2 changes: 1 addition & 1 deletion public/templates/home.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<div class="row home" itemscope itemtype="http://www.schema.org/ItemList">
<!-- BEGIN categories -->
<div class="{categories.class}">
<a href="category/{categories.slug}" itemprop="url">
<a href="{relative_path}/category/{categories.slug}" itemprop="url">
<meta itemprop="name" content="{categories.name}">
<h4><span class="badge {categories.badgeclass}">{categories.topic_count} </span> {categories.name}</h4>
<div class="icon" style="background: {categories.background}; color: {categories.color};">
Expand Down
4 changes: 2 additions & 2 deletions public/templates/login.tpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">[[login:login]]</span>
Expand Down Expand Up @@ -41,7 +41,7 @@
<div class="form-group">
<div class="col-lg-offset-2 col-lg-10">
<hr />
<button class="btn btn-primary btn-lg btn-block" id="login" type="submit">[[login:login]]</button> &nbsp; <a id="reset-link" class="hide" href="/reset">[[login:forgot_password]]</a>
<button class="btn btn-primary btn-lg btn-block" id="login" type="submit">[[login:login]]</button> &nbsp; <a id="reset-link" class="hide" href="{relative_path}/reset">[[login:forgot_password]]</a>
</div>
</div>
<input type="hidden" name="_csrf" value="{token}" id="csrf-token" />
Expand Down
2 changes: 1 addition & 1 deletion public/templates/logout.tpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">[[global:logout]]</span>
Expand Down
1 change: 0 additions & 1 deletion public/templates/noscript/category.tpl
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<ol class="breadcrumb">
<li><a href="/">Home</a></li>
<li class="active">{category_name}</li>
<div id="category_active_users"></div>
</ol>
<ul class="topics">
<!-- BEGIN topics -->
Expand Down
2 changes: 1 addition & 1 deletion public/templates/outgoing.tpl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="outgoing">
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">Home</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">Home</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">[[notifications:outgoing_link]]</span>
Expand Down
22 changes: 11 additions & 11 deletions public/templates/recent.tpl
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<ol class="breadcrumb">
<li><a href="/">Home</a></li>
<li class="active">Recent <a href="/recent.rss"><i class="fa fa-rss-square"></i></a></li>
<li><a href="{relative_path}/">Home</a></li>
<li class="active">Recent <a href="{relative_path}/recent.rss"><i class="fa fa-rss-square"></i></a></li>
</ol>

<ul class="nav nav-pills">
<li class=''><a href='/recent/day'>[[recent:day]]</a></li>
<li class=''><a href='/recent/week'>[[recent:week]]</a></li>
<li class=''><a href='/recent/month'>[[recent:month]]</a></li>
<li class=''><a href='{relative_path}/recent/day'>[[recent:day]]</a></li>
<li class=''><a href='{relative_path}/recent/week'>[[recent:week]]</a></li>
<li class=''><a href='{relative_path}/recent/month'>[[recent:month]]</a></li>
</ul>

<br />

<a href="/recent">
<a href="{relative_path}/recent">
<div class="alert alert-warning hide" id="new-topics-alert"></div>
</a>

Expand All @@ -27,7 +27,7 @@
<div class="row">
<div class="col-md-12 col-xs-12 topic-row img-thumbnail">

<a href="../../topic/{topics.slug}">
<a href="{relative_path}/topic/{topics.slug}">
<h3><span class="topic-title"><strong><i class="fa {topics.pin-icon}"></i> <i class="fa {topics.lock-icon}"></i></strong> {topics.title}</span></h3>
</a>
<small>
Expand All @@ -42,11 +42,11 @@
</span>
|
<span>
<a href="/user/{topics.userslug}">
<a href="{relative_path}/user/{topics.userslug}">
<img class="teaser-pic" src="{topics.picture}" title="{topics.username}"/>
</a>
posted in
<a href="../../category/{topics.categorySlug}">
<a href="{relative_path}/category/{topics.categorySlug}">
<i class="fa {topics.categoryIcon}"></i> {topics.categoryName}
</a>
<span class="timeago" title="{topics.relativeTime}"></span>
Expand All @@ -57,10 +57,10 @@
<!-- IF topics.unreplied -->
No one has replied
<!-- ELSE -->
<a href="/user/{topics.teaser_userslug}">
<a href="{relative_path}/user/{topics.teaser_userslug}">
<img class="teaser-pic" src="{topics.teaser_userpicture}" title="{topics.teaser_username}"/>
</a>
<a href="../../topic/{topics.slug}#{topics.teaser_pid}">
<a href="{relative_path}/topic/{topics.slug}#{topics.teaser_pid}">
replied
</a>
<span class="timeago" title="{topics.teaser_timestamp}"></span>
Expand Down
2 changes: 1 addition & 1 deletion public/templates/register.tpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">[[register:register]]</span>
Expand Down
7 changes: 4 additions & 3 deletions public/templates/reset.tpl
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">[[reset_password:reset_password]]</span>
</li>
</ol>

<div class="alert alert-info">
[[reset_password:reset_password:enter_email]]
</div>
[[reset_password:reset_password:enter_email]]
</div>

<div class="well">
<div class="alert alert-success" id="success" style="display:none">
<button type="button" class="close" data-dismiss="alert">&times;</button>
Expand Down
4 changes: 2 additions & 2 deletions public/templates/reset_code.tpl
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
</li>
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/reset" itemprop="url"><span itemprop="title">[[reset_password:reset_password]]</span></a>
<a href="{relative_path}/reset" itemprop="url"><span itemprop="title">[[reset_password:reset_password]]</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">[[reset_password:update_password]]</span>
Expand Down
6 changes: 3 additions & 3 deletions public/templates/search.tpl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<ol class="breadcrumb">
<li><a href="/">[[global:home]]</a></li>
<li><a href="{relative_path}/">[[global:home]]</a></li>
<li class="active">[[global:header.search]]</li>
</ol>

Expand All @@ -26,7 +26,7 @@

<!-- BEGIN topics -->
<li class="category-item">
<a href="../../topic/{topics.slug}" id="tid-{topics.tid}">
<a href="{relative_path}/topic/{topics.slug}" id="tid-{topics.tid}">
<div>
<div class="col-md-12 img-thumbnail">
<div class="search-result-post">
Expand All @@ -50,7 +50,7 @@
<ul id="topics-container" data-search-query="{search_query}">
<!-- BEGIN posts -->
<li class="category-item">
<a href="../../topic/{posts.topicSlug}#{posts.pid}" id="tid-{posts.tid}">
<a href="{relative_path}/topic/{posts.topicSlug}#{posts.pid}" id="tid-{posts.tid}">
<div>
<div class="col-md-12 img-thumbnail">
<div class="search-result-post">
Expand Down
14 changes: 7 additions & 7 deletions public/templates/topic.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
<div class="topic">
<ol class="breadcrumb">
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
<a href="{relative_path}/" itemprop="url"><span itemprop="title">[[global:home]]</span></a>
</li>
<li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="/category/{category_slug}" itemprop="url"><span itemprop="title">{category_name}</span></a>
<a href="{relative_path}/category/{category_slug}" itemprop="url"><span itemprop="title">{category_name}</span></a>
</li>
<li class="active" itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb">
<span itemprop="title">{topic_name} <a target="_blank" href="../{topic_id}.rss"><i class="fa fa-rss-square"></i></a></span>
Expand All @@ -33,7 +33,7 @@
<meta itemprop="dateModified" content="{posts.relativeEditTime}">

<div class="col-md-1 profile-image-block hidden-xs hidden-sm sub-post">
<a href="/user/{posts.userslug}">
<a href="{relative_path}/user/{posts.userslug}">
<img src="{posts.picture}" align="left" class="img-thumbnail" itemprop="image" />
<!-- IF posts.user_banned -->
<span class="label label-danger">[[topic:banned]]</span>
Expand All @@ -44,7 +44,7 @@

<div class="col-md-11">
<div class="post-block">
<a class="main-post avatar" href="/user/{posts.userslug}">
<a class="main-post avatar" href="{relative_path}/user/{posts.userslug}">
<img itemprop="image" src="{posts.picture}" align="left" class="img-thumbnail" width=150 height=150 />
</a>
<h3 class="main-post">
Expand All @@ -54,12 +54,12 @@
<div class="topic-buttons">
<div class="btn-group">
<button class="btn btn-sm btn-default dropdown-toggle" data-toggle="dropdown" type="button" title="[[topic:posted_by]] {posts.username}">
<span class="username-field" href="/user/{posts.userslug}" itemprop="author">{posts.username}&nbsp;</span>
<span class="username-field" href="{relative_path}/user/{posts.userslug}" itemprop="author">{posts.username}&nbsp;</span>
<span class="caret"></span>
</button>

<ul class="dropdown-menu">
<li><a href="/user/{posts.userslug}"><i class="fa fa-user"></i> [[topic:profile]]</a></li>
<li><a href="{relative_path}/user/{posts.userslug}"><i class="fa fa-user"></i> [[topic:profile]]</a></li>
<li><a href="#" class="chat"><i class="fa fa-comment"></i> [[topic:chat]]</a></li>
</ul>
</div>
Expand Down Expand Up @@ -120,7 +120,7 @@
<span class="pull-right">
[[category:posted]] <span class="relativeTimeAgo timeago" title="{posts.relativeTime}"></span>
<!-- IF posts.editor -->
<span>| [[category:last_edited_by]] <strong><a href="/user/{posts.editorslug}">{posts.editorname}</a></strong></span>
<span>| [[category:last_edited_by]] <strong><a href="{relative_path}/user/{posts.editorslug}">{posts.editorname}</a></strong></span>
<span class="timeago" title="{posts.relativeEditTime}"></span>
<!-- ENDIF posts.editor -->
</span>
Expand Down
Loading

0 comments on commit 9da165c

Please sign in to comment.