hello github! 😘

This commit is contained in:
Abdulrahman
2018-01-09 02:09:07 +03:00
commit 7f4a4f6ff9
540 changed files with 70817 additions and 0 deletions

23
.gitignore vendored Normal file
View File

@@ -0,0 +1,23 @@
cache/*.php
cache/*.log
plugins/*.php
config.php
uploads/*
!uploads/index.html
!uploads/php.ini
!uploads/thumbs
uploads/thumbs/*
!uploads/thumbs/index.html
!uploads/thumbs/php.ini
.DS_Store
*/.DS_Store
*/*/.DS_Store
encodings.xml
kleeja.iml
modules.xml
php.xml
vcs.xml
workspace.xml
Project_Default.xml
.buildpath
.project

126
CHANGELOG.md Executable file
View File

@@ -0,0 +1,126 @@
# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
## 2.3
- fix bug where 'empty files' error when url uplaoding is on.
- fix bug where limiting download size is not working.
- fix bugs where some images in ACP are not shown/missing.
- you can use {username} in folder name now.
- only show/validate captcha for login/admin login if GD is installed.
- fix progress bar (with a style that supports that).
## 2.2
- fix a bug where a user can not upload files with uppercase extensions like PNG.
- fix a bug where a long filename might ruin the download.html page.
- fix a bug where the 'site is closed' not shown.
- new functions add_to_htaccess, remove_from_htaccess to make it easier for plugins to add rules.
- fix typo in download.html link target attribute.
## 2.1
- fix bug where installation shows white page if mysqli is not installed.
- fix bug where some links in admin/users page doesn't work
- prevent non-founder admins from installing/uploading/enabling plugins or styles.
- fix bug where uploading doesn't work because of default php uploading error system.
- fix a problem where a plugin cache still exists after enabling/disabling it.
- fix a bug where file inputs don't increase (reported by ali iraq)
- fix a bug where an admin can not login when Kleeja is closed.
## 2.0
- New file-based-plugin system. No more 'eval' function.
- Removed the ability to edit a template or restore backup template.
- IP addresses now respect CloudFlare integration
- wrong time at show last visit files/images (reported by: bader_vip)
- fix bug:1104, where kleeja_date doesn't respect user time zone (reported by: bader_vip)
- fix bug:1124, fix permission for fileuser (reported by: sadiq6210)
- fix bug:1134, where you can download files without waiting using imgf links (reported by: 2mka)
- fix bug:1121, where kleeja web site links are wrong (reported by: yasorno)
- fix bug:1120, where editing ACLs doesn't work .. (reported by: sadiq6210)
- Captcha in admin login to prevent automated bots.
- screenshots+info of styles in control panel
- fix bug when searching for selected imagess by ip, or username.
- fix bug 1102, where mobile devices users can not copy urls from inputs (style)
- fix bug where calls+reports deleting queue doesn't work! (un-reported)
- fix bug:1117, deleting files from user folder other than page 1 won't work (reported by: bader_vip)
- when enabling htaccess url, rename file from htaccess.tx to .htaccess
- remove KLIVE codes
- fix Default style to be responsive (works with mobile phones + tables)
- fix acp notifications
- alert the user if the file is not allowed [ext + size] before uploading.
- use ig, ip, g, p
- new style based on Bootstrap 4
- new Admin style based on Bootstrap 4
- kljuploader class refactored to an interface, so we could add other uploading methods
- fix image quality problem if watermark is on
- new way of detecting and securing kleeja during uploading.
- open ip search in new window
- fix htaccess rule where fileuser page not accessible by others
- Images has their own links form now.
- Captcha in login page to prevent password guessing.
- you can now use parameters in uploading folder input like {year} {month} {week} {day}.
- show captcha for admin login if first attempt was wrong.
- only support php 7+.
## 1.7
- Kleeja 1.7 is compatible with PHP7 now.
- some other fixes.
## 1.6
- Fix XSS bug at uploading files [ thanks to Ebram Atef @geekpero ]; bug#1253
- Add useful https header to improve security.
- fix compatibility issue with php 5.5; bug#1252, bug#1240, bug#1239, bug#1241
- fix an error with thumbs.php if no GD installed
- fix bug where admin can not change the ACL [permissions] of users. bug##1229
- fix bug where user cant see his folder if ACL to see others folders is off to him. bug#1228.
- remove gzip feature because user who doesnt know how to use it keep using it. bug#1226
- no more mysql driver, all now transformed to mysqli. bug #1224
- fix bug if number of files that user can upload is 0, he can still upload! bug#1223.
- remove backup feature, no need for it.
## 1.5.4
- When the database old, tell the user to update.
- fix bug in ACP where secondary menu not appear
- add link to user folder at do.php?id=.. page
## 1.5.3
- add turkish language.
- disable ajax by default at ACP ( you can add AJAX_ACP in config.php to turn ajax on )
- some style improvments at ACP
- hide un-important items from ACP menu and add a button to show them.
- fix problems with login + captcha that's appeared at 1.5.2
## 1.5.2
- Add Persian language (thanx for dverbame)
- Fix bug with thumbs size (reported by : Tony Broomfield)
- fix bug where Last visit in ACP doesnt use Kleeja zone (reborted by: Bader_vip)
- fix bug where total files number excludes images (reborted by: Bader_vip)
- fix bug where guests can not access user folders, ucp.php?go=fileuser&id=[userid] (reported by: ibragate)
- fix bug where kleeja doesnt respect decoding type when it set to nothing (reported by: althani)
- fix security issue ..
- Username at registering now should be between 4 to 25 characters (reported by ibragate)
- fix bug where user can not open other page while uploading files (reported by gulfup.com)
- faster home page with new improved javascript tabs
- Juqery.js library is included offically with Kleeja now
- fix bug when there is no file and request thumbf=..., it shows txt error instead of image error.
- good look of images at userfile while loading instead of just white spaces.
- return back to "mysql_real_escape_string, (reported by twitter/Abdullah_says)
## 1.5.1
- Fix bug with uploading from URL.
- Fix bug in SQL when reparing tables.
- FIx bug where function is miswritten [helper_thumb_imagick]
- Fix unclear halt at install.php file
## 1.0 (was in 2007)
- ...

59
README.md Normal file
View File

@@ -0,0 +1,59 @@
# Kleeja
The powerful and easiest way to run File Upload Service on your website.
Trusted by thousands of webmasters since 2007.
## Key Features & Highlights
### Multi-lingual
The script allows you to change the language from Admin Panel easily...
### User-friendly interface with multiple file fields:
The admin can choose the number of file fields which will appear to the user in a very elegant way ... the script interface is also very user-friendly.
### Security:
The script has a user sessions system and the Admin user can also sign out from the Admin Panel and act as a normal user...
### Limit file types and sizes:
The script has an advanced file types management system, The Admin can also control the file size for every single file type for users and guests...
### Limited upload space:
You can limit your upload space and the upload center will close automatically with a simple message when it reaches the limit
### Want to use google Analytics?
You can simply add the "Google Analytics" code in the script settings without having to edit the script files..
### Forums user integration:
You can integrate your current (phpBB ,VBulltin) forum users with your upload center easily...
### Watermark:
The Admin can enable the Watermark option, so that the site logo will appear on the uploaded images...
### Image Thumbnails:
The Admin can also enable this option from the Admin Panel so that the users will be given thumbnail links for the uploaded images...
### Report abuse system:
The user can report abusing files from a simple page without even having to enter the abusing file URL... All the reports will be sent to the Admin Panel with a simple report management system and the Admin can also reply to it ...
### Advanced contact system:
The users can contact the Admin and the messages will be sent to the Admin Panel , with the Admin reply ability...
### Cache system:
This script uses cache (APC, or Flat files) so that the pages would load faster...
### Registration control:
The Admin can choose to open or close new user registration at any time with ease...
### Closing the upload center:
The Admin can choose to open or close the upload center with a custom message.
### UTF8:
The script uses UTF8 encoding
### Who's online:
The Admin can enable the (Who's online) option in a elegant way with separation between users and guests...
### Adjustable Download Counter:
Adjust the waiting period for users before they can download (great for showing ads, so users will spend more time on your pages)
### Single or Mass banning system:
The Admin can ban users using a simplified banning system...
### Multiple Admins:
Yes, you can add more than one Admin user from the Admin Panel ...
### Total repair system:
Deletes cache, Re-checks counters and repairs tables...
### Changing file name with two methods:
You can automatically change the uploaded file's name by the "time" function, the "MD5 encryption" function or you can choose not to use any...
### Uploading from URLs (leech):
Yes, the Admin can enable it from the Admin Panel, although this option is in development...
### Advanced Admin Dashboard:
The Admin home page is the starter page for the Admin where statistics and usage details are listed...
### Terms of service:
The user can't upload before agreeing to the terms, which you can easily edit...
### File deletion URL:
because we care about the privacy of our users, a URL will be given to users after a successful uploading process which the users can use for deleting the uploaded files...
### Spams & Flood Protection:
Kleeja has Spam protection and Flood protection, also it comes with Captcha system.

34
admin/Masmak/admin_ban.html Executable file
View File

@@ -0,0 +1,34 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.R_BAN}</li>
</ol>
<div class="card">
<div class="card-body">
{lang.BAN_EXP1}
<br>
{lang.BAN_EXP2}
</div>
</div>
<br>
<form method="post" action="{action}" id="ban_form">
<div class="form-group">
<!-- textarea -->
<textarea name="ban_text" class="form-control" rows="2" cols="20" style="width:99%; height: 100px;direction:ltr;">{ban}</textarea>
</div>
<br>
<input type="submit" name="submit" value="{lang.UPDATE_BAN}" class="btn btn-primary">
{H_FORM_KEYS}
</form>

114
admin/Masmak/admin_calls.html Executable file
View File

@@ -0,0 +1,114 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.R_CALLS}</li>
<IF NAME="current_smt == show_h24"><li class="breadcrumb-item active"> {lang.SHOW_FROM_24H}</li></IF>
</ol>
<IF NAME="no_results">
<div class="alert alert-info">{lang.MESSAGE_NONE}</div>
<ELSE>
<form method="post" name="callform" action="{action}" id="calls_form">
<div id="accordion" role="tablist" aria-multiselectable="true">
<LOOP NAME="arr">
<div class="card mb-1" id="su[{{id}}]">
<div class="card-header" role="tab" id="heading{{id}}">
<h6 class="mb-0">
<input type="checkbox" class="custom-checkbox" name="del_{{id}}" value="{{id}}" onclick="change_color(this,'su[{{id}}]', 'bg-warning card', 'card');" rel="_del" />
<a data-toggle="collapse" data-parent="#accordion" href="#collapse{{id}}" aria-expanded="false" aria-controls="collapse{{id}}">
{{name}}
<IF LOOP="sent"><i class="fa fa-reply" title="{lang.IS_SEND_MAIL}" data-toggle="tooltip"></i></IF>
</a>
<small class="pull-(lang.DIR==ltr?right:left)">{{human_time}}</small>
</h6>
</div>
<div id="collapse{{id}}" class="collapse" role="tabpanel" aria-labelledby="heading{{id}}">
<div class="card-body">
{{text}}
<br>
<br>
____<br>
<IF LOOP="mail"><span class="text-muted">{lang.EMAIL}:</span> {{mail}}<br></IF>
<span class="text-muted">{lang.IP}:</span> <a href="{{ip_finder}}" target="_blank">{{ip}}</a><br>
<span class="text-muted">{lang.TIME}:</span> {{time}}<br>
<IF LOOP="mail">
<hr>
<a class="btn btn-primary" data-toggle="modal" data-target="#contactForm{{id}}" href="#">
{lang.REPLY_CALL}
</a>
</IF>
</div>
</div>
</div>
</LOOP>
</div>
<!-- pagination -->
{page_nums}
<div class="clearfix"></div>
<br>
<div class="row justify-content-between">
<div class="col col-md-auto">[ <a href="javascript:void(0);" onclick="checkAll(document.callform, '_del', 'su', 'card bg-warning mb-1', 'card mb-1');">{lang.CHECK_ALL}</a> ]</div>
<div class="col col-md-auto"><input type="submit" class="btn btn-outline-primary" name="submit" value="{lang.DEL_SELECTED}" /></div>
</div>
{H_FORM_KEYS}
</form>
<!-- contact form modals -->
<LOOP NAME="arr">
<div class="modal" id="contactForm{{id}}">
<div class="modal-dialog" role="document">
<div class="modal-content">
<form method="post" action="{action}" id="send_form" role="form">
<div class="modal-header">
<h5 class="modal-title">{lang.REPLY_CALL}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
{{text}}
<br>
<br>
____<br>
<IF LOOP="mail"><span class="text-muted">{lang.EMAIL}:</span> {{mail}}<br></IF>
<br>
<textarea name="v_{{id}}" cols="80" class="form-control" rows="3" placeholder="{lang.TEXT}"></textarea>
<input type="hidden" name="reply_submit" value="1">
</div>
<div class="modal-footer">
<button type="submit" name="reply_submit" class="btn btn-primary btn-sm"><span>{lang.REPLY}</span></button>
</div>
</form>
</div>
</div>
</div>
</LOOP>
</IF>
<IF NAME="there_queue">
<br><hr>
<div class="alert alert-info">{lang.DELETE_PROCESS_IN_WORK}</div>
</IF>

View File

@@ -0,0 +1,30 @@
<IF NAME="current_smt == general">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.R_CHECK_UPDATE}</li>
</ol>
<div class="alert <IF NAME="error">alert-warning<ELSE>alert-info</IF>">{text}</div>
<ELSEIF NAME="current_smt == howto">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.HOW_UPDATE_KLEEJA}</li>
</ol>
<ul class="update_list">
<li>{lang.HOW_UPDATE_KLEEJA_STEP1}</li>
<li>{lang.HOW_UPDATE_KLEEJA_STEP2}</li>
<li>{lang.HOW_UPDATE_KLEEJA_STEP3}
<input class="form-control" type="text" value="{update_link}" readonly>
</li>
</ul>
</IF>

20
admin/Masmak/admin_configs.html Executable file
View File

@@ -0,0 +1,20 @@
<form method="post" action="{action}" id="opt_form" class="form">
<!-- admin configs tr extra begin -->
{options}
<!-- admin configs tr extra -->
<!-- button -->
<div class="form-group">
<br>
<input type="hidden" name="submit" value="1" />
<button type="submit" id="submit" name="_submit_" class="btn btn-primary"><span>{n_submit}</span></button>
</div>
{H_FORM_KEYS}
</form>

3
admin/Masmak/admin_err.html Executable file
View File

@@ -0,0 +1,3 @@
<div class="alert alert-danger" role="alert">
{text}
</div>

63
admin/Masmak/admin_extra.html Executable file
View File

@@ -0,0 +1,63 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item">{lang.R_EXTRA}</li>
<IF NAME="current_smt == he">
<li class="breadcrumb-item active">{lang.ADD_HEADER_EXTRA}</li>
<ELSEIF NAME="current_smt == fe">
<li class="breadcrumb-item active">{lang.ADD_FOOTER_EXTRA}</li>
</IF>
</ol>
<form method="post" action="{action}" id="extra_form">
<IF NAME="current_smt == he">
<div class="card">
<div class="card-body">
{lang.EX_HEADER_N}
</div>
</div>
<br>
<div class="form-group">
<textarea id="ex_header" name="ex_header" class="form-control" rows="8">{ex_header}</textarea>
</div>
<ELSEIF NAME="current_smt == fe">
<div class="card">
<div class="card-body">
{lang.EX_FOOTER_N}
</div>
</div>
<br>
<div class="form-group">
<textarea id="ex_footer" name="ex_footer" class="form-control" rows="8">{ex_footer}</textarea>
</div>
</IF>
<br>
<input type="submit" name="submit" value="{lang.UPDATE_EXTRA}" class="btn btn-primary">
{H_FORM_KEYS}
</form>

83
admin/Masmak/admin_files.html Executable file
View File

@@ -0,0 +1,83 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.R_FILES} (<span>{current_page}/{total_pages}</span>)</li>
</ol>
<IF NAME="is_search">
<div class="card">
<span>{lang.FIND_IP_FILES} ( {nums_rows} ) {lang.FILE} <IF NAME="nums_rows"> | <a href="{deletelink}" onclick="javascript:get_kleeja_link(this.href, '#content', {confirm:true}); return false;">{lang.DELETEALLRES}</a></IF></span>
</div>
</IF>
<form method="post" name="filesform" action="{action}" id="files_form">
<IF NAME="no_results">
<div class="alert alert-info">
{lang.NO_RESULT_USE_SYNC}
</div>
<ELSE>
<!-- start data table -->
<div class="table-responsive">
<table class="table table-bordered table-hover table-striped table-sm" width="100%" cellspacing="0">
<thead>
<tr>
<th><a href="javascript:void(0);" onclick="checkAll(document.filesform, '_del', 'su');" title="{lang.DELETE}">#</a></th>
<th style="width:20px;"></th>
<th style="white-space:nowrap;">
<a title="{lang.ALPHABETICAL_ORDER_FILES}"
href="{ord_action}&amp;order_by=real_filename">{lang.FILENAME}</a>
<a href="{page2_action}&amp;order_way=1"><i class="fa fa-sort-asc" title="&uarr;"></i></a>
<a href="{page2_action}&amp;order_way=2"><i class="fa fa-sort-desc"
title="&darr;"></i></a>
</th>
<th><a title="{lang.ORDER_SIZE}" href="{ord_action}&amp;order_by=size">{lang.SIZE}</a></th>
<th><a href="{ord_action}&amp;order_by=folder">{lang.FILDER}</a></th>
<th><a href="{ord_action}&amp;order_by=user">{lang.BY}</a></th>
<th><a href="{ord_action}&amp;order_by=user_ip">{lang.IP}</a></th>
<th><a title="{lang.ORDER_TOTAL_DOWNLOADS}" href="{ord_action}&amp;order_by=uploads"><i class="fa fa-download" title="{lang.FILEUPS}" data-toggle="tooltip"></i></a></th>
<th><a href="{ord_action}&amp;order_by=report"><i class="fa fa-flag" title="{lang.NUMPER_REPORT}" data-toggle="tooltip"></i></a></th>
<th><a href="{ord_action}&amp;order_by=time">{lang.FILEDATE}</a></th>
</tr>
</thead>
<tbody>
<LOOP NAME="arr">
<tr id="su[{{id}}]" class="osilver">
<td><input type="checkbox" name="del_{{id}}" value="{{id}}" onclick="change_color(this,'su[{{id}}]');" rel="_del" /></td>
<td style="width:20px;"><img src="{{typeicon}}" alt="{{type}}" title="{{type}}" data-toggle="tooltip"/></td>
<td title="{{fullname}}" data-toggle="tooltip">{{name}}</td>
<td>{{size}}</td>
<td>{{folder}}</td>
<td>{{user}}</td>
<td>{{ip}} <a title="{lang.SHOWFILESBYIP}" href="{{showfilesbyip}}"><i class="fa fa-search"></i></a></td>
<td><IF LOOP="direct"><i class="fa fa-bell-slash-o" title="{lang.DIRECT_FILE_NOTE}" data-toggle="tooltip"></i><ELSE>{{ups}}</IF></td>
<td>{{report}}</td>
<td title="{{time}}" data-toggle="tooltip">{{time_human}}</td>
<!-- admin files data td2 extra -->
</tr>
</LOOP>
</tbody>
</table>
</div>
<!-- end data table -->
<div class="form-group">
<!--<div class="col">[ <a href="javascript:void(0);" onclick="checkAll(document.filesform, '_del', 'su');">{lang.CHECK_ALL}</a> ]</div>-->
<input type="submit" class="btn btn-outline-primary" name="submit" value="{lang.DEL_SELECTED}">
</div>
<!-- pagination -->
{page_nums}
</IF>
{H_FORM_KEYS}
</form>

228
admin/Masmak/admin_footer.html Executable file
View File

@@ -0,0 +1,228 @@
<br>
</div>
<!-- /.container-fluid -->
</div>
<!-- /.content-wrapper -->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fa fa-chevron-up"></i>
</a>
<!-- Bootstrap core JavaScript -->
<script src="{STYLE_PATH_ADMIN}js/jquery.min.js"></script>
<script src="{STYLE_PATH_ADMIN}js/tether.min.js"></script>
<script src="{STYLE_PATH_ADMIN}js/popper.min.js"></script>
<script src="{STYLE_PATH_ADMIN}js/bootstrap.min.js"></script>
<!-- extra javascript -->
<script type="text/javascript" src="{STYLE_PATH_ADMIN}js/jqBarGraph.js"></script>
<IF NAME="go_to==d_img_ctrl">
<script type="text/javascript" src="{STYLE_PATH_ADMIN}js/jquery.waitforimages.js"></script>
</IF>
<script type="text/javascript">
<!--//
$(function () {
//check for msg, reports every 5min
setTimeout(check_msg_and_reports, 240000);
$('[data-toggle="tooltip"]').tooltip();
$('[data-toggle="popover"]').popover();
<IF NAME="go_to==start">
$('#chart_stats').jqBarGraph({
data: arrayOfDataMulti,
colors: ['#0275d8', '#d9534f'],
legends: ['{lang.FILE}', '{lang.IMAGE}'],
legend: true,
animate: true,
height: 240,
barSpace: 5,
width: $('#chart_stats').width
});
</IF>
<IF NAME="go_to==d_img_ctrl">
$('.xthumbs').waitForImages(function(){
$('#imgs_loading').fadeOut(2000);
$('#imgs_loading').css('display', 'none');
});
//when checked one checkbox?
$(".kcheck input[type=checkbox]").change( function(){
if($('.kcheck input[type=checkbox]:checked').length == 1){
$('#search-one-item').css('display', 'inline');
} else{
$('#search-one-item select').prop('selectedIndex', 0);
$('#search-one-item').css('display', 'none');
}
});
$(".kcheck input[type=checkbox]").click( function(){
$(this).attr('checked', !$(this).attr('checked'));
$(this).trigger('change');
});
$(".kcheck").click( function(){
$(this).find('input').attr('checked', !$(this).find('input').attr('checked'));
$(this).find('input').trigger('change');
});
$('#search-one-item select').change(function(){
tt = this.options[this.selectedIndex].value;
dd = $('.kcheck input[type=checkbox]:checked').val();
if(tt == 1){
s_value = $('#ip_'+dd).html();
}else if(tt == 2){
s_value = $('#user_'+dd).html();
}
window.open("{action_search}&s_input="+tt+"&s_value=" + encodeURI(s_value), '_blank');
});
$('.img-thumb-item a').click(function (e) {
$('.image-model img').attr('src', $(this).attr('data-img-url'));
// return false;
});
</IF>
$(".cb-enable").click(function(){
var parent = $(this).parents('.switch');
$('.cb-disable',parent).removeClass('selected');
$(this).addClass('selected');
$('.checkbox',parent).attr('checked', true);
});
$(".cb-disable").click(function(){
var parent = $(this).parents('.switch');
$('.cb-enable',parent).removeClass('selected');
$(this).addClass('selected');
$('.checkbox',parent).attr('checked', false);
});
// Scroll to top button appear
$(document).scroll(function() {
var scrollDistance = $(this).scrollTop();
if (scrollDistance > 100) {
$('.scroll-to-top').fadeIn();
} else {
$('.scroll-to-top').fadeOut();
}
});
});
function check_msg_and_reports(){
$.ajax({
url: './?check_msgs=1',
success: function (data) {
if (data.indexOf("::") !== -1) {
var nums = data.split("::");
if (nums[0] !== 0) {
$('.bubble_calls').html(nums[0]).css('display', 'inline');
}
if (nums[1] !== 0) {
$('.bubble_reports').html(nums[1]).css('display', 'inline');
}
}
}
});
setTimeout(check_msg_and_reports, 240000);
}
function change_color(obj, id, c, c2) {
c = (c === null) ? 'bg-danger' : c;
c2 = (c === null) ? 'bg-warning' : c2;
var ii = document.getElementById(id);
if (obj.checked) {
ii.setAttribute("class", c);
ii.setAttribute("className", c)
} else {
ii.setAttribute("class", c2);
ii.setAttribute("className", c2)
}
}
function checkAll(form, id, _do_c_, c, c2) {
for (var i = 0; i < form.elements.length; i++) {
if (form.elements[i].getAttribute("rel") !== id) { continue; }
if (form.elements[i].checked) {
uncheckAll(form, id, _do_c_, c, c2);
break
}
form.elements[i].checked = true;
change_color(form.elements[i], _do_c_ + '[' + form.elements[i].value + ']', c, c2)
}
}
function uncheckAll(form, id, _do_c_, c, c2) {
for (var i = 0; i < form.elements.length; i++) {
if (form.elements[i].getAttribute("rel") !== id) { continue; }
form.elements[i].checked = false;
change_color(form.elements[i], _do_c_ + '[' + form.elements[i].value + ']', c, c2)
}
}
function change_color_exts(id) {
eval('var ii = document.getElementById("su[' + id + ']");');
eval('var g_obj = document.getElementById("gal_' + id + '");');
eval('var u_obj = document.getElementById("ual_' + id + '");');
if (g_obj.checked && u_obj.checked) {
ii.setAttribute("class", 'o_all');
ii.setAttribute("className", 'o_all')
} else if (g_obj.checked) {
ii.setAttribute("class", 'o_g');
ii.setAttribute("className", 'o_g')
} else if (u_obj.checked) {
ii.setAttribute("class", 'o_u');
ii.setAttribute("className", 'o_u')
} else {
ii.setAttribute("class", '');
ii.setAttribute("className", '')
}
}
function checkAll_exts(form, id, _do_c_) {
for (var i = 0; i < form.elements.length; i++) {
if (form.elements[i].getAttribute("rel") !== id) { continue; }
if (form.elements[i].checked) {
uncheckAll_exts(form, id, _do_c_);
break
}
form.elements[i].checked = true;
change_color_exts(form.elements[i].value)
}
}
function uncheckAll_exts(form, id, _do_c_) {
for (var i = 0; i < form.elements.length; i++) {
if (form.elements[i].getAttribute("rel") !== id) { continue; }
form.elements[i].checked = false;
change_color_exts(form.elements[i].value)
}
}
function confirm_form(r)
{
var msg = !r ? '{lang.ARE_YOU_SURE_DO_THIS}' : r;
return confirm(msg);
}
function get_kleeja_link(link) {
location.href = link;
}
//-->
</script>
</body>
</html>

125
admin/Masmak/admin_header.html Executable file
View File

@@ -0,0 +1,125 @@
<!DOCTYPE html>
<html lang="{lang.LANG_SMALL_NAME}">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title>{lang.KLEEJA_CP} - {config.sitename}</title>
<link rel="shortcut icon" href="{STYLE_PATH_ADMIN}images/favicon.ico" />
<link rel="icon" type="image/png" href="{STYLE_PATH_ADMIN}images/favicon.png" />
<!-- Bootstrap core CSS -->
<link href="{STYLE_PATH_ADMIN}css/bootstrap.min.css" rel="stylesheet">
<!-- Custom fonts for this template -->
<link href="{STYLE_PATH_ADMIN}css/font-awesome.min.css" rel="stylesheet" type="text/css">
<!-- Plugin CSS -->
<link href="{STYLE_PATH_ADMIN}css/dataTables.bootstrap4.css" rel="stylesheet">
<!-- Custom styles for this template -->
<link href="{STYLE_PATH_ADMIN}css/sb-admin.css" rel="stylesheet">
<link href="{STYLE_PATH_ADMIN}css/custom.css" rel="stylesheet">
<IF NAME="lang.DIR==rtl">
<link rel="stylesheet" type="text/css" href="{STYLE_PATH_ADMIN}css/bootstrap.rtl.min.css" />
<link rel="stylesheet" type="text/css" href="{STYLE_PATH_ADMIN}css/sb-admin-rtl.css" />
<style type="text/css">
body{font-family: "Tahoma",Arial,sans-serif;}
body{
direction: rtl; /* placing it here fixes the issue with jquery white page bug */
}
</style>
</IF>
<script type="text/javascript">
<!--//
var STYLE_PATH_ADMIN = '{STYLE_PATH_ADMIN}';
var go_to = '{go_to}';
//-->
</script>
</head>
<body class="fixed-nav sticky-footer bg-{admin_theme_color}" id="page-top">
<!-- Navigation -->
<nav class="navbar navbar-expand-lg navbar-{admin_theme_color} bg-{admin_theme_color} fixed-top" id="mainNav">
<a class="navbar-brand" href="./"><img src="{STYLE_PATH_ADMIN}/images/kleeja.png" alt="Kleeja" style="margin:2px 8px;vertical-align:middle;width:24px"/> Kleeja <small>{assigned_klj_ver}</small></a>
<button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#navbarAcp" aria-controls="navbarAcp" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarAcp">
<!-- side menu -->
<ul class="navbar-nav navbar-sidenav">
<li class="nav-item<IF NAME="go_to==start"> activex</IF>" data-toggle="tooltip" data-placement="right" title="{lang.R_CPINDEX}">
<a class="first-level nav-link <IF NAME="go_to==start">nav-link-collapse</IF>" href="./"><i class="fa fa-fw fa-dashboard"></i> {lang.R_CPINDEX}</a>
<ul class="sidenav-second-level<IF NAME="go_to!=start"> collapse</IF>" id="collapseIndex">
<IF NAME="go_to==start">{go_menu_html}</IF>
</ul>
</li>
<LOOP NAME="adm_extensions_menu">
<li class="nav-item ({{current}}?activex:)" id="menu_item{{i}}" data-toggle="tooltip" data-placement="right" title="{{title}}">
<a class="first-level nav-link<IF LOOP="current"><IF NAME="go_menu_html"> nav-link-collapse</IF></IF>" title="{{title}}" href="{{link}}"<IF LOOP="confirm"> onclick="return confirm_form();"</IF>>
<i class="fa fa-fw fa-{{icon}}"></i> {{title}} {{bubble}}
</a>
<IF NAME="go_menu_html">
<ul class="sidenav-second-level<IF LOOP="current"><ELSE> collapse</IF>" id="collapseItem{{i}}">
<IF LOOP="current">{go_menu_html}</IF>
</ul>
</IF>
</li>
</LOOP>
</ul>
<!-- top menu -->
<ul class="navbar-nav ml-auto">
<LOOP NAME="adm_topmenu">
<li class="nav-item dropdown">
<a class="nav-link mr-lg-2" href="{{link}}">
<i class="fa fa-fw fa-{{icon}}"></i> <span class="hidden-lg-up">{{title}} {{bubble}}</span>
<IF LOOP="counter"><span class="new-indicator text-warning hidden-md-down"><i class="fa fa-fw fa-circle"></i><span class="number bubble_{{m}}">{{counter}}</span></span></IF>
</a>
</li>
</LOOP>
<li class="nav-item">
<a class="nav-link" href="./?cp={go_to}&amp;change_theme=<IF NAME="admin_theme_color==dark">light<ELSE>dark</IF>&amp;{GET_FORM_KEY_GLOBAL}"><i class="fa fa-fw fa-lightbulb-o"></i></a>
</li>
<li class="nav-item">
<a class="nav-link" href="https://www.kleeja.com" target="_blank" title="kleeja.com"><i class="fa fa-fw fa-support"></i></a>
</li>
<li class="nav-item">
<a class="nav-link" href="./?cp=b_lgoutcp&amp;{GET_FORM_KEY_GLOBAL}" onclick="javascript:return confirm_form();"><i class="fa fa-fw fa-sign-out"></i> {lang.R_LGOUTCP} [ {username} ]</a>
</li>
<li class="nav-item">
<a class="nav-link" href="{config.siteurl}"><i class="fa fa-fw fa-sign-out"></i> {lang.RETURN_HOME}</a>
</li>
</ul>
</div>
</nav>
<div class="content-wrapper">
<div class="container-fluid">

