
Files to change:
- addcomments.tpl (add tag question/answer)
- addnews.tpl (add tag question/answer)
- comments.tpl (Change and add editor style)
- fullstory.tpl (add topnews list style)
- login.tpl (add tag do not remember me option)
- pm.tpl (add google reCaptcha)
- profile_popup.tpl (add tag subscribe to user RSS feed and change tags)
- registration.tpl (add tag question/answer)
- shortstory.tpl
- userinfo.tpl (add ignore list and change tags)
- preview.css (add pre code style)
- /style/engine.css (add pre code style)
- /style/styles.css (or your theme main css style file)
- .htaccess (change structure for template protection)
Files to add:
- frame.css (popup windows page)
- print.tpl (articles print page)
- relatednews.tpl (additional files for related news module)
- static_print.tpl (static print page)
- topnews.tpl (additional files for top news module)
- dleimages/delete.png
- dleimages/no_image.jpg
- dleimages/videopreview.jpg
- dleimages/youtubepreview.jpg
- images/complaint.png
- bbcodes/typograf.gif
- images/button.png
- images/loading.gif
- images/offline.png
- images/online.png
- images/shadow.png
- images/tableft.gif
- images/tabright.gif
Files to change
1) Open addcomments.tpl
Find
[sec_code]
Add before
[question]
<tr>
<td class="label">Question:</td>
<td><div>{question}</div></td>
</tr>
<tr>
<td class="label">Answer:<span class="impot">*</span></td>
<td><div><input type="text" name="question_answer" id="question_answer" class="f_input" /></div></td>
</tr>
[/question]
2) Open addnews.tpl
Add the following code on the beginning of the file:
<link rel="stylesheet" type="text/css" href="engine/skins/chosen/chosen.css"/>
<script type="text/javascript" src="engine/skins/chosen/chosen.js"></script>
<script type="text/javascript">
$(function(){
$('#category').chosen({allow_single_deselect:true, no_results_text: 'No category found or not selected'});
});
</script>
Find
[sec_code]
Add before
[question]
<tr>
<td class="label">Question:</td>
<td><div>{question}</div></td>
</tr>
<tr>
<td class="label">Answer:<span class="impot">*</span></td>
<td><div><input type="text" name="question_answer" class="f_input" /></div></td>
</tr>
[/question]
3) Open comments.tpl
Find
<li>[com-edit]Edit[/com-edit]</li>
Add before
<li>[complaint]Report Abuse[/complaint]</li>
<li>Registration: {registration}</li>
Add before
<li>Status: [online]<img src="{THEME}/images/online.png" style="vertical-align: middle;" title="Currently Online" alt="Currently Online" />[/online][offline]<img src="{THEME}/images/offline.png" style="vertical-align: middle;" title="Currently Offline" alt="Currently Offline" />[/offline]</li>
4) Open fullstory.tpl
Find
<li>{favorites}</li>
Add after
<li>[complaint]<img src="{THEME}/images/complaint.png" title="Report Error" alt="Report Error" />[/complaint]</li>
Find
<div class="ratebox"><div class="rate">{rating}</div></div>
Replace with
[rating]<div class="ratebox"><div class="rate">{rating}</div></div>[/rating]
Find
<a class="addcombtn" href="javascript:ShowOrHide('addcform')">
Replace with
<a class="addcombtn" href="#" onclick="$('#addcform') .toggle();return false;">
End: Skip this step if you are not using "Default" theme
5) Open shortstory.tpl
Find
<div class="ratebox"><div class="rate">{rating}</div></div>
Replace with
[rating]<div class="ratebox"><div class="rate">{rating}</div></div>[/rating]
6) Open login.tpl
Find
<label for="login_name">Name:</label><input type="text" name="login_name" id="login_name" />
Replace with
<label for="login_name">{login-method}</label><input type="text" name="login_name" id="login_name" />
Note: the theme design maybe vary, so don't worry if you can't find the code above, this upgrade instruction is base on the "Default" theme that comes with script, so if you are not using Default theme then please note this option is for "Login" method, the tag is only to let your site members know that which method your website is setting to login by using "Username" or "E-mail", so the exactly purpose of tag {login-method} is to switch between method text, so if you have special design on your theme, you just need to put the text to tell your members which method you use for login in your website, so that you don't have to put the tag {login-method} in your theme, for example www.dlestarter.com is using email login method and we use icon for login input, so we just use email icon and text to tell our members that we use email login, not username...so that's good example.
Find
<li class="lbtn"><button class="fbutton" onclick="submit();" type="submit" title="Login"><span>Login</span></button></li>
Add before
<li class="lfield lfchek"><input type="checkbox" name="login_not_save" id="login_not_save" value="1"/><label for="login_not_save"> Do not remember me</label></li>
7) Open pm.tpl
Find
<li>[del]Delete[/del]</li>
Add before
<li>[complaint]Report Abuse[/complaint]</li> <li>[ignore]Add Sender to my block list[/ignore]</li>
- [ignore] and [/ignore] for the link adding the sender to the ignore list or black list.
Find
<div class="dpad">[inbox]Inbox[/inbox] | [outbox]Outbox[/outbox] | [new_pm]Send New PM[/new_pm]</div>
Replace with
<div class="dpad">
<div class="pm_status">
<div class="pm_status_head">PM Statistics</div>
<div class="pm_status_content">PM for your account usages:
{pm-progress-bar}
{proc-pm-limit}% out of ({pm-limit} allowed)
</div>
</div>
<div style="padding-top:10px;">[inbox]Inbox[/inbox]<br /><br />
[outbox]Outbox[/outbox]<br /><br />
[new_pm]Send New PM[/new_pm]</div>
</div><br />
<div class="clr"></div>
- {pm-progress-bar} this is the bar to show the level of pm box in your account
- {proc-pm-limit}% this is the percentage of usages
- {pm-limit} this is the total PM message allowed for your user account (Set in usergroup manager)
8) Open profile_popup.tpl
Find
{news_num} [ {news} ]
Add after
[rss]<img src="{THEME}/images/rss.png" alt="rss" style="vertical-align: middle; margin-left: 5px;" />[/rss]
Find
{news_num}
Replace with
{news_num}
Find
{comm_num}
Replace with
{comm-num}
Find
<li><span class="grey">Last Visited:</span> <b>{lastdate}</b></li>
Replace with
<li><span class="grey">Last Visited:</span> <b>{lastdate}</b>, <span class="grey">Status:</span> [online]<img src="{THEME}/images/online.png" style="vertical-align: middle;" title="Currently Online" alt="Currently Online" />[/online][offline]<img src="{THEME}/images/offline.png" style="vertical-align: middle;" title="Currently Offline" alt="Currently Offline" />[/offline]</li>
9) Open registration.tpl
Find
[sec_code]
Find
[question]
<tr>
<td class="label">Question:</td>
<td><div>{question}</div></td>
</tr>
<tr>
<td class="label">Answer:<span class="impot">*</span></td>
<td><div><input type="text" name="question_answer" class="f_input" /></div></td>
</tr>
[/question]
10) Open userinfo.tpl
Find
{news_num}
Replace with
{news-num}
Find
{comm_num}
Replace with
{comm-num}
Find
<tr>
<td class="label">Location:</td>
<td><input type="text" name="land" value="{land}" class="f_input" /></td>
</tr>
Add after
<tr>
<td class="label">My Black list:</td>
<td>{ignore-list}</td>
</tr>
Find
<li><span class="grey">Last visited:</span> <b>{lastdate}</b></li>
Add after:
<li>Status: [online]<img src="{THEME}/images/online.png" style="vertical-align: middle;" title="Currently Online" alt="Currently Online" />[/online][offline]<img src="{THEME}/images/offline.png" style="vertical-align: middle;" title="Currently Offline" alt="Currently Offline" />[/offline]</li>
11/12) Open the file /style/engine.css and preview.css
Add the following code at the end:
/*--- Code tag highlight [ code ]---*/
pre code {
display: block; padding: 0.5em;
background: #f9fafa;
border: 1px solid #dce7e7;
overflow:auto;
white-space: pre;
}
pre .comment,
pre .template_comment,
pre .diff .header,
pre .doctype,
pre .lisp .string,
pre .javadoc {
color: #93a1a1;
font-style: italic;
}
pre .keyword,
pre .css .rule .keyword,
pre .winutils,
pre .javascript .title,
pre .method,
pre .addition,
pre .css .tag,
pre .lisp .title {
color: #859900;
}
pre .number,
pre .command,
pre .string,
pre .tag .value,
pre .phpdoc,
pre .tex .formula,
pre .regexp,
pre .hexcolor {
color: #2aa198;
}
pre .title,
pre .localvars,
pre .function .title,
pre .chunk,
pre .decorator,
pre .builtin,
pre .built_in,
pre .lisp .title,
pre .identifier,
pre .title .keymethods,
pre .id {
color: #268bd2;
}
pre .tag .title,
pre .rules .property,
pre .django .tag .keyword {
font-weight: bold;
}
pre .attribute,
pre .variable,
pre .instancevar,
pre .lisp .body,
pre .smalltalk .number,
pre .constant,
pre .class .title,
pre .parent,
pre .haskell .label {
color: #b58900;
}
pre .preprocessor,
pre .pi,
pre .shebang,
pre .symbol,
pre .diff .change,
pre .special,
pre .keymethods,
pre .attr_selector,
pre .important,
pre .subst,
pre .cdata {
color: #cb4b16;
}
pre .deletion {
color: #dc322f;
}
pre .tex .formula {
background: #eee8d5;
}
13) Open style/engine.css
Add the following code at the end:
.pm_progress_bar {
border: 1px solid #d8d8d8;
padding: 1px;
margin-top: 10px;
margin-bottom: 10px;
}
.pm_progress_bar span {
background: #000000;
font-size: 0em;
text-indent: -2000em;
height: 10px;
display: block;
overflow: hidden;
}
14) Open style/styles.css
Add the following code at the end:
.pm_status {
float:left;
border: 1px solid #d8d8d8;
padding: 0px;
background-color: #fff;
width: 280px;
height: 100px;
margin-left: 20px;
margin-right: 5px;
}
.pm_status_head {
border-bottom: 1px solid #d8d8d8;
font-size: 0.9em;
background: #fff url("../images/bbcodes.png") repeat-x 0 100%;
height: 22px;
padding: 0;
font-weight: bold;
text-align: center;
color: #4e4e4e;
}
15) open the {THEME}/.htaccess
htaccess
Order allow,deny Deny from all <FilesMatch ".(css)$|^$"> Order deny,allow Allow from all </FilesMatch>For example if you are using theme "WStarter" then the file /templates/WStarter/.htaccess must contain the code above
Files to add (Download from attached file)
Please download the attached file and place them within folder /templates/YOUR THEME/The following files are included in the package (You can use your own images if you like)
- frame.css (popup windows page)
- print.tpl (articles print page)
- relatednews.tpl (additional files for related news module)
- static_print.tpl (static print page)
- topnews.tpl (additional files for top news module)
- dleimages/delete.png
- dleimages/no_image.jpg
- dleimages/videopreview.jpg
- dleimages/youtubepreview.jpg
- images/complaint.png
- bbcodes/typograf.gif
- images/button.png
- images/loading.gif
- images/offline.png
- images/online.png
- images/shadow.png
- images/tableft.gif
- images/tabright.gif
topnews.tpl
Example Code:
<li><a href="{link}">{title}</a></li>
- {link}: is the full link url for the article, it will automatically converted to any link formats of your SEO settings or none SEO
- {title}: is the actual article title
Additional Tags for DLE 9.5,9.6 in user profile and commnets
The following tags are applied to template files userinfo.tpl and comments.tpl
- [fullname]xxx[/fullname] is used for open and close tag if full name field {fullname} was input, for example, in templates/Default/userinfo.tpl,
Find:
<li><span class="grey">Full name:</span> <b>{fullname}</b></li>Replace with:
[fullname]<li><span class="grey">Full name:</span> <b>{fullname}</b></li>[/fullname]If the user input the information in Full name filed then it will show, if not then nothing will show, this tag is intended for remove empty fields in user profile and comments - [icq]xxx[/icq] is used for open and close tag if icq field {icq} was input, for example, in templates/Default/userinfo.tpl,
Find:
<li><span class="grey">ICQ:</span> <b>{icq}</b></li>Replace with:
[icq]<li><span class="grey">ICQ:</span> <b>{icq}</b></li>[/icq]If the user input the information in icq filed then it will show, if not then nothing will show, this tag is intended for remove empty fields in user profile and comments - [land]xxx[/land] is used for open and close tag if location field {land} was input, for example, in templates/Default/userinfo.tpl,
Find:
<li><span class="grey">Location:</span> {land}</li>Replace with:
[land]<li><span class="grey">Location:</span> {land}</li>[/land]If the user input the information in location filed then it will show, if not then nothing will show, this tag is intended for remove empty fields in user profile and comments - [info]xxx[/info] is used for open and close tag if short information field {info} was input, for example, in templates/Default/userinfo.tpl,
Find:
<li><span class="grey">Information:</span> {info}</li>Replace with:
[info]<li><span class="grey">Information:</span> {info}</li>[/info]If the user input the information in short information filed then it will show, if not then nothing will show, this tag is intended for remove empty fields in user profile and comments - [signature]xxx[/signature] is used for open and close tag if signature field {signature} was filled, for example,
Example Code:
[signature]<hr /> <b>{signature}</b>[/signature]If the user filled the information in signature filed then it will show, if not then nothing will show, this tag is intended for remove empty fields in user profile and comments - [news-num]xxx[/news-num] is used for open and close tag if the user have posted article in your website for example,
Example Code:
[news-num]<li style="margin-top:10px;">Posts: <b>{news-num}</b> <span class="button">{news}</span> [rss]<img alt="" src="{THEME}/images/ico/ico_rss.png" border="0" style="vertical-align:middle; margin-bottom: 3px;" title="Feed - Bookmark Posts" />[/rss]</li>[/news-num]If the user had posted at least 1 article in your website then it will show, if not then nothing will show, this tag is intended for remove empty fields in user profile and comments - [comm-num]xxx[/comm-num] is used for open and close tag if the user have posted comment in your website for example,
Example Code:
[comm-num]<li style="margin-top:10px;">Comments: <b>{comm-num}</b> <span class="button">{comments}</span></li>[/comm-num]If the user had posted at least 1 comment in your website then it will show, if not then nothing will show, this tag is intended for remove empty fields in user profile and comments
Reference User Manual:
- http://dle-news.ru/extras/diffs/93/
- http://dle-news.ru/extras/diffs/94/
- http://dle-news.ru/extras/diffs/95/
- http://dle-news.ru/extras/diffs/96/
-
Upgrade theme from 9.4 to 9.5
Since Datalife Engine 9.5 was released, there are some tags and styles are changed and we see many websites have posted the tutorials how to upgrade theme from 9.4 to ...
-
Upgrade Theme from 9.3 to 9.5
Upgrade Datalife Engine theme from 9.3 to 9.5 is our upgrade guide project to help users upgrade the theme in single tutorial without having to worry about 9.4 upgrade ...
-
Upgrade Theme from 9.2 to 9.5
Upgrade Datalife Engine theme from 9.2 to 9.5 is our upgrade guide project to help users upgrade the theme in single tutorial without having to worry about 9.3 and 9.4 ...
-
Upgrade Theme from 9.2 to 9.4
Upgrade Datalife Engine theme from 9.2 to 9.4 is our upgrade guide project to help users upgrade the theme in single tutorial without having to worry about 9.3 upgrade ...



