Esempio n. 1
0
<?php

include 'function.php';
echo json_encode(check_all());
Esempio n. 2
0
							<li>Execute this query:
								<code>
									UPDATE cms_user SET `user_name` = 'admin', `password` = '21232f297a57a5a743894a0e4a801fc3', `email` = '*****@*****.**' WHERE `user_id` = 1
								</code>
							</li>
							<li>By performing query above, your user name and password is:
								<ul>
									<li><b>Username : </b>admin</li>
									<li><b>Password : </b>admin</li>
								</ul>										
							</li>
						</ol>
					</li>
					<li>If manual installation doesn't work, you can ask in forum, open an issue in github, or put comment in No-CMS blog</li>
				</ol>
				<div id="php_error" class="message"><?php 
check_all(true);
?>
</div>
			</div>
		
			<p class="well span9">
			    CodeIgniter forum member can visit  No-CMS thread here:  <a href="http://codeigniter.com/forums/viewthread/209171/">http://codeigniter.com/forums/viewthread/209171/</a><br />
			    Github user can visit No-CMS repo:  <a href="https://github.com/goFrendiAsgard/No-CMS/">https://github.com/goFrendiAsgard/No-CMS/</a><br />
			    While normal people can visit No-CMS blog: <a href="http://www.getnocms.com/">http://www.getnocms.com/</a><br />
			    In case of you've found a critical bug, you can also email me at <a href="mailto:gofrendiasgard@gmail.com">gofrendiasgard@gmail.com</a><br />
			    That's all. Start your new adventure with No-CMS !!!
		    </p>
	    </div>
	</div>
</body>
Esempio n. 3
0
$protocol = stripos($_SERVER['SERVER_PROTOCOL'], 'https') === true ? 'https://' : 'http://';
$url_path = parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH);
if ($_SERVER['SERVER_PORT'] != '80') {
    define('SITE_URL', $protocol . $_SERVER['SERVER_NAME'] . $url_path);
} else {
    define('SITE_URL', $protocol . $_SERVER['SERVER_NAME'] . ':' . $_SERVER['SERVER_PORT'] . $url_path);
}
require_once BASEPATH . '/hm_include/install/install_model.php';
$step = $_GET['step'];
switch ($step) {
    case 1:
        require_once BASEPATH . '/hm_include/install/step1.php';
        break;
    case 2:
        if (check_all()) {
            if (isset($_POST['submit'])) {
                if (is_connect()) {
                    header('Location: ?step=3');
                    exit;
                } else {
                    $error = '<div class="alert alert-danger" role="alert">Không thể kết nối đến cơ sở dữ liệu</div>';
                }
            }
            require_once BASEPATH . '/hm_include/install/step2.php';
        } else {
            header('Location: ?step=1');
            exit;
        }
        break;
    case 3:
$name = $_POST['givenname'];
$sn = $_POST['sn'];
$postaladdress = $_POST['postaladdress'];
$homephone = $_POST['homephone'];
$mobile = $_POST['mobile'];
$modifica = $_POST['modifica'];
$telephonenumber = $_POST['telephonenumber'];
$mail = $_POST['contacto_mail'];
$mail2 = $_POST['contacto_mail2'];
if ($name != '') {
    $cn = $name . ' ' . $sn;
} else {
    $cn = $sn;
}
include_once 'util.php';
if (check_all($mail, $cn, $homephone, $mobile)) {
    $info = '';
    $info['objectclass'] = 'inetOrgPerson';
    /* sn es obligatorio, si no tiene, le ponemos cn */
    if ($sn == '') {
        $info['sn'] = clean_name($cn);
    } else {
        $info['sn'][0] = clean_name($sn);
    }
    /* givenName es obligatorio, si no tiene, le ponemos sn */
    if ($name == '') {
        $info['givenname'][0] = clean_name($sn);
    } else {
        $info['givenname'][0] = clean_name($name);
    }
    $my_cn = clean_name($cn);
Esempio n. 5
0
include 'control_sesion.php';
include_once 'util.php';
$user = $_SESSION['user'];
$givenname = $_POST['givenname_admin'];
$sn = $_POST['sn_admin'];
$userpassword = $_POST['userpassword_admin'];
$voicemailpassword = $_POST['voicemailpassword_admin'];
$departmentNumber = $_POST['departmentNumber_admin'];
$mail = $_POST['mail_admin'];
$habilitado = $_POST['habilitado'];
if (!empty($givenname)) {
    $uid = $cn = super_clean_name($givenname) . '.' . super_clean_name($sn);
} else {
    $uid = $cn = super_clean_name($sn);
}
if (check_all($mail, $cn, $departmentNumber, $departmentNumber)) {
    // regular
    $info = '';
    $info['objectclass'] = 'inetOrgPerson';
    /* sn es obligatorio, si no tiene, le ponemos cn */
    if ($sn == '') {
        $info['sn'] = $cn;
    } else {
        $info['sn'][0] = super_clean_name($sn);
    }
    /* givenName es obligatorio, si no tiene, le ponemos sn */
    if (empty($givenname)) {
        $info['givenname'][0] = super_clean_name($sn);
    } else {
        $info['givenname'][0] = super_clean_name($givenname);
    }