96
admin/Masmak/admin_img.html Executable file
View File

@@ -0,0 +1,96 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active justify-content-between">
{lang.R_IMG_CTRL} ({current_page}/{total_pages})
</li>
<li class="pull-(lang.DIR==ltr?right:left)">
<div id="imgs_loading"><img src="{STYLE_PATH_ADMIN}images/ajax-loader-small.gif" /></div>
</li>
</ol>
<IF NAME="config.thumbs_imgs"><ELSE>
<div class="alert alert-info">
{lang.THUMB_DIS_LONGTIME}
</div>
</IF>
<form method="post" name="imgform" action="{action}" id="imgs_form">
<IF NAME="no_results">
<div class="alert alert-info">
<h2>{lang.NO_RESULT_USE_SYNC}</h2>
</div>
<ELSE>
<!-- start data div -->
<div class="row text-center text-lg-left xthumbs">
<LOOP NAME="arr">
<div class="col-lg-3 col-md-4 col-xs-6 img-thumb-item" data-toggle="tooltip" data-html="true" title="<span>{lang.FILENAME} : </span>{{name}}<br />
<span>{lang.FILEUPS} : </span> {{ups}}<br />
<span>{lang.FILESIZE} : </span> {{size}}<br />
<span>{lang.FILEDATE} : </span> {{time}}<br />
<span>{lang.BY} : </span> {{user}}<br />
<span>{lang.IP} : </span> {{ip}}">
<a href="{{href}}" target="_blank" data-img-url="{{href}}" class="d-block mb-4 h-100" data-toggle="modal" data-target=".image-model">
<img class="img-fluid img-thumbnail" src="{{thumb_link}}" alt="" style="min-height:200px;" id="su[{{id}}]" onError="this.onerror=null;this.src='{STYLE_PATH_ADMIN}images/image-not-found.png';">
</a>
<div class="ktip" style="display: none;">
<span id="user_{{id}}">{{user}}</span>
<span id="ip_{{id}}">{{ip}}</span>
</div>
<p class="kcheck">
<input id="del_{{id}}" name="del_{{id}}" type="checkbox" value="{{id}}" rel="_del" onclick="change_color(this, 'su[{{id}}]', 'img-thumbnail img-fluid bg-danger', 'img-thumbnail img-fluid');" />
</p>
</div>
</LOOP>
</div>
<!-- end data div -->
<!-- pagination -->
{page_nums}
<div class="row justify-content-between">
<div class="col col-md-auto check_all">[ <a href="javascript:void(0);" onclick="checkAll(document.imgform, '_del', 'su', 'img-thumbnail img-fluid bg-danger', 'img-thumbnail img-fluid');">{lang.CHECK_ALL}</a> ]</div>
<div class="col col-md-auto" id="search-one-item" style="display:none">
<select class="custom-select">
<option value="0">{lang.SEARCH_SUBMIT} : </option>
<option value="1">{lang.SEARCH4FILES_BYIP}</option>
<option value="2">{lang.SEARCH4FILES_BYUSER}</option>
</select>
</div>
<div class="col col-md-auto">
<input type="submit" class="btn btn-outline-primary" name="submit" value="{lang.DEL_SELECTED}" />
</div>
</div>
</IF>
{H_FORM_KEYS}
</form>
<div class="modal fade image-model" tabindex="-1" role="dialog" aria-labelledby="ImagePreviewModel" aria-hidden="true">
<div class="modal-dialog ">
<div class="modal-content">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
<img src="{STYLE_PATH_ADMIN}images/placeholder.jpg" class="img-fluid" style="height: auto" onclick="window.open(this.src, '_blank');"/>
</div>
</div>
</div>

3
admin/Masmak/admin_info.html Executable file
View File

@@ -0,0 +1,3 @@
<div class="alert alert-success" role="alert">
{text}
</div>

139
admin/Masmak/admin_login.html Executable file
View File

@@ -0,0 +1,139 @@
<!DOCTYPE html>
<html lang="{lang.LANG_SMALL_NAME}">
<head>
<title>{lang.LOGIN} - {lang.KLEEJA_CP} - {config.sitename}</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="robots" content="noindex" />
<link rel="shortcut icon" href="{STYLE_PATH_ADMIN}images/favicon.ico" />
<link rel="icon" href="{STYLE_PATH_ADMIN}images/favicon.png" />
<link rel="stylesheet" type="text/css" media="screen" href="{STYLE_PATH_ADMIN}css/bootstrap.min.css" />
<IF NAME="lang.DIR==rtl">
<link rel="stylesheet" type="text/css" media="all" href="{STYLE_PATH_ADMIN}css/bootstrap.rtl.min.css" />
<link rel="stylesheet" type="text/css" href="{STYLE_PATH_ADMIN}css/sb-admin-rtl.css" />
<style type="text/css">
body{font-family: "Tahoma",Arial,sans-serif;}
.container{
direction: rtl; /* placing it here fixes the issue with jquery white page bug */
}
</style>
</IF>
<style type="text/css">
body {
padding-top: 40px;
padding-bottom: 40px;
background:#fcedef;
}
.form-signin {
max-width: 330px;
padding: 15px;
margin: 50px auto;
}
.form-signin-logo{
display: block;
margin: 0 auto;
text-align: center;
}
.form-signin-heading{
font-size:16px;
color: darkslategray;
}
.form-signin .form-signin-heading, .form-signin-logo,
.form-signin .checkbox {
margin-bottom: 10px;
}
.form-signin .checkbox {
font-weight: normal;
}
.form-signin .form-control {
position: relative;
font-size: 16px;
height: auto;
padding: 10px;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.form-signin .form-control:focus {
z-index: 2;
}
.form-signin input[type="text"] {
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
.form-signin input[type="password"] {
margin-bottom: 10px;
border-top-left-radius: 0;
border-top-right-radius: 0;
}
</style>
{extra_header_admin_login}
</head>
<body id="login_body">
<div class="container">
<form action="{action}" method="post" style="clear: both;" id="login_form" class="form-signin">
<IF NAME="err">
<hr>
<div class="alert alert-danger">
{errs}
</div>
</IF>
<!--{lang.KLEEJA_CP}-->
<img src="{STYLE_PATH_ADMIN}images/kleeja.png" class="form-signin-logo">
<h2 class="form-signin-heading">{lang.WELCOME}</h2>
<input type="text" class="form-control" placeholder="{lang.USERNAME}" readonly="readonly" value="{username}">
<input type="hidden" name="lname" id="lname" value="{username}" />
<input type="password" name="lpass_{KEY_FOR_PASS}" class="form-control" placeholder="{lang.PASSWORD}" autofocus>
<!-- captcha -->
<IF NAME="show_captcha">
<div class="form-group text-center">
<p class="form-control-static">
<img style="vertical-align:middle;" id="kleeja_img_captcha" src="{captcha_file_path}" alt="{lang.REFRESH_CAPTCHA}"
title="{lang.REFRESH_CAPTCHA}"
onclick="javascript:update_kleeja_captcha('{captcha_file_path}', 'kleeja_code_answer');" />
</p>
<input type="text" class="formin" name="kleeja_code_answer" id="kleeja_code_answer" tabindex="4" autocomplete="false" />
<p class="form-text text-muted">{lang.NOTE_CODE}</p>
</div>
</IF>
<!-- end captcha -->
<button class="btn btn-lg btn-primary btn-block" type="submit" name="submit">{lang.LOGIN}</button>
{H_FORM_KEYS}
<input type="hidden" name="kid" value="{KEY_FOR_WEE}" />
<hr>
<div class="row justify-content-between">
<small><a href="{config.siteurl}" title="{lang.RETURN_HOME}" class="muted"> &laquo; {lang.RETURN_HOME}</a></small>
<small>({not_you})</small>
</div>
</form>
</div> <!-- /container -->
</body>
</html>

129
admin/Masmak/admin_plugins.html Executable file
View File

@@ -0,0 +1,129 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item">{lang.R_PLUGINS}</li>
</ol>
<IF NAME="no_plugins">
<div class="alert alert-info">
{lang.NO_PLUGINS}
<br>
<br>
<a class="btn btn-primary btn-lg text-center" href="#" data-toggle="modal" data-target="#plugin_add_new">
<i class="fa fa-upload"></i> {lang.UPLOAD_LOCAL_PC}
</a>
</div>
<ELSE>
<IF NAME="installed_plugins">
<div class="row">
<LOOP NAME="installed_plugins">
<div class="col-sm-12 col-md-3 mt-2">
<div class="card">
<img class="card-img-top" src="{{icon}}" alt="{{plg_name}}">
<div class="card-body">
<h4 class="card-title" style="max-height: 30px; min-height: 30px; overflow-y: auto">
<IF LOOP="plg_disabled">
{{plg_name}}
<i class="fa fa-toggle-off"></i>
<ELSE>
{{extra_info.plugin_title}} {{extra_info.plugin_version}}
</IF>
</h4>
<p class="card-text" style="max-height: 100px; min-height: 100px; overflow-y: auto">
<IF LOOP="plg_disabled">
{{plg_dsc}}
<ELSE>
{{extra_info.plugin_description}}
</IF>
<br>
<small>{{extra_info.plugin_developer}}</small>
</p>
</div>
<div class="card-footer">
<IF LOOP="plg_disabled">
<a class="btn btn-outline-primary btn-sm" href="{plugin_enable_link}{{plg_name}}" title="{lang.ENABLE}"><i class="fa fa-toggle-on" title="{lang.ENABLE}"></i> {lang.ENABLE}</a>
<ELSE>
<a class="btn btn-outline-primary btn-sm" href="{plugin_disable_link}{{plg_name}}" title="{lang.DISABLE}"><i class="fa fa-toggle-off" title="{lang.DISABLE}"></i> {lang.DISABLE}</a>
</IF>
<a class="btn btn-outline-primary btn-sm" href="{plugin_uninstall_link}{{plg_name}}" title="{lang.DELETE}" onclick="javascript:return confirm_form();"><i class="fa fa-remove" title="{lang.DELETE}"></i> {lang.DELETE}</a>
</div>
</div>
</div>
</LOOP>
</div>
<br>
<hr>
</IF>
<!-- available plugins -->
<nav class="breadcrumb">
<div class="breadcrumb-item align-middle">{lang.ADD_NEW_PLUGIN}</div>
<a class="btn btn-primary btn-sm float-right" href="#" data-toggle="modal" data-target="#plugin_add_new">
<i class="fa fa-upload"></i> {lang.UPLOAD_LOCAL_PC}
</a>
</nav>
<br>
<ul class="list-unstyled list-group">
<LOOP NAME="available_plugins">
<li class="media d-flex justify-content-between list-group-item">
<img class="mr-3 rounded-circle" src="{{icon}}" alt="{{name}}" style="width: 75px">
<div class="media-body">
<h5 class="mt-0 mb-1 pull-(lang.DIR==ltr?left:right)">{{name}}</h5>
<a class="btn btn-primary pull-(lang.DIR==ltr?right:left)" href="{plugin_install_link}{{name}}" title="{lang.ENABLE}" onclick="javascript:return confirm_form('{lang.PLUGIN_CONFIRM_ADD}');"><i class="fa fa-download" title="{lang.ENABLE}"></i></a>
</div>
</li>
</LOOP>
</ul>
</IF>
<!-- new plugin modal -->
<div id="plugin_add_new" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="addNewPlugin" aria-hidden="true">
<form method="post" action="{action}" id="add_plugin_form" enctype="multipart/form-data">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="addNewPlugin">{lang.ADD_NEW_PLUGIN}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<label class="form-control">
<input type="file" id="file" name="plugin_file">
</label>
{H_FORM_KEYS}
</div>
<div class="modal-footer">
<input type="submit" name="newplugin" class="btn btn-primary" value="{lang.SUBMIT}">
</div>
</div>
</div>
</form>
</div>
<!-- end new plugin modal -->

71
admin/Masmak/admin_repair.html Executable file
View File

@@ -0,0 +1,71 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item">{lang.R_REPAIR}</li>
</ol>
<div class="card card-inverse card-primary">
<div class="card-body">
<h3 class="card-title">{lang.DEL_CACHE}</h3>
<a href="{del_cache_link}" class="btn btn-secondary">{lang.DELETE}</a>
</div>
</div>
<br>
<div class="card card-primary card-inverse">
<div class="card-body">
<h3 class="card-title">{lang.ALL_FILES}: {all_files}</h3>
<p class="card-text">{lang.WHY_SYNCING}</p>
<a href="{resync_files_link}" class="btn btn-secondary">{lang.RESYNC}</a>
</div>
</div>
<br>
<div class="card card-primary card-inverse">
<div class="card-body">
<h3 class="card-title">{lang.ALL_IMAGES}: {all_images}</h3>
<p class="card-text">{lang.WHY_SYNCING}</p>
<a href="{resync_images_link}" class="btn btn-secondary">{lang.RESYNC}</a>
</div>
</div>
<br>
<div class="card card-primary card-inverse">
<div class="card-body">
<h3 class="card-title">{lang.USERS_ST}: {all_users}</h3>
<p class="card-text">{lang.WHY_SYNCING}</p>
<a href="{resync_users_link}" class="btn btn-secondary">{lang.RESYNC}</a>
</div>
</div>
<br>
<div class="card card-primary card-inverse">
<div class="card-body">
<h3 class="card-title">{lang.SIZES_ST}: {all_sizes}</h3>
</div>
</div>
<br>
<div class="card card-primary card-inverse">
<div class="card-body">
<h3 class="card-title">{lang.REPAIR_DB_TABLES}</h3>
<p class="card-text">{lang.WHY_SYNCING}</p>
<a href="{repair_tables_link}" class="btn btn-secondary">{lang.SUBMIT}</a>
</div>
</div>
<br>
<div class="card card-primary card-inverse">
<div class="card-body">
<h4 class="card-title">{lang.ADVICE_CRON_LINK}:</h4>
<p class="card-text">
<input class="form-control" value="{queue_cron_job_url}" readonly="readonly" />
</p>
</div>
</div>

119
admin/Masmak/admin_reports.html Executable file
View File

@@ -0,0 +1,119 @@

<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.R_REPORTS}</li>
<IF NAME="current_smt == show_h24"><li class="breadcrumb-item active"> {lang.SHOW_FROM_24H}</li></IF>
</ol>
<IF NAME="no_results">
<div class="alert alert-info">{lang.MESSAGE_NONE}</div>
<ELSE>
<form method="post" name="reportform" action="{action}" id="reports_form">
<div id="accordion" role="tablist" aria-multiselectable="true">
<LOOP NAME="arr">
<div class="card mb-1" id="su[{{id}}]">
<div class="card-header" role="tab" id="heading{{id}}">
<h6 class="mb-0">
<input type="checkbox" class="custom-checkbox" name="del_{{id}}" value="{{id}}" onclick="change_color(this,'su[{{id}}]', 'bg-warning card', 'card');" rel="_del" />
<a data-toggle="collapse" data-parent="#accordion" href="#collapse{{id}}" aria-expanded="false" aria-controls="collapse{{id}}">
{{name}}
<IF LOOP="sent"><i class="fa fa-reply" title="{lang.IS_SEND_MAIL}" data-toggle="tooltip"></i></IF>
</a>
<small class="pull-(lang.DIR==ltr?right:left)">{{human_time}}</small>
</h6>
</div>
<div id="collapse{{id}}" class="collapse" role="tabpanel" aria-labelledby="heading{{id}}">
<div class="card-body">
{{text}}
<br>
<br>
____<br>
<IF LOOP="mail"><span class="text-muted">{lang.EMAIL}:</span> {{mail}}<br></IF>
<span class="text-muted">{lang.IP}:</span> <a href="{{ip_finder}}" target="_blank">{{ip}}</a><br>
<span class="text-muted">{lang.TIME}:</span> {{time}}<br>
<span class="text-muted">{lang.URL}:</span> <a target="_blank" href="{{url}}">{lang.CLICKHERE}<a/><br>
<IF LOOP="mail">
<hr>
<a class="btn btn-primary" data-toggle="modal" data-target="#contactForm{{id}}" href="#">
{lang.REPLY_REPORT}
</a>
</IF>
</div>
</div>
</div>
</LOOP>
</div>
<!-- pagination -->
{page_nums}
<div class="clearfix"></div>
<br>
<div class="row justify-content-between">
<div class="col col-md-auto">[ <a href="javascript:void(0);" onclick="checkAll(document.reportform, '_del', 'su', 'card bg-warning mb-1', 'card mb-1');">{lang.CHECK_ALL}</a> ]</div>
<div class="col col-md-auto"><input type="submit" class="btn btn-outline-primary" name="submit" value="{lang.DEL_SELECTED}" /></div>
</div>
{H_FORM_KEYS}
</form>
<!-- contact form modals -->
<LOOP NAME="arr">
<div class="modal" id="contactForm{{id}}">
<div class="modal-dialog" role="document">
<div class="modal-content">
<form method="post" action="{action}" id="send_form" role="form">
<div class="modal-header">
<h5 class="modal-title">{lang.REPLY_REPORT}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
{{text}}
<br>
<br>
____<br>
<IF LOOP="mail"><span class="text-muted">{lang.EMAIL}:</span> {{mail}}<br></IF>
<br>
<textarea name="v_{{id}}" cols="80" class="form-control" rows="3" placeholder="{lang.TEXT}"></textarea>
<input type="hidden" name="reply_submit" value="1">
</div>
<div class="modal-footer">
<button type="submit" name="reply_submit" class="btn btn-primary btn-sm"><span>{lang.REPLY}</span></button>
</div>
</form>
</div>
</div>
</div>
</LOOP>
</IF>
<IF NAME="there_queue">
<br><hr>
<div class="alert alert-info">{lang.DELETE_PROCESS_IN_WORK}</div>
</IF>

30
admin/Masmak/admin_rules.html Executable file
View File

@@ -0,0 +1,30 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.R_RULES}</li>
</ol>
<div class="card">
<div class="card-body">
{lang.RULES_EXP}
</div>
</div>
<br>
<form method="post" action="{action}" id="rules_form">
<div class="form-group">
<textarea class="form-control" name="rules_text" id="rules_text" rows="10">{rules}</textarea>
</div>
<br>
<input type="submit" name="submit" value="{lang.UPDATE_RULES}" class="btn btn-primary">
{H_FORM_KEYS}
</form>

