mirror of
https://github.com/slawkens/myaac.git
synced 2025-04-26 09:19:22 +02:00
* moved more templates to Twig
* now you can replace template in your main template, example is templates/kathrine/templates/success.html * removed output_errors, replace with template * some grammar fixes * moved some forum code to Twig templates * added movies link to tibiacom template
This commit is contained in:
parent
7620ec896b
commit
37502c5562
@ -751,28 +751,6 @@ function news_place()
|
||||
return $news;
|
||||
}
|
||||
|
||||
function output_errors($errors)
|
||||
{
|
||||
global $template_path;
|
||||
?>
|
||||
<div class="SmallBox" >
|
||||
<div class="MessageContainer" >
|
||||
<div class="BoxFrameHorizontal" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-horizontal.gif);" /></div>
|
||||
<div class="BoxFrameEdgeLeftTop" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></div>
|
||||
<div class="BoxFrameEdgeRightTop" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></div>
|
||||
<div class="ErrorMessage" >
|
||||
<div class="BoxFrameVerticalLeft" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-vertical.gif);" />
|
||||
</div>
|
||||
<div class="BoxFrameVerticalRight" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-vertical.gif);" /></div>
|
||||
<div class="AttentionSign" style="background-image:url(<?php echo $template_path; ?>/images/content/attentionsign.gif);" />
|
||||
</div><b>The Following Errors Have Occurred:</b><br/>
|
||||
<?php
|
||||
foreach($errors as $field => $message)
|
||||
echo $message . '<br/>';
|
||||
|
||||
echo '</div> <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> </div></div><br/>';
|
||||
}
|
||||
|
||||
/**
|
||||
* Template place holder
|
||||
*
|
||||
|
@ -30,9 +30,9 @@ $cache = Cache::getInstance($config['cache_engine'], $config['cache_prefix']);
|
||||
require_once LIBS . 'Twig/Autoloader.php';
|
||||
Twig_Autoloader::register();
|
||||
|
||||
$loader = new Twig_Loader_Filesystem(SYSTEM . 'templates');
|
||||
$twig = new Twig_Environment($loader, array(
|
||||
'cache' => CACHE . 'twig/',
|
||||
$twig_loader = new Twig_Loader_Filesystem(SYSTEM . 'templates');
|
||||
$twig = new Twig_Environment($twig_loader, array(
|
||||
'cache' => CACHE . 'twig/'
|
||||
));
|
||||
|
||||
$function = new Twig_SimpleFunction('getStyle', function ($i) {
|
||||
|
@ -27,7 +27,7 @@ if(!$logged)
|
||||
else
|
||||
{
|
||||
if(!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
|
||||
echo $twig->render('account.login.html', array(
|
||||
'redirect' => isset($_REQUEST['redirect']) ? $_REQUEST['redirect'] : null,
|
||||
@ -141,7 +141,7 @@ if(!$logged)
|
||||
$new_password2 = isset($_POST['newpassword2']) ? $_POST['newpassword2'] : NULL;
|
||||
$old_password = isset($_POST['oldpassword']) ? $_POST['oldpassword'] : NULL;
|
||||
if(empty($new_password) && empty($new_password2) && empty($old_password)) {
|
||||
echo $twig->render('account.changepassword.html');
|
||||
echo $twig->render('account.change_password.html');
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -177,7 +177,7 @@ if(!$logged)
|
||||
echo '</div> <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> </div></div><br/>';
|
||||
|
||||
//show form
|
||||
echo $twig->render('account.changepassword.html');
|
||||
echo $twig->render('account.change_password.html');
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -209,8 +209,9 @@ if(!$logged)
|
||||
$message = '<br/><p class="error">An error occorred while sending email with password:<br/>' . $mailer->ErrorInfo . '</p>';
|
||||
}
|
||||
|
||||
echo $twig->render('account.changepassword.success.html', array(
|
||||
'message' => $message
|
||||
echo $twig->render('success.html', array(
|
||||
'title' => 'Password Changed',
|
||||
'description' => 'Your password has been changed.' . $message
|
||||
));
|
||||
$_SESSION['password'] = $new_password;
|
||||
}
|
||||
@ -226,25 +227,25 @@ if(!$logged)
|
||||
$email_new = $_POST['new_email'];
|
||||
$post_password = $_POST['password'];
|
||||
if(empty($email_new)) {
|
||||
$change_email_errors[] = "Please enter your new email address.";
|
||||
$errors[] = "Please enter your new email address.";
|
||||
}
|
||||
else
|
||||
{
|
||||
if(!check_mail($email_new)) {
|
||||
$change_email_errors[] = "E-mail address is not correct.";
|
||||
$errors[] = "E-mail address is not correct.";
|
||||
}
|
||||
}
|
||||
if(empty($post_password)) {
|
||||
$change_email_errors[] = "Please enter password to your account.";
|
||||
$errors[] = "Please enter password to your account.";
|
||||
}
|
||||
else
|
||||
{
|
||||
$post_password = encrypt(($config_salt_enabled ? $account_logged->getCustomField('salt') : '') . $post_password);
|
||||
if($post_password != $account_logged->getPassword()) {
|
||||
$change_email_errors[] = "Wrong password to account.";
|
||||
$errors[] = "Wrong password to account.";
|
||||
}
|
||||
}
|
||||
if(empty($change_email_errors)) {
|
||||
if(empty($errors)) {
|
||||
$email_new_time = time() + $config['account_mail_change'] * 24 * 3600;
|
||||
$account_logged->setCustomField("email_new", $email_new);
|
||||
$account_logged->setCustomField("email_new_time", $email_new_time);
|
||||
@ -253,17 +254,17 @@ if(!$logged)
|
||||
else
|
||||
{
|
||||
//show errors
|
||||
echo $twig->render('account.error_box.html', array('errors' => $change_email_errors));
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
|
||||
//show form
|
||||
echo $twig->render('account.changemail.html', array(
|
||||
echo $twig->render('account.change_mail.html', array(
|
||||
'new_email' => isset($_POST['new_email']) ? $_POST['new_email'] : null
|
||||
));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
echo $twig->render('account.changemail.html', array(
|
||||
echo $twig->render('account.change_mail.html', array(
|
||||
'new_email' => isset($_POST['new_email']) ? $_POST['new_email'] : null
|
||||
));
|
||||
}
|
||||
@ -277,7 +278,11 @@ if(!$logged)
|
||||
$account_logged->setEmail($email_new);
|
||||
$account_logged->save();
|
||||
$account_logged->logAction('Account email changed to <b>' . $email_new . '</b>');
|
||||
echo '<div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Email Address Change Accepted</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" > <table style="width:100%;" ><tr><td>You have accepted <b>'.$account_logged->getEmail().'</b> as your new email adress.</td></tr> </table> </div> </table></div></td></tr><br/><center><table border="0" cellspacing="0" cellpadding="0" ><form action="?subtopic=accountmanagement" method="post" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$template_path.'/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></center>';
|
||||
|
||||
echo $twig->render('success.html', array(
|
||||
'title' => 'Email Address Change Accepted',
|
||||
'description' => 'You have accepted <b>' . $account_logged->getEmail() . '</b> as your new email adress.'
|
||||
));
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -298,114 +303,55 @@ if(!$logged)
|
||||
|
||||
//########### CHANGE PUBLIC INFORMATION (about account owner) ######################
|
||||
if($action == "changeinfo") {
|
||||
$show_form = true;
|
||||
$new_rlname = isset($_POST['info_rlname']) ? htmlspecialchars(stripslashes($_POST['info_rlname'])) : NULL;
|
||||
$new_location = isset($_POST['info_location']) ? htmlspecialchars(stripslashes($_POST['info_location'])) : NULL;
|
||||
$new_country = isset($_POST['info_country']) ? htmlspecialchars(stripslashes($_POST['info_country'])) : NULL;
|
||||
if(isset($_POST['changeinfosave']) && $_POST['changeinfosave'] == 1) {
|
||||
$errors = array();
|
||||
|
||||
if(!isset($config['countries'][$new_country]))
|
||||
$errors[] = 'Country is not correct.';
|
||||
|
||||
if(empty($errors)) {
|
||||
//save data from form
|
||||
$account_logged->setCustomField("rlname", $new_rlname);
|
||||
$account_logged->setCustomField("location", $new_location);
|
||||
$account_logged->setCustomField("country", $new_country);
|
||||
$account_logged->logAction('Changed Real Name to ' . $new_rlname . ', Location to ' . $new_location . ' and Country to ' . $config['countries'][$new_country] . '.');
|
||||
echo '<div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Public Information Changed</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" > <table style="width:100%;" ><tr><td>Your public information has been changed.</td></tr> </table> </div> </table></div></td></tr><br><center><table border="0" cellspacing="0" cellpadding="0" ><form action="?subtopic=accountmanagement" method="post" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$template_path.'/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></center>';
|
||||
echo $twig->render('success.html', array(
|
||||
'title' => 'Public Information Changed',
|
||||
'description' => 'Your public information has been changed.'
|
||||
));
|
||||
$show_form = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
else {
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
}
|
||||
}
|
||||
|
||||
//show form
|
||||
if($show_form) {
|
||||
$account_rlname = $account_logged->getCustomField("rlname");
|
||||
$account_location = $account_logged->getCustomField("location");
|
||||
if ($config['account_country'])
|
||||
$account_country = $account_logged->getCustomField("country");
|
||||
?>
|
||||
Here you can tell other players about yourself. This information will be displayed alongside the data of your characters. If you do not want to fill in a certain field, just leave it blank.<br/><br/>
|
||||
<form action="?subtopic=accountmanagement&action=changeinfo" method=post>
|
||||
<div class="TableContainer" >
|
||||
<table class="Table1" cellpadding="0" cellspacing="0" >
|
||||
<div class="CaptionContainer" >
|
||||
<div class="CaptionInnerContainer" >
|
||||
<span class="CaptionEdgeLeftTop" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightTop" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionBorderTop" style="background-image:url(<?php echo $template_path; ?>/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionVerticalLeft" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-vertical.gif);" /></span>
|
||||
<div class="Text" >Change Public Information</div>
|
||||
<span class="CaptionVerticalRight" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-vertical.gif);" /></span>
|
||||
<span class="CaptionBorderBottom" style="background-image:url(<?php echo $template_path; ?>/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionEdgeLeftBottom" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightBottom" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
</div>
|
||||
</div>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="InnerTableContainer" >
|
||||
<table style="width:100%;" >
|
||||
<tr>
|
||||
<td class="LabelV" >Real Name:</td>
|
||||
<td style="width:90%;" >
|
||||
<input name="info_rlname" value="<?php echo $account_rlname; ?>" size="30" maxlength="50" >
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="LabelV" >Location:</td>
|
||||
<td>
|
||||
<input name="info_location" value="<?php echo $account_location; ?>" size="30" maxlength="50" >
|
||||
</td>
|
||||
</tr>
|
||||
<?php if($config['account_country']): ?>
|
||||
<tr>
|
||||
<td class="LabelV" >Country:</td>
|
||||
<td>
|
||||
<select name="info_country" id="account_country">
|
||||
<?php
|
||||
|
||||
$countries = array();
|
||||
foreach (array('pl', 'se', 'br', 'us', 'gb',) as $country)
|
||||
echo '<option value="' . $country . '">' . $config['countries'][$country] . '</option>';
|
||||
$countries[$country] = $config['countries'][$country];
|
||||
|
||||
$countries['--'] = '----------';
|
||||
|
||||
echo '<option value="">----------</option>';
|
||||
foreach ($config['countries'] as $code => $country)
|
||||
echo '<option value="' . $code . '"' . ($account_country == $code ? ' selected' : '') . '>' . $country . '</option>';
|
||||
?>
|
||||
</select>
|
||||
<img src="" id="account_country_img"/>
|
||||
<script>
|
||||
function updateFlag()
|
||||
{
|
||||
var img = $('#account_country_img');
|
||||
var country = $('#account_country :selected').val();
|
||||
if(country.length) {
|
||||
img.attr('src', 'images/flags/' + country + '.gif');
|
||||
img.show();
|
||||
}
|
||||
else {
|
||||
img.hide();
|
||||
}
|
||||
}
|
||||
$countries[$code] = $country;
|
||||
|
||||
$(function() {
|
||||
updateFlag();
|
||||
$('#account_country').change(function() {
|
||||
updateFlag();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</table>
|
||||
</div> </table></div></td></tr><br/>
|
||||
<table width="100%">
|
||||
<tr align="center"><td><table border="0" cellspacing="0" cellpadding="0" ><tr>
|
||||
<td style="border:0px;" >
|
||||
<input type="hidden" name="changeinfosave" value="1" >
|
||||
<div class="BigButton" style="background-image:url(<?php echo $template_path; ?>/images/buttons/sbutton.gif)" >
|
||||
<div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" >
|
||||
<div class="BigButtonOver" style="background-image:url(<?php echo $template_path; ?>/images/buttons/sbutton_over.gif);" ></div>
|
||||
<input class="ButtonText" type="image" name="Submit" alt="Submit" src="<?php echo $template_path; ?>/images/buttons/_sbutton_submit.gif" ></div></div>
|
||||
</td><tr></form></table></td><td><table border="0" cellspacing="0" cellpadding="0" >
|
||||
<form action="?subtopic=accountmanagement" method="post" >
|
||||
<tr><td style="border:0px;" ><div class="BigButton" style="background-image:url(<?php echo $template_path; ?>/images/buttons/sbutton.gif)" >
|
||||
<div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" >
|
||||
<div class="BigButtonOver" style="background-image:url(<?php echo $template_path; ?>/images/buttons/sbutton_over.gif);" ></div>
|
||||
<input class="ButtonText" type="image" name="Back" alt="Back" src="<?php echo $template_path; ?>/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></td></tr></table>
|
||||
<?php
|
||||
echo $twig->render('account.change_info.html', array(
|
||||
'countries' => $countries,
|
||||
'account_rlname' => $account_rlname,
|
||||
'account_location' => $account_location,
|
||||
'account_country' => $account_country
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
@ -448,7 +394,7 @@ if(!$logged)
|
||||
if(!empty($reg_errors))
|
||||
{
|
||||
//show errors
|
||||
echo $twig->render('account.error_box.html', array('errors' => $reg_errors));
|
||||
echo $twig->render('error_box.html', array('errors' => $reg_errors));
|
||||
}
|
||||
|
||||
//show form
|
||||
@ -628,11 +574,7 @@ if(!$logged)
|
||||
|
||||
if(!$name_changed) {
|
||||
if(!empty($errors)) {
|
||||
echo '<div class="SmallBox" > <div class="MessageContainer" > <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="ErrorMessage" > <div class="BoxFrameVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="BoxFrameVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="AttentionSign" style="background-image:url('.$template_path.'/images/content/attentionsign.gif);" /></div><b>The Following Errors Have Occurred:</b><br/>';
|
||||
foreach($errors as $errors) {
|
||||
echo '<li>'.$errors;
|
||||
}
|
||||
echo '</div> <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> </div></div><br/>';
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
}
|
||||
echo 'To change a name of character select player and choose a new name.<br/>
|
||||
<font color="red">Change name cost ' . $config['account_change_character_name_points'] . ' premium points. You have ' . $points . ' premium points.</font><br/><br/><form action="?subtopic=accountmanagement&action=changename" method="post" ><input type="hidden" name="changenamesave" value="1"><div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Change Name</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" >
|
||||
@ -673,16 +615,19 @@ if(!$logged)
|
||||
$points = $account_logged->getCustomField('premium_points');
|
||||
if(isset($_POST['changesexsave']) && $_POST['changesexsave'] == 1) {
|
||||
if($points < $config['account_change_character_sex_points'])
|
||||
$errors[] = 'You need ' . $config['account_change_character_sex_points'] . ' premium points to change sex. You have <b>'.$points.'<b> premium points.';
|
||||
$errors[] = 'You need ' . $config['account_change_character_sex_points'] . ' premium points to change sex. You have <b>'.$points.'</b> premium points.';
|
||||
|
||||
if(empty($errors) && $new_sex != 0 && $new_sex != 1)
|
||||
if(empty($errors) && !isset($config['genders'][$new_sex])) {
|
||||
$errors[] = 'This sex is invalid.';
|
||||
}
|
||||
|
||||
if(empty($errors)) {
|
||||
$player = $ots->createObject('Player');
|
||||
$player = new OTS_Player();
|
||||
$player->load($player_id);
|
||||
|
||||
if($player->isLoaded()) {
|
||||
$player_account = $player->getAccount();
|
||||
|
||||
if($account_logged->getId() == $player_account->getId()) {
|
||||
if($player->isOnline()) {
|
||||
$errors[] = 'This character is online.';
|
||||
@ -707,55 +652,32 @@ if(!$logged)
|
||||
$player->save();
|
||||
$account_logged->setCustomField("premium_points", $points - $config['account_change_character_name_points']);
|
||||
$account_logged->logAction('Changed sex on character <b>' . $player->getName() . '</b> from <b>' . $old_sex_str . '</b> to <b>' . $new_sex_str . '</b>.');
|
||||
echo '<div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Character Sex Changed</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" > <table style="width:100%;" ><tr><td>The character <b>'.$player->getName().'</b> sex has been changed to <b>' . $sexes[$new_sex] . '</b>.</td></tr> </table> </div> </table></div></td></tr><br><center><table border="0" cellspacing="0" cellpadding="0" ><form action="?subtopic=accountmanagement" method="post" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$template_path.'/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></center>';
|
||||
echo $twig->render('success.html', array(
|
||||
'title' => 'Character Sex Changed',
|
||||
'description' => 'The character <b>' . $player->getName() . '</b> sex has been changed to <b>' . $new_sex_str . '</b>.'
|
||||
));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
else {
|
||||
$errors[] = 'Character <b>'.$player_name.'</b> is not on your account.';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$errors[] = 'Character with this name doesn\'t exist.';
|
||||
else {
|
||||
$errors[] = "Character with this name doesn't exist.";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(!$sex_changed) {
|
||||
if(!empty($errors)) {
|
||||
echo '<div class="SmallBox" > <div class="MessageContainer" > <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="ErrorMessage" > <div class="BoxFrameVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="BoxFrameVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="AttentionSign" style="background-image:url('.$template_path.'/images/content/attentionsign.gif);" /></div><b>The Following Errors Have Occurred:</b><br/>';
|
||||
foreach($errors as $errors) {
|
||||
echo '<li>'.$errors;
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
}
|
||||
echo '</div> <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> </div></div><br/>';
|
||||
}
|
||||
echo 'To change a sex of character select player and choose a new sex.<br/>
|
||||
<font color="red">Change sex cost ' . $config['account_change_character_sex_points'] . ' premium points. You have ' . $points . ' premium points.</font><br/><br/><form action="?subtopic=accountmanagement&action=changesex" method="post" ><input type="hidden" name="changesexsave" value="1"><div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Change sex</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" >
|
||||
<table style="width:100%;" >
|
||||
<tr>
|
||||
<td class="LabelV" ><span >Character:</td>
|
||||
<td style="width:90%;" >
|
||||
<select name="player_id">';
|
||||
$players = $account_logged->getPlayersList();
|
||||
foreach($players as $player)
|
||||
echo '<option value="' . $player->getId() . '">' . $player->getName() . '</option>';
|
||||
echo '
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="LabelV" ><span >New Sex:</td>
|
||||
<td>
|
||||
<select name="new_sex">';
|
||||
foreach($config['genders'] as $id => $name) {
|
||||
echo '<option value="' . $id . '"' . ($player->getSex() == $id ? ' selected' : '') . '>' . $name . '</option>';
|
||||
}
|
||||
echo '
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table> </div> </table></div></td></tr><br/><table style="width:100%" ><tr align="center" ><td><table border="0" cellspacing="0" cellpadding="0" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Submit" alt="Submit" src="'.$template_path.'/images/buttons/_sbutton_submit.gif" ></div></div></td><tr></form></table></td><td><table border="0" cellspacing="0" cellpadding="0" ><form action="?subtopic=accountmanagement" method="post" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$template_path.'/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></td></tr></table>';
|
||||
echo $twig->render('account.change_sex.html', array(
|
||||
'config' => $config,
|
||||
'players' => $account_logged->getPlayersList(),
|
||||
'player_sex' => isset($player) ? $player->getSex() : -1,
|
||||
'points' => $points
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -767,7 +689,7 @@ if(!$logged)
|
||||
if(isset($_POST['deletecharactersave']) && $_POST['deletecharactersave'] == 1) {
|
||||
if(!empty($player_name) && !empty($password_verify)) {
|
||||
if(check_name($player_name)) {
|
||||
$player = $ots->createObject('Player');
|
||||
$player = new OTS_Player();
|
||||
$player->find($player_name);
|
||||
if($player->isLoaded()) {
|
||||
$player_account = $player->getAccount();
|
||||
@ -783,45 +705,39 @@ if(!$logged)
|
||||
else
|
||||
$player->setCustomField('deleted', 1);
|
||||
$account_logged->logAction('Deleted character <b>' . $player->getName() . '</b>.');
|
||||
echo '<div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Character Deleted</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" > <table style="width:100%;" ><tr><td>The character <b>'.$player_name.'</b> has been deleted.</td></tr> </table> </div> </table></div></td></tr><br><center><table border="0" cellspacing="0" cellpadding="0" ><form action="?subtopic=accountmanagement" method="post" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$template_path.'/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></center>';
|
||||
echo $twig->render('success.html', array(
|
||||
'title' => 'Character Deleted',
|
||||
'description' => 'The character <b>' . $player_name . '</b> has been deleted.'
|
||||
));
|
||||
}
|
||||
else
|
||||
$delete_errors[] = 'This character is online.';
|
||||
$errors[] = 'This character is online.';
|
||||
}
|
||||
else
|
||||
{
|
||||
$delete_errors[] = 'Wrong password to account.';
|
||||
else {
|
||||
$errors[] = 'Wrong password to account.';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$delete_errors[] = 'Character <b>'.$player_name.'</b> is not on your account.';
|
||||
else {
|
||||
$errors[] = 'Character <b>'.$player_name.'</b> is not on your account.';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$delete_errors[] = 'Character with this name doesn\'t exist.';
|
||||
else {
|
||||
$errors[] = 'Character with this name doesn\'t exist.';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$delete_errors[] = 'Name contain illegal characters.';
|
||||
else {
|
||||
$errors[] = 'Name contain illegal characters.';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$delete_errors[] = 'Character name or/and password is empty. Please fill in form.';
|
||||
else {
|
||||
$errors[] = 'Character name or/and password is empty. Please fill in form.';
|
||||
}
|
||||
}
|
||||
if(!$dontshowtableagain) {
|
||||
if(!empty($delete_errors)) {
|
||||
echo '<div class="SmallBox" > <div class="MessageContainer" > <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="ErrorMessage" > <div class="BoxFrameVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="BoxFrameVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="AttentionSign" style="background-image:url('.$template_path.'/images/content/attentionsign.gif);" /></div><b>The Following Errors Have Occurred:</b><br/>';
|
||||
foreach($delete_errors as $delete_error) {
|
||||
echo '<li>'.$delete_error;
|
||||
if(!empty($errors)) {
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
}
|
||||
echo '</div> <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> </div></div><br/>';
|
||||
}
|
||||
echo 'To delete a character enter the name of the character and your password.<br/><br/><form action="?subtopic=accountmanagement&action=deletecharacter" method="post" ><input type="hidden" name="deletecharactersave" value="1"><div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Delete Character</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" > <table style="width:100%;" ><tr><td class="LabelV" ><span >Character Name:</td><td style="width:90%;" ><input name="delete_name" value="" size="30" maxlength="29" ></td></tr><tr><td class="LabelV" ><span >Password:</td><td><input type="password" name="delete_password" size="30" maxlength="29" ></td></tr> </table> </div> </table></div></td></tr><br/><table style="width:100%" ><tr align="center" ><td><table border="0" cellspacing="0" cellpadding="0" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Submit" alt="Submit" src="'.$template_path.'/images/buttons/_sbutton_submit.gif" ></div></div></td><tr></form></table></td><td><table border="0" cellspacing="0" cellpadding="0" ><form action="?subtopic=accountmanagement" method="post" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$template_path.'/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></td></tr></table>';
|
||||
echo $twig->render('account.delete_character.html');
|
||||
}
|
||||
}
|
||||
|
||||
@ -974,7 +890,7 @@ if(!$logged)
|
||||
$newchar_created = true;
|
||||
$account_logged->logAction('Created character <b>' . $player->getName() . '</b>.');
|
||||
unset($player);
|
||||
$player = $ots->createObject('Player');
|
||||
$player = new OTS_Player();
|
||||
$player->find($newchar_name);
|
||||
if($player->isLoaded())
|
||||
{
|
||||
@ -992,7 +908,13 @@ if(!$logged)
|
||||
$loaded_items_to_copy = $db->query("SELECT * FROM player_items WHERE player_id = ".$char_to_copy->getId()."");
|
||||
foreach($loaded_items_to_copy as $save_item)
|
||||
$db->query("INSERT INTO `player_items` (`player_id` ,`pid` ,`sid` ,`itemtype`, `count`, `attributes`) VALUES ('".$player->getId()."', '".$save_item['pid']."', '".$save_item['sid']."', '".$save_item['itemtype']."', '".$save_item['count']."', '".$save_item['attributes']."');");
|
||||
echo '<div class="TableContainer" > <table class="Table1" cellpadding="0" cellspacing="0" > <div class="CaptionContainer" > <div class="CaptionInnerContainer" > <span class="CaptionEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionBorderTop" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <div class="Text" >Character Created</div> <span class="CaptionVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></span> <span class="CaptionBorderBottom" style="background-image:url('.$template_path.'/images/content/table-headline-border.gif);" ></span> <span class="CaptionEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> <span class="CaptionEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></span> </div> </div> <tr> <td> <div class="InnerTableContainer" > <table style="width:100%;" ><tr><td>The character <b>'.$newchar_name.'</b> has been created.<br/>Please select the outfit when you log in for the first time.<br/><br/><b>See you on '.$config['lua']['serverName'].'!</b></td></tr> </table> </div> </table></div></td></tr><br/><center><table border="0" cellspacing="0" cellpadding="0" ><form action="?subtopic=accountmanagement" method="post" ><tr><td style="border:0px;" ><div class="BigButton" style="background-image:url('.$template_path.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$template_path.'/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></center>';
|
||||
|
||||
echo $twig->render('success.html', array(
|
||||
'title' => 'Character Created',
|
||||
'description' => 'The character <b>' . $newchar_name . '</b> has been created.<br/>
|
||||
Please select the outfit when you log in for the first time.<br/><br/>
|
||||
<b>See you on ' . $config['lua']['serverName'] . '!</b>'
|
||||
));
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -1003,11 +925,7 @@ if(!$logged)
|
||||
}
|
||||
|
||||
if(count($newchar_errors) > 0) {
|
||||
echo '<div class="SmallBox" > <div class="MessageContainer" > <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeLeftTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeRightTop" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="ErrorMessage" > <div class="BoxFrameVerticalLeft" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="BoxFrameVerticalRight" style="background-image:url('.$template_path.'/images/content/box-frame-vertical.gif);" /></div> <div class="AttentionSign" style="background-image:url('.$template_path.'/images/content/attentionsign.gif);" /></div>';
|
||||
echo '<b>The Following Errors Have Occurred:</b><br/>';
|
||||
foreach($newchar_errors as $newchar_error)
|
||||
echo '<li>'.$newchar_error . '</li>';
|
||||
echo '</div> <div class="BoxFrameHorizontal" style="background-image:url('.$template_path.'/images/content/box-frame-horizontal.gif);" /></div> <div class="BoxFrameEdgeRightBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> <div class="BoxFrameEdgeLeftBottom" style="background-image:url('.$template_path.'/images/content/box-frame-edge.gif);" /></div> </div></div><br/>';
|
||||
echo $twig->render('error_box.html', array('errors' => $newchar_errors));
|
||||
}
|
||||
|
||||
if(!$newchar_created) {
|
||||
|
@ -81,7 +81,7 @@ if(!empty($action))
|
||||
}
|
||||
|
||||
if(!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
}
|
||||
?>
|
||||
<?php
|
||||
|
@ -677,7 +677,7 @@ WHERE killers.death_id = '".$death['id']."' ORDER BY killers.final_hit DESC, kil
|
||||
else
|
||||
{
|
||||
$search_errors[] = 'Character <b>' . $name . '</b> does not exist or has been deleted.';
|
||||
output_errors($search_errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $search_errors));
|
||||
$search_errors = array();
|
||||
|
||||
$promotion = '';
|
||||
@ -706,4 +706,4 @@ else
|
||||
}
|
||||
|
||||
if(!empty($search_errors))
|
||||
output_errors($search_errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $search_errors));
|
@ -69,7 +69,7 @@ if($canEdit)
|
||||
}
|
||||
|
||||
if(!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
}
|
||||
|
||||
echo $twig->render('commands.form.html', array(
|
||||
|
@ -37,7 +37,9 @@ if($step == 'save')
|
||||
|
||||
// account
|
||||
if(isset($account_id)) {
|
||||
if(!check_number($account_id))
|
||||
if(empty($account_id))
|
||||
$errors['account'] = 'Please enter your account number!';
|
||||
else if(!check_number($account_id))
|
||||
$errors['account'] = 'Invalid account number format. Please use only numbers 0-9.';
|
||||
}
|
||||
else {
|
||||
@ -50,11 +52,8 @@ if($step == 'save')
|
||||
// email
|
||||
if(empty($email))
|
||||
$errors['email'] = 'Please enter your email address!';
|
||||
else
|
||||
{
|
||||
if(!check_mail($email))
|
||||
$errors['email'] = 'E-mail address is not correct.';
|
||||
}
|
||||
else if(!check_mail($email))
|
||||
$errors['email'] = 'Email address is not correct.';
|
||||
|
||||
// country
|
||||
$country = '';
|
||||
@ -62,7 +61,7 @@ if($step == 'save')
|
||||
{
|
||||
$country = $_POST['country'];
|
||||
if(!isset($country))
|
||||
$errors['country'] = 'Country is not set';
|
||||
$errors['country'] = 'Country is not set.';
|
||||
elseif(!isset($config['countries'][$country]))
|
||||
$errors['country'] = 'Country is invalid.';
|
||||
}
|
||||
@ -74,10 +73,10 @@ if($step == 'save')
|
||||
$verifyResponse = file_get_contents('https://www.google.com/recaptcha/api/siteverify?secret='.$config['recaptcha_secret_key'].'&response='.$_POST['g-recaptcha-response']);
|
||||
$responseData = json_decode($verifyResponse);
|
||||
if(!$responseData->success)
|
||||
$errors['verification'] = 'Please confirm that your not a robot.';
|
||||
$errors['verification'] = "Please confirm that you're not a robot.";
|
||||
}
|
||||
else
|
||||
$errors['verification'] = 'Please confirm that your not a robot.';
|
||||
$errors['verification'] = "Please confirm that you're not a robot.";
|
||||
}
|
||||
|
||||
// password
|
||||
@ -393,7 +392,7 @@ function validate_form(thisform)
|
||||
}
|
||||
|
||||
if(!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
?>
|
||||
To play on <?php echo $config['lua']['serverName']; ?> you need an account.
|
||||
All you have to do to create your new account is to enter an account <?php echo (USE_ACCOUNT_NAME ? 'name' : 'number'); ?>, password<?php
|
||||
|
@ -28,6 +28,7 @@ $sections = array();
|
||||
foreach(getForumSections() as $section)
|
||||
{
|
||||
$sections[$section['id']] = array(
|
||||
'id' => $section['id'],
|
||||
'name' => $section['name'],
|
||||
'description' => $section['description'],
|
||||
'closed' => $section['closed'] == '1'
|
||||
@ -130,22 +131,33 @@ if(!$logged)
|
||||
$number_of_rows = 0;
|
||||
if(empty($action))
|
||||
{
|
||||
echo '<b>Boards</b>';
|
||||
echo '<table width="100%"><tr bgcolor="'.$config['vdarkborder'].'"><td><font color="white" size="1"><b>Board</b></font></td><td><font color="white" size="1"><b>Posts</b></font></td><td><font color="white" size="1"><b>Threads</b></font></td><td align="center"><font color="white" size="1"><b>Last Post</b></font></td></tr>';
|
||||
$info = $db->query("SELECT `section`, COUNT(`id`) AS 'threads', SUM(`replies`) AS 'replies' FROM `" . TABLE_PREFIX . "forum` WHERE `first_post` = `id` GROUP BY `section`")->fetchAll();
|
||||
|
||||
$boards = array();
|
||||
foreach($info as $data)
|
||||
$counters[$data['section']] = array('threads' => $data['threads'], 'posts' => $data['replies'] + $data['threads']);
|
||||
foreach($sections as $id => $section)
|
||||
{
|
||||
$last_post = $db->query("SELECT `players`.`name`, `" . TABLE_PREFIX . "forum`.`post_date` FROM `players`, `" . TABLE_PREFIX . "forum` WHERE `" . TABLE_PREFIX . "forum`.`section` = ".(int) $id." AND `players`.`id` = `" . TABLE_PREFIX . "forum`.`author_guid` ORDER BY `post_date` DESC LIMIT 1")->fetch();
|
||||
echo '<tr bgcolor="'.getStyle(++$number_of_rows).'"><td><a href="' . getForumBoardLink($id) . '">'.$section['name'].'</a><br /><small>'.$section['description'].'</small></td><td>'.(int) (isset($counters[$id]['posts']) ? $counters[$id]['posts'] : 0).'</td><td>'.(int) (isset($counters[$id]['threads']) ? $counters[$id]['threads'] : 0).'</td><td>';
|
||||
if(isset($last_post['name']))
|
||||
echo date('d.m.y H:i:s', $last_post['post_date']).'<br />by ' . getPlayerLink($last_post['name']);
|
||||
else
|
||||
echo 'No posts';
|
||||
echo '</td></tr>';
|
||||
$boards[] = array(
|
||||
'link' => getForumBoardLink($id),
|
||||
'name' => $section['name'],
|
||||
'description' => $section['description'],
|
||||
'posts' => isset($counters[$id]['posts']) ? $counters[$id]['posts'] : 0,
|
||||
'threads' => isset($counters[$id]['threads']) ? $counters[$id]['threads'] : 0,
|
||||
'last_post' => array(
|
||||
'name' => isset($last_post['name']) ? $last_post['name'] : null,
|
||||
'date' => isset($last_post['post_date']) ? $last_post['post_date'] : null,
|
||||
'player_link' => isset($last_post['name']) ? getPlayerLink($last_post['name']) : null,
|
||||
)
|
||||
);
|
||||
}
|
||||
echo '</table>';
|
||||
|
||||
echo $twig->render('forum.boards.html', array(
|
||||
'boards' => $boards,
|
||||
'config' => $config
|
||||
));
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@ -166,7 +178,7 @@ if($action == 'show_board')
|
||||
if(!$sections[$section_id]['closed'] || Forum::isModerator())
|
||||
{
|
||||
echo '<br /><br />
|
||||
<a href="?subtopic=forum&action=new_topic§ion_id='.$section_id.'"><img src="images/forum/topic.gif" border="0" /></a>';
|
||||
<a href="?subtopic=forum&action=new_thread§ion_id='.$section_id.'"><img src="images/forum/topic.gif" border="0" /></a>';
|
||||
}
|
||||
|
||||
echo '<br /><br />Page: '.$links_to_pages.'<br />';
|
||||
@ -175,7 +187,7 @@ if($action == 'show_board')
|
||||
{
|
||||
echo '<table width="100%"><tr bgcolor="'.$config['vdarkborder'].'" align="center"><td><font color="white" size="1"><b>Thread</b></font></td><td><font color="white" size="1"><b>Thread Starter</b></font></td><td><font color="white" size="1"><b>Replies</b></font></td><td><font color="white" size="1"><b>Views</b></font></td><td><font color="white" size="1"><b>Last Post</b></font></td></tr>';
|
||||
|
||||
$player = $ots->createObject('Player');
|
||||
$player = new OTS_Player();
|
||||
foreach($last_threads as $thread)
|
||||
{
|
||||
echo '<tr bgcolor="' . getStyle($number_of_rows++) . '"><td>';
|
||||
@ -209,7 +221,7 @@ if($action == 'show_board')
|
||||
}
|
||||
echo '</table>';
|
||||
if(!$sections[$section_id]['closed'] || Forum::isModerator())
|
||||
echo '<br /><a href="?subtopic=forum&action=new_topic§ion_id='.$section_id.'"><img src="images/forum/topic.gif" border="0" /></a>';
|
||||
echo '<br /><a href="?subtopic=forum&action=new_thread§ion_id='.$section_id.'"><img src="images/forum/topic.gif" border="0" /></a>';
|
||||
}
|
||||
else
|
||||
echo '<h3>No threads in this board.</h3>';
|
||||
@ -392,7 +404,7 @@ if($action == 'new_post')
|
||||
if(!$saved)
|
||||
{
|
||||
if(!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
|
||||
echo '<form action="?" method="POST">
|
||||
<input type="hidden" name="action" value="new_post" />
|
||||
@ -508,7 +520,7 @@ if($action == 'edit_post')
|
||||
if(!$saved)
|
||||
{
|
||||
if(!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
|
||||
echo '<br /><form action="?" method="POST"><input type="hidden" name="action" value="edit_post" /><input type="hidden" name="id" value="'.$post_id.'" /><input type="hidden" name="subtopic" value="forum" /><input type="hidden" name="save" value="save" /><table width="100%"><tr bgcolor="'.$config['vdarkborder'].'"><td colspan="2"><font color="white"><b>Edit Post</b></font></td></tr><tr bgcolor="'.$config['darkborder'].'"><td width="180"><b>Character:</b></td><td><select name="char_id"><option value="0">(Choose character)</option>';
|
||||
foreach($players_from_account as $player)
|
||||
@ -536,99 +548,94 @@ if($action == 'edit_post')
|
||||
echo '<br />Your account is banned, deleted or you don\'t have any player with level '.$config['forum_level_required'].' on your account. You can\'t post.';
|
||||
}
|
||||
|
||||
if($action == 'new_topic')
|
||||
if($action == 'new_thread')
|
||||
{
|
||||
if(Forum::canPost($account_logged))
|
||||
{
|
||||
$players_from_account = $db->query("SELECT `players`.`name`, `players`.`id` FROM `players` WHERE `players`.`account_id` = ".(int) $account_logged->getId())->fetchAll();
|
||||
$section_id = (int) $_REQUEST['section_id'];
|
||||
$players_from_account = $db->query('SELECT `players`.`name`, `players`.`id` FROM `players` WHERE `players`.`account_id` = '.(int) $account_logged->getId())->fetchAll();
|
||||
$section_id = isset($_REQUEST['section_id']) ? $_REQUEST['section_id'] : null;
|
||||
if($section_id !== null) {
|
||||
echo '<a href="' . getPageLink('forum') . '">Boards</a> >> <a href="' . getForumBoardLink($section_id) . '">' . $sections[$section_id]['name'] . '</a> >> <b>Post new thread</b><br />';
|
||||
if(isset($sections[$section_id]['name']))
|
||||
{
|
||||
if (isset($sections[$section_id]['name'])) {
|
||||
if ($sections[$section_id]['closed'] && !Forum::isModerator())
|
||||
$errors[] = 'You cannot create topic on this board.';
|
||||
|
||||
$quote = (int)(isset($_REQUEST['quote']) ? $_REQUEST['quote'] : 0);
|
||||
$text = isset($_REQUEST['text']) ? stripslashes(trim($_REQUEST['text'])) : '';
|
||||
$text = isset($_REQUEST['text']) ? stripslashes($_REQUEST['text']) : '';
|
||||
$char_id = (int)(isset($_REQUEST['char_id']) ? $_REQUEST['char_id'] : 0);
|
||||
$post_topic = isset($_REQUEST['topic']) ? stripslashes(trim($_REQUEST['topic'])) : '';
|
||||
$post_topic = isset($_REQUEST['topic']) ? stripslashes($_REQUEST['topic']) : '';
|
||||
$smile = (int)(isset($_REQUEST['smile']) ? $_REQUEST['smile'] : 0);
|
||||
$saved = false;
|
||||
if(isset($_REQUEST['save']))
|
||||
{
|
||||
if (isset($_REQUEST['save'])) {
|
||||
$errors = array();
|
||||
|
||||
$lenght = 0;
|
||||
for($i = 0; $i < strlen($post_topic); $i++)
|
||||
{
|
||||
for ($i = 0; $i < strlen($post_topic); $i++) {
|
||||
if (ord($post_topic[$i]) >= 33 && ord($post_topic[$i]) <= 126)
|
||||
$lenght++;
|
||||
}
|
||||
if ($lenght < 1 || strlen($post_topic) > 60)
|
||||
$errors[] = 'Too short or too long topic (short: ' . $lenght . ' long: ' . strlen($post_topic) . ' letters). Minimum 1 letter, maximum 60 letters.';
|
||||
$lenght = 0;
|
||||
for($i = 0; $i < strlen($text); $i++)
|
||||
{
|
||||
for ($i = 0; $i < strlen($text); $i++) {
|
||||
if (ord($text[$i]) >= 33 && ord($text[$i]) <= 126)
|
||||
$lenght++;
|
||||
}
|
||||
if ($lenght < 1 || strlen($text) > 15000)
|
||||
$errors[] = 'Too short or too long post (short: ' . $lenght . ' long: ' . strlen($text) . ' letters). Minimum 1 letter, maximum 15000 letters.';
|
||||
|
||||
if ($char_id == 0)
|
||||
$errors[] = 'Please select a character.';
|
||||
$player_on_account = false;
|
||||
if(count($errors) == 0)
|
||||
{
|
||||
|
||||
if (count($errors) == 0) {
|
||||
foreach ($players_from_account as $player)
|
||||
if ($char_id == $player['id'])
|
||||
$player_on_account = true;
|
||||
if (!$player_on_account)
|
||||
$errors[] = 'Player with selected ID ' . $char_id . ' doesn\'t exist or isn\'t on your account';
|
||||
}
|
||||
if(count($errors) == 0)
|
||||
{
|
||||
|
||||
if (count($errors) == 0) {
|
||||
$last_post = 0;
|
||||
$query = $db->query('SELECT post_date FROM ' . TABLE_PREFIX . 'forum ORDER BY post_date DESC LIMIT 1');
|
||||
if($query->rowCount() > 0)
|
||||
{
|
||||
$query = $db->query('SELECT `post_date` FROM `' . TABLE_PREFIX . 'forum` ORDER BY `post_date` DESC LIMIT 1');
|
||||
if ($query->rowCount() > 0) {
|
||||
$query = $query->fetch();
|
||||
$last_post = $query['post_date'];
|
||||
}
|
||||
if ($last_post + $config['forum_post_interval'] - time() > 0 && !Forum::isModerator())
|
||||
$errors[] = 'You can post one time per ' . $config['forum_post_interval'] . ' seconds. Next post after ' . ($last_post + $config['forum_post_interval'] - time()) . ' second(s).';
|
||||
}
|
||||
if(count($errors) == 0)
|
||||
{
|
||||
if (count($errors) == 0) {
|
||||
$saved = true;
|
||||
$db->query("INSERT INTO `" . TABLE_PREFIX . "forum` (`id` ,`first_post` ,`last_post` ,`section` ,`replies` ,`views` ,`author_aid` ,`author_guid` ,`post_text` ,`post_topic` ,`post_smile` ,`post_date` ,`last_edit_aid` ,`edit_date`, `post_ip`) VALUES ('null', '0', '".time()."', '".(int) $section_id."', '0', '0', '".$account_logged->getId()."', '".(int) $char_id."', ".$db->quote($text).", ".$db->quote($post_topic).", '".(int) $smile."', '".time()."', '0', '0', '".$_SERVER['REMOTE_ADDR']."')");
|
||||
$db->query("INSERT INTO `" . TABLE_PREFIX . "forum` (`first_post` ,`last_post` ,`section` ,`replies` ,`views` ,`author_aid` ,`author_guid` ,`post_text` ,`post_topic` ,`post_smile` ,`post_date` ,`last_edit_aid` ,`edit_date`, `post_ip`) VALUES ('0', '" . time() . "', '" . (int)$section_id . "', '0', '0', '" . $account_logged->getId() . "', '" . (int)$char_id . "', " . $db->quote($text) . ", " . $db->quote($post_topic) . ", '" . (int)$smile . "', '" . time() . "', '0', '0', '" . $_SERVER['REMOTE_ADDR'] . "')");
|
||||
$thread_id = $db->lastInsertId();
|
||||
$db->query("UPDATE `" . TABLE_PREFIX . "forum` SET `first_post`=" . (int)$thread_id . " WHERE `id` = " . (int)$thread_id);
|
||||
header('Location: ' . getForumThreadLink($thread_id));
|
||||
echo '<br />Thank you for posting.<br /><a href="' . getForumThreadLink($thread_id) . '">GO BACK TO LAST THREAD</a>';
|
||||
}
|
||||
}
|
||||
if(!$saved)
|
||||
{
|
||||
if (!$saved) {
|
||||
if (!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
|
||||
echo '<form action="?" method="POST"><input type="hidden" name="action" value="new_topic" /><input type="hidden" name="section_id" value="'.$section_id.'" /><input type="hidden" name="subtopic" value="forum" /><input type="hidden" name="save" value="save" /><table width="100%"><tr bgcolor="'.$config['vdarkborder'].'"><td colspan="2"><font color="white"><b>Post New Reply</b></font></td></tr><tr bgcolor="'.$config['darkborder'].'"><td width="180"><b>Character:</b></td><td><select name="char_id"><option value="0">(Choose character)</option>';
|
||||
foreach($players_from_account as $player)
|
||||
{
|
||||
echo '<option value="'.$player['id'].'"';
|
||||
if($player['id'] == $char_id)
|
||||
echo ' selected="selected"';
|
||||
echo '>'.$player['name'].'</option>';
|
||||
}
|
||||
echo '</select></td></tr><tr bgcolor="'.$config['lightborder'].'"><td><b>Topic:</b></td><td><input type="text" name="topic" value="'.htmlspecialchars($post_topic).'" size="40" maxlength="60" /> (Optional)</td></tr>
|
||||
<tr bgcolor="'.$config['darkborder'].'"><td valign="top"><b>Message:</b><font size="1"><br />You can use:<br />[player]Nick[/player]<br />[url]http://address.com/[/url]<br />[img]http://images.com/images3.gif[/img]<br />[code]Code[/code]<br />[b]<b>Text</b>[/b]<br />[i]<i>Text</i>[/i]<br />[u]<u>Text</u>[/u]<br />and smileys:<br />;) , :) , :D , :( , :rolleyes:<br />:cool: , :eek: , :o , :p</font></td><td><textarea rows="10" cols="60" name="text">'.htmlspecialchars($text).'</textarea><br />(Max. 15,000 letters)</td></tr>
|
||||
<tr bgcolor="'.$config['lightborder'].'"><td valign="top">Options:</td><td><label><input type="checkbox" name="smile" value="1"';
|
||||
if($smile == 1)
|
||||
echo ' checked="checked"';
|
||||
echo '/>Disable Smileys in This Post </label></td></tr></table><center><input type="submit" value="Post Thread" /></center></form>';
|
||||
echo $twig->render('forum.new_thread.html', array(
|
||||
'section_id' => $section_id,
|
||||
'config' => $config,
|
||||
'players' => $players_from_account,
|
||||
'post_player_id' => $char_id,
|
||||
'post_thread' => $post_topic,
|
||||
'text' => $text,
|
||||
'smiles_enabled' => $smile > 0
|
||||
));
|
||||
}
|
||||
}
|
||||
else
|
||||
echo 'Board with ID ' . $board_id . ' doesn\'t exist.';
|
||||
}
|
||||
else
|
||||
echo 'Please enter section_id.';
|
||||
}
|
||||
else
|
||||
echo 'Your account is banned, deleted or you don\'t have any player with level '.$config['forum_level_required'].' on your account. You can\'t post.';
|
||||
}
|
||||
@ -645,6 +652,17 @@ if($action == 'move_thread')
|
||||
{
|
||||
if($post['id'] == $post['first_post'])
|
||||
{
|
||||
echo $twig->render('forum.move_thread.html', array(
|
||||
'thread' => $post['post_topic'],
|
||||
'author' => $name[0],
|
||||
'board' => $sections[$post['section']]['name'],
|
||||
'post_id' => $post['id'],
|
||||
'sections' => $sections,
|
||||
'section_link' => getForumBoardLink($post['section']),
|
||||
'config' => $config
|
||||
));
|
||||
|
||||
/*
|
||||
echo '<br/><table bgcolor='.$config['vdarkborder'].' border=0 cellpadding=2 cellspacing=0 width=100%>
|
||||
<tr bgcolor='.$config['vdarkborder'].'><td class=white colspan=5><B>Move thread to another board</B></td></tr>
|
||||
<tr><td><table border=0 cellpadding=3 cellspacing=1 width=100%>
|
||||
@ -656,11 +674,11 @@ if($action == 'move_thread')
|
||||
<strong>THREAD:</strong> '.$post['post_topic'].'
|
||||
<br/><strong>AUTHOR:</strong> '.$name[0].'
|
||||
<br/><strong>BOARD:</strong> '.$sections[$post['section']]['name'].'<br/>
|
||||
<br/><strong>Select the new board: </strong><SELECT NAME=sektion>';
|
||||
<br/><strong>Select the new board: </strong><SELECT NAME=section>';
|
||||
foreach($sections as $id => $section) { echo '<OPTION value="'.$id.'">'.$section['name'].'</OPTION>'; } echo '</SELECT>
|
||||
<INPUT TYPE="submit" VALUE="Move Thread"></FORM>
|
||||
<form action="' . getForumBoardLink($post['section']) . '" method="POST">
|
||||
<input type="submit" value="Cancel"></form></td></tr></table></td></tr></table>';
|
||||
<input type="submit" value="Cancel"></form></td></tr></table></td></tr></table>';*/
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -675,7 +693,7 @@ if($action == 'moved_thread')
|
||||
if(Forum::isModerator())
|
||||
{
|
||||
$id = (int) $_REQUEST['id'];
|
||||
$board = (int) $_REQUEST['sektion'];
|
||||
$board = (int) $_REQUEST['section'];
|
||||
$post = $db->query("SELECT `id`, `first_post`, `section` FROM `" . TABLE_PREFIX . "forum` WHERE `id` = ".$id." LIMIT 1")->fetch();
|
||||
if($post['id'] == $id)
|
||||
{
|
||||
@ -707,10 +725,8 @@ class Forum
|
||||
|
||||
return
|
||||
$db->query(
|
||||
'SELECT ' . $db->fieldName('id') .
|
||||
' FROM ' . $db->tableName('players') .
|
||||
' WHERE ' . $db->fieldName('account_id') . ' = ' . $db->quote($account->getId()) .
|
||||
' AND ' . $db->fieldName('level') . ' >= ' . $db->quote($config['forum_level_required']) .
|
||||
'SELECT `id` FROM `players` WHERE `account_id` = ' . $db->quote($account->getId()) .
|
||||
' AND `level` >= ' . $db->quote($config['forum_level_required']) .
|
||||
' LIMIT 1')->rowCount() > 0;
|
||||
}
|
||||
|
||||
|
@ -11,7 +11,7 @@
|
||||
defined('MYAAC') or die('Direct access not allowed!');
|
||||
$title = 'Movies';
|
||||
|
||||
$movies = $db->query('SELECT * FROM ' . $db->tableName(TABLE_PREFIX . 'movies') . ' ORDER BY ' . $db->fieldName('ordering'));
|
||||
$movies = $db->query('SELECT * FROM `' . TABLE_PREFIX . 'movies` ORDER BY `ordering`;');
|
||||
if(!$movies->rowCount())
|
||||
{
|
||||
?>
|
||||
@ -22,10 +22,10 @@ There are no movies added yet.
|
||||
return;
|
||||
}
|
||||
?>
|
||||
<center>
|
||||
<div style="text-align: center;">
|
||||
<?php foreach($movies as $movie): ?>
|
||||
<?php echo $movie['title']; ?><br/>
|
||||
Author: <?php echo $movie['author']; ?><br/>
|
||||
<iframe width="560" height="315" src="https://www.youtube.com/embed/<?php echo $movie['youtube_id']; ?>" frameborder="0" allowfullscreen></iframe><br/><br/>
|
||||
<?php endforeach; ?>
|
||||
</center>
|
||||
</div>
|
||||
|
@ -151,7 +151,7 @@ if($canEdit)
|
||||
}
|
||||
|
||||
if(!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
|
||||
if($cache->enabled())
|
||||
{
|
||||
|
@ -53,7 +53,7 @@ if($canEdit) {
|
||||
}
|
||||
|
||||
if (!empty($errors))
|
||||
output_errors($errors);
|
||||
echo $twig->render('error_box.html', array('errors' => $errors));
|
||||
}
|
||||
|
||||
echo $twig->render('screenshots.form.html', array(
|
||||
|
@ -94,4 +94,6 @@ if($config['forum'] != '')
|
||||
}
|
||||
|
||||
$twig->addGlobal('template_path', $template_path);
|
||||
if($twig_loader && file_exists(BASE . $template_path . '/templates'))
|
||||
$twig_loader->prependPath(BASE . $template_path . '/templates');
|
||||
?>
|
||||
|
83
system/templates/account.change_info.html
Normal file
83
system/templates/account.change_info.html
Normal file
@ -0,0 +1,83 @@
|
||||
Here you can tell other players about yourself. This information will be displayed alongside the data of your characters. If you do not want to fill in a certain field, just leave it blank.<br/><br/>
|
||||
<form action="?subtopic=accountmanagement&action=changeinfo" method=post>
|
||||
<div class="TableContainer" >
|
||||
<table class="Table1" cellpadding="0" cellspacing="0" >
|
||||
<div class="CaptionContainer" >
|
||||
<div class="CaptionInnerContainer" >
|
||||
<span class="CaptionEdgeLeftTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionBorderTop" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionVerticalLeft" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);" /></span>
|
||||
<div class="Text" >Change Public Information</div>
|
||||
<span class="CaptionVerticalRight" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);" /></span>
|
||||
<span class="CaptionBorderBottom" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionEdgeLeftBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
</div>
|
||||
</div>
|
||||
<tr>
|
||||
<td>{{ config.darkborder }}
|
||||
<div class="InnerTableContainer" >
|
||||
<table style="width:100%;" >
|
||||
<tr>
|
||||
<td class="LabelV" >Real Name:</td>
|
||||
<td style="width:90%;" >
|
||||
<input name="info_rlname" value="{{ account_rlname }}" size="30" maxlength="50" >
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="LabelV" >Location:</td>
|
||||
<td>
|
||||
<input name="info_location" value="{{ account_location }}" size="30" maxlength="50" >
|
||||
</td>
|
||||
</tr>
|
||||
{% if config.account_country %}
|
||||
<tr>
|
||||
<td class="LabelV" >Country:</td>
|
||||
<td>
|
||||
<select name="info_country" id="account_country">
|
||||
{% for code, country in countries %}
|
||||
<option value="{{ code}}"{% if account_country == code %} selected{% endif %}>{{ country }} </option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<img src="" id="account_country_img"/>
|
||||
<script>
|
||||
function updateFlag()
|
||||
{
|
||||
var img = $('#account_country_img');
|
||||
var country = $('#account_country :selected').val();
|
||||
if(country.length) {
|
||||
img.attr('src', 'images/flags/' + country + '.gif');
|
||||
img.show();
|
||||
}
|
||||
else {
|
||||
img.hide();
|
||||
}
|
||||
}
|
||||
|
||||
$(function() {
|
||||
updateFlag();
|
||||
$('#account_country').change(function() {
|
||||
updateFlag();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
</table>
|
||||
</div> </table></div></td></tr><br/>
|
||||
<table width="100%">
|
||||
<tr align="center"><td><table border="0" cellspacing="0" cellpadding="0" ><tr>
|
||||
<td style="border:0px;" >
|
||||
<input type="hidden" name="changeinfosave" value="1" >
|
||||
<div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" >
|
||||
<div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" >
|
||||
<div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div>
|
||||
<input class="ButtonText" type="image" name="Submit" alt="Submit" src="{{ template_path }}/images/buttons/_sbutton_submit.gif" ></div></div>
|
||||
</td><tr></form></table></td><td><table border="0" cellspacing="0" cellpadding="0" >
|
||||
<form action="?subtopic=accountmanagement" method="post" >
|
||||
<tr><td style="border:0px;" ><div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" >
|
||||
<div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" >
|
||||
<div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div>
|
||||
<input class="ButtonText" type="image" name="Back" alt="Back" src="{{ template_path }}/images/buttons/_sbutton_back.gif" ></div></div></td></tr></form></table></td></tr></table>
|
78
system/templates/account.change_sex.html
Normal file
78
system/templates/account.change_sex.html
Normal file
@ -0,0 +1,78 @@
|
||||
To change a sex of character select player and choose a new sex.<br/>
|
||||
<font color="red">Change sex cost {{ config.account_change_character_sex_points }} premium points. You have {{ points }} premium points.</font><br/><br/>
|
||||
<form action="?subtopic=accountmanagement&action=changesex" method="post">
|
||||
<input type="hidden" name="changesexsave" value="1"/>
|
||||
<div class="TableContainer">
|
||||
<table class="Table1" cellpadding="0" cellspacing="0">
|
||||
<div class="CaptionContainer">
|
||||
<div class="CaptionInnerContainer">
|
||||
<span class="CaptionEdgeLeftTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
<span class="CaptionEdgeRightTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
<span class="CaptionBorderTop" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);"></span>
|
||||
<span class="CaptionVerticalLeft" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);"></span>
|
||||
<div class="Text" >Change sex</div>
|
||||
<span class="CaptionVerticalRight" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);"></span>
|
||||
<span class="CaptionBorderBottom" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionEdgeLeftBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
</div>
|
||||
</div>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="InnerTableContainer">
|
||||
<table style="width:100%;" >
|
||||
<tr>
|
||||
<td class="LabelV" ><span >Character:</td>
|
||||
<td style="width:90%;" >
|
||||
<select name="player_id">
|
||||
{% for player in players %}
|
||||
<option value="{{ player.getId() }}">{{ player.getName() }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="LabelV" ><span >New Sex:</td>
|
||||
<td>
|
||||
<select name="new_sex">
|
||||
{% for id, gender in config.genders %}
|
||||
<option value="{{ id }}"{% if player_sex == id %} selected{% endif %}>{{ gender }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<br/>
|
||||
<table style="width:100%">
|
||||
<tr align="center">
|
||||
<td>
|
||||
<table border="0" cellspacing="0" cellpadding="0" >
|
||||
<tr>
|
||||
<td style="border:0px;" >
|
||||
<div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Submit" alt="Submit" src="{{ template_path }}/images/buttons/_sbutton_submit.gif" ></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
</form>
|
||||
</table>
|
||||
</td>
|
||||
<td>
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<form action="?subtopic=accountmanagement" method="post">
|
||||
<tr>
|
||||
<td style="border:0px;" >
|
||||
<div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="{{ template_path }}/images/buttons/_sbutton_back.gif" ></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
68
system/templates/account.delete_character.html
Normal file
68
system/templates/account.delete_character.html
Normal file
@ -0,0 +1,68 @@
|
||||
To delete a character enter the name of the character and your password.<br/><br/>
|
||||
<form action="?subtopic=accountmanagement&action=deletecharacter" method="post">
|
||||
<input type="hidden" name="deletecharactersave" value="1"/>
|
||||
<div class="TableContainer">
|
||||
<table class="Table1" cellpadding="0" cellspacing="0" >
|
||||
<div class="CaptionContainer">
|
||||
<div class="CaptionInnerContainer">
|
||||
<span class="CaptionEdgeLeftTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
<span class="CaptionEdgeRightTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
<span class="CaptionBorderTop" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);"></span>
|
||||
<span class="CaptionVerticalLeft" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);"></span>
|
||||
<div class="Text" >Delete Character</div>
|
||||
<span class="CaptionVerticalRight" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);"></span>
|
||||
<span class="CaptionBorderBottom" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);"></span>
|
||||
<span class="CaptionEdgeLeftBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
<span class="CaptionEdgeRightBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
</div>
|
||||
</div>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="InnerTableContainer">
|
||||
<table style="width:100%;">
|
||||
<tr>
|
||||
<td class="LabelV" ><span>Character Name:</span></td>
|
||||
<td style="width:90%;">
|
||||
<input name="delete_name" value="" size="30" maxlength="29"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="LabelV" ><span>Password:</span></td>
|
||||
<td>
|
||||
<input type="password" name="delete_password" size="30" maxlength="29"/>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<br/>
|
||||
<table style="width:100%">
|
||||
<tr align="center">
|
||||
<td>
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td style="border:0px;">
|
||||
<div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Submit" alt="Submit" src="{{ template_path }}/images/buttons/_sbutton_submit.gif" ></div>
|
||||
</div>
|
||||
</td>
|
||||
<tr>
|
||||
</form>
|
||||
</table>
|
||||
</td>
|
||||
<td>
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<form action="?subtopic=accountmanagement" method="post">
|
||||
<tr>
|
||||
<td style="border:0px;">
|
||||
<div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="{{ template_path }}/images/buttons/_sbutton_back.gif" ></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
@ -1,4 +1,4 @@
|
||||
Please enter your account name and your password.<br/><a href="?subtopic=createaccount" >Create an account</a> if you do not have one yet.<br/><br/>
|
||||
Please enter your account {{ account|lower }} and your password.<br/><a href="?subtopic=createaccount" >Create an account</a> if you do not have one yet.<br/><br/>
|
||||
<form action="?subtopic=accountmanagement" method="post" >
|
||||
{% if redirect is not null %}
|
||||
<input type="hidden" name="redirect" value="{{ redirect }}" />
|
||||
@ -7,15 +7,15 @@ Please enter your account name and your password.<br/><a href="?subtopic=createa
|
||||
<table class="Table1" cellpadding="0" cellspacing="0" >
|
||||
<div class="CaptionContainer" >
|
||||
<div class="CaptionInnerContainer" >
|
||||
<span class="CaptionEdgeLeftTop" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightTop" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionBorderTop" style="background-image:url(<?php echo $template_path; ?>/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionVerticalLeft" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-vertical.gif);" /></span>
|
||||
<span class="CaptionEdgeLeftTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionBorderTop" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionVerticalLeft" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);" /></span>
|
||||
<div class="Text" >Account Login</div>
|
||||
<span class="CaptionVerticalRight" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-vertical.gif);" /></span>
|
||||
<span class="CaptionBorderBottom" style="background-image:url(<?php echo $template_path; ?>/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionEdgeLeftBottom" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightBottom" style="background-image:url(<?php echo $template_path; ?>/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionVerticalRight" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);" /></span>
|
||||
<span class="CaptionBorderBottom" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);" ></span>
|
||||
<span class="CaptionEdgeLeftBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
<span class="CaptionEdgeRightBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);" /></span>
|
||||
</div>
|
||||
</div>
|
||||
<tr>
|
||||
|
@ -484,8 +484,7 @@
|
||||
<table border="0" cellspacing="0" cellpadding="0" >
|
||||
<form action="?subtopic=accountmanagement&action=changename" method="post" >
|
||||
<tr>
|
||||
<td style="border:0px;" ><div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div>
|
||||
<input class="ButtonText" type="image" name="Change Name" alt="Change Name" src="images/buttons/_sbutton_change_name.gif" ></div>
|
||||
<td style="border:0px;" ><div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Change Name" alt="Change Name" src="images/buttons/_sbutton_change_name.gif" ></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
@ -498,8 +497,7 @@
|
||||
<table border="0" cellspacing="0" cellpadding="0" >
|
||||
<form action="?subtopic=accountmanagement&action=changesex" method="post" >
|
||||
<tr>
|
||||
<td style="border:0px;" ><div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div>
|
||||
<input class="ButtonText" type="image" name="Change Sex" alt="Change Sex" src="images/buttons/_sbutton_change_sex.gif" ></div>
|
||||
<td style="border:0px;" ><div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$template_path.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Change Sex" alt="Change Sex" src="images/buttons/_sbutton_change_sex.gif" ></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
@ -9,7 +9,7 @@
|
||||
<div class="AttentionSign" style="background-image:url({{ template_path }}/images/content/attentionsign.gif);"></div>
|
||||
<b>The Following Errors Have Occurred:</b><br/>
|
||||
{% for error in errors %}
|
||||
<li>{{ error }}</li>
|
||||
<li>{{ error|raw }}</li>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div class="BoxFrameHorizontal" style="background-image:url({{ template_path }}/images/content/box-frame-horizontal.gif);"></div>
|
35
system/templates/forum.boards.html
Normal file
35
system/templates/forum.boards.html
Normal file
@ -0,0 +1,35 @@
|
||||
<b>Boards</b>
|
||||
<table width="100%">
|
||||
<tr bgcolor="{{ config.vdarkborder }}">
|
||||
<td>
|
||||
<font color="white" size="1"><b>Board</b></font>
|
||||
</td>
|
||||
<td>
|
||||
<font color="white" size="1"><b>Posts</b></font>
|
||||
</td>
|
||||
<td>
|
||||
<font color="white" size="1"><b>Threads</b></font>
|
||||
</td>
|
||||
<td align="center">
|
||||
<font color="white" size="1"><b>Last Post</b></font>
|
||||
</td>
|
||||
</tr>
|
||||
{% set i = 0 %}
|
||||
{% for board in boards %}
|
||||
{% set i = i + 1 %}
|
||||
<tr bgcolor="{{ getStyle(i) }}">
|
||||
<td>
|
||||
<a href="{{ board.link }}">{{ board.name }}</a><br /><small>{{ board.description }}</small>
|
||||
</td>
|
||||
<td>{{ board.posts }}</td>
|
||||
<td>{{ board.threads }}</td>
|
||||
<td>
|
||||
{% if board.last_post.name is not null %}
|
||||
{{ board.last_post.date|date("d.m.y H:i:s") }}<br/>by {{ board.last_post.player_link|raw }}
|
||||
{% else %}
|
||||
No posts
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
34
system/templates/forum.move_thread.html
Normal file
34
system/templates/forum.move_thread.html
Normal file
@ -0,0 +1,34 @@
|
||||
<br/>
|
||||
<table bgcolor="{{ config.vdarkborder }}" border="0" cellpadding="2" cellspacing="0" width="100%">
|
||||
<tr bgcolor="{{ config.vdarkborder }}">
|
||||
<td class="white" colspan="5"><b>Move thread to another board</b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<table border="0" cellpadding="3" cellspacing="1" width="100%">
|
||||
<tr bgcolor="{{ config.lightborder }}">
|
||||
<td>
|
||||
<form action="" method="get">
|
||||
<input type="hidden" name="subtopic" value="forum" />
|
||||
<input type="hidden" name="action" value="moved_thread" />
|
||||
<input type="hidden" name="id" value="{{ post_id }}" />
|
||||
<strong>THREAD:</strong> {{ thread }}<br/>
|
||||
<strong>AUTHOR:</strong> {{ author }}<br/>
|
||||
<strong>BOARD:</strong> {{ board }}<br/><br/>
|
||||
<strong>Select the new board: </strong>
|
||||
<select name="section">
|
||||
{% for section in sections %}
|
||||
<option value="{{ section.id }}">{{ section.name }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<input type="submit" value="Move Thread">
|
||||
</form>
|
||||
<form action="{{ section_link }}" method="post">
|
||||
<input type="submit" value="Cancel">
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
39
system/templates/forum.new_thread.html
Normal file
39
system/templates/forum.new_thread.html
Normal file
@ -0,0 +1,39 @@
|
||||
<form action="?" method="post">
|
||||
<input type="hidden" name="action" value="new_topic" />
|
||||
<input type="hidden" name="section_id" value="{{ section_id }}" />
|
||||
<input type="hidden" name="subtopic" value="forum" />
|
||||
<input type="hidden" name="save" value="save" />
|
||||
<table width="100%">
|
||||
<tr bgcolor="{{ config.vdarkborder }}">
|
||||
<td colspan="2">
|
||||
<font color="white"><b>Post New Reply</b></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr bgcolor="{{ config.darkborder }}">
|
||||
<td width="180"><b>Character:</b></td>
|
||||
<td>
|
||||
<select name="char_id"><option value="0">(Choose character)</option>
|
||||
{% for player in players %}
|
||||
<option value="{{ player.id }}"
|
||||
{% if player.id == post_player_id %} selected="selected"{% endif %}>{{ player.name }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr bgcolor="{{ config.lightborder }}">
|
||||
<td><b>Topic:</b></td>
|
||||
<td><input type="text" name="topic" value="{{ post_thread|escape }}" size="40" maxlength="60" /> (Optional)</td>
|
||||
</tr>
|
||||
<tr bgcolor="{{ config.darkborder }}">
|
||||
<td valign="top"><b>Message:</b><font size="1"><br />You can use:<br />[player]Nick[/player]<br />[url]http://address.com/[/url]<br />[img]http://images.com/images3.gif[/img]<br />[code]Code[/code]<br />[b]<b>Text</b>[/b]<br />[i]<i>Text</i>[/i]<br />[u]<u>Text</u>[/u]<br />and smileys:<br />;) , :) , :D , :( , :rolleyes:<br />:cool: , :eek: , :o , :p</font></td>
|
||||
<td><textarea rows="10" cols="60" name="text">{{ text|escape }}</textarea><br />(Max. 15,000 letters)</td>
|
||||
</tr>
|
||||
<tr bgcolor="{{ config.lightborder }}">
|
||||
<td valign="top">Options:</td>
|
||||
<td><label><input type="checkbox" name="smile" value="1"{% if smiles_enabled %} checked="checked"{% endif %}/>Disable Smileys in This Post </label></td>
|
||||
</tr>
|
||||
</table>
|
||||
<center>
|
||||
<input type="submit" value="Post Thread" />
|
||||
</center>
|
||||
</form>
|
@ -6,7 +6,7 @@
|
||||
<span class="CaptionEdgeRightTop" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
<span class="CaptionBorderTop" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);"></span>
|
||||
<span class="CaptionVerticalLeft" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);"></span>
|
||||
<div class="Text" >Password Changed</div>
|
||||
<div class="Text" >{{ title }}</div>
|
||||
<span class="CaptionVerticalRight" style="background-image:url({{ template_path }}/images/content/box-frame-vertical.gif);"></span>
|
||||
<span class="CaptionBorderBottom" style="background-image:url({{ template_path }}/images/content/table-headline-border.gif);"></span>
|
||||
<span class="CaptionEdgeLeftBottom" style="background-image:url({{ template_path }}/images/content/box-frame-edge.gif);"></span>
|
||||
@ -18,7 +18,7 @@
|
||||
<div class="InnerTableContainer">
|
||||
<table style="width:100%;">
|
||||
<tr>
|
||||
<td>Your password has been changed.{{ message|raw }}</td>
|
||||
<td>{{ description|raw }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
@ -32,9 +32,7 @@
|
||||
<form action="?subtopic=accountmanagement" method="post">
|
||||
<tr>
|
||||
<td style="border:0px;">
|
||||
<div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)">
|
||||
<div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="{{ template_path }}/images/buttons/_sbutton_back.gif" >
|
||||
</div>
|
||||
<div class="BigButton" style="background-image:url({{ template_path }}/images/buttons/sbutton.gif)"><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url({{ template_path }}/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="{{ template_path }}/images/buttons/_sbutton_back.gif" ></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
13
templates/kathrine/templates/success.html
Normal file
13
templates/kathrine/templates/success.html
Normal file
@ -0,0 +1,13 @@
|
||||
<h2>{{ title }}</h2><br/>
|
||||
{{ description|raw }}
|
||||
<div style="text-align: center; margin: 0 auto;">
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<form action="?subtopic=accountmanagement" method="post">
|
||||
<tr>
|
||||
<td style="border:0px; text-align: center;">
|
||||
<input type="submit" name="Back" value="Back"/>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
</table>
|
||||
</div>
|
@ -568,7 +568,14 @@ endif;
|
||||
<div class='RightChain' style='background-image:url(<?php echo $template_path; ?>/images/general/chain.gif);'></div>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
<a href="<?php echo $template['link_movies']; ?>">
|
||||
<div id='submenu_movies' class='Submenuitem' onMouseOver='MouseOverSubmenuItem(this)' onMouseOut='MouseOutSubmenuItem(this)'>
|
||||
<div class='LeftChain' style='background-image:url(<?php echo $template_path; ?>/images/general/chain.gif);'></div>
|
||||
<div id='ActiveSubmenuItemIcon_movies' class='ActiveSubmenuItemIcon' style='background-image:url(<?php echo $template_path; ?>/images/menu/icon-activesubmenu.gif);'></div>
|
||||
<div class='SubmenuitemLabel'>Movies</div>
|
||||
<div class='RightChain' style='background-image:url(<?php echo $template_path; ?>/images/general/chain.gif);'></div>
|
||||
</div>
|
||||
</a>
|
||||
<?php
|
||||
if(isset($config['movies'])): ?>
|
||||
echo "<a href='<?php echo $template['link_movies']; ?>'>
|
||||
|
Loading…
x
Reference in New Issue
Block a user