You are on page 1of 2

<?php if($this->session->userdata('userid') == 1) { ?

>

<?php } ?>

<?php if(!$this->session->userdata('loggedIn')) { ?>

<?php } else { ?>

<?php } ?>

<?php if($first_condition){ ?>


/*$first_condition is true*/
<?php }else if ($second_condition){ ?>
/*$first_condition is false and $second_condition is true*/
<?php }else{ ?>
/*$first_condition and $second_condition are false*/
<?php } ?>

<form method="post" accept-charset="utf-8" action="<?php echo


site_url("yourcontroller/about"); ?>">
<select name="hours" onchange="this.form.submit()">
<option value="24">24</option>
<option value="12">12</option>
<option value="1">1</option>
</select>
</form>

12
passing data from php to java script via view
Simply use one of the following methods.

<script type="text/javascript">
var js_variable = '<?php echo $php_variable;?>';
<script>
OR

<script type="text/javascript">
var js_variable = <?php echo json_encode($php_variable); ?>;
</script>

I found the problem, it was related to a security feature in WHM/cPanel

Restrict outgoing SMTP to root, exim, and mailman (FKA SMTP Tweak)

Login to CPanel > Tweak Settings > All> "Restrict outgoing SMTP to root, exim, and
mailman (FKA SMTP Tweak) and switch it from �On� to �Off�.
for my case I used the shell (ssh) to fix this :

/scripts/smtpmailgidonly off

and I posted an answer here


https://stackoverflow.com/questions/14297264/password-not-accepted-from-server-535-
incorrect-authentication-data-when-send/44564332#44564332

11
down vote
It is very important to set a default timezone to get the correct result

<?php
// set default timezone
date_default_timezone_set('Europe/Berlin');

// timestamp
$timestamp = 1307595105;

// output
echo date('d M Y H:i:s Z',$timestamp);
echo date('c',$timestamp);
?>
Online conversion help: http://freeonlinetools24.com/timestamp

When importing a template, if you're shown a "500 Internal Server Error", this can
be solved by adding the following to your "wp-config.php" file.

ini_set('memory_limit', '256M');
ini_set('upload_max_filesize', '32M');
ini_set('post_max_size', '32M');
ini_set('file_uploads', 'On');
ini_set('max_execution_time', '300');

1
2
3
4
5
6
7

ini_set('memory_limit', '256M');
ini_set('upload_max_filesize', '32M');
ini_set('post_max_size', '32M');
ini_set('file_uploads', 'On');
ini_set('max_execution_time', '300');

https://www.md5online.org/

You might also like