177
admin/Masmak/admin_search.html Executable file
View File

@@ -0,0 +1,177 @@
<script type="text/javascript">
function check_search_files_form(form) {
var do_it = false;
if (form.filename.value != '') {
do_it = true;
} else if (form.username.value != ''){
do_it = true;
}else if(form.ext.value != ''){
do_it = true;
}else if(form.size.value != ''){
do_it = true;
}else if(form.ups.value != ''){
do_it = true;
}else if(form.rep.value != ''){
do_it = true;
}else if(form.lastdown.value != ''){
do_it = true;
}else if(form.user_ip.value != ''){
do_it = true;
}
if(!do_it)
{
alert("{lang.NO_SEARCH_WORD}");
return false;
}
}
function check_search_users_form(form)
{
var do_it = false;
if(form.username.value != '') {
do_it = true;
}else if(form.username.value != '') {
do_it = true;
}
if(!do_it)
{
alert("{lang.NO_SEARCH_WORD}");
return false;
}
}
</script>
<IF NAME="current_smt==files">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.SEARCH_FILES}</li>
</ol>
<form method="post" action="{action}" onsubmit="return check_search_files_form(this);" id="adv_search">
<div class="form-group">
<label for="filename">{lang.FILENAME}</label>
<input type="text" class="form-control" id="filename" name="filename" placeholder="">
</div>
<div class="form-group">
<label for="username">{lang.USERNAME}</label>
<input type="text" class="form-control" id="username" name="username" placeholder="" value="{filled_username}">
</div>
<div class="form-group">
<label for="user_ip">{lang.IP}</label>
<input type="text" class="form-control" id="user_ip" name="user_ip" placeholder="" value="{filled_ip}">
</div>
<div class="form-group">
<label for="ext">{lang.FILETYPE}</label>
<input type="text" class="form-control" id="ext" name="ext" placeholder="">
</div>
<div class="form-group">
<label for="size">{lang.FILESIZE}</label>
<div class="input-group">
<span class="input-group-addon">
<select name="than">
<option value="1">&gt;</option>
<option value="2">&lt;</option>
</select>
</span>
<input type="text" class="form-control" id="size" name="size" placeholder="">
</div>
</div>
<div class="form-group">
<label for="ups">{lang.FILEUPS}</label>
<div class="input-group">
<span class="input-group-addon">
<select name="uthan">
<option value="1">&gt;</option>
<option value="2">&lt;</option>
</select>
</span>
<input type="text" class="form-control" id="ups" name="ups" placeholder="">
</div>
</div>
<div class="form-group">
<label for="rep">{lang.REPORT}</label>
<div class="input-group">
<span class="input-group-addon">
<select name="rthan">
<option value="1">&gt;</option>
<option value="2">&lt;</option>
</select>
</span>
<input type="text" class="form-control" id="rep" name="rep" placeholder="">
</div>
</div>
<div class="form-group">
<label for="lastdown">{lang.LAST_DOWN}</label>
<div class="input-group">
<span class="input-group-addon">{lang.WAS_B4}</span>
<input type="text" class="form-control" id="lastdown" name="lastdown" placeholder="">
<span class="input-group-addon">{lang.DAYS}</span>
</div>
</div>
<br>
<input type="submit" name="search_file" value="{lang.SEARCH_SUBMIT}" class="btn btn-primary btn-lg"/>
{H_FORM_KEYS}
</form>
<ELSEIF NAME="current_smt==users">
<!-- start users search -->
<IF NAME="default_user_system">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.SEARCH_USERS}</li>
</ol>
<form method="post" action="{action}" onsubmit="return check_search_users_form(this);" id="user_search">
<div class="form-group">
<label for="username">{lang.USERNAME}</label>
<input type="text" class="form-control" id="username" name="username" placeholder="">
</div>
<div class="form-group">
<label for="usermail">{lang.EMAIL}</label>
<input type="text" class="form-control" id="usermail" name="usermail" placeholder="">
</div>
<br>
<input type="submit" name="search_user" value="{lang.SEARCH_SUBMIT}" class="btn btn-primary btn-lg"/>
{H_FORM_KEYS2}
</form>
</IF>
</IF>

437
admin/Masmak/admin_start.html Executable file
View File

@@ -0,0 +1,437 @@
<!-- general -->
<IF NAME="current_smt == general">
<!-- hello message -->
<ol class="breadcrumb">
<li class="breadcrumb-item active">{usernamelang}</li>
</ol>
<IF NAME="ADM_NOTIFICATIONS">
<!-- notifications -->
<div class="card mb-3">
<div class="card-header">
<i class="fa fa-bell-o"></i> {lang.NOTE}
</div>
<div class="list-group list-group-flush small">
<LOOP NAME="ADM_NOTIFICATIONS">
<div class="list-group-item list-group-item-action">
<div class="media">
<IF LOOP="msg_type==error">
<span class="d-flex mr-3 rounded-circle fa fa fa-warning" style="font-size: 30px;"></span>
<ELSEIF LOOP="msg_type==info">
<span class="d-flex mr-3 rounded-circle fa fa-info-circle" style="font-size: 30px;"></span>
</IF>
<div class="media-body">
<strong>{{title}}</strong> <br>
{{msg}}
<!--<div class="text-muted smaller">Today at 5:43 PM - 5m ago</div>-->
</div>
</div>
</div>
</LOOP>
</div>
</div>
<!-- end notifications -->
</IF>
{extra_adm_start_html}
<!-- stats boxes -->
<!-- Icon Cards -->
<div class="row">
<div class="col-xl-3 col-sm-6 mb-3">
<div class="card text-white bg-primary o-hidden h-100">
<div class="card-body">
<div class="card-body-icon">
<i class="fa fa-fw fa-comments"></i>
</div>
<div class="mr-5">
{kbubbles.calls} {lang.R_CALLS}
</div>
</div>
<a href="./?cp=e_calls" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.VIEW}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
<a href="./?cp=e_calls&amp;smt=show_h24" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.SHOW_FROM_24H}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
</div>
</div>
<div class="col-xl-3 col-sm-6 mb-3">
<div class="card text-white bg-success o-hidden h-100">
<div class="card-body">
<div class="card-body-icon">
<i class="fa fa-fw fa-flag"></i>
</div>
<div class="mr-5">
{kbubbles.reports} {lang.R_REPORTS}
</div>
</div>
<a href="./?cp=f_reports" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.VIEW}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
<a href="./?cp=f_reports&amp;smt=show_h24" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.SHOW_FROM_24H}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
</div>
</div>
<div class="col-xl-3 col-sm-6 mb-3">
<div class="card text-white bg-danger o-hidden h-100">
<div class="card-body">
<div class="card-body-icon">
<i class="fa fa-fw fa-files-o"></i>
</div>
<div class="mr-5">
<small>{lang.AFILES_NUM}</small>
<br>
{files_number} <small>({stat_files} {lang.FILE} + {stat_imgs} {lang.IMAGE})</small>
</div>
</div>
<a href="./?cp=c_files" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.R_FILES}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
<a href="./?cp=d_img_ctrl" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.R_IMG_CTRL}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
</div>
</div>
<div class="col-xl-3 col-sm-6 mb-3">
<div class="card text-white bg-info o-hidden h-100">
<div class="card-body">
<div class="card-body-icon">
<i class="fa fa-fw fa-users"></i>
</div>
<div class="mr-5">
{users_number} {lang.AUSERS_NUM}
<IF NAME="config.user_system==1">
<br><small>{lang.LAST_REG}: {lst_reg}</small>
</IF>
</div>
</div>
<a href="./?cp=g_users" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.R_USERS}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
<a href="./?cp=h_search&smt=users" class="card-footer text-white clearfix small z-1">
<span class="float-left">{lang.SEARCH_USERS}</span>
<span class="float-right"><i class="fa fa-angle-right"></i></span>
</a>
</div>
</div>
</div>
<!-- end stats boxes -->
<hr>
<!-- last visit actions -->
<IF NAME="last_visit">
<div class="card">
<div class="card-header">
{lang.LAST_VISIT} ({last_visit})
</div>
<div class="card-body">
<div class="row">
<div class="col-sm-6">
<div class="card">
<div class="card-body">
<h3 class="card-title">{lang.FLS_LST_VST_SEARCH}:</h3>
<IF NAME="files_last_visit"><a href="{h_lst_files}{files_last_visit}" class="btn btn-primary">{lang.LAST_VIEW}</a> &nbsp; {lang.OR} &nbsp;</IF>
<select class="show_since_time custom-select" tabindex="3" onchange="javascript:get_kleeja_link('{h_lst_files}' + (Math.round((new Date()).getTime() / 1000) - $(this).val()), '#content');">">
<option>{lang.TIME}...</option>
<option value="3600">{lang.HOUR}</option>
<option value="18000">{lang.5HOURS}</option>
<option value="864000">{lang.DAY}</option>
<option value="6048000">{lang.WEEK}</option>
<option value="25920000">{lang.MONTH}</option>
<option value="31536000">{lang.YEAR}</option>
</select>
</div>
</div>
<br>
</div>
<div class="col-sm-6">
<div class="card">
<div class="card-body">
<h3 class="card-title">{lang.IMG_LST_VST_SEARCH}:</h3>
<IF NAME="image_last_visit"><a href="{h_lst_imgs}{image_last_visit}" class="btn btn-primary">{lang.LAST_VIEW}</a> &nbsp; {lang.OR} &nbsp;</IF>
<select class="show_since_time custom-select" tabindex="3" onchange="javascript:get_kleeja_link('{h_lst_imgs}' + (Math.round((new Date()).getTime() / 1000) - $(this).val()), '#content');">">
<option>{lang.TIME}...</option>
<option value="3600">{lang.HOUR}</option>
<option value="18000">{lang.5HOURS}</option>
<option value="864000">{lang.DAY}</option>
<option value="6048000">{lang.WEEK}</option>
<option value="25920000">{lang.MONTH}</option>
<option value="31536000">{lang.YEAR}</option>
</select>
</div>
</div>
</div>
</div>
</div>
</div>
</IF>
<!-- end last visit actions -->
<hr>
<!-- stats_chart -->
<IF NAME="stats_chart">
<div class="card mb-3">
<div class="card-header">
<i class="fa fa-area-chart"></i> {lang.STATS}
</div>
<div class="card-body">
<div id="chart_stats"></div>
</div>
</div>
<script type="text/javascript">
{stats_chart}
</script>
</IF>
<!-- end stats_chart -->
<br>
<!-- hurry hurry actions -->
<div class="card">
<div class="card-header">
{lang.HURRY_HURRY}
</div>
<ul class="list-group list-group-flush">
<li class="list-group-item d-flex justify-content-between">
{lang.STYLE}
<div>
<select name="style_change" id="style_change" class="custom-select">
{hurry_styles_list}
</select>
<button class="btn btn-outline-primary" onclick="javascript:get_kleeja_link('{hurry_style_link}' + $('#style_change').val()); return false;"><span>{lang.CHANGE}</span></button>
</div>
</li>
<li class="list-group-item d-lg-flex justify-content-between">
{lang.LANGUAGE}
<div>
<select name="lang_change" class="custom-select" id="lang_change">
{hurry_langs_list}
</select>
&nbsp; {lang.FOR} &nbsp;
<select name="groups_list" class="custom-select" id="groups_list">
{hurry_groups_list}
</select>
<button class="btn btn-outline-primary mt-2" onclick="javascript:get_kleeja_link('{hurry_lang_link}' + $('#lang_change').val() + '&qg=' + $('#groups_list').val()); return false;"><span>{lang.CHANGE}</span></button>
</div>
</li>
<li class="list-group-item d-lg-flex justify-content-between">
{lang.R_REPAIR}
<button class="btn btn-outline-primary" onclick="javascript:get_kleeja_link('{del_cache_link}'); return false;"><span>{lang.DEL_CACHE}</span></button>
</li>
</ul>
</div>
<!-- hurry hurry actions -->
<hr>
<!-- another stats -->
<div class="card">
<ul class="list-group list-group-flush">
<li class="list-group-item d-flex justify-content-between">
{lang.LSTDELST}
<span>{last_del_fles}</span>
</li>
<li class="list-group-item">
{lang.AFILES_SIZE_SPACE}
<br>
<div class="progress" style="width: 100%">
<div class="progress-bar" role="progressbar" aria-valuenow="{per1}" aria-valuemin="0" aria-valuemax="100">{per1}%</div>
</div>
</li>
<li class="list-group-item d-flex justify-content-between">
{lang.KLEEJA_VERSION}
<span>{kleeja_version}</span>
</li>
</ul>
</div>
<!-- end another stats -->
<ELSEIF NAME="current_smt == other">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.OTHER_INFO}</li>
</ol>
<div class="card">
<ul class="list-group list-group-flush">
<li class="list-group-item d-flex justify-content-between">
{lang.PHP_VER}
<span>{php_version}</span>
</li>
<li class="list-group-item d-flex justify-content-between">
{lang.MYSQL_VER}
<span>{mysql_version}</span>
</li>
<li class="list-group-item d-flex justify-content-between">
{lang.KLEEJA_VERSION}
<span>{kleeja_version}</span>
</li>
</ul>
</div>
<hr>
<div class="card">
<ul class="list-group list-group-flush">
<li class="list-group-item d-flex justify-content-between">
max_execution_time
<span>{max_execution_time}</span>
</li>
<li class="list-group-item d-flex justify-content-between">
upload_max_filesize
<span>{upload_max_filesize}</span>
</li>
<li class="list-group-item d-flex justify-content-between">
post_max_size
<span>{post_max_size}</span>
</li>
<li class="list-group-item d-flex justify-content-between">
memory_limit
<span>{memory_limit}</span>
</li>
</ul>
</div>
<hr>
<!-- search engines stats -->
<div class="card">
<div class="card-header">
{lang.SEARCH_STAT} / <b>Google</b>
</div>
<ul class="list-group list-group-flush">
<li class="list-group-item d-flex justify-content-between">
{lang.LAST_GOOGLE}
<span>{s_last_google}</span>
</li>
<li class="list-group-item d-flex justify-content-between">
{lang.GOOGLE_NUM}
<span>{s_google_num}</span>
</li>
</ul>
</div>
<br>
<div class="card">
<div class="card-header">
{lang.SEARCH_STAT} / <b>Bing</b>
</div>
<ul class="list-group list-group-flush">
<li class="list-group-item d-flex justify-content-between">
{lang.LAST_BING}
<span>{s_last_bing}</span>
</li>
<li class="list-group-item d-flex justify-content-between">
{lang.BING_NUM}
<span>{s_bing_num}</span>
</li>
</ul>
</div>
<!-- end search engines stats -->
<ELSEIF NAME="current_smt == team">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item active">{lang.KLEEJA_TEAM}</li>
</ol>
<ul class="list-group">
<div class="list-group-item list-group-item-action flex-column align-items-start ">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">Abdullrahman M. Alshuwayi</h5>
<small><a href="http://twitter.com/abdu1m" target="_blank">@abdu1m</a></small>
</div>
<p class="mb-1">Founder and main developer, skilled and has 13+ years of programming experience.
<br><small>2007-{current_year}</small></p>
<small style="font-family: Tahoma, sans-serif">عبدالرحمن الشويعي</small>
</div>
<div class="list-group-item list-group-item-action flex-column align-items-start ">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">Bader N. Al-Mutairi</h5>
<small><a href="http://twitter.com/phpfalcon" target="_blank">@phpfalcon</a></small>
</div>
<p class="mb-1">An app developer with a passion for making beautiful things.
<br><small>2009-2012</small></p>
<small style="font-family: Tahoma, sans-serif">بدر المطيري</small>
</div>
<div class="list-group-item list-group-item-action flex-column align-items-start ">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">Moayead Y. Hejazi</h5>
</div>
<p class="mb-1">Enthusiastic and Leader in customer support.
<br><small>2011-2017</small></p>
<small style="font-family: Tahoma, sans-serif">مؤيد حجازي</small>
</div>
</ul>
<IF NAME="translator_copyrights">
<hr>
<small>{translator_copyrights}</small>
</IF>
<hr>
<small>You can support Kleeja by reporting or fixing a bug, designing a style, building a plugin or even just sending a thank you message to info@kleeja.com.</small>
<br>
<br>
<hr>
<div class="text-muted text-center">Kleeja proudly made in Buraydah City <br> ❤ Trusted since 2007 <br><small>{kleeja_version}</small></div>
</IF>

68
admin/Masmak/admin_styles.html Executable file
View File

@@ -0,0 +1,68 @@
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item">{lang.R_STYLES}</li>
<li class="float-right">
<a class="btn btn-primary btn-sm" href="#" data-toggle="modal" data-target="#style_add_new">
<i class="fa fa-upload"></i> {lang.UPLOAD_LOCAL_PC}
</a>
</li>
</ol>
<ul class="list-unstyled list-group">
<LOOP NAME="arr">
<li class="media justify-content-between d-lg-flex list-group-item">
<img class="mr-3" src="{{icon}}" alt="{{style_name}}" style="width: 250px">
<div class="media-body col-xs-12" style="padding: 10px">
<h5 class="mt-0 mb-1">{{info.name}} <small class="text-muted">{{info.version}}</small> </h5>
<p>{{info.desc}}</p>
<p class="text-muted">{{info.copyright}}</p>
<div class="mt-4">
<IF LOOP="is_default">
<span class="badge badge-pill badge-dark"><i class="fa fa-certificate text-warning" title="{lang.STYLE_IS_DEFAULT}"></i> {lang.STYLE_IS_DEFAULT}</span>
<ELSE>
<a href="{{link_mk_default}}" class="btn btn-primary" title="{lang.MAKE_AS_DEFAULT}"><i class="fa fa-check-square-o" title="{lang.MAKE_AS_DEFAULT}"></i> {lang.MAKE_AS_DEFAULT}</a>
</IF>
</div>
</div>
</li>
</LOOP>
</ul>
<!-- new style modal -->
<div id="style_add_new" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="addNewStyle" aria-hidden="true">
<form method="post" action="{action}" id="add_style_form" enctype="multipart/form-data">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="addNewStyle">{lang.UPLOAD_LOCAL_PC}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<label class="form-control">
<input type="file" id="file" name="style_file">
</label>
{H_FORM_KEYS}
</div>
<div class="modal-footer">
<input type="submit" name="newstyle" class="btn btn-primary" value="{lang.SUBMIT}">
</div>
</div>
</div>
</form>
</div>
<!-- end new style modal -->

802
admin/Masmak/admin_users.html Executable file
View File

@@ -0,0 +1,802 @@
<IF NAME="current_smt == general">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item">{lang.R_GROUPS}</li>
</ol>
<IF NAME="user_not_normal"><ELSE>
<a href="#" class="btn btn-primary pull-(lang.DIR==ltr?right:left)" data-toggle="modal" data-target="#group_add_new">
<i class="fa fa-plus-circle"></i> {lang.ADD_NEW_GROUP}
</a>
</IF>
<div class="clearfix"></div>
<br>
<!-- if not normal user system, tell him -->
<IF NAME="user_not_normal">
<div class="alert alert-info">
{lang.USERS_NOT_NORMAL_SYS}
</div>
<br>
</IF>
<!-- start data table -->
<UNLESS NAME="no_results">
<h3>{lang.ESSENTIAL_GROUPS}</h3>
<!-- start essential groups -->
<div class="row">
<LOOP NAME="e_groups">
<div class="col-xl-4 col-sm-6 mb-4">
<div class="card text-white bg-{{style.background}} o-hidden h-100">
<div class="card-body">
<div class="card-body-icon">
<i class="fa fa-fw {{style.icon}}"></i>
</div>
<div class="mr-5">
{{name}}
<UNLESS NAME="user_not_normal">
<IF LOOP="is_default">
<i class="fa fa-check" title="{lang.GROUP_IS_DEFAULT}" data-toggle="tooltip"></i>
</IF>
</UNLESS>
</div>
</div>
<a href="{action}&amp;smt=group_data&amp;qg={{id}}" class="card-footer bg-white clearfix small z-1" title="{lang.EDIT_DATA}">
<i class="fa fa-edit"></i> {lang.EDIT_DATA}
</a>
<a href="{action}&amp;smt=group_acl&amp;qg={{id}}" class="card-footer bg-white clearfix small z-1" title="{lang.EDIT_ACL}">
<i class="fa fa-tasks"></i> {lang.EDIT_ACL}
</a>
<a href="{action}&amp;smt=group_exts&amp;qg={{id}}" class="card-footer bg-white clearfix small z-1" title="{lang.R_EXTS}">
<i class="fa fa-file-code-o"></i> {lang.R_EXTS}
</a>
<IF LOOP="id != 2">
<a class="card-footer bg-white clearfix small z-1" href="{action}&amp;smt=show_group&amp;qg={{id}}" title="{lang.USERS}">
<i class="fa fa-users"></i> {lang.USERS}
</a>
</IF>
</div>
</div>
</LOOP>
</div>
<IF NAME="c_groups">
<br>
<hr>
<br>
<h3>{lang.CUSTOM_GROUPS}</h3>
<div class="row">
<LOOP NAME="c_groups">
<div class="col-xl-4 col-sm-6 mb-4">
<div class="card text-white o-hidden h-100" style="background-color: #a85053; border-color: #a85053;">
<div class="card-body">
<div class="card-body-icon">
<i class="fa fa-fw fa-user-plus"></i>
</div>
<div class="mr-5">
{{name}}
<IF NAME="user_not_normal"><ELSE><IF LOOP="is_default">
<i class="fa fa-check" title="{lang.GROUP_IS_DEFAULT}" data-toggle="tooltip"></i>
</IF></IF>
</div>
</div>
<a href="{action}&amp;smt=group_data&amp;qg={{id}}" class="card-footer bg-white clearfix small z-1" title="{lang.EDIT_DATA}">
<i class="fa fa-edit"></i> {lang.EDIT_DATA}
</a>
<a href="{action}&amp;smt=group_acl&amp;qg={{id}}" class="card-footer bg-white clearfix small z-1" title="{lang.EDIT_ACL}">
<i class="fa fa-tasks"></i> {lang.EDIT_ACL}
</a>
<a href="{action}&amp;smt=group_exts&amp;qg={{id}}" class="card-footer bg-white clearfix small z-1" title="{lang.R_EXTS}">
<i class="fa fa-file-code-o"></i> {lang.R_EXTS}
</a>
<a class="card-footer bg-white clearfix small z-1" href="{action}&amp;smt=show_group&amp;qg={{id}}" title="{lang.USERS}">
<i class="fa fa-users"></i> {lang.USERS}
</a>
<a href="#" class="card-footer bg-white clearfix small z-1" data-toggle="modal" data-target="#delete_group_{{id}}" title="{lang.DELETE}">
<i class="fa fa-remove"></i> {lang.DELETE}
</a>
</div>
</div>
</LOOP>
</div>
</IF>
<!-- end c_groups -->
</UNLESS>
<!-- end if result -->
<!-- new group modal -->
<div id="group_add_new" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="addNewGroup" aria-hidden="true">
<form method="post" action="{action}" id="add_group_form">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="addNewGroup">{lang.ADD_NEW_GROUP}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<div class="form-group">
<label for="gname">{lang.GROUP_NAME}</label>
<input type="text" class="form-control" id="gname" name="gname">
</div>
<div class="form-group">
<label for="cfrom">{lang.COPY_FROM}</label>
<select class="form-control" id="cfrom" name="cfrom">
<option value="-1">{lang.DEFAULT_GROUP}</option>
<LOOP NAME="e_groups"><IF LOOP="id == 2"><ELSE><option value="{{id}}">{{name}}</option></IF></LOOP>
<LOOP NAME="c_groups"><option value="{{id}}">{{name}}</option></LOOP>
</select>
</div>
{H_FORM_KEYS3}
</div>
<div class="modal-footer">
<input type="submit" name="newgroup" class="btn btn-primary" value="{lang.SUBMIT}">
</div>
</div>
</div>
</form>
</div>
<!-- end new group modal -->
<!-- end delete group modal -->
<LOOP NAME="c_groups">
<div id="delete_group_{{id}}" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="delAGroup" aria-hidden="true">
<form method="post" action="{action}" id="del_group_form{{id}}">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="delAGroup">{lang.DELETE_GROUP} : {{name}}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<input type="hidden" name="dgroup" id="dgroup" value="{{id}}" />
<div class="form-group">
<label for="tgroup">{lang.G_USERS_MOVE_TO}</label>
<select class="form-control" id="tgroup" name="tgroup">
<IF LOOP="is_default"><ELSE><option value="-1">{lang.DEFAULT_GROUP}</option></IF>
<LOOP NAME="e_groups"><IF LOOP="id == 2"><ELSE><option value="{{id}}">{{name}}</option></IF></LOOP>
<LOOP NAME="c_groups"><option value="{{id}}">{{name}}</option></LOOP>
</select>
</div>
{H_FORM_KEYS4}
</div>
<div class="modal-footer">
<input type="submit" name="delgroup" class="btn btn-primary" value="{lang.SUBMIT}">
</div>
</div>
</div>
</form>
</div>
</LOOP>
<!-- end delete group modal -->
<!-- ********** -->
<!-- ********** -->
<!-- end smt == general -->
<!-- ********** -->
<!-- ********** -->
<ELSEIF NAME="show_results">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item"><a href="{cp_users_url}&amp;smt=general">{lang.R_GROUPS}</a></li>
<IF NAME="is_search"><li class="breadcrumb-item active"><IF NAME="current_smt == show_group">{group_name}<ELSE>{lang.SEARCH_USERS}</IF> ( {nums_rows} )</li></IF>
</ol>
<!-- if not normal user system, tell him -->
<IF NAME="user_not_normal">
<div class="alert alert-info">
{lang.USERS_NOT_NORMAL_SYS}
</div>
<br>
</IF>
<IF NAME="GE_INFO">
<script type="text/javascript">
setTimeout(function() {
$('.infoexts').fadeOut('fast');
}, 5000);
</script>
<div class="alert alert-info infoexts">
{GE_INFO}
</div>
</IF>
<br>
<IF NAME="arr">
<ul class="list-group">
<LOOP NAME="arr">
<li class="list-group-item d-flex justify-content-between">
<div class="col col-md-auto">
<h3>{{name}} <IF LOOP="founder==1"><i class="fa fa-star text-warning" title="{lang.FOUNDER}" data-toggle="tooltip" style="font-size: medium;vertical-align: top;"></i></IF></h3>
<small class="text-muted">
<i class="fa fa-users"></i> {lang.GROUP}: {{group}} &nbsp; <i class="fa fa-clock-o"></i> {lang.LAST_VISIT}: {{last_visit}}
</small>
</div>
<div class="col col-md-auto">
<div class="btn-group btn-group-sm" role="group" aria-label="...">
<a target="_blank" href="{{userfile_link}}" title="{lang.BROSWERF}" class="btn btn-secondary"><i class="fa fa-folder-open-o" title="{lang.BROSWERF}"></i> {lang.BROSWERF}</a>
<a href="{{delusrfile_link}}&amp;{GET_FORM_KEY}" class="btn btn-secondary" onclick="javascript:return confirm_form();" title="{lang.ADMIN_DELETE_FILES}"><i class="fa fa-trash" title="{lang.ADMIN_DELETE_FILES}"></i> {lang.ADMIN_DELETE_FILES}</a>
<IF LOOP="delusr_link">
<a href="{{delusr_link}}&amp;{GET_FORM_KEY}" class="btn btn-secondary" onclick="javascript:return confirm_form();" title="{lang.DELETE}"><i class="fa fa-remove" title="{lang.DELETE}"></i> {lang.DELETE}</a>
</IF>
<a href="{{editusr_link}}" title="{lang.EDIT}" class="btn btn-secondary"><i class="fa fa-edit" title="{lang.EDIT}"></i> {lang.EDIT}</a>
</div>
</div>
</li>
</LOOP>
</ul>
<ELSE>
<div class="alert alert-info">{lang.NOTHING}</div>
</IF>
<!-- pagination -->
{page_nums}
<!-- ********** -->
<!-- ********** -->
<!-- end show results -->
<!-- ********** -->
<!-- ********** -->
<ELSEIF NAME="current_smt == new_u">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item"><a href="{cp_users_url}&amp;smt=general">{lang.R_GROUPS}</a></li>
<li class="breadcrumb-item active">{lang.NEW_USER} </li>
</ol>
<IF NAME="errs">
<div class="alert alert-danger">
{errs}
</div>
</IF>
<form method="post" action="{action}" id="add_user_form">
<div class="form-group">
<label for="lname">{lang.USERNAME}</label>
<input type="text" class="form-control" id="lname" name="lname" value="{uname}" >
</div>
<div class="form-group">
<label for="lmail">{lang.EMAIL}</label>
<input type="email" class="form-control" id="lmail" name="lmail" value="{umail}" >
</div>
<div class="form-group">
<label for="lpass">{lang.PASSWORD}</label>
<input type="password" class="form-control" id="lpass" name="lpass" value="" autocomplete="false" >
</div>
<div class="form-group">
<label for="lgroup">{lang.GROUP}</label>
<select class="form-control" id="lgroup" name="lgroup">
<LOOP NAME="u_groups">
<option value="{{id}}"<IF LOOP="selected"> selected="selected"</IF>>{{name}} <IF LOOP="default">({lang.DEFAULT_GROUP})</IF></option>
</LOOP>
</select>
</div>
<br>
<input type="submit" name="newuser" value="{lang.SUBMIT}" class="btn btn-primary" />
{H_FORM_KEYS2}
</form>
<!-- ********** -->
<!-- ********** -->
<!-- end new user -->
<!-- ********** -->
<!-- ********** -->
<ELSEIF NAME="current_smt == edit_user">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item"><a href="{cp_users_url}&amp;smt=general">{lang.R_GROUPS}</a></li>
<li class="breadcrumb-item active">{lang.EDIT} ({title_name})</li>
</ol>
<IF NAME="errs">
<div class="alert alert-danger">
{errs}
</div>
</IF>
<form method="post" action="{action}&amp;uid={userid}&amp;qg={u_qg}&amp;page={u_page}" id="edit_user_form">
<div class="form-group">
<label for="l_name">{lang.USERNAME}</label>
<input type="text" class="form-control" id="l_name" name="l_name" value="{u_name}">
</div>
<div class="form-group">
<label for="l_mail">{lang.EMAIL}</label>
<input type="email" class="form-control" id="l_mail" name="l_mail" value="{u_mail}">
</div>
<div class="form-group">
<label for="l_pass">{lang.PASS_ON_CHANGE}</label>
<input type="password" class="form-control" id="l_pass" name="l_pass" value="">
</div>
<div class="form-group">
<label for="l_show_filecp">{lang.SHOW_MY_FILECP}</label>
<select class="form-control" id="l_show_filecp" name="l_show_filecp">
<option value="1"<IF NAME="u_show_filecp"> selected="selected"</IF>>{lang.YES}</option>
<option value="0"<IF NAME="u_show_filecp"><ELSE> selected="selected"</IF>>{lang.NO}</option>
</select>
</div>
<div class="form-group">
<label for="l_group">{lang.GROUP}</label>
<select class="form-control" id="l_group" name="l_group">
<LOOP NAME="u_groups">
<IF LOOP="id == 2"><ELSE>
<option value="{{id}}"<IF LOOP="selected"> selected="selected"</IF>>{{name}} <IF LOOP="default">({lang.DEFAULT_GROUP})</IF></option>
</IF>
</LOOP>
</select>
</div>
<IF NAME="im_founder">
<div class="form-group">
<label for="l_founder">{lang.FOUNDER}</label>
<select class="form-control" id="l_founder" name="l_founder">
<option value="1"<IF NAME="u_founder"> selected="selected"</IF>>{lang.YES}</option>
<option value="0"<IF NAME="u_founder"><ELSE> selected="selected"</IF>>{lang.NO}</option>
</select>
</div>
</IF>
<div class="br"></div>
<input type="hidden" name="l_qg" value="{u_qg}" />
<input type="hidden" name="l_page" value="{u_page}" />
<input type="hidden" name="uid" value="{userid}" />
<br>
<input type="submit" class="btn btn-primary" name="edituser" value="{lang.SUBMIT}" />
{H_FORM_KEYS8}
</form>
<!-- ********** -->
<!-- ********** -->
<!-- end edit user -->
<!-- ********** -->
<!-- ********** -->
<ELSEIF NAME="current_smt == group_acl">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item"><a href="{cp_users_url}&amp;smt=general">{lang.R_GROUPS}</a></li>
<li class="breadcrumb-item active">{lang.EDIT_ACL} ({group_name})</li>
</ol>
<form method="post" action="{action}" id="edit_acl_form">
<ul class="list-group">
<LOOP NAME="acls">
<li class="list-group-item d-flex justify-content-between">
<div class="col col-md-auto">
{{acl_title}}
</div>
<div class="col col-md-auto">
<p class="field switch">
<label class="cb-enable<IF LOOP="acl_can == 1"> selected</IF>"><span>{lang.HE_CAN}</span></label>
<label class="cb-disable<IF LOOP="acl_can == 0"> selected</IF>"><span>{lang.HE_CAN_NOT}</span></label>
<input type="checkbox" id="acls_{{acl_name}}" class="checkbox" name="{{acl_name}}" <IF LOOP="acl_can == 1">checked="checked"</IF> />
</p>
</div>
</li>
</LOOP>
</ul>
<br>
<input type="submit" name="editacl" value="{lang.SUBMIT}" class="btn btn-primary" />
{H_FORM_KEYS5}
</form>
<!-- ********** -->
<!-- ********** -->
<!-- end acl -->
<!-- ********** -->
<!-- ********** -->
<ELSEIF NAME="current_smt == group_exts">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item"><a href="{cp_users_url}&amp;smt=general">{lang.R_GROUPS}</a></li>
<li class="breadcrumb-item active">{lang.R_EXTS} ({group_name})</li>
</ol>
<a href="#" class="btn btn-primary pull-(lang.DIR==ltr?right:left)" data-toggle="modal" data-target="#new_ext_form">
<i class="fa fa-plus-circle"></i> {lang.ADD_NEW_EXT}
</a>
<div class="clearfix"></div>
<IF NAME="GE_INFO">
<script type="text/javascript">
setTimeout(function() {
$('.infoexts').fadeOut('fast');
}, 5000);
</script>
<div class="infoexts">
<IF NAME="DELETED_EXT">
<IF NAME="DELETED_EXT == 2">
<div class="alert alert-info">{lang.EXT_DELETED}</div>
<ELSE>
<div class="alert alert-danger">{lang.DATA_CHANGED_NO}</div>
</IF>
</IF>
<IF NAME="ADDED_EXT">
<IF NAME="ADDED_EXT == 2">
<div class="alert alert-info">{lang.NEW_EXT_ADD}</div>
<ELSE>
<div class="alert alert-danger">{lang.DATA_CHANGED_NO}</div>
</IF>
</IF>
</div>
</IF>
<br>
<form method="post" action="{action}" id="edit_exts_form">
<table class="table table-striped">
<tr>
<th style="width: 20px">#</th>
<th>{lang.EXT}</th>
<th>{lang.SIZE}</th>
<th style="width: 100px">{lang.DELETE}</th>
</tr>
<LOOP NAME="exts">
<tr>
<td><img src="{{ext_icon}}"></td>
<td><b>{{ext_name}}</b></td>
<td>
<div class="input-group">
<input type="text" name="size[{{ext_id}}]" value="{{ext_size}}" size="6" class="form-control" style="float:left;">
<span class="input-group-addon hidden-sm-down">{lang.KILOBYTE}</span>
</div>
</td>
<td>
<a href="{action}&del={{ext_id}}&{GET_FORM_KEY}" onclick="return confirm_from();"
title="{lang.DELETE}" data-toggle="tooltip" class="btn btn-danger">
<span class="fa fa-trash"></span>
</a>
</td>
</tr>
</LOOP>
</table>
<input type="submit" name="editexts" value="{lang.SUBMIT}" class="btn btn-primary" />
<br>
{H_FORM_KEYS7}
</form>
<br>
<div class="card">
{lang.E_EXTS} <a href="#converter_form" data-toggle="modal" data-target="#converter_modal">{lang.BCONVERTER}</a>
</div>
<!-- add new ext -->
<div id="new_ext_form" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="addNewExt" aria-hidden="true">
<form method="post" action="{action}" id="add_new_ext--change--">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="addNewExt">{lang.ADD_NEW_EXT}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<div class="form-group">
<label for="gname">{lang.ADD_NEW_EXT_EXP}</label>
<input type="text" class="form-control" id="extisnew" name="extisnew">
</div>
{H_FORM_KEYS7}
</div>
<div class="modal-footer">
<input type="submit" name="newext" class="btn btn-primary" value="{lang.SUBMIT}">
</div>
</div>
</div>
</form>
</div>
<!-- end add new ext -->
<!-- converter -->
<div id="converter_modal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="converterBox" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="converterBox">{lang.BCONVERTER}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<form>
<table class="table table-striped text-center">
<tr class="first">
<td>Byte</td>
<td>Kilobyte</td>
<td>Megabyte</td>
<td>Gigabyte</td>
</tr>
<tr>
<td><input type="text" size="10" name="byte" value="0" class="form-control" /></td>
<td><input type="text" size="10" name="kb" value="0" class="form-control" /></td>
<td><input type="text" size="10" name="mb" value="0" class="form-control" /></td>
<td><input type="text" size="10" name="gb" value="0" class="form-control" /></td>
</tr>
<tr>
<td style="border-width:0px">
<button type="button" name="B2" class="btn btn-primary" onClick="convert(this.form)"><span
class="bc"> &gt; </span></button>
</td>
<td style="border-width:0px">
<button type="button" name="B22" class="btn btn-primary" onClick="convertkb(this.form)"><span class="bc"> &lt; &gt; </span>
</button>
</td>
<td style="border-width:0px">
<button type="button" name="B23" class="btn btn-primary" onClick="convertmb(this.form)"><span class="bc"> &lt; &gt; </span>
</td>
<td style="border-width:0px">
<button type="button" name="B24" class="btn btn-primary" onClick="convertgb(this.form)"><span class="bc"> &lt; </span>
</td>
</tr>
</table>
</form>
</div>
</div>
</div>
</div>
<!-- end converter -->
<!-- converter table -->
<script type="text/javascript">
/*Created by: Uncle Jim :: http://jdstiles.com/javamain.html */
function convert(f)
{
f.kb.value=Math.round(f.byte.value/1024*100000)/100000
f.mb.value=Math.round(f.byte.value/1048576*100000)/100000
f.gb.value=Math.round(f.byte.value/1073741824*100000)/100000
}
function convertkb(f)
{
f.byte.value=Math.round(f.kb.value*1024*100000)/100000
f.mb.value=Math.round(f.kb.value/1024*100000)/100000
f.gb.value=Math.round(f.kb.value/1048576*100000)/100000
}
function convertmb(f)
{
f.byte.value=Math.round(f.mb.value*1048576*100000)/100000
f.kb.value=Math.round(f.mb.value*1024*100000)/100000
f.gb.value=Math.round(f.mb.value/1024*100000)/100000
}
function convertgb(f)
{
f.byte.value=Math.round(f.gb.value*1073741824*100000)/100000
f.kb.value=Math.round(f.gb.value*1048576*100000)/100000
f.mb.value=Math.round(f.gb.value*1024*100000)/100000
}
</script>
<!-- ********** -->
<!-- ********** -->
<!-- end exts -->
<!-- ********** -->
<!-- ********** -->
<ELSEIF NAME="current_smt == group_data">
<!-- Breadcrumbs -->
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="./">{lang.R_CPINDEX}</a></li>
<li class="breadcrumb-item"><a href="{cp_users_url}&amp;smt=general">{lang.R_GROUPS}</a></li>
<li class="breadcrumb-item active">{lang.EDIT_DATA} ({group_name})</li>
</ol>
<form method="post" action="{action}" id="edit_data_form">
<UNLESS NAME="user_not_normal">
<div class="form-group">
<label for="group_name">{lang.GROUP_NAME}</label>
<IF NAME="gdata.group_is_essential">
<p class="form-control-static"><b>{group_name}</b></p>
<ELSE>
<input type="text" class="form-control" id="group_name" name="group_name" value="{gdata.group_name}">
</IF>
</div>
<fieldset class="form-group">
<legend class="col-form-legend">{lang.GROUP_IS_DEFAULT}</legend>
<div class="form-check">
<label class="form-check-label">
<input type="radio" class="form-check-input" name="group_is_default" id="group_is_default1" value="1" <IF NAME="gdata.group_is_default == 1">checked="checked"</IF>>
{lang.YES}
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input type="radio" class="form-check-input" name="group_is_default" id="group_is_default0" value="0" <IF NAME="gdata.group_is_default == 0">checked="checked"</IF>>
{lang.NO}
</label>
</div>
</fieldset>
<hr>
</UNLESS>
<LOOP NAME="data">
{{option}}
</LOOP>
<br>
<input type="submit" name="editdata" value="{lang.SUBMIT}" class="btn btn-primary" />
{H_FORM_KEYS6}
</form>
</IF>

1353
admin/Masmak/css/bootstrap-grid.css vendored Executable file

File diff suppressed because it is too large Load Diff

2
admin/Masmak/css/bootstrap-grid.min.css vendored Executable file

File diff suppressed because one or more lines are too long

330
admin/Masmak/css/bootstrap-reboot.css vendored Executable file
View File

@@ -0,0 +1,330 @@
html {
box-sizing: border-box;
font-family: sans-serif;
line-height: 1.15;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
-ms-overflow-style: scrollbar;
-webkit-tap-highlight-color: transparent;
}
*,
*::before,
*::after {
box-sizing: inherit;
}
@-ms-viewport {
width: device-width;
}
article, aside, dialog, figcaption, figure, footer, header, hgroup, main, nav, section {
display: block;
}
body {
margin: 0;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
font-size: 1rem;
font-weight: normal;
line-height: 1.5;
color: #212529;
background-color: #fff;
}
[tabindex="-1"]:focus {
outline: none !important;
}
hr {
box-sizing: content-box;
height: 0;
overflow: visible;
}
h1, h2, h3, h4, h5, h6 {
margin-top: 0;
margin-bottom: .5rem;
}
p {
margin-top: 0;
margin-bottom: 1rem;
}
abbr[title],
abbr[data-original-title] {
text-decoration: underline;
-webkit-text-decoration: underline dotted;
text-decoration: underline dotted;
cursor: help;
border-bottom: 0;
}
address {
margin-bottom: 1rem;
font-style: normal;
line-height: inherit;
}
ol,
ul,
dl {
margin-top: 0;
margin-bottom: 1rem;
}
ol ol,
ul ul,
ol ul,
ul ol {
margin-bottom: 0;
}
dt {
font-weight: bold;
}
dd {
margin-bottom: .5rem;
margin-left: 0;
}
blockquote {
margin: 0 0 1rem;
}
dfn {
font-style: italic;
}
b,
strong {
font-weight: bolder;
}
small {
font-size: 80%;
}
sub,
sup {
position: relative;
font-size: 75%;
line-height: 0;
vertical-align: baseline;
}
sub {
bottom: -.25em;
}
sup {
top: -.5em;
}
a {
color: #007bff;
text-decoration: none;
background-color: transparent;
-webkit-text-decoration-skip: objects;
}
a:hover {
color: #0056b3;
text-decoration: underline;
}
a:not([href]):not([tabindex]) {
color: inherit;
text-decoration: none;
}
a:not([href]):not([tabindex]):focus, a:not([href]):not([tabindex]):hover {
color: inherit;
text-decoration: none;
}
a:not([href]):not([tabindex]):focus {
outline: 0;
}
pre,
code,
kbd,
samp {
font-family: monospace, monospace;
font-size: 1em;
}
pre {
margin-top: 0;
margin-bottom: 1rem;
overflow: auto;
}
figure {
margin: 0 0 1rem;
}
img {
vertical-align: middle;
border-style: none;
}
svg:not(:root) {
overflow: hidden;
}
a,
area,
button,
[role="button"],
input,
label,
select,
summary,
textarea {
-ms-touch-action: manipulation;
touch-action: manipulation;
}
table {
border-collapse: collapse;
}
caption {
padding-top: 0.75rem;
padding-bottom: 0.75rem;
color: #868e96;
text-align: left;
caption-side: bottom;
}
th {
text-align: left;
}
label {
display: inline-block;
margin-bottom: .5rem;
}
button:focus {
outline: 1px dotted;
outline: 5px auto -webkit-focus-ring-color;
}
input,
button,
select,
optgroup,
textarea {
margin: 0;
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
button,
input {
overflow: visible;
}
button,
select {
text-transform: none;
}
button,
html [type="button"],
[type="reset"],
[type="submit"] {
-webkit-appearance: button;
}
button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
padding: 0;
border-style: none;
}
input[type="radio"],
input[type="checkbox"] {
box-sizing: border-box;
padding: 0;
}
input[type="date"],
input[type="time"],
input[type="datetime-local"],
input[type="month"] {
-webkit-appearance: listbox;
}
textarea {
overflow: auto;
resize: vertical;
}
fieldset {
min-width: 0;
padding: 0;
margin: 0;
border: 0;
}
legend {
display: block;
width: 100%;
max-width: 100%;
padding: 0;
margin-bottom: .5rem;
font-size: 1.5rem;
line-height: inherit;
color: inherit;
white-space: normal;
}
progress {
vertical-align: baseline;
}
[type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
height: auto;
}
[type="search"] {
outline-offset: -2px;
-webkit-appearance: none;
}
[type="search"]::-webkit-search-cancel-button,
[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
::-webkit-file-upload-button {
font: inherit;
-webkit-appearance: button;
}
output {
display: inline-block;
}
summary {
display: list-item;
}
template {
display: none;
}
[hidden] {
display: none !important;
}
/*# sourceMappingURL=bootstrap-reboot.css.map */

2
admin/Masmak/css/bootstrap-reboot.min.css vendored Executable file
View File

@@ -0,0 +1,2 @@
html{box-sizing:border-box;font-family:sans-serif;line-height:1.15;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%;-ms-overflow-style:scrollbar;-webkit-tap-highlight-color:transparent}*,::after,::before{box-sizing:inherit}@-ms-viewport{width:device-width}article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}body{margin:0;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-size:1rem;font-weight:400;line-height:1.5;color:#212529;background-color:#fff}[tabindex="-1"]:focus{outline:0!important}hr{box-sizing:content-box;height:0;overflow:visible}h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5rem}p{margin-top:0;margin-bottom:1rem}abbr[data-original-title],abbr[title]{text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;cursor:help;border-bottom:0}address{margin-bottom:1rem;font-style:normal;line-height:inherit}dl,ol,ul{margin-top:0;margin-bottom:1rem}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:.5rem;margin-left:0}blockquote{margin:0 0 1rem}dfn{font-style:italic}b,strong{font-weight:bolder}small{font-size:80%}sub,sup{position:relative;font-size:75%;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}a{color:#007bff;text-decoration:none;background-color:transparent;-webkit-text-decoration-skip:objects}a:hover{color:#0056b3;text-decoration:underline}a:not([href]):not([tabindex]){color:inherit;text-decoration:none}a:not([href]):not([tabindex]):focus,a:not([href]):not([tabindex]):hover{color:inherit;text-decoration:none}a:not([href]):not([tabindex]):focus{outline:0}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}pre{margin-top:0;margin-bottom:1rem;overflow:auto}figure{margin:0 0 1rem}img{vertical-align:middle;border-style:none}svg:not(:root){overflow:hidden}[role=button],a,area,button,input,label,select,summary,textarea{-ms-touch-action:manipulation;touch-action:manipulation}table{border-collapse:collapse}caption{padding-top:.75rem;padding-bottom:.75rem;color:#868e96;text-align:left;caption-side:bottom}th{text-align:left}label{display:inline-block;margin-bottom:.5rem}button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,input{overflow:visible}button,select{text-transform:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{padding:0;border-style:none}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=date],input[type=datetime-local],input[type=month],input[type=time]{-webkit-appearance:listbox}textarea{overflow:auto;resize:vertical}fieldset{min-width:0;padding:0;margin:0;border:0}legend{display:block;width:100%;max-width:100%;padding:0;margin-bottom:.5rem;font-size:1.5rem;line-height:inherit;color:inherit;white-space:normal}progress{vertical-align:baseline}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{outline-offset:-2px;-webkit-appearance:none}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{font:inherit;-webkit-appearance:button}output{display:inline-block}summary{display:list-item}template{display:none}[hidden]{display:none!important}
/*# sourceMappingURL=bootstrap-reboot.min.css.map */

8185
admin/Masmak/css/bootstrap.css vendored Executable file

File diff suppressed because it is too large Load Diff

7
admin/Masmak/css/bootstrap.min.css vendored Executable file

File diff suppressed because one or more lines are too long

6
admin/Masmak/css/bootstrap.rtl.min.css vendored Executable file

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,63 @@
#thmb_dim_w, #thmb_dim_h{
width: 90px; display: inline-block;
}
.img-thumb-item{
position: relative;
}
.kcheck {
position: absolute;
bottom: 10px;
left: 20px;
z-index: 10;
}
.cb-enable, .cb-disable, .cb-enable span, .cb-disable span { background: url(../images/switch.gif) repeat-x; display: block; float: left; }
.cb-enable span, .cb-disable span { line-height: 30px; display: block; background-repeat: no-repeat; font-weight: bold; }
.cb-enable span { background-position: left -90px; padding: 0 10px; }
.cb-disable span { background-position: right -180px;padding: 0 10px; }
.cb-disable.selected { background-position: 0 -30px; }
.cb-disable.selected span { background-position: right -210px; color: #fff; }
.cb-enable.selected { background-position: 0 -60px; }
.cb-enable.selected span { background-position: left -150px; color: #fff; }
.switch label { cursor: pointer; }
.switch input { display: none; }
.navbar-light .navbar-sidenav .activex .first-level{
background-color: #4a7996 !important;
color: #fff !important;
}
.navbar-dark .navbar-sidenav .activex .first-level{
background-color: #000 !important;
color: #fff !important;
}
.navbar-light .nav-link:hover{
background-color: #ccc !important;
}
.navbar-dark .nav-link:hover{
background-color: #5e6872 !important;
}
.navbar-light ul.sidenav-second-level{
background-color: #e9ecef !important;
}
.navbar-dark ul.sidenav-second-level{
background-color: #495057 !important;
}
.nav-item a.first-level{
padding: 12px 15px !important;
}
.sidenav-second-level li a{
padding: 12px 20px !important;
}
#chart_stats{
margin: 0 auto;
overflow-x: scroll;
}

View File

@@ -0,0 +1,194 @@
table.dataTable {
clear: both;
margin-top: 6px !important;
margin-bottom: 6px !important;
max-width: none !important;
border-collapse: separate !important;
}
table.dataTable td,
table.dataTable th {
-webkit-box-sizing: content-box;
box-sizing: content-box;
}
table.dataTable td.dataTables_empty,
table.dataTable th.dataTables_empty {
text-align: center;
}
table.dataTable.nowrap th,
table.dataTable.nowrap td {
white-space: nowrap;
}
div.dataTables_wrapper div.dataTables_length label {
font-weight: normal;
text-align: left;
white-space: nowrap;
}
div.dataTables_wrapper div.dataTables_length select {
width: 75px;
display: inline-block;
}
div.dataTables_wrapper div.dataTables_filter {
text-align: right;
}
div.dataTables_wrapper div.dataTables_filter label {
font-weight: normal;
white-space: nowrap;
text-align: left;
}
div.dataTables_wrapper div.dataTables_filter input {
margin-left: 0.5em;
display: inline-block;
width: auto;
}
div.dataTables_wrapper div.dataTables_info {
padding-top: 0.85em;
white-space: nowrap;
}
div.dataTables_wrapper div.dataTables_paginate {
margin: 0;
white-space: nowrap;
text-align: right;
}
div.dataTables_wrapper div.dataTables_paginate ul.pagination {
margin: 2px 0;
white-space: nowrap;
justify-content: flex-end;
}
div.dataTables_wrapper div.dataTables_processing {
position: absolute;
top: 50%;
left: 50%;
width: 200px;
margin-left: -100px;
margin-top: -26px;
text-align: center;
padding: 1em 0;
}
table.dataTable thead > tr > th.sorting_asc, table.dataTable thead > tr > th.sorting_desc, table.dataTable thead > tr > th.sorting,
table.dataTable thead > tr > td.sorting_asc,
table.dataTable thead > tr > td.sorting_desc,
table.dataTable thead > tr > td.sorting {
padding-right: 30px;
}
table.dataTable thead > tr > th:active,
table.dataTable thead > tr > td:active {
outline: none;
}
table.dataTable thead .sorting,
table.dataTable thead .sorting_asc,
table.dataTable thead .sorting_desc,
table.dataTable thead .sorting_asc_disabled,
table.dataTable thead .sorting_desc_disabled {
cursor: pointer;
position: relative;
}
table.dataTable thead .sorting:before, table.dataTable thead .sorting:after,
table.dataTable thead .sorting_asc:before,
table.dataTable thead .sorting_asc:after,
table.dataTable thead .sorting_desc:before,
table.dataTable thead .sorting_desc:after,
table.dataTable thead .sorting_asc_disabled:before,
table.dataTable thead .sorting_asc_disabled:after,
table.dataTable thead .sorting_desc_disabled:before,
table.dataTable thead .sorting_desc_disabled:after {
position: absolute;
bottom: 0.9em;
display: block;
opacity: 0.3;
}
table.dataTable thead .sorting:before,
table.dataTable thead .sorting_asc:before,
table.dataTable thead .sorting_desc:before,
table.dataTable thead .sorting_asc_disabled:before,
table.dataTable thead .sorting_desc_disabled:before {
right: 1em;
content: "\2191";
}
table.dataTable thead .sorting:after,
table.dataTable thead .sorting_asc:after,
table.dataTable thead .sorting_desc:after,
table.dataTable thead .sorting_asc_disabled:after,
table.dataTable thead .sorting_desc_disabled:after {
right: 0.5em;
content: "\2193";
}
table.dataTable thead .sorting_asc:before,
table.dataTable thead .sorting_desc:after {
opacity: 1;
}
table.dataTable thead .sorting_asc_disabled:before,
table.dataTable thead .sorting_desc_disabled:after {
opacity: 0;
}
div.dataTables_scrollHead table.dataTable {
margin-bottom: 0 !important;
}
div.dataTables_scrollBody table {
border-top: none;
margin-top: 0 !important;
margin-bottom: 0 !important;
}
div.dataTables_scrollBody table thead .sorting:after,
div.dataTables_scrollBody table thead .sorting_asc:after,
div.dataTables_scrollBody table thead .sorting_desc:after {
display: none;
}
div.dataTables_scrollBody table tbody tr:first-child th,
div.dataTables_scrollBody table tbody tr:first-child td {
border-top: none;
}
div.dataTables_scrollFoot table {
margin-top: 0 !important;
border-top: none;
}
@media screen and (max-width: 767px) {
div.dataTables_wrapper div.dataTables_length,
div.dataTables_wrapper div.dataTables_filter,
div.dataTables_wrapper div.dataTables_info,
div.dataTables_wrapper div.dataTables_paginate {
text-align: center;
}
}
table.dataTable.table-condensed > thead > tr > th {
padding-right: 20px;
}
table.dataTable.table-condensed .sorting:after,
table.dataTable.table-condensed .sorting_asc:after,
table.dataTable.table-condensed .sorting_desc:after {
top: 6px;
right: 6px;
}
table.table-bordered.dataTable th,
table.table-bordered.dataTable td {
border-left-width: 0;
}
table.table-bordered.dataTable th:last-child, table.table-bordered.dataTable th:last-child,
table.table-bordered.dataTable td:last-child,
table.table-bordered.dataTable td:last-child {
border-right-width: 0;
}
table.table-bordered.dataTable tbody th,
table.table-bordered.dataTable tbody td {
border-bottom-width: 0;
}
div.dataTables_scrollHead table.table-bordered {
border-bottom-width: 0;
}
div.table-responsive > div.dataTables_wrapper > div.row {
margin: 0;
}
div.table-responsive > div.dataTables_wrapper > div.row > div[class^="col-"]:first-child {
padding-left: 0;
}
div.table-responsive > div.dataTables_wrapper > div.row > div[class^="col-"]:last-child {
padding-right: 0;
}

2337
admin/Masmak/css/font-awesome.css vendored Executable file

File diff suppressed because it is too large Load Diff

4
admin/Masmak/css/font-awesome.min.css vendored Executable file

File diff suppressed because one or more lines are too long

58
admin/Masmak/css/index.html Executable file
View File

@@ -0,0 +1,58 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256"/>
<title>Powered by Kleeja</title>
<style type="text/css">* {
font-size: 100%;
margin: 0;
padding: 0;
color: #CECFCE;
}
body {
font-family: Tahoma, Arial, sans-serif;
font-size: 100%;
color: #69788E;
margin: 10px 30px;
background: #F7F7F7;
}
a:link, a:visited {
text-decoration: none;
color: #CECFCE;
}
a:active, a:hover {
text-decoration: underline;
color: #111;
}
h1 {
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-size: 1.70em;
font-weight: normal;
color: #333333;
margin-top: 0;
margin-bottom: 10px;
}
.content_box {
border: 1px dashed #CECFCE;
background: #FFFFFF;
padding: 10px;
margin-right: auto;
margin-left: auto;
}</style>
</head>
<body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br/>
<div class="content_box">
<p>
<a target="_blank" href="http://www.kleeja.com" title="kleeja"></a>
</p>
<br/>
<h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div>
<br/>
<div class="content_box"style="font-size: 140%">Powered by Kleeja</div>
</body>
</html>

View File

@@ -0,0 +1,30 @@
@media (min-width: 992px) {
.content-wrapper {
margin-right: 250px;
margin-left: auto;
}
#mainNav .navbar-collapse .navbar-sidenav {
right: 0;
left: auto;
}
}
.card-body-icon { left: -25px; right: auto}
#mainNav .navbar-collapse .navbar-sidenav .nav-link-collapse.collapsed:after {
content: '\f104';
}
#mainNav .navbar-collapse .navbar-sidenav .nav-link-collapse:after {
float: left;
}
#imgs_form .kcheck{
right: 20px;
left: auto;
}

351
admin/Masmak/css/sb-admin.css Executable file
View File

@@ -0,0 +1,351 @@
/*!
* Start Bootstrap - SB Admin v4.0.0-beta (https://startbootstrap.com/template-overviews/sb-admin)
* Copyright 2013-2017 Start Bootstrap
* Licensed under MIT (https://github.com/BlackrockDigital/startbootstrap-sb-admin/blob/master/LICENSE)
*/
html {
position: relative;
min-height: 100%; }
body.sticky-footer {
margin-bottom: 56px; }
body.sticky-footer .content-wrapper {
min-height: calc(100vh - 56px - 56px); }
body.fixed-nav {
padding-top: 56px; }
.content-wrapper {
min-height: calc(100vh - 56px);
padding-top: 1rem; }
.scroll-to-top {
position: fixed;
right: 15px;
bottom: 3px;
display: none;
width: 50px;
height: 50px;
text-align: center;
color: white;
background: rgba(52, 58, 64, 0.5);
line-height: 45px; }
.scroll-to-top:focus, .scroll-to-top:hover {
color: white; }
.scroll-to-top:hover {
background: #343a40; }
.scroll-to-top i {
font-weight: 800; }
.smaller {
font-size: 0.7rem; }
.o-hidden {
overflow: hidden !important; }
.z-0 {
z-index: 0; }
.z-1 {
z-index: 1; }
.card-body-icon {
position: absolute;
z-index: 0;
top: -25px;
right: -25px;
font-size: 5rem;
-webkit-transform: rotate(15deg);
-ms-transform: rotate(15deg);
transform: rotate(15deg); }
@media (min-width: 576px) {
.card-columns {
column-count: 1; } }
@media (min-width: 768px) {
.card-columns {
column-count: 2; } }
@media (min-width: 1200px) {
.card-columns {
column-count: 2; } }
#mainNav .navbar-collapse {
overflow: auto;
max-height: 75vh; }
#mainNav .navbar-collapse .navbar-nav .nav-item .nav-link {
cursor: pointer; }
#mainNav .navbar-collapse .navbar-sidenav .nav-link-collapse:after {
float: right;
content: '\f107';
font-family: 'FontAwesome'; }
#mainNav .navbar-collapse .navbar-sidenav .nav-link-collapse.collapsed:after {
content: '\f105'; }
#mainNav .navbar-collapse .navbar-sidenav .sidenav-second-level,
#mainNav .navbar-collapse .navbar-sidenav .sidenav-third-level {
padding-left: 0; }
#mainNav .navbar-collapse .navbar-sidenav .sidenav-second-level > li > a,
#mainNav .navbar-collapse .navbar-sidenav .sidenav-third-level > li > a {
display: block;
padding: 0.5em 0; }
#mainNav .navbar-collapse .navbar-sidenav .sidenav-second-level > li > a:focus, #mainNav .navbar-collapse .navbar-sidenav .sidenav-second-level > li > a:hover,
#mainNav .navbar-collapse .navbar-sidenav .sidenav-third-level > li > a:focus,
#mainNav .navbar-collapse .navbar-sidenav .sidenav-third-level > li > a:hover {
text-decoration: none; }
#mainNav .navbar-collapse .navbar-sidenav .sidenav-second-level > li > a {
padding-left: 1em; }
#mainNav .navbar-collapse .navbar-sidenav .sidenav-third-level > li > a {
padding-left: 2em; }
#mainNav .navbar-collapse .sidenav-toggler {
display: none; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link {
position: relative;
min-width: 45px; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link:after {
float: right;
width: auto;
content: '\f105';
border: none;
font-family: 'FontAwesome'; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link .new-indicator {
position: absolute;
top: 0;
right: 25px;
font-size: 1.1rem; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link .new-indicator .number {
position: absolute;
top: 6px;
left: 0;
width: 22.625px;
text-align: center;
color: white;
font-size: 0.5rem; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown.show > .nav-link:after {
content: '\f107'; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown .dropdown-menu > .dropdown-item > .dropdown-message {
overflow: hidden;
max-width: none;
text-overflow: ellipsis; }
@media (min-width: 992px) {
#mainNav .navbar-brand {
width: 250px; }
#mainNav .navbar-collapse {
overflow: visible;
max-height: none; }
#mainNav .navbar-collapse .navbar-sidenav {
position: absolute;
top: 0;
left: 0;
overflow-x: hidden;
overflow-y: auto;
-webkit-flex-direction: column;
-ms-flex-direction: column;
flex-direction: column;
margin-top: 56px; }
#mainNav .navbar-collapse .navbar-sidenav > .nav-item {
width: 250px;
padding: 0; }
#mainNav .navbar-collapse .navbar-sidenav > .nav-item > .nav-link {
padding: 1em; }
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level,
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level {
padding-left: 0;
list-style: none; }
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li,
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li {
width: 250px; }
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a,
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a {
padding: 1em; }
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a {
padding-left: 2em; }
#mainNav .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a {
padding-left: 3em; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link {
min-width: 0; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link:after {
width: 24px;
text-align: center; }
#mainNav .navbar-collapse .navbar-nav > .nav-item.dropdown .dropdown-menu > .dropdown-item > .dropdown-message {
max-width: 300px; } }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav .nav-link-collapse:after {
color: #868e96; }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item > .nav-link {
color: #868e96; }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item > .nav-link:hover {
color: #adb5bd; }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a,
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a {
color: #868e96; }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a:focus, #mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a:hover,
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a:focus,
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a:hover {
color: #adb5bd; }
#mainNav.navbar-dark .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link:after {
color: #adb5bd; }
@media (min-width: 992px) {
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav {
background: #343a40; }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav li.active a {
color: white !important;
background-color: #495057; }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav li.active a:focus, #mainNav.navbar-dark .navbar-collapse .navbar-sidenav li.active a:hover {
color: white; }
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level,
#mainNav.navbar-dark .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level {
background: #343a40; } }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav .nav-link-collapse:after {
color: rgba(0, 0, 0, 0.5); }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item > .nav-link {
color: rgba(0, 0, 0, 0.5); }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item > .nav-link:hover {
color: rgba(0, 0, 0, 0.7); }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a,
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a {
color: rgba(0, 0, 0, 0.5); }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a:focus, #mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level > li > a:hover,
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a:focus,
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level > li > a:hover {
color: rgba(0, 0, 0, 0.7); }
#mainNav.navbar-light .navbar-collapse .navbar-nav > .nav-item.dropdown > .nav-link:after {
color: rgba(0, 0, 0, 0.5); }
@media (min-width: 992px) {
#mainNav.navbar-light .navbar-collapse .navbar-sidenav {
background: #f8f9fa; }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav li.active a {
color: #000 !important;
background-color: #e9ecef; }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav li.active a:focus, #mainNav.navbar-light .navbar-collapse .navbar-sidenav li.active a:hover {
color: #000; }
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-second-level,
#mainNav.navbar-light .navbar-collapse .navbar-sidenav > .nav-item .sidenav-third-level {
background: #f8f9fa; } }
#mainNav.fixed-top .sidenav-toggler {
display: none; }
@media (min-width: 992px) {
#mainNav.fixed-top .navbar-sidenav {
height: calc(100vh - 112px); }
#mainNav.fixed-top .sidenav-toggler {
position: absolute;
top: 0;
left: 0;
display: flex;
overflow-x: hidden;
overflow-y: auto;
-webkit-flex-direction: column;
-ms-flex-direction: column;
flex-direction: column;
margin-top: calc(100vh - 56px); }
#mainNav.fixed-top .sidenav-toggler > .nav-item {
width: 250px;
padding: 0; }
#mainNav.fixed-top .sidenav-toggler > .nav-item > .nav-link {
padding: 1em; } }
#mainNav.fixed-top.navbar-dark .sidenav-toggler {
background-color: #212529; }
#mainNav.fixed-top.navbar-dark .sidenav-toggler a i {
color: #adb5bd; }
#mainNav.fixed-top.navbar-light .sidenav-toggler {
background-color: #dee2e6; }
#mainNav.fixed-top.navbar-light .sidenav-toggler a i {
color: rgba(0, 0, 0, 0.5); }
body.sidenav-toggled #mainNav.fixed-top .sidenav-toggler {
overflow-x: hidden;
width: 55px; }
body.sidenav-toggled #mainNav.fixed-top .sidenav-toggler .nav-item,
body.sidenav-toggled #mainNav.fixed-top .sidenav-toggler .nav-link {
width: 55px !important; }
body.sidenav-toggled #mainNav.fixed-top #sidenavToggler i {
-webkit-transform: scaleX(-1);
-moz-transform: scaleX(-1);
-o-transform: scaleX(-1);
transform: scaleX(-1);
filter: FlipH;
-ms-filter: 'FlipH'; }
#mainNav.static-top .sidenav-toggler {
display: none; }
@media (min-width: 992px) {
#mainNav.static-top .sidenav-toggler {
display: flex; } }
body.sidenav-toggled #mainNav.static-top #sidenavToggler i {
-webkit-transform: scaleX(-1);
-moz-transform: scaleX(-1);
-o-transform: scaleX(-1);
transform: scaleX(-1);
filter: FlipH;
-ms-filter: 'FlipH'; }
.content-wrapper {
overflow-x: hidden;
background: white; }
@media (min-width: 992px) {
.content-wrapper {
margin-left: 250px; } }
#sidenavToggler i {
font-weight: 800; }
.navbar-sidenav-tooltip.show {
display: none; }
@media (min-width: 992px) {
body.sidenav-toggled .content-wrapper {
margin-left: 55px; } }
body.sidenav-toggled .navbar-sidenav {
overflow-x: hidden;
width: 55px; }
body.sidenav-toggled .navbar-sidenav .nav-link-text {
display: none; }
body.sidenav-toggled .navbar-sidenav .nav-item,
body.sidenav-toggled .navbar-sidenav .nav-link {
width: 55px !important; }
body.sidenav-toggled .navbar-sidenav .nav-item:after,
body.sidenav-toggled .navbar-sidenav .nav-link:after {
display: none; }
body.sidenav-toggled .navbar-sidenav-tooltip.show {
display: flex; }
.card-login {
max-width: 25rem; }
.card-register {
max-width: 40rem; }
footer.sticky-footer {
position: absolute;
right: 0;
bottom: 0;
width: 100%;
height: 56px;
background-color: #e9ecef;
line-height: 55px; }
@media (min-width: 992px) {
footer.sticky-footer {
width: calc(100% - 250px); } }
@media (min-width: 992px) {
body.sidenav-toggled footer.sticky-footer {
width: calc(100% - 55px); } }

5
admin/Masmak/css/sb-admin.min.css vendored Executable file

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

File diff suppressed because it is too large Load Diff

After

Width:  |  Height:  |  Size: 434 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

58
admin/Masmak/fonts/index.html Executable file
View File

@@ -0,0 +1,58 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256"/>
<title>Powered by Kleeja</title>
<style type="text/css">* {
font-size: 100%;
margin: 0;
padding: 0;
color: #CECFCE;
}
body {
font-family: Tahoma, Arial, sans-serif;
font-size: 100%;
color: #69788E;
margin: 10px 30px;
background: #F7F7F7;
}
a:link, a:visited {
text-decoration: none;
color: #CECFCE;
}
a:active, a:hover {
text-decoration: underline;
color: #111;
}
h1 {
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-size: 1.70em;
font-weight: normal;
color: #333333;
margin-top: 0;
margin-bottom: 10px;
}
.content_box {
border: 1px dashed #CECFCE;
background: #FFFFFF;
padding: 10px;
margin-right: auto;
margin-left: auto;
}</style>
</head>
<body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br/>
<div class="content_box">
<p>
<a target="_blank" href="http://www.kleeja.com" title="kleeja"></a>
</p>
<br/>
<h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div>
<br/>
<div class="content_box"style="font-size: 140%">Powered by Kleeja</div>
</body>
</html>

Binary file not shown.

After

Width:  |  Height:  |  Size: 477 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

58
admin/Masmak/images/index.html Executable file
View File

@@ -0,0 +1,58 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256"/>
<title>Powered by Kleeja</title>
<style type="text/css">* {
font-size: 100%;
margin: 0;
padding: 0;
color: #CECFCE;
}
body {
font-family: Tahoma, Arial, sans-serif;
font-size: 100%;
color: #69788E;
margin: 10px 30px;
background: #F7F7F7;
}
a:link, a:visited {
text-decoration: none;
color: #CECFCE;
}
a:active, a:hover {
text-decoration: underline;
color: #111;
}
h1 {
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-size: 1.70em;
font-weight: normal;
color: #333333;
margin-top: 0;
margin-bottom: 10px;
}
.content_box {
border: 1px dashed #CECFCE;
background: #FFFFFF;
padding: 10px;
margin-right: auto;
margin-left: auto;
}</style>
</head>
<body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br/>
<div class="content_box">
<p>
<a target="_blank" href="http://www.kleeja.com" title="kleeja"></a>
</p>
<br/>
<h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div>
<br/>
<div class="content_box"style="font-size: 140%">Powered by Kleeja</div>
</body>
</html>

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
admin/Masmak/images/switch.gif Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

58
admin/Masmak/index.html Executable file
View File

@@ -0,0 +1,58 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256"/>
<title>Powered by Kleeja</title>
<style type="text/css">* {
font-size: 100%;
margin: 0;
padding: 0;
color: #CECFCE;
}
body {
font-family: Tahoma, Arial, sans-serif;
font-size: 100%;
color: #69788E;
margin: 10px 30px;
background: #F7F7F7;
}
a:link, a:visited {
text-decoration: none;
color: #CECFCE;
}
a:active, a:hover {
text-decoration: underline;
color: #111;
}
h1 {
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-size: 1.70em;
font-weight: normal;
color: #333333;
margin-top: 0;
margin-bottom: 10px;
}
.content_box {
border: 1px dashed #CECFCE;
background: #FFFFFF;
padding: 10px;
margin-right: auto;
margin-left: auto;
}</style>
</head>
<body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br/>
<div class="content_box">
<p>
<a target="_blank" href="http://www.kleeja.com" title="kleeja"></a>
</p>
<br/>
<h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div>
<br/>
<div class="content_box"style="font-size: 140%">Powered by Kleeja</div>
</body>
</html>

3831
admin/Masmak/js/bootstrap.js vendored Executable file

File diff suppressed because it is too large Load Diff

6
admin/Masmak/js/bootstrap.min.js vendored Executable file

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,184 @@
/*! DataTables Bootstrap 3 integration
* ©2011-2015 SpryMedia Ltd - datatables.net/license
*/
/**
* DataTables integration for Bootstrap 3. This requires Bootstrap 3 and
* DataTables 1.10 or newer.
*
* This file sets the defaults and adds options to DataTables to style its
* controls using Bootstrap. See http://datatables.net/manual/styling/bootstrap
* for further information.
*/
(function( factory ){
if ( typeof define === 'function' && define.amd ) {
// AMD
define( ['jquery', 'datatables.net'], function ( $ ) {
return factory( $, window, document );
} );
}
else if ( typeof exports === 'object' ) {
// CommonJS
module.exports = function (root, $) {
if ( ! root ) {
root = window;
}
if ( ! $ || ! $.fn.dataTable ) {
// Require DataTables, which attaches to jQuery, including
// jQuery if needed and have a $ property so we can access the
// jQuery object that is used
$ = require('datatables.net')(root, $).$;
}
return factory( $, root, root.document );
};
}
else {
// Browser
factory( jQuery, window, document );
}
}(function( $, window, document, undefined ) {
'use strict';
var DataTable = $.fn.dataTable;
/* Set the defaults for DataTables initialisation */
$.extend( true, DataTable.defaults, {
dom:
"<'row'<'col-sm-12 col-md-6'l><'col-sm-12 col-md-6'f>>" +
"<'row'<'col-sm-12'tr>>" +
"<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
renderer: 'bootstrap'
} );
/* Default class modification */
$.extend( DataTable.ext.classes, {
sWrapper: "dataTables_wrapper container-fluid dt-bootstrap4",
sFilterInput: "form-control form-control-sm",
sLengthSelect: "form-control form-control-sm",
sProcessing: "dataTables_processing card",
sPageButton: "paginate_button page-item"
} );
/* Bootstrap paging button renderer */
DataTable.ext.renderer.pageButton.bootstrap = function ( settings, host, idx, buttons, page, pages ) {
var api = new DataTable.Api( settings );
var classes = settings.oClasses;
var lang = settings.oLanguage.oPaginate;
var aria = settings.oLanguage.oAria.paginate || {};
var btnDisplay, btnClass, counter=0;
var attach = function( container, buttons ) {
var i, ien, node, button;
var clickHandler = function ( e ) {
e.preventDefault();
if ( !$(e.currentTarget).hasClass('disabled') && api.page() != e.data.action ) {
api.page( e.data.action ).draw( 'page' );
}
};
for ( i=0, ien=buttons.length ; i<ien ; i++ ) {
button = buttons[i];
if ( $.isArray( button ) ) {
attach( container, button );
}
else {
btnDisplay = '';
btnClass = '';
switch ( button ) {
case 'ellipsis':
btnDisplay = '&#x2026;';
btnClass = 'disabled';
break;
case 'first':
btnDisplay = lang.sFirst;
btnClass = button + (page > 0 ?
'' : ' disabled');
break;
case 'previous':
btnDisplay = lang.sPrevious;
btnClass = button + (page > 0 ?
'' : ' disabled');
break;
case 'next':
btnDisplay = lang.sNext;
btnClass = button + (page < pages-1 ?
'' : ' disabled');
break;
case 'last':
btnDisplay = lang.sLast;
btnClass = button + (page < pages-1 ?
'' : ' disabled');
break;
default:
btnDisplay = button + 1;
btnClass = page === button ?
'active' : '';
break;
}
if ( btnDisplay ) {
node = $('<li>', {
'class': classes.sPageButton+' '+btnClass,
'id': idx === 0 && typeof button === 'string' ?
settings.sTableId +'_'+ button :
null
} )
.append( $('<a>', {
'href': '#',
'aria-controls': settings.sTableId,
'aria-label': aria[ button ],
'data-dt-idx': counter,
'tabindex': settings.iTabIndex,
'class': 'page-link'
} )
.html( btnDisplay )
)
.appendTo( container );
settings.oApi._fnBindAction(
node, {action: button}, clickHandler
);
counter++;
}
}
}
};
// IE9 throws an 'unknown error' if document.activeElement is used
// inside an iframe or frame.
var activeEl;
try {
// Because this approach is destroying and recreating the paging
// elements, focus is lost on the select button which is bad for
// accessibility. So we want to restore focus once the draw has
// completed
activeEl = $(host).find(document.activeElement).data('dt-idx');
}
catch (e) {}
attach(
$(host).empty().html('<ul class="pagination"/>').children('ul'),
buttons
);
if ( activeEl !== undefined ) {
$(host).find( '[data-dt-idx='+activeEl+']' ).focus();
}
};
return DataTable;
}));

58
admin/Masmak/js/index.html Executable file
View File

@@ -0,0 +1,58 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256"/>
<title>Powered by Kleeja</title>
<style type="text/css">* {
font-size: 100%;
margin: 0;
padding: 0;
color: #CECFCE;
}
body {
font-family: Tahoma, Arial, sans-serif;
font-size: 100%;
color: #69788E;
margin: 10px 30px;
background: #F7F7F7;
}
a:link, a:visited {
text-decoration: none;
color: #CECFCE;
}
a:active, a:hover {
text-decoration: underline;
color: #111;
}
h1 {
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-size: 1.70em;
font-weight: normal;
color: #333333;
margin-top: 0;
margin-bottom: 10px;
}
.content_box {
border: 1px dashed #CECFCE;
background: #FFFFFF;
padding: 10px;
margin-right: auto;
margin-left: auto;
}</style>
</head>
<body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br/>
<div class="content_box">
<p>
<a target="_blank" href="http://www.kleeja.com" title="kleeja"></a>
</p>
<br/>
<h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div>
<br/>
<div class="content_box"style="font-size: 140%">Powered by Kleeja</div>
</body>
</html>

34
admin/Masmak/js/jqBarGraph.js Executable file
View File

@@ -0,0 +1,34 @@
/**
* jqBarGraph - jQuery plugin
* @version: 1.1 (2011/04/03)
* @requires jQuery v1.2.2 or later
* @author Ivan Lazarevic
* Examples and documentation at: http://www.workshop.rs/jqbargraph/
*
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
*/
(function($){var opts=new Array;var level=new Array;$.fn.jqBarGraph=$.fn.jqbargraph=function(options){init=function(el){opts[el.id]=$.extend({},$.fn.jqBarGraph.defaults,options);$(el).css({'width':opts[el.id].width,'height':opts[el.id].height,'position':'relative','text-align':'center'});doGraph(el);};sum=function(ar){total=0;for(val in ar){total+=ar[val];}
return total.toFixed(2);};max=function(ar){maxvalue=0;for(var val in ar){value=ar[val][0];if(value instanceof Array)value=sum(value);if(parseFloat(value)>parseFloat(maxvalue))maxvalue=value;}
return maxvalue;};maxMulti=function(ar){maxvalue=0;maxvalue2=0;for(var val in ar){ar2=ar[val][0];for(var val2 in ar2){if(ar2[val2]>maxvalue2)maxvalue2=ar2[val2];}
if(maxvalue2>maxvalue)maxvalue=maxvalue2;}
return maxvalue;};doGraph=function(el){arr=opts[el.id];data=arr.data;if(data==undefined){$(el).html('There is not enought data for graph');return;}
if(arr.sort=='asc')data.sort(sortNumberAsc);if(arr.sort=='desc')data.sort(sortNumberDesc);legend='';prefix=arr.prefix;postfix=arr.postfix;space=arr.barSpace;legendWidth=arr.legend?arr.legendWidth:0;fieldWidth=($(el).width()-legendWidth)/data.length;totalHeight=$(el).height();var leg=new Array();max=max(data);colPosition=0;for(var val in data){valueData=data[val][0];if(valueData instanceof Array)
value=sum(valueData);else
value=valueData;lbl=data[val][1];color=data[val][2];unique=val+el.id;if(color==undefined&&arr.colors==false)
color=arr.color;if(arr.colors&&!color){colorsCounter=arr.colors.length;if(colorsCounter==colPosition)colPosition=0;color=arr.colors[colPosition];colPosition++;}
if(arr.type=='multi')color='none';if(lbl==undefined)lbl=arr.lbl;out="<div class='graphField"+el.id+"' id='graphField"+unique+"' style='position: absolute'>";out+="<div class='graphValue"+el.id+"' id='graphValue"+unique+"'>"+prefix+value+postfix+"</div>";out+="<div class='graphBar"+el.id+"' id='graphFieldBar"+unique+"' style='background-color:"+color+";position: relative; overflow: hidden;'></div>";if(!arr.legend||arr.legends)
out+="<div class='graphLabel"+el.id+"' id='graphLabel"+unique+"'>"+lbl+"</div>";out+="</div>";$(el).append(out);totalHeightBar=totalHeight-$('.graphLabel'+el.id).height()-$('.graphValue'+el.id).height();fieldHeight=(totalHeightBar*value)/max;$('#graphField'+unique).css({'left':(fieldWidth)*val,'width':fieldWidth-space,'margin-left':space});if(valueData instanceof Array){if(arr.type=="multi"){maxe=maxMulti(data);totalHeightBar=fieldHeight=totalHeight-$('.graphLabel'+el.id).height();$('.graphValue'+el.id).remove();}else{maxe=max;}
for(i in valueData){heig=totalHeightBar*valueData[i]/maxe;wid=parseInt((fieldWidth-space)/valueData.length);sv='';fs=0;if(arr.showValues){sv=arr.prefix+valueData[i]+arr.postfix;fs=12;}
o="<div class='subBars"+el.id+"' style='height:"+heig+"px; background-color: "+arr.colors[i]+"; left:"+wid*i+"px; color:"+arr.showValuesColor+"; font-size:"+fs+"px' >"+sv+"</div>";$('#graphFieldBar'+unique).prepend(o);}}
if(arr.type=='multi')
$('.subBars'+el.id).css({'width':wid,'position':'absolute','bottom':0});if(arr.position=='bottom')$('.graphField'+el.id).css('bottom',0);if(!arr.legends)
leg.push([color,lbl,el.id,unique]);if(arr.animate){$('#graphFieldBar'+unique).css({'height':0});$('#graphFieldBar'+unique).animate({'height':fieldHeight},arr.speed*1000);}else{$('#graphFieldBar'+unique).css({'height':fieldHeight});}}
for(var l in arr.legends){leg.push([arr.colors[l],arr.legends[l],el.id,l]);}
createLegend(leg);if(arr.legend){$(el).append("<div id='legendHolder"+unique+"'></div>");$('#legendHolder'+unique).css({'width':legendWidth,'float':'right','text-align':'left'});$('#legendHolder'+unique).append(legend);$('.legendBar'+el.id).css({'float':'left','margin':3,'height':12,'width':20,'font-size':0});}
if(arr.title){$(el).wrap("<div id='graphHolder"+unique+"'></div>");$('#graphHolder'+unique).prepend(arr.title).css({'width':arr.width+'px','text-align':'center'});}};createLegend=function(legendArr){legend='';for(var val in legendArr){legend+="<div id='legend"+legendArr[val][3]+"' style='overflow: hidden; zoom: 1;'>";legend+="<div class='legendBar"+legendArr[val][2]+"' id='legendColor"+legendArr[val][3]+"' style='background-color:"+legendArr[val][0]+"'></div>";legend+="<div class='legendLabel"+legendArr[val][2]+"' id='graphLabel"+unique+"'>"+legendArr[val][1]+"</div>";legend+="</div>";}};this.each(function()
{init(this);})};$.fn.jqBarGraph.defaults={barSpace:10,width:400,height:300,color:'#000000',colors:false,lbl:'',sort:false,position:'bottom',prefix:'',postfix:'',animate:true,speed:1.5,legendWidth:100,legend:false,legends:false,type:false,showValues:true,showValuesColor:'#fff',title:false};function sortNumberAsc(a,b){if(a[0]<b[0])return-1;if(a[0]>b[0])return 1;return 0;}
function sortNumberDesc(a,b){if(a[0]>b[0])return-1;if(a[0]<b[0])return 1;return 0;}})(jQuery);

15344
admin/Masmak/js/jquery.dataTables.js vendored Executable file

File diff suppressed because it is too large Load Diff

4
admin/Masmak/js/jquery.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,144 @@
/*
* waitForImages 1.4
* -----------------
* Provides a callback when all images have loaded in your given selector.
* http://www.alexanderdickson.com/
*
*
* Copyright (c) 2011 Alex Dickson
* Licensed under the MIT licenses.
* See website for more info.
*
*/
;(function($) {
// Namespace all events.
var eventNamespace = 'waitForImages';
// CSS properties which contain references to images.
$.waitForImages = {
hasImageProperties: [
'backgroundImage',
'listStyleImage',
'borderImage',
'borderCornerImage'
]
};
// Custom selector to find `img` elements that have a valid `src` attribute and have not already loaded.
$.expr[':'].uncached = function(obj) {
// Ensure we are dealing with an `img` element with a valid `src` attribute.
if ( ! $(obj).is('img[src!=""]')) {
return false;
}
// Firefox's `complete` property will always be`true` even if the image has not been downloaded.
// Doing it this way works in Firefox.
var img = document.createElement('img');
img.src = obj.src;
return ! img.complete;
};
$.fn.waitForImages = function(finishedCallback, eachCallback, waitForAll) {
// Handle options object.
if ($.isPlainObject(arguments[0])) {
eachCallback = finishedCallback.each;
waitForAll = finishedCallback.waitForAll;
finishedCallback = finishedCallback.finished;
}
// Handle missing callbacks.
finishedCallback = finishedCallback || $.noop;
eachCallback = eachCallback || $.noop;
// Convert waitForAll to Boolean
waitForAll = !! waitForAll;
// Ensure callbacks are functions.
if (!$.isFunction(finishedCallback) || !$.isFunction(eachCallback)) {
throw new TypeError('An invalid callback was supplied.');
};
return this.each(function() {
// Build a list of all imgs, dependent on what images will be considered.
var obj = $(this),
allImgs = [];
if (waitForAll) {
// CSS properties which may contain an image.
var hasImgProperties = $.waitForImages.hasImageProperties || [],
matchUrl = /url\((['"]?)(.*?)\1\)/g;
// Get all elements, as any one of them could have a background image.
obj.find('*').each(function() {
var element = $(this);
// If an `img` element, add it. But keep iterating in case it has a background image too.
if (element.is('img:uncached')) {
allImgs.push({
src: element.attr('src'),
element: element[0]
});
}
$.each(hasImgProperties, function(i, property) {
var propertyValue = element.css(property);
// If it doesn't contain this property, skip.
if ( ! propertyValue) {
return true;
}
// Get all url() of this element.
var match;
while (match = matchUrl.exec(propertyValue)) {
allImgs.push({
src: match[2],
element: element[0]
});
};
});
});
} else {
// For images only, the task is simpler.
obj
.find('img:uncached')
.each(function() {
allImgs.push({
src: this.src,
element: this
});
});
};
var allImgsLength = allImgs.length,
allImgsLoaded = 0;
// If no images found, don't bother.
if (allImgsLength == 0) {
finishedCallback.call(obj[0]);
};
$.each(allImgs, function(i, img) {
var image = new Image;
// Handle the image loading and error with the same callback.
$(image).bind('load.' + eventNamespace + ' error.' + eventNamespace, function(event) {
allImgsLoaded++;
// If an error occurred with loading the image, set the third argument accordingly.
eachCallback.call(img.element, allImgsLoaded, allImgsLength, event.type == 'load');
if (allImgsLoaded == allImgsLength) {
finishedCallback.call(obj[0]);
return false;
};
});
image.src = img.src;
});
});
};
})(jQuery);

2448
admin/Masmak/js/popper.js Executable file

File diff suppressed because it is too large Load Diff

5
admin/Masmak/js/popper.min.js vendored Executable file

File diff suppressed because one or more lines are too long

1
admin/Masmak/js/tether.min.js vendored Executable file

File diff suppressed because one or more lines are too long

452
admin/index.php Executable file
View File

@@ -0,0 +1,452 @@
<?php
/**
*
* @package adm
* @copyright (c) 2007 Kleeja.com
* @license ./docs/license.txt
*
*/
/**
* @ignore
*/
define('IN_KLEEJA', true);
define ('PATH' , '../');
define ('IN_ADMIN' , true);
require_once PATH . 'includes/common.php';
$go_to = ig('cp') ? g('cp') : 'start';
$username = $usrcp->name();
$AJAX_ACP = defined('AJAX_ACP');
$config['enable_captcha'] = 1;
#for security
if (!$username)
{
is_array($plugin_run_result = Plugins::getInstance()->run('user_not_admin_admin_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
redirect(PATH . 'ucp.php?go=login&return=' . urlencode(ADMIN_PATH . '?cp=' . $go_to));
}
#get language of admin
get_lang('acp');
//
//need to login again
//
if(
(empty($_SESSION['ADMINLOGIN']) || $_SESSION['ADMINLOGIN'] != md5(sha1($config['h_key']) . $usrcp->name() . $config['siteurl'])) ||
(empty($_SESSION['USER_SESS']) || $_SESSION['USER_SESS'] != session_id()) ||
(empty($_SESSION['ADMINLOGIN_T']) || $_SESSION['ADMINLOGIN_T'] < time())
)
{
if(ig('go') && g('go') == 'login')
{
if (ip('submit'))
{
//login
$ERRORS = array();
$pass_field = 'lpass_' . preg_replace('/[^0-9]/', '', sha1($klj_session . sha1($config['h_key']) . p('kid')));
if(!empty($_SESSION['SHOW_CAPTCHA']))
{
if(!kleeja_check_captcha())
{
$ERRORS[] = $lang['WRONG_VERTY_CODE'];
}
}
if (empty(p('lname')) || empty(p($pass_field)))
{
$ERRORS[] = $lang['EMPTY_FIELDS'];
}
elseif(!user_can('enter_acp'))
{
$ERRORS[] = $lang['U_NOT_ADMIN'];
}
elseif(!kleeja_check_form_key('admin_login'))
{
$ERRORS[] = $lang['INVALID_FORM_KEY'];
}
is_array($plugin_run_result = Plugins::getInstance()->run('admin_login_submit', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
if(empty($ERRORS))
{
if($f = $usrcp->data(p('lname'), p($pass_field), false, 3600*6, true))
{
$_SESSION['USER_SESS'] = session_id();
$_SESSION['ADMINLOGIN'] = md5(sha1($config['h_key']) . $usrcp->name() . $config['siteurl']);
//to make sure, sometime setting time from functions doesn't work
$_SESSION['ADMINLOGIN_T'] = time() + 18000;
unset($_SESSION['SHOW_CAPTCHA']);
redirect('./' . basename(ADMIN_PATH) . '?cp=' . $go_to);
$SQL->close();
exit;
}
else
{
//Wrong entries
$ERRORS[] = $lang['LOGIN_ERROR'];
$_SESSION['SHOW_CAPTCHA'] = function_exists('gd_info');
}
}
//let's see if there is errors
if(sizeof($ERRORS))
{
$errs = '';
foreach($ERRORS as $r)
{
$errs .= '- ' . $r . '. <br />';
}
}
}
}
//show template login .
$action = './' . basename(ADMIN_PATH) . '?go=login&amp;cp=' . $go_to;
$H_FORM_KEYS = kleeja_add_form_key('admin_login');
$KEY_FOR_WEE = sha1(microtime() . sha1($config['h_key']));
$KEY_FOR_PASS = preg_replace('/[^0-9]/', '', sha1($klj_session . sha1($config['h_key']) . $KEY_FOR_WEE));
$not_you = sprintf($lang['USERNAME_NOT_YOU'], '<a href="' .$config['siteurl'] . 'ucp.php?go=logout">', '</a>');
$show_captcha = !empty($_SESSION['SHOW_CAPTCHA']);
$extra_header_admin_login = '';
$err = false;
if(!empty($errs))
{
$err = true;
}
is_array($plugin_run_result = Plugins::getInstance()->run('before_display_template_admin_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//prevent indexing this page by bots
header('HTTP/1.1 503 Service Temporarily Unavailable');
echo $tpl->display("admin_login");
$SQL->close();
exit;
}#end login
//ummm let's say it's illegal action
if ($_SERVER['REQUEST_METHOD'] == 'POST' && defined('STOP_CSRF'))
{
$t_reff = explode('/', $_SERVER['HTTP_REFERER']);
$t_host = explode('/', $_SERVER['HTTP_HOST']);
if ($t_reff[2] != $t_host[0])
{
$usrcp->logout_cp();
redirect($config['siteurl']);
$SQL->close();
exit;
}
}
//current admin theme color
if(ig('change_theme'))
{
$admin_theme_color = g('change_theme', 'str', 'dark');
if(in_array($admin_theme_color, array('dark', 'light')))
{
$usrcp->kleeja_set_cookie('klj_adm_theme_color', $admin_theme_color, time() + 31536000);
}
else
{
$admin_theme_color = 'dark';
}
}
else
{
if (!($admin_theme_color = $usrcp->kleeja_get_cookie('klj_adm_theme_color')))
{
$admin_theme_color = 'dark';
}
}
(!defined('LAST_VISIT')) ? define('LAST_VISIT', time() - 3600 * 12) : null;
//last visit
$last_visit = defined('LAST_VISIT') && preg_match('/[0-9]{10}/', LAST_VISIT) ? kleeja_date(LAST_VISIT) : false;
//
//exceptional
//it won't be included in the menu list
//
$ext_expt = array(
'start',
'b_lgoutcp',
'i_exts'
);
//confirm message
$ext_confirm = array();
//formkey extension, CSRF protection
$GET_FORM_KEY_GLOBAL = kleeja_add_form_key_get('GLOBAL_FORM_KEY');
$ext_formkey = array();
//default icons
$ext_icons = array(
'configs' => 'sliders',
'files' => 'folder-open-o',
'img_ctrl' => 'image',
'calls' => 'envelope',
'reports' => 'bell',
'users' => 'user-o',
'search' => 'search',
'plugins' => 'plug',
'ban' => 'minus-circle',
'rules' => 'institution',
'styles' => 'paint-brush',
'extra' => 'window-restore',
'check_update' => 'download',
'repair' => 'wrench',
);
//
//We hide list of admin menu and show only if there is auth.
//
$SHOW_LIST = true;
//get adm extensions
$adm_extensions = array();
if (($dh = @opendir(ADM_FILES_PATH)) !== false)
{
while (($file = readdir($dh)) !== false)
{
if(strpos($file, '.php') !== false)
{
$adm_extensions[] = str_replace('.php', '', $file);
}
}
closedir($dh);
}
//no extensions ?
if(!$adm_extensions || !is_array($adm_extensions))
{
if(ig('_ajax_'))
{
echo_ajax(888, 'Error while loading admin extensions!.');
}
big_error('No Extensions', 'Error while loading admin extensions !');
}
is_array($plugin_run_result = Plugins::getInstance()->run('begin_admin_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
/**
* Exception of 406 ! dirty hosting
* 'configs' word listed as dangrous requested word
* so we replaced this word with 'options' instead.
*/
if($go_to == 'options')
{
$go_to = 'a_configs';
}
//no request or wrong !
if(!$go_to || empty($go_to) || !in_array($go_to, $adm_extensions))
{
$go_to = 'start';
}
//make array for menu
$adm_extensions_menu = $adm_topmenu = array();
//sort the items as alphabetic !
sort($adm_extensions);
$i = 0;
$cr_time = LAST_VISIT > 0 ? LAST_VISIT : time() - 3600*12;
// check calls and reports numbers
if(ig('check_msgs') || !ig('_ajax_')):
//small bubble system
//any item can show what is inside it as unread messages
$kbubbles = array();
//for calls and reports
foreach(array('call'=>'calls', 'reports'=>'reports') as $table=>$n)
{
$query = array(
'SELECT' => 'COUNT(' . $table[0] . '.id) AS total_rows',
'FROM' => "`{$dbprefix}" . $table . "` " . $table[0]
);
$fetched = $SQL->fetch_array($SQL->build($query));
$kbubbles[$n] = $fetched['total_rows'];
$SQL->freeresult();
}
#if ajax, echo differntly
if(ig('check_msgs'))
{
$SQL->close();
exit($kbubbles['calls'] . '::' . $kbubbles['reports']);
}
//add your own bubbles here
is_array($plugin_run_result = Plugins::getInstance()->run('kbubbles_admin_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
endif;
foreach($adm_extensions as $m)
{
//some exceptions
if(@in_array($m, $ext_expt))
{
continue;
}
is_array($plugin_run_result = Plugins::getInstance()->run('foreach_ext_admin_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$s = $m;
$m = isset($m[1]) && $m[1] == '_' ? substr($m , 2) : $m;
++$i;
$adm_extensions_menu[$i] = array(
'm' => $m,
'i' => $i+1,
'i2' => $i+2,
'icon' => !empty($ext_icons[$m]) ? $ext_icons[$m] : 'puzzle-piece',
'lang' => !empty($lang['R_'. strtoupper($m)]) ? $lang['R_'. strtoupper($m)] : (!empty($olang['R_' . strtoupper($m)]) ? $olang['R_' . strtoupper($m)] : strtoupper($m)),
'link' => './' . basename(ADMIN_PATH) . '?cp=' . ($m == 'configs' ? 'options' : $s) . (@in_array($m, $ext_formkey) ? '&amp;' . $GET_FORM_KEY_GLOBAL : ''),
'confirm' => (@in_array($m, $ext_confirm)) ? true : false,
'current' => ($s == $go_to) ? true : false,
'goto' => str_replace('a_configs', 'options', $s),
'bubble' => !emptY($kbubbles[$m]) ? '<span class="badge badge-pill badge-warning bubble_' . $m . '"' . ($kbubbles[$m] == 0 ? ' style="display:none"' : '') . '>' . $kbubbles[$m] . '</span>' : '',
'counter' => !emptY($kbubbles[$m]) ? $kbubbles[$m] : ''
);
//add another item to array for title='' in href or other thing
$adm_extensions_menu[$i]['title'] = $adm_extensions_menu[$i]['lang'];
is_array($plugin_run_result = Plugins::getInstance()->run('endforeach_ext_admin_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
}
#to attach kleeja version in the menu start item
$assigned_klj_ver = preg_replace('!#([a-z0-9]+)!', '', KLEEJA_VERSION);
#for plugins
$styleePath = null;
//get it
if (file_exists(ADM_FILES_PATH . '/' . $go_to . '.php'))
{
$include = true;
is_array($plugin_run_result = Plugins::getInstance()->run("require_admin_page_begin_{$go_to}", get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
if($include)
{
include_once ADM_FILES_PATH . '/' . $go_to . '.php';
}
is_array($plugin_run_result = Plugins::getInstance()->run("require_admin_page_end_{$go_to}", get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
}
else
{
$include_alternative = null;
is_array($plugin_run_result = Plugins::getInstance()->run("not_exists_{$go_to}", get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
if(!empty($include_alternative) && file_exists($include_alternative))
{
include_once $include_alternative;
}
else
{
if (ig('_ajax_'))
{
echo_ajax(888, 'Error while loading : ' . $go_to);
}
big_error('In Loading !', 'Error while loading : ' . $go_to);
}
}
//no style defined
if(empty($stylee))
{
$text = $lang['NO_TPL_SHOOSED'];
$stylee = 'admin_info';
}
$go_menu_html = '';
if(isset($go_menu))
{
foreach($go_menu as $m=>$d)
{
$go_menu_html .= '<li class="' . ($d['current'] ? 'active' : '') . '" id="c_' . $d['goto'] . '">' .
'<a' . ($m == 'site' ? ' target="_blank" ' : ' ') . 'href="' . $d['link'] . '" ' . ($d['confirm'] ? ' onclick="javascript:return confirm_form();"' : '') . '>' .
$d['name'] . '</a></li>';
}
}
is_array($plugin_run_result = Plugins::getInstance()->run('end_admin_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//header
if(!ig('_ajax_'))
{
echo $tpl->display("admin_header");
}
//body
if(!ig('_ajax_'))
{
$is_ajax = 'no';
echo $tpl->display($stylee, $styleePath);
}
else
{
$is_ajax = 'yes';
echo_ajax(1, $tpl->display($stylee, $styleePath), $go_menu_html);
}
//footer
if(!ig('_ajax_'))
{
echo $tpl->display("admin_footer");
}
//close db
$SQL->close();
exit;

3
cache/.htaccess vendored Executable file
View File

@@ -0,0 +1,3 @@
Options -Indexes
Order Allow,Deny
Deny from All

58
cache/index.html vendored Executable file
View File

@@ -0,0 +1,58 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256"/>
<title>Powered by Kleeja</title>
<style type="text/css">* {
font-size: 100%;
margin: 0;
padding: 0;
color: #CECFCE;
}
body {
font-family: Tahoma, Arial, sans-serif;
font-size: 100%;
color: #69788E;
margin: 10px 30px;
background: #F7F7F7;
}
a:link, a:visited {
text-decoration: none;
color: #CECFCE;
}
a:active, a:hover {
text-decoration: underline;
color: #111;
}
h1 {
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-size: 1.70em;
font-weight: normal;
color: #333333;
margin-top: 0;
margin-bottom: 10px;
}
.content_box {
border: 1px dashed #CECFCE;
background: #FFFFFF;
padding: 10px;
margin-right: auto;
margin-left: auto;
}</style>
</head>
<body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br/>
<div class="content_box">
<p>
<a target="_blank" href="http://www.kleeja.com" title="kleeja"></a>
</p>
<br/>
<h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div>
<br/>
<div class="content_box"style="font-size: 140%">Powered by Kleeja</div>
</body>
</html>

565
do.php Executable file
View File

@@ -0,0 +1,565 @@
<?php
/**
*
* @package Kleeja
* @copyright (c) 2007 Kleeja.com
* @license ./docs/license.txt
*
*/
/**
* @ignore
*/
define('IN_KLEEJA', true);
define ('IN_DOWNLOAD', true);
require_once 'includes/common.php';
is_array($plugin_run_result = Plugins::getInstance()->run('begin_download_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//
//page of wait downloading files
//
if (ig('id') || ig('filename'))
{
is_array($plugin_run_result = Plugins::getInstance()->run('begin_download_id_filename', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$query = array(
'SELECT' => 'f.id, f.real_filename, f.name, f.folder, f.size, f.time, f.uploads, f.type',
'FROM' => "{$dbprefix}files f",
'LIMIT' => "1",
);
#if user system is default, we use users table
if((int) $config['user_system'] == 1)
{
$query['SELECT'] .= ', u.name AS fusername, u.id AS fuserid';
$query['JOINS'] = array(
array(
'LEFT JOIN' => "{$dbprefix}users u",
'ON' => 'u.id=f.user'
)
);
}
if (ig('filename'))
{
$filename_l = (string) $SQL->escape(g('filename'));
if(ig('x'))
{
$query['WHERE'] = "f.name='" . $filename_l . '.' . $SQL->escape(g('x')) . "'";
}
else
{
$query['WHERE'] = "f.name='" . $filename_l . "'";
}
}
else
{
$id_l = g('id', 'int');
$query['WHERE'] = "f.id=" . $id_l;
}
is_array($plugin_run_result = Plugins::getInstance()->run('qr_download_id_filename', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$result = $SQL->build($query);
if ($SQL->num_rows($result) != 0)
{
$file_info = $SQL->fetch_array($result);
$SQL->freeresult($result);
// some vars
$id = $file_info['id'];
$name = $fname = $file_info['name'];
$real_filename = $file_info['real_filename'];
$type = $file_info['type'];
$size = $file_info['size'];
$time = $file_info['time'];
$uploads = $file_info['uploads'];
$fname2 = str_replace('.', '-', htmlspecialchars($name));
$name = $real_filename != '' ? str_replace('.' . $type, '', htmlspecialchars($real_filename)) : $name;
$name = strlen($name) > 70 ? substr($name, 0, 70) . '...' : $name;
$fusername = $config['user_system'] == 1 && $file_info['fuserid'] > -1 ? $file_info['fusername'] : false;
$userfolder = $config['siteurl'] . ($config['mod_writer'] ? 'fileuser-' . $file_info['fuserid'] . '.html' : 'ucp.php?go=fileuser&amp;id=' . $file_info['fuserid']);
if (ig('filename'))
{
$url_file = $config['mod_writer'] ? $config['siteurl'] . "downf-" . $fname2 . ".html" : $config['siteurl'] . "do.php?downf=" . $fname;
}
else
{
$url_file = $config['mod_writer'] ? $config['siteurl'] . "down-" . $file_info['id'] . ".html" : $config['siteurl'] . "do.php?down=" . $file_info['id'];
}
if(!empty($config['livexts']))
{
$livexts = explode(',', $config['livexts']);
if (in_array($type, $livexts))
{
if (ig('filename'))
{
$url_filex = $config['mod_writer'] ? $config['siteurl'] . "downexf-" . $fname2 . ".html" : $config['siteurl'] . "do.php?downexf=" . $fname;
}
else
{
$url_filex = $config['mod_writer'] ? $config['siteurl'] . "downex-" . $file_info['id'] . ".html" : $config['siteurl'] . "do.php?downex=" . $file_info['id'];
}
redirect($url_filex, false);
}
}
$REPORT = ($config['mod_writer']) ? $config['siteurl'] . "report-" . $file_info['id'] . ".html" : $config['siteurl'] . "go.php?go=report&amp;id=" . $file_info['id'];
$seconds_w = user_can('enter_acp') ? 0 : $config['sec_down'];
$time = kleeja_date($time);
$size = readable_size($size);
$file_ext_icon = file_exists('images/filetypes/' . $type . '.png') ? 'images/filetypes/' . $type . '.png' : 'images/filetypes/file.png';
$sty = 'download';
$title = $name . ' - ' . $lang['DOWNLAOD'];
}
else
{
//file not exists
is_array($plugin_run_result = Plugins::getInstance()->run('not_exists_qr_downlaod_file', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
kleeja_err($lang['FILE_NO_FOUNDED']);
}
is_array($plugin_run_result = Plugins::getInstance()->run('b4_showsty_downlaod_id_filename', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//add http reffer to session to prevent errors with some browsers !
$_SESSION['HTTP_REFERER'] = $file_info['id'];
// show style ...
Saaheader($title);
echo $tpl->display($sty);
Saafooter();
}
//
//download file
//
# guidelines for _get variable names
#
# down: [0-9], default, came from do.php?id=[0-9]
# downf: [a-z0-9].[ext], came from do.php?filename=[a-z0-9].[ext]
#
# img: [0-9], default, direct from do.php?img=[0-9]
# imgf: [a-z0-9].[ext], direct from do.php?imgf=[a-z0-9].[ext]
#
# thmb: [0-9], default, direct from do.php?thmb=[0-9]
# thmbf: [a-z0-9].[ext], direct from do.php?thmbf=[a-z0-9].[ext]
#
# live extensions feature uses downex, downexf as in down & downf
#
# x : used only for html links, where x = extension, downf is filename without extension
else if (ig('down') || ig('downf') ||
ig('img') || ig('imgf') ||
ig('thmb') || ig('thmbf') ||
ig('downex') || ig('downexf'))
{
is_array($plugin_run_result = Plugins::getInstance()->run('begin_down_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//kleeja_log('downloading file start - (' . var_dump($_GET) . ') -> ' . $_SERVER['HTTP_REFERER']);
//must know from where he came ! and stop him if not image
//todo: if it's download manger, let's pass this
if (ig('down') || ig('downf'))
{
//if not from our site and the waiting page
$not_reffer = true;
$isset_down_h = ig('downf') && ig('x') ? 'downloadf-' . g('downf') . '-' . g('x') . '.html' : (ig('down') ? 'download' . g('down') . '.html' : '');
if (!empty($_SERVER['HTTP_REFERER'])
&& strpos($_SERVER['HTTP_REFERER'], $isset_down_h) !== false)
{
$not_reffer = false;
}
$isset_down = ig('downf') ? 'do.php?filename=' . g('downf') : (ig('down') ? 'do.php?id=' . g('down') : '');
if (!empty($_SERVER['HTTP_REFERER'])
&& strpos($_SERVER['HTTP_REFERER'], $isset_down) !== false)
{
$not_reffer = false;
}
if (!empty($_SERVER['HTTP_REFERER'])
&& strpos($config['siteurl'], str_replace(array('http://', 'www.', 'https://'), '', htmlspecialchars($_SERVER['HTTP_REFERER']))))
{
$not_reffer = false;
}
if (isset($_SERVER["HTTP_RANGE"]))
{
$not_reffer = false;
}
if(isset($_SESSION['HTTP_REFERER']))
{
$not_reffer = false;
unset($_SESSION['HTTP_REFERER']);
}
if ($not_reffer)
{
if (ig('downf'))
{
$go_to = $config['siteurl'] . ($config['mod_writer'] && ig('x') ? "downloadf-" . g('downf') . '-' . g('x') . ".html" : "do.php?filename=" . g('downf'));
}
else
{
$go_to = $config['siteurl'] . ($config['mod_writer'] ? 'download' . g('down') . '.html' : 'do.php?id=' . g('down'));
}
redirect($go_to);
$SQL->close();
exit;
}
}
//download by id or filename
//is the requested variable is filename(filename123.gif) or id (123) ?
$is_id_filename = ig('downf') || ig('imgf') || ig('thmbf') || ig('downexf') ? true : false;
$filename = $id = null;
if ($is_id_filename)
{
$var = ig('downf') ? 'downf' : (ig('imgf') ? 'imgf' : (ig('thmbf') ? 'thmbf' : (ig('downexf') ? 'downexf' : false)));
#x, represent the extension, came from html links
if (ig('x') && $var)
{
$filename = $SQL->escape(g($var)) . '.' . $SQL->escape(g('x'));
}
else
{
$filename = $SQL->escape(g($var));
}
}
else
{
$id = ig('down') ? g('down', 'int') : (ig('img') ? g('img', 'int') : (ig('thmb') ? g('thmb', 'int') : (ig('downex') ? g('downex', 'int') : null)));
}
//is internet explore 8 ?
$is_ie8 = is_browser('ie8');
//is internet explore 6 ?
$is_ie6 = is_browser('ie6');
$livexts = explode(",", $config['livexts']);
//get info file
$query = array('SELECT' => 'f.id, f.name, f.real_filename, f.folder, f.type, f.size, f.time',
'FROM' => "{$dbprefix}files f",
'WHERE' => $is_id_filename ? "f.name='" . $filename . "'" . (ig('downexf') ? " AND f.type IN ('" . implode("', '", $livexts) . "')" : '') :
'f.id=' . $id . (ig('downex') ? " AND f.type IN ('" . implode("', '", $livexts) . "')" : ''),
'LIMIT' => '1'
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_down_go_page_filename', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$result = $SQL->build($query);
$is_live = false;
$pre_ext = !empty($filename) && strpos($filename, '.') !== false ? explode('.', $filename) : array();
$pre_ext = array_pop($pre_ext);
$is_image = in_array(strtolower(trim($pre_ext)), array('gif', 'jpg', 'jpeg', 'bmp', 'png')) ? true : false;
#initiate variables
$ii = $n = $rn = $t = $f = $ftime = $d_size = null;
if ($SQL->num_rows($result))
{
$row = $SQL->fetch($result);
$ii = $row['id'];
$n = $row['name'];
$rn = $row['real_filename'];
$t = strtolower(trim($row['type']));
$f = $row['folder'];
$ftime = $row['time'];
$d_size = $row['size'];
#img or not
$is_image = in_array($t, array('gif', 'jpg', 'jpeg', 'bmp', 'png')) ? true : false;
#live url
$is_live = in_array($t, $livexts) ? true : false;
$SQL->free($result);
//fix bug where a user can override files wait counter
if (!$is_image && (ig('img') || ig('thmb')))
{
$go_to = $config['siteurl'] . ($config['mod_writer'] ? 'download' . $ii . '.html' : 'do.php?id=' . $ii);
redirect($go_to);
}
//check if the vistor is new in this page before updating kleeja counter
if (!preg_match('/,' . $ii . ',/i', $usrcp->kleeja_get_cookie('oldvistor')) && !isset($_SERVER['HTTP_RANGE']))
{
//updates number of uploads ..
$update_query = array(
'UPDATE' => "{$dbprefix}files",
'SET' => 'uploads=uploads+1, last_down=' . time(),
'WHERE' => $is_id_filename ? "name='" . $filename . "'" : 'id=' . $id,
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_update_no_uploads_down', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$SQL->build($update_query);
//
//Define as old vistor
//if this vistor has other views then add this view too
//old vistor just for 1 day
//
if ($usrcp->kleeja_get_cookie('oldvistor'))
{
$usrcp->kleeja_set_cookie('oldvistor', $usrcp->kleeja_get_cookie('oldvistor') . $ii . ',', time() + 86400);
}
else
{
//first time
$usrcp->kleeja_set_cookie('oldvistor', ',' . $ii . ',', time() + 86400);
}
}
}
else
{
//not exists img or thumb
if (ig('img') || ig('thmb') || ig('thmbf') || ig('imgf'))
{
is_array($plugin_run_result = Plugins::getInstance()->run('not_exists_qr_down_img', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$f = 'images';
$n = 'not_exists.jpg';
//set image condition on
$is_image = true;
}
else
{
//not exists file
is_array($plugin_run_result = Plugins::getInstance()->run('not_exists_qr_down_file', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
kleeja_err($lang['FILE_NO_FOUNDED']);
}
}
//download process
$path_file = ig('thmb') || ig('thmbf') ? "./{$f}/thumbs/{$n}" : "./{$f}/{$n}";
$chunksize = 8192;
$resuming_on = true;
is_array($plugin_run_result = Plugins::getInstance()->run('down_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
# this is a solution to ignore downloading through the file, redirect to the actual file
# where you can add 'define("MAKE_DOPHP_301_HEADER", true);' in config.php to stop the load
# if there is any.ead
if (defined('MAKE_DOPHP_301_HEADER'))
{
header('HTTP/1.1 301 Moved Permanently');
header('Location: ' . $path_file);
$SQL->close();
exit;
}
//start download ,,
if (!is_readable($path_file))
{
is_array($plugin_run_result = Plugins::getInstance()->run('down_file_not_exists', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
if ($is_image)
{
$path_file = 'images/not_exists.jpg';
}
else
{
big_error($lang['FILE_NO_FOUNDED'], $lang['NOT_FOUND']);
}
}
if (!($size = @kleeja_filesize($path_file)))
{
$size = $d_size;
}
$name = empty($rn) ? $n : $rn;
if (is_browser('mozilla'))
{
$h_name = "filename*=UTF-8''" . rawurlencode(htmlspecialchars_decode($name));
}
else if (is_browser('opera, safari, konqueror'))
{
$h_name = 'filename="' . str_replace('"', '', htmlspecialchars_decode($name)) . '"';
}
else
{
$h_name = 'filename="' . rawurlencode(htmlspecialchars_decode($name)) . '"';
}
//Figure out the MIME type (if not specified)
$ext = explode('.', $path_file);
$ext = array_pop($ext);
$mime_type = get_mime_for_header($ext);
#disable execution time limit
@set_time_limit(0);
#disable output buffering
#TODO check effectiveness
$level = ob_get_level();
while ($level > 0)
{
ob_end_clean();
$level--;
}
if (!is_null($SQL))
{
$SQL->close();
}
session_write_close();
// required for IE, otherwise Content-Disposition may be ignored
if(@ini_get('zlib.output_compression'))
{
@ini_set('zlib.output_compression', 'Off');
}
#open the file
if (($fp = @fopen($path_file, 'rb')) === false)
{
#so ... it's failed to open !
header("HTTP/1.0 404 Not Found");
@fclose($fp);
big_error($lang['FILE_NO_FOUNDED'], $lang['NOT_FOUND']);
}
#Unsetting all previously set headers.
header_remove();
is_array($plugin_run_result = Plugins::getInstance()->run('do_page_before_headers_set', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
#send file headers
header('Pragma: public');
header('Accept-Ranges: bytes');
header("Content-Description: File Transfer");
header("Content-Type: $mime_type");
header('Date: ' . gmdate('D, d M Y H:i:s', empty($ftime) ? time() : $ftime) . ' GMT');
#header('Last-Modified: ' . gmdate('D, d M Y H:i:s', $ftime) . ' GMT');
#header('Content-Encoding: none');
header('Content-Disposition: ' . ($is_image || $is_live ? 'inline' : 'attachment') . '; ' . $h_name);
is_array($plugin_run_result = Plugins::getInstance()->run('do_page_headers_set', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
#if(!$is_image && !$is_live && $is_ie8)
#{
# header('X-Download-Options: noopen');
#}
#header(($is_ie6 ? 'Expires: -1' : 'Expires: Mon, 26 Jul 1997 05:00:00 GMT'));
#(($is_ie8) ? '; authoritative=true; X-Content-Type-Options: nosniff;' : '')
#add multipart download and resume support
if (isset($_SERVER["HTTP_RANGE"]) && $resuming_on)
{
list($a, $range) = explode("=", $_SERVER["HTTP_RANGE"], 2);
list($range) = explode(",", $range, 2);
list($range, $range_end) = explode("=", $range);
$range = round(floatval($range), 0);
$range_end = !$range_end ? $size - 1 : round(floatval($range_end), 0);
$partial_length = $range_end - $range + 1;
header("HTTP/1.1 206 Partial Content");
header("Content-Length: $partial_length");
header("Content-Range: bytes " . ($range - $range_end / $size));
fseek($fp, $range);
}
else
{
$partial_length = $size;
header("Content-Length: $partial_length");
}
#output file
$bytes_sent = 0;
#read and output the file in chunks
while (!feof($fp) && (!connection_aborted()) && ($bytes_sent < $partial_length))
{
$buffer = fread($fp, $chunksize);
print($buffer);
flush();
$bytes_sent += strlen($buffer);
if(defined('TrottleLimit'))
{
sleep(1);
}
}
fclose($fp);
if(function_exists('fastcgi_finish_request'))
{
fastcgi_finish_request();
}
exit;
}
//
//no one of above are there, you can use this hook to get more actions here
//
else
{
is_array($plugin_run_result = Plugins::getInstance()->run('err_navig_download_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
kleeja_err($lang['ERROR_NAVIGATATION']);
}
is_array($plugin_run_result = Plugins::getInstance()->run('end_download_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
#<-- EOF

BIN
docs/How To.pdf Normal file

Binary file not shown.

58
docs/index.html Executable file
View File

@@ -0,0 +1,58 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256"/>
<title>Powered by Kleeja</title>
<style type="text/css">* {
font-size: 100%;
margin: 0;
padding: 0;
color: #CECFCE;
}
body {
font-family: Tahoma, Arial, sans-serif;
font-size: 100%;
color: #69788E;
margin: 10px 30px;
background: #F7F7F7;
}
a:link, a:visited {
text-decoration: none;
color: #CECFCE;
}
a:active, a:hover {
text-decoration: underline;
color: #111;
}
h1 {
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-size: 1.70em;
font-weight: normal;
color: #333333;
margin-top: 0;
margin-bottom: 10px;
}
.content_box {
border: 1px dashed #CECFCE;
background: #FFFFFF;
padding: 10px;
margin-right: auto;
margin-left: auto;
}</style>
</head>
<body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br/>
<div class="content_box">
<p>
<a target="_blank" href="http://www.kleeja.com" title="kleeja"></a>
</p>
<br/>
<h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div>
<br/>
<div class="content_box"style="font-size: 140%">Powered by Kleeja</div>
</body>
</html>

Binary file not shown.

14
download.php Executable file
View File

@@ -0,0 +1,14 @@
<?php
/**
*
* @package Kleeja
* @copyright (c) 2007 Kleeja.com
* @license ./docs/license.txt
*
*/
//
// we deprecated download.php , so we have to put it for those who upgraded
// to this version
//
require 'do.php';

680
go.php Executable file
View File

@@ -0,0 +1,680 @@
<?php
/**
*
* @package Kleeja
* @copyright (c) 2007 Kleeja.com
* @license ./docs/license.txt
*
*/
/**
* @ignore
*/
define('IN_KLEEJA', true);
define('IN_GO' , true);
require_once 'includes/common.php';
$current_go_case = g('go');
is_array($plugin_run_result = Plugins::getInstance()->run('begin_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
switch($current_go_case)
{
//
//Page of allowed extensions for all groups
//
case 'exts' :
case 'guide' :
$stylee = 'guide';
$titlee = $lang['GUIDE'];
$tgroups = $ttgroups = array();
$tgroups = array_keys($d_groups);
$same_group= $rando = 0;
foreach($tgroups as $gid)
{
#if this is admin group, dont show it public
if($gid == 1 && (int) $userinfo['group_id'] != 1)
{
continue;
}
#TODO: if no exts, show that
foreach($d_groups[$gid]['exts'] as $ext=>$size)
{
$ttgroups[] = array(
'ext' => $ext,
'size' => readable_size($size),
'group' => $gid,
'group_name'=> str_replace(array('{lang.ADMINS}', '{lang.USERS}', '{lang.GUESTS}'),
array($lang['ADMINS'], $lang['USERS'], $lang['GUESTS']),
$d_groups[$gid]['data']['group_name']),
'most_firstrow'=> $same_group == 0 ? true : false,
'firstrow'=> $same_group ==0 or $same_group != $gid ? true : false,
'rando' => $rando,
);
$same_group = $gid;
}
$rando = $rando ? 0 : 1;
}
is_array($plugin_run_result = Plugins::getInstance()->run('guide_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
break;
//
//Page of reporting
//
case 'report' :
if(!user_can('access_report'))
{
is_array($plugin_run_result = Plugins::getInstance()->run('user_cannot_access_report', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
kleeja_info($lang['HV_NOT_PRVLG_ACCESS']);
}
//page info
$stylee = 'report';
$titlee = $lang['REPORT'];
$id_d = ig('id') ? g('id', 'int') : (ip('rid') ? p('rid', 'int') : 0);
$url_id = (int) $config['mod_writer'] == 1 ? $config['siteurl'] . 'download' . $id_d . '.html' : $config['siteurl'] . 'do.php?id=' . $id_d;
$action = $config['siteurl'] . 'go.php?go=report';
$H_FORM_KEYS = kleeja_add_form_key('report');
$NOT_USER = !$usrcp->name() ? true : false;
$s_url = p('surl');
#Does this file exists ?
if(ig('id') || ip('rid'))
{
$query = array(
'SELECT' => 'f.real_filename, f.name',
'FROM' => "{$dbprefix}files f",
'WHERE' => 'id=' . $id_d
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_report_go_id', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$result = $SQL->build($query);
if ($SQL->num_rows($result))
{
$row = $SQL->fetch_array($result);
$filename_for_show = $row['real_filename'] == '' ? $row['name'] : $row['real_filename'];
}
else
{
is_array($plugin_run_result = Plugins::getInstance()->run('not_exists_qr_report_go_id', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
kleeja_err($lang['FILE_NO_FOUNDED']);
}
$SQL->freeresult($result);
}
//no error yet
$ERRORS = false;
//_post
$t_rname = p('rname');
$t_rmail = p('rmail');
$t_rtext = p('rtext');
if (!ip('submit'))
{
// first
is_array($plugin_run_result = Plugins::getInstance()->run('no_submit_report_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
}
else
{
$ERRORS = array();
is_array($plugin_run_result = Plugins::getInstance()->run('submit_report_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//check for form key
if(!kleeja_check_form_key('report'))
{
$ERRORS['form_key'] = $lang['INVALID_FORM_KEY'];
}
if(!kleeja_check_captcha())
{
$ERRORS['captcha'] = $lang['WRONG_VERTY_CODE'];
}
if ((empty(p('rname')) && $NOT_USER))
{
$ERRORS['rname'] = $lang['EMPTY_FIELDS'] . ' : ' . (empty(p('rname')) && $NOT_USER ? ' [ ' . $lang['YOURNAME'] . ' ] ' : '')
. (empty(p('rurl')) ? ' [ ' . $lang['URL'] . ' ] ': '');
}
if(ip('surl') && trim(p('surl')) == '')
{
$ERRORS['surl'] = $lang['EMPTY_FIELDS'] . ' : [ ' . $lang['URL_F_FILE'] . ' ]';
}
if (ip('rmail') && !preg_match("/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,4})$/i", trim(strtolower(p('rmail')))) && $NOT_USER)
{
$ERRORS['rmail'] = $lang['WRONG_EMAIL'];
}
if (strlen(p('rtext')) > 300)
{
$ERRORS['rtext'] = $lang['NO_ME300RES'];
}
if (!ip('surl') && !ip('rid'))
{
$ERRORS['rid'] = $lang['NO_ID'];
}
is_array($plugin_run_result = Plugins::getInstance()->run('submit_report_go_page2', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//no error , lets do process
if(empty($ERRORS))
{
$name = $NOT_USER ? (string) $SQL->escape(p('rname')) : $usrcp->name();
$text = (string) $SQL->escape(p('rtext'));
$mail = $NOT_USER ? (string) strtolower(trim($SQL->escape(p('rmail')))) : $usrcp->mail();
$url = (string) ip('rid') ? $SQL->escape($url_id) : $SQL->real_escape(p('surl'));
$time = (int) time();
$rid = ip('rid') ? 0 : p('rid', 'int');
$ip = get_ip();
$insert_query = array(
'INSERT' => 'name ,mail ,url ,text ,time ,ip',
'INTO' => "{$dbprefix}reports",
'VALUES' => "'$name', '$mail', '$url', '$text', $time, '$ip'"
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_insert_new_report', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$SQL->build($insert_query);
//update number of reports
$update_query = array(
'UPDATE' => "{$dbprefix}files",
'SET' => 'report=report+1',
'WHERE' => 'id=' . $rid,
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_update_no_file_report', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$SQL->build($update_query);
$to = $config['sitemail2']; //administrator e-mail
$message = $text . "\n\n\n\n" . 'URL :' . $url . ' - TIME : ' . date('d-m-Y h:i a', $time) . ' - IP:' . $ip;
$subject = $lang['REPORT'];
send_mail($to, $message, $subject, $mail, $name);
kleeja_info($lang['THNX_REPORTED']);
}
}
is_array($plugin_run_result = Plugins::getInstance()->run('report_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
break;
//
//Pages of rules
//
case 'rules' :
$stylee = 'rules';
$titlee = $lang['RULES'];
$contents = strlen($ruless) > 3 ? stripslashes($ruless) : $lang['NO_RULES_NOW'];
is_array($plugin_run_result = Plugins::getInstance()->run('rules_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
break;
//
//Page of call-us
//
case 'call' :
//Not allowed to access this page ?
if (!user_can('access_call'))
{
is_array($plugin_run_result = Plugins::getInstance()->run('user_cannot_access_call', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
kleeja_info($lang['HV_NOT_PRVLG_ACCESS']);
}
//page info
$stylee = 'call';
$titlee = $lang['CALL'];
$action = './go.php?go=call';
$H_FORM_KEYS = kleeja_add_form_key('call');
$NOT_USER = !$usrcp->name() ? true : false;
//no error yet
$ERRORS = false;
//_post
$t_cname = p('cname');
$t_cmail = p('cmail');
$t_ctext = p('ctext');
is_array($plugin_run_result = Plugins::getInstance()->run('no_submit_call_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
if (ip('submit'))
{
//after sumit
$ERRORS = array();
is_array($plugin_run_result = Plugins::getInstance()->run('submit_call_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//check for form key
if(!kleeja_check_form_key('call'))
{
$ERRORS['form_key'] = $lang['INVALID_FORM_KEY'];
}
if(!kleeja_check_captcha())
{
$ERRORS['captcha'] = $lang['WRONG_VERTY_CODE'];
}
if ((empty(p('cname')) && $NOT_USER) || empty(p('ctext')) )
{
$ERRORS['cname'] = $lang['EMPTY_FIELDS'] . ' : ' . (empty(p('cname')) && $NOT_USER ? ' [ ' . $lang['YOURNAME'] . ' ] ' : '')
. (empty(p('ctext')) ? ' [ ' . $lang['TEXT'] . ' ] ': '');
}
if (ip('cmail') && !preg_match("/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,4})$/i", trim(strtolower(p('cmail')))) && $NOT_USER)
{
$ERRORS['cmail'] = $lang['WRONG_EMAIL'];
}
if (strlen(p('ctext')) > 300)
{
$ERRORS['ctext'] = $lang['NO_ME300TEXT'];
}
if($t_cname == '_kleeja_')
{
update_config('new_version', '');
}
is_array($plugin_run_result = Plugins::getInstance()->run('submit_call_go_page2', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//no errors ,lets do process
if(empty($ERRORS))
{
$name = $NOT_USER ? (string) $SQL->escape(p('cname')) : $usrcp->name();
$text = (string) $SQL->escape(p('ctext'));
$mail = $NOT_USER ? (string) strtolower(trim($SQL->escape(p('cmail')))) : $usrcp->mail();
$timee = (int) time();
$ip = get_ip();
$insert_query = array(
'INSERT' => "name ,text ,mail ,time ,ip",
'INTO' => "`{$dbprefix}call`",
'VALUES' => "'$name', '$text', '$mail', $timee, '$ip'"
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_insert_new_call', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
if ($SQL->build($insert_query))
{
send_mail($config['sitemail2'], $text . "\n\n\n\n" . 'TIME : ' . date('d-m-Y h:i a', $timee) . ' - IP:' . $ip, $lang['CALL'], $mail, $name);
kleeja_info($lang['THNX_CALLED']);
}
}
}
is_array($plugin_run_result = Plugins::getInstance()->run('call_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
break;
//
//Page for requesting delete file
//
case 'del' :
is_array($plugin_run_result = Plugins::getInstance()->run('del_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//stop .. check first ..
if (!$config['del_url_file'])
{
kleeja_info($lang['NO_DEL_F'], $lang['E_DEL_F']);
}
//examples :
//f2b3a82060a22a80283ed961d080b79f
//aa92468375a456de21d7ca05ef945212
//
$cd = preg_replace('/[^0-9a-z]/i', '', $SQL->escape(g('cd'))); // may.. will protect
if (empty($cd))
{
kleeja_err($lang['WRONG_URL']);
}
else
{
//to check
if(ig('sure') && g('sure') == 'ok')
{
$query = array(
'SELECT'=> 'f.id, f.name, f.folder, f.size, f.type',
'FROM' => "{$dbprefix}files f",
'WHERE' => "f.code_del='" . $cd . "'",
'LIMIT' => '1',
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_select_file_with_code_del', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$result = $SQL->build($query);
if ($SQL->num_rows($result) != 0)
{
while($row=$SQL->fetch_array($result))
{
@kleeja_unlink($row['folder'] . '/' . $row['name']);
//delete thumb
if (file_exists($row['folder'] . '/thumbs/' . $row['name']))
{
@kleeja_unlink($row['folder'] . '/thumbs/' . $row['name']);
}
$is_img = in_array($row['type'], array('png','gif','jpg','jpeg','tif','tiff', 'bmp')) ? true : false;
$query_del = array(
'DELETE' => "{$dbprefix}files",
'WHERE' => 'id=' . $row['id']
);
is_array($plugin_run_result = Plugins::getInstance()->run('qr_del_file_with_code_del', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
$SQL->build($query_del);
if($SQL->affected())
{
//update number of stats
$update_query = array(
'UPDATE' => "{$dbprefix}stats",
'SET' => ($is_img ? 'imgs=imgs-1':'files=files-1') . ',sizes=sizes-' . $row['size'],
);
$SQL->build($update_query);
kleeja_info($lang['DELETE_SUCCESFUL']);
}
else
{
kleeja_info($lang['ERROR_TRY_AGAIN']);
}
break;//to prevent divel actions
}
$SQL->freeresult($result);
}
}
else
{
//fix for IE+
$extra_codes = '<script type="text/javascript">
function confirm_from()
{
if(confirm(\'' . $lang['ARE_YOU_SURE_DO_THIS'] . '\')){
window.location = "go.php?go=del&sure=ok&cd=' . $cd . '";
}else{
window.location = "index.php";
}
}
window.onload=confirm_from;
</script>';
kleeja_info($lang['ARE_YOU_SURE_DO_THIS'], '', true, false, 0, $extra_codes);
}
}#else
break;
//
//Page of Kleeja stats
//
case 'stats' :
//Not allowed to access this page ?
if (!user_can('access_stats'))
{
is_array($plugin_run_result = Plugins::getInstance()->run('user_cannot_access_stats', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
kleeja_info($lang['HV_NOT_PRVLG_ACCESS']);
}
//stop .. check first ..
if (!$config['allow_stat_pg'])
{
kleeja_info($lang['STATS_CLOSED'], $lang['STATS_CLOSED']);
}
//stats of most online users
if(empty($config['most_user_online_ever']) || trim($config['most_user_online_ever']) == '')
{
$most_online = 1;// 1 == you
$on_muoe = time();
}
else
{
list($most_online, $on_muoe) = @explode(':', $config['most_user_online_ever']);
}
//ok .. go on
$titlee = $lang['STATS'];
$stylee = 'stats';
$files_st = $stat_files;
$imgs_st = $stat_imgs;
$users_st = $stat_users;
$sizes_st = readable_size($stat_sizes);
$lst_dl_st = (int) $config['del_f_day'] <= 0 ? false : kleeja_date($stat_last_f_del);
$lst_reg = empty($stat_last_user) ? $lang['UNKNOWN'] : $stat_last_user;
$on_muoe = kleeja_date($on_muoe);
is_array($plugin_run_result = Plugins::getInstance()->run('stats_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
break;
//
// Page for redirect to downloading a file
// [!] depreacted from 1rc6+, see do.php
//
case 'down':
//go.php?go=down&n=$1&f=$2&i=$3
if(ig('n'))
{
$url_file = (int) $config['mod_writer'] == 1 ? $config['siteurl'] . 'download' . g('i', 'int') . '.html' : $config['siteurl'] . 'do.php?id=' . g('n', 'int');
}
else
{
$url_file = $config['siteurl'];
}
$SQL->close();
redirect($url_file);
exit;
break;
//
// for queue
//
case 'queue':
#img header and print spacer gif
header('Cache-Control: no-cache');
header('Content-type: image/gif');
header('Content-length: 43');
echo base64_decode('R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==');
#do some of the queue ..
if(preg_match('/:del_[a-z0-9]{0,3}calls:/i', $config['queue']))
{
klj_clean_old('call', (strpos(':del_allcalls:', $config['queue']) !== false ? 'all': 30));
}
elseif(preg_match('/:del_[a-z0-9]{0,3}reports:/i', $config['queue']))
{
klj_clean_old('reports', (strpos(':del_allreports:', $config['queue']) !== false ? 'all': 30));
}
elseif((int) $config['del_f_day'] > 0)
{
klj_clean_old_files($config['klj_clean_files_from']);
}
is_array($plugin_run_result = Plugins::getInstance()->run('go_queue', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
#end
$SQL->close();
exit;
break;
//
//this is a part of ACP, only admins can access this part of page
//
case 'resync':
if(!user_can('enter_acp'))
{
kleeja_info($lang['HV_NOT_PRVLG_ACCESS']);
exit;
}
#get admin functions
include 'includes/functions_adm.php';
#get admin langauge
get_lang('acp');
switch(g('case')):
//
//re-sync total files number ..
//
case 'sync_files':
#no start ? or there
$start = !ig('start') ? false : g('start', 'int');
$end = sync_total_files(true, $start);
#no end, then sync'ing is done...
if(!$end)
{
delete_cache('data_stats');
$text = $title = sprintf($lang['SYNCING_DONE'], $lang['ALL_FILES']);
$link_to_go = './admin/?cp=r_repair#!cp=r_repair';
}
else
{
$text = $title = sprintf($lang['SYNCING'], $lang['ALL_FILES']) . ' (' . (!$start ? 0 : $start) . '->' . (!$end ? '?' : $end) . ')';
$link_to_go = './go.php?go=resync&case=sync_files&start=' . $end;
}
//to be sure !
$text .= '<script type="text/javascript"> setTimeout("location.href=\'' . $link_to_go . '\';", 3000);</script>' . "\n";
kleeja_info($text, $title, true, $link_to_go, 2);
break;
//
//re-sync total images number ..
//
case 'sync_images':
#no start ? or there
$start = !ig('start') ? false : g('start', 'int');
$end = sync_total_files(false, $start);
#no end, then sync'ing is done...
if(!$end)
{
delete_cache('data_stats');
$text = $title = sprintf($lang['SYNCING_DONE'], $lang['ALL_IMAGES']) . ' (' . (!$start ? 0 : $start) . '->' . (!$end ? '?' : $end) . ')';
$link_to_go = './admin/?cp=r_repair#!cp=r_repair';
}
else
{
$text = $title = sprintf($lang['SYNCING'], $lang['ALL_IMAGES']);
$link_to_go = './go.php?go=resync&case=sync_images&start=' . $end;
}
//to be sure !
$text .= '<script type="text/javascript"> setTimeout("location.href=\'' . $link_to_go . '\';", 3000);</script>' . "\n";
kleeja_info($text, $title, true, $link_to_go, 2);
break;
endswitch;
break;
/**
* Ajax get uploading progress
*/
case 'uploading_progress':
header('Content-type: application/json; charset=UTF-8');
$field_value = ig('value') ? g('value', 'int') : 0;
$result_data = array(
'current_progress' => 0,
);
// if($field_value == 0)
// {
// exit(json_encode($result_data));
// }
if(!function_exists('ini_get'))
{
exit(json_encode($result_data));
}
$key = ini_get("session.upload_progress.prefix") . $field_value;
$progress_session_info = empty($_SESSION[$key]) ? null : $_SESSION[$key];
if(empty($progress_session_info))
{
exit(json_encode($result_data));
}
$result_data['current_progress'] = ($progress_session_info['bytes_processed'] / $progress_session_info['content_length']) * 100;
exit(json_encode($result_data));
break;
//
// Default , if you are a developer , you can embed your page here with this hook
// by using g('go') and your codes.
//
default:
$no_request = true;
is_array($plugin_run_result = Plugins::getInstance()->run('default_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
if($no_request)
{
kleeja_err($lang['ERROR_NAVIGATATION']);
}
break;
}#end switch
is_array($plugin_run_result = Plugins::getInstance()->run('end_go_page', get_defined_vars())) ? extract($plugin_run_result) : null; //run hook
//no template ?
$stylee = empty($stylee) ? 'info' : $stylee;
$titlee = empty($titlee) ? '' : $titlee;
//header
Saaheader($titlee);
//tpl
echo $tpl->display($stylee);
//footer
Saafooter();

25
htaccess.txt Normal file
View File

@@ -0,0 +1,25 @@
#start Kleeja rules
<IfModule mod_rewrite.c>
RewriteEngine on
#RewriteBase /
RewriteRule ^index.html$ index.php
RewriteRule ^download([0-9]*).html$ do.php?id=$1
RewriteRule ^downloadf-(.*)-([a-zA-Z0-9_-]*).html$ do.php?filename=$1&x=$2
RewriteRule ^down-([0-9]*).html$ do.php?down=$1
RewriteRule ^downf-(.*)-([a-zA-Z0-9_-]*).html$ do.php?downf=$1&x=$2
RewriteRule ^downex-([0-9]*).html$ do.php?down=$1
RewriteRule ^downexf-(.*)-([a-zA-Z0-9_-]*).html$ do.php?downexf=$1&x=$2
RewriteRule ^thumb([0-9]*).html$ do.php?thmb=$1
RewriteRule ^imagef-(.*)-([a-zA-Z0-9_-]*).html$ do.php?imgf=$1&x=$2
RewriteRule ^thumbf-(.*)-([a-zA-Z0-9_-]*).html$ do.php?thmbf=$1&x=$2
RewriteRule ^image([0-9]*).html$ do.php?img=$1
RewriteRule ^del([a-zA-Z0-9_-]*).html$ go.php?go=del&cd=$1
RewriteRule ^(call|guide|rules|stats).html$ go.php?go=$1
RewriteRule ^report[_-]([0-9]*).html$ go.php?go=report&id=$1
RewriteRule ^(filecp|profile|fileuser|register|login|logout).html$ ucp.php?go=$1
RewriteRule ^fileuser[_-]([0-9]+).html$ ucp.php?go=fileuser&id=$1
RewriteRule ^fileuser[_-]([0-9]+)-([0-9]+).html$ ucp.php?go=fileuser&id=$1&page=$2
#for future plugins
RewriteRule ^go-(.*).html$ go.php?go=$1
</IfModule>
#end Kleeja rules

BIN
images/apple-touch-icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

BIN
images/banned_user.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

BIN
images/banned_user.psd Normal file

Binary file not shown.

BIN
images/favicon.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
images/favicon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
images/favicon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

BIN
images/filegroups/1.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

BIN
images/filegroups/10.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

BIN
images/filegroups/11.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

BIN
images/filegroups/2.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

BIN
images/filegroups/3.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

BIN
images/filegroups/4.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

BIN
images/filegroups/5.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

BIN
images/filegroups/6.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

BIN
images/filegroups/7.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

BIN
images/filegroups/8.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

BIN
images/filegroups/9.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

1
images/filegroups/index.html Executable file
View File

@@ -0,0 +1 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=windows-1256" /><title>Powered by Kleeja</title><style type="text/css">* {font-size: 100%;margin:0;padding: 0; color:#CECFCE;}body { font-family: Tahoma ,Arial, sans-serif;font-size: 100%;color: #69788E; margin: 10px 30px;background: #F7F7F7;}a:link, a:visited {text-decoration: none;color:#CECFCE;}a:active, a:hover {text-decoration: underline;color: #111;}h1 {font-family: "Trebuchet MS", Helvetica, sans-serif; font-size: 1.70em;font-weight: normal;color: #333333;margin-top: 0; margin-bottom: 10px;}.content_box {border: 1px dashed #CECFCE;background: #FFFFFF;padding: 10px;margin-right: auto;margin-left: auto;}</style> </head> <body title="&#1603;&#1604;&#1610;&#1580;&#1575;"><br /><div class="content_box"><p><a target="_blank" href="http://www.kleeja.com" title="kleeja"><img border="0" src="http://kleeja.com/index.png"></a></p><br /><h1><span style="font-size:250%;color:#D80000;">403 - Access forbidden!</span></h1></div><br /><div class="content_box"><span style="font-size: 140%">Powered by Kleeja &gt;&gt;&gt; the best uploader ...</span > >> <a target="_blank" href="http://www.kleeja.com/bugs/ar/">Bugs</a> | <a target="_blank" href="http://www.kleeja.com/plugins/">Plugins</a> | <a target="_blank" href="http://www.kleeja.com/styles/">Styles</a> | </div></body></html>

BIN
images/filetypes/3gp.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 639 B

BIN
images/filetypes/7z.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 159 B

BIN
images/filetypes/aep.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 707 B

BIN
images/filetypes/ai.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 665 B

BIN
images/filetypes/aiff.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 876 B

BIN
images/filetypes/ani.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 205 B

Some files were not shown because too many files have changed in this diff Show More