コード例 #1
0
 public function renderUsersView()
 {
     $userModel = $this->container->get('UserModel');
     htmlHeader('users');
     require VIEW_DIR . '/menu.php';
     require VIEW_DIR . '/users.php';
     htmlFooter();
 }
コード例 #2
0
ファイル: ModuleHandler.class.php プロジェクト: relip/xe-core
 /**
  * prepares variables to use in moduleHandler
  * @param string $module name of module
  * @param string $act name of action
  * @param int $mid
  * @param int $document_srl
  * @param int $module_srl
  * @return void
  **/
 function ModuleHandler($module = '', $act = '', $mid = '', $document_srl = '', $module_srl = '')
 {
     // If XE has not installed yet, set module as install
     if (!Context::isInstalled()) {
         $this->module = 'install';
         $this->act = Context::get('act');
         return;
     }
     // Set variables from request arguments
     $this->module = $module ? $module : Context::get('module');
     $this->act = $act ? $act : Context::get('act');
     $this->mid = $mid ? $mid : Context::get('mid');
     $this->document_srl = $document_srl ? (int) $document_srl : (int) Context::get('document_srl');
     $this->module_srl = $module_srl ? (int) $module_srl : (int) Context::get('module_srl');
     $this->entry = Context::convertEncodingStr(Context::get('entry'));
     // Validate variables to prevent XSS
     $isInvalid = null;
     if ($this->module && !preg_match("/^([a-z0-9\\_\\-]+)\$/i", $this->module)) {
         $isInvalid = true;
     }
     if ($this->mid && !preg_match("/^([a-z0-9\\_\\-]+)\$/i", $this->mid)) {
         $isInvalid = true;
     }
     if ($this->act && !preg_match("/^([a-z0-9\\_\\-]+)\$/i", $this->act)) {
         $isInvalid = true;
     }
     if ($isInvalid) {
         htmlHeader();
         echo Context::getLang("msg_invalid_request");
         htmlFooter();
         Context::close();
         exit;
     }
     if (isset($this->act) && substr($this->act, 0, 4) == 'disp') {
         if (Context::get('_use_ssl') == 'optional' && Context::isExistsSSLAction($this->act) && $_SERVER['HTTPS'] != 'on') {
             header('location:https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']);
             return;
         }
     }
     // execute addon (before module initialization)
     $called_position = 'before_module_init';
     $oAddonController =& getController('addon');
     $addon_file = $oAddonController->getCacheFilePath(Mobile::isFromMobilePhone() ? 'mobile' : 'pc');
     @(include $addon_file);
 }
コード例 #3
0
 /**
  * Trackbacks sent
  * @return object
  */
 function procTrackbackSend()
 {
     // Yeokingeul to post numbers and shipping addresses Wanted
     $document_srl = Context::get('target_srl');
     $trackback_url = Context::get('trackback_url');
     $charset = Context::get('charset');
     if (!$document_srl || !$trackback_url || !$charset) {
         return new Object(-1, 'msg_invalid_request');
     }
     // Login Information Wanted
     $logged_info = Context::get('logged_info');
     if (!$logged_info->member_srl) {
         return new Object(-1, 'msg_not_permitted');
     }
     // Posts of the information obtained permission to come and check whether
     $oDocumentModel =& getModel('document');
     $oDocument = $oDocumentModel->getDocument($document_srl);
     if (!$oDocument->isExists() || !$oDocument->getSummary()) {
         return new Object(-1, 'msg_invalid_request');
     }
     if ($oDocument->getMemberSrl() != $logged_info->member_srl) {
         return new Object(-1, 'msg_not_permitted');
     }
     // Specify the title of the module, the current article
     $oModuleModel =& getModel('module');
     $module_info = $oModuleModel->getModuleInfoByModuleSrl($oDocument->get('module_srl'));
     Context::setBrowserTitle($module_info->browser_title);
     // Shipping yeokingeul
     $output = $this->sendTrackback($oDocument, $trackback_url, $charset);
     if ($output->toBool() && !in_array(Context::getRequestMethod(), array('XMLRPC', 'JSON'))) {
         global $lang;
         htmlHeader();
         alertScript($lang->success_registed);
         reload(true);
         closePopupScript();
         htmlFooter();
         Context::close();
         exit;
     }
     return $output;
 }
コード例 #4
0
function shareHtml($htmlUrl)
{
    $serverPath = $_SERVER['DOCUMENT_ROOT'] . "/web_test/image_test/upload_html/";
    // echo 'path: '.$serverPath.$htmlUrl;
    if (!file_exists($serverPath . $htmlUrl)) {
        // file check
        echo 'file not found';
        exit;
    }
    htmlHeader();
    $toDeleteString = ":8080";
    $toReplaceString = "";
    $myfile = fopen($serverPath . $htmlUrl, "r") or die("Unable to open file!");
    // Output one line until end-of-file
    while (!feof($myfile)) {
        // echo str_replace($toDeleteString, $toReplaceString, fgets($myfile)) . "<br>";
        echo fgets($myfile) . "<br>";
    }
    fclose($myfile);
    htmlFooter();
}
コード例 #5
0
ファイル: Context.class.php プロジェクト: 1Sam/rhymix
 /**
  * Single Sign On (SSO)
  *
  * @return bool True : Module handling is necessary in the control path of current request , False : Otherwise
  */
 public function checkSSO()
 {
     // pass if it's not GET request or XE is not yet installed
     if ($this->db_info->use_sso != 'Y' || isCrawler()) {
         return TRUE;
     }
     $checkActList = array('rss' => 1, 'atom' => 1);
     if (self::getRequestMethod() != 'GET' || !self::isInstalled() || isset($checkActList[self::get('act')])) {
         return TRUE;
     }
     // pass if default URL is not set
     $default_url = trim($this->db_info->default_url);
     if (!$default_url) {
         return TRUE;
     }
     if (substr_compare($default_url, '/', -1) !== 0) {
         $default_url .= '/';
     }
     // Get current site information (only the base URL, not the full URL)
     $current_site = self::getRequestUri();
     // Step 1: if the current site is not the default site, send SSO validation request to the default site
     if ($default_url !== $current_site && !self::get('SSOID') && $_COOKIE['sso'] !== md5($current_site)) {
         // Set sso cookie to prevent multiple simultaneous SSO validation requests
         setcookie('sso', md5($current_site), 0, '/');
         // Redirect to the default site
         $redirect_url = sprintf('%s?return_url=%s', $default_url, urlencode(base64_encode($current_site)));
         header('Location:' . $redirect_url);
         return FALSE;
     }
     // Step 2: receive and process SSO validation request at the default site
     if ($default_url === $current_site && self::get('return_url')) {
         // Get the URL of the origin site
         $url = base64_decode(self::get('return_url'));
         $url_info = parse_url($url);
         // Check that the origin site is a valid site in this XE installation (to prevent open redirect vuln)
         if (!getModel('module')->getSiteInfoByDomain(rtrim($url, '/'))->site_srl) {
             htmlHeader();
             echo self::getLang("msg_invalid_request");
             htmlFooter();
             return FALSE;
         }
         // Redirect back to the origin site
         $url_info['query'] .= ($url_info['query'] ? '&' : '') . 'SSOID=' . session_id();
         $redirect_url = sprintf('%s://%s%s%s%s', $url_info['scheme'], $url_info['host'], $url_info['port'] ? ':' . $url_info['port'] : '', $url_info['path'], $url_info['query'] ? '?' . $url_info['query'] : '');
         header('Location:' . $redirect_url);
         return FALSE;
     }
     // Step 3: back at the origin site, set session ID to be the same as the default site
     if ($default_url !== $current_site && self::get('SSOID')) {
         // Check that the session ID was given by the default site (to prevent session fixation CSRF)
         if (isset($_SERVER['HTTP_REFERER']) && strpos($_SERVER['HTTP_REFERER'], $default_url) !== 0) {
             htmlHeader();
             echo self::getLang("msg_invalid_request");
             htmlFooter();
             return FALSE;
         }
         // Set session ID
         setcookie(session_name(), self::get('SSOID'));
         // Finally, redirect to the originally requested URL
         $url_info = parse_url(self::getRequestUrl());
         $url_info['query'] = preg_replace('/(^|\\b)SSOID=([^&?]+)/', '', $url_info['query']);
         $redirect_url = sprintf('%s://%s%s%s%s', $url_info['scheme'], $url_info['host'], $url_info['port'] ? ':' . $url_info['port'] : '', $url_info['path'], $url_info['query'] ? '?' . $url_info['query'] : '');
         header('Location:' . $redirect_url);
         return FALSE;
     }
     // If none of the conditions above apply, proceed normally
     return TRUE;
 }
コード例 #6
0
ファイル: index.php プロジェクト: kleopatra999/PHPhoto
    if (eregi('/phpinfo/', ini_get('disable_functions'))) {
        $diag_mesgs .= "phpinfo() function is disabled<br />\n";
    } else {
        $diag_mesgs .= "phpinfo() function is enabled<br />\n";
    }
    $diag_mesgs .= '$convert_writable is ' . trueFalse($convert_writable) . ',&nbsp; ' . '$convert_readable is ' . trueFalse($convert_readable) . ',&nbsp; ' . '$reqd_view is ' . $reqd_view . "<br />\n" . '$thmbs_ena is ' . trueFalse($thmbs_ena) . ',&nbsp; ' . '$namelinks_ena is ' . trueFalse($namelinks_ena) . ',&nbsp; ' . '$check_security is ' . trueFalse($check_security) . "<br />\n" . '$is_readable_disa is ' . trueFalse($is_readable_disa) . ',&nbsp; ' . '$file_exists_disa is ' . trueFalse($file_exists_disa) . ',&nbsp; ' . '$compat_quote is ' . trueFalse($compat_quote) . "<br /></span>\n";
}
/*
+----------+
|  Output  |
+----------+
*/
/**
* Echo an HTML header if the script is running stand-alone.
*/
echo htmlHeader($header);
/**
* Image is a popup target (experimental).
*/
if (@$get_vars['Qtmp'] == 'popup') {
    echo displayImage($reqd_image, $img_sz_labels);
    echo footerRow();
    echo htmlFooter($header);
    exit;
}
/**
* Open the Qdig gallery table.
*/
// For injecting some output ahead of the gallery
if (isset($pre_gallery)) {
    echo $pre_gallery;
コード例 #7
0
 /**
  * Add a group of friends
  * @return void|Object (success : void, fail : Object)
  **/
 function procCommunicationAddFriendGroup()
 {
     // Check login information
     if (!Context::get('is_logged')) {
         return new Object(-1, 'msg_not_logged');
     }
     $logged_info = Context::get('logged_info');
     // Variables
     $args->friend_group_srl = trim(Context::get('friend_group_srl'));
     $args->member_srl = $logged_info->member_srl;
     $args->title = Context::get('title');
     $args->title = htmlspecialchars($args->title);
     if (!$args->title) {
         return new Object(-1, 'msg_invalid_request');
     }
     // modify if friend_group_srl exists.
     if ($args->friend_group_srl) {
         $output = executeQuery('communication.renameFriendGroup', $args);
         $msg_code = 'success_updated';
         // add if not exists
     } else {
         $output = executeQuery('communication.addFriendGroup', $args);
         $msg_code = 'success_registed';
     }
     if (!$output->toBool()) {
         if (!in_array(Context::getRequestMethod(), array('XMLRPC', 'JSON'))) {
             global $lang;
             htmlHeader();
             alertScript($lang->fail_to_registed);
             closePopupScript();
             htmlFooter();
             Context::close();
             exit;
         } else {
             return $output;
         }
     } else {
         if (!in_array(Context::getRequestMethod(), array('XMLRPC', 'JSON'))) {
             global $lang;
             htmlHeader();
             alertScript($lang->success_registed);
             reload(true);
             closePopupScript();
             htmlFooter();
             Context::close();
             exit;
         } else {
             $this->setMessage($msg_code);
         }
     }
 }
コード例 #8
0
ファイル: orgile.php プロジェクト: r00tjimmy/orgile
function articlePage($section, $filePath)
{
    // -----[ CACHE LITE ]-----
    // Cache Lite is optional but recommended as it rolls and stores the page as HTML
    // and avoids having to rebuild the page everytime it is called. You will need to clear
    // the cache if you update the page. You could create a seperate "clearcache.php" page.
    // See: "/site/orgile/clearcache.php".
    require_once 'Cache/Lite/Output.php';
    $options = array('cacheDir' => '/srv/www/' . SITEURL . '/www/site/ramcache/', 'lifeTime' => '604800');
    // Define cache directory and cache lifetime (168 hours).
    $cache = new Cache_Lite_Output($options);
    // Begin cache lite.
    if (!$cache->start($filePath)) {
        if (is_file($filePath)) {
            $fileData = file_get_contents($filePath, NULL, NULL, 0, 1000);
            // This reads the first 1000 chars for speed.
            // Pulls details from .org file header.
            $regex = '/^#\\+\\w*:(.*)/m';
            preg_match_all($regex, $fileData, $matches);
            $title = trim($matches[1][0]);
            $author = trim($matches[1][1]);
            $date = trim($matches[1][2]);
            $date = date('c', cleanDate($date));
            $description = trim($matches[1][3]);
            $description = strip_tags($description);
            // Create HTML header.
            $htmlHeader = htmlHeader($date, $author, $description, $title, dropDash($section));
            // Starts the object buffer.
            ob_start();
            pageHeader();
            print '<div id="columnX">';
            fetchOne($filePath, 'orgile');
            print '</div>';
            print '<div id="columnY">';
            print '<aside>';
            print '<div class="content">';
            print '<h2><a href="/' . spaceDash($section) . '/" title="' . spaceDash($section) . '">' . spaceDash($section) . '</a>:</h2>';
            print '<ul class="side">';
            fetchSome($section, 'list', '0', 'sort');
            // See function below.
            print '</ul><br>';
            print '</div>' . sideContent();
            print '</aside>';
            print '</div>';
            pageFooter();
            // End the object buffer.
            $content = ob_get_contents();
            ob_end_clean();
            $content = $htmlHeader . $content;
        }
        // End: is_file($filePath).
        print $content;
        // End cache.
        $cache->end();
    }
    // End: cache lite.
}
コード例 #9
0
<?php

/*
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Objet');
?>

</head>
<body>

<div class="container">  
	<div id="header">
		<div class="span-18">
			<img src="<?php 
echo base_url() . "www/images/logo.png";
?>
" style="vertical-align:middle;">
		</div>
		<div class="column span-5 last" id="identification">
			Utilisateur <i><?php 
echo $this->session->userdata('user_name');
コード例 #10
0
 /**
  * prepares variables to use in moduleHandler
  * @param string $module name of module
  * @param string $act name of action
  * @param int $mid
  * @param int $document_srl
  * @param int $module_srl
  * @return void
  * */
 function ModuleHandler($module = '', $act = '', $mid = '', $document_srl = '', $module_srl = '')
 {
     // If XE has not installed yet, set module as install
     if (!Context::isInstalled()) {
         $this->module = 'install';
         $this->act = Context::get('act');
         return;
     }
     $oContext = Context::getInstance();
     if ($oContext->isSuccessInit == FALSE) {
         $logged_info = Context::get('logged_info');
         if ($logged_info->is_admin != "Y") {
             $this->error = 'msg_invalid_request';
             return;
         }
     }
     // Set variables from request arguments
     $this->module = $module ? $module : Context::get('module');
     $this->act = $act ? $act : Context::get('act');
     $this->mid = $mid ? $mid : Context::get('mid');
     $this->document_srl = $document_srl ? (int) $document_srl : (int) Context::get('document_srl');
     $this->module_srl = $module_srl ? (int) $module_srl : (int) Context::get('module_srl');
     if ($entry = Context::get('entry')) {
         $this->entry = Context::convertEncodingStr($entry);
     }
     // Validate variables to prevent XSS
     $isInvalid = NULL;
     if ($this->module && !preg_match("/^([a-z0-9\\_\\-]+)\$/i", $this->module)) {
         $isInvalid = TRUE;
     }
     if ($this->mid && !preg_match("/^([a-z0-9\\_\\-]+)\$/i", $this->mid)) {
         $isInvalid = TRUE;
     }
     if ($this->act && !preg_match("/^([a-z0-9\\_\\-]+)\$/i", $this->act)) {
         $isInvalid = TRUE;
     }
     if ($isInvalid) {
         htmlHeader();
         echo Context::getLang("msg_invalid_request");
         htmlFooter();
         Context::close();
         exit;
     }
     if (isset($this->act) && (strlen($this->act) >= 4 && substr_compare($this->act, 'disp', 0, 4) === 0)) {
         if (Context::get('_use_ssl') == 'optional' && Context::isExistsSSLAction($this->act) && $_SERVER['HTTPS'] != 'on') {
             if (Context::get('_https_port') != null) {
                 header('location:https://' . $_SERVER['HTTP_HOST'] . ':' . Context::get('_https_port') . $_SERVER['REQUEST_URI']);
             } else {
                 header('location:https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']);
             }
             return;
         }
     }
     // call a trigger before moduleHandler init
     ModuleHandler::triggerCall('moduleHandler.init', 'before', $this);
     // execute addon (before module initialization)
     $called_position = 'before_module_init';
     $oAddonController = getController('addon');
     $addon_file = $oAddonController->getCacheFilePath(Mobile::isFromMobilePhone() ? 'mobile' : 'pc');
     if (file_exists($addon_file)) {
         include $addon_file;
     }
 }
コード例 #11
0
<?php

/*
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un Login');
?>

</head>
<body>


<div class="container">
	<div id="header">
		<img src="<?php 
echo base_url() . "www/images/logo.png";
?>
" style="vertical-align:middle;">
		<?php 
echo htmlNavigation($this->session->userdata('user_id') == 0);
?>
		<div class="span-12"><h2><img src="<?php 
コード例 #12
0
ファイル: tutor-guides.php プロジェクト: joseph1125/capp-site
<?php

include_once 'app.php';
include_once 'navbar.php';
?>

<!DOCTYPE html>
<html>
  <?php 
htmlHeader('Guidance to Tutors of CAPP Co-Assessment of Presentations by Peers');
?>
  <body>
    <?php 
navHeader();
?>
    <div class="jumbotron">
      <div class="container">
        <h1>Guidance to Tutors</h1>
      </div>
    </div>
    <div class="container">
      <section>
        <div class="page-header">
          <h2>Concerns from Students</h2>
        </div>
        <p>
          When asking students to conduct self and peer assessment, most of them resist. Such resistance is due to the following major reasons:
          <ul>
            <li>Most students think that their peers do not do the peer assessment fairly and responsibly.</li>
            <li>Students feel that do not have sufficient knowledge and skill to assess their peers' work.</li>
            <li>Students worry that if they gave low marks or negative comments to their classmates, their friendship with peers would be adversely affected.</li>
コード例 #13
0
<?php

/*
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un champ');
?>

</head>
<body>


<div class="container">  
	<div class="prepend column span-15">
		<h1><img src="<?php 
echo base_url();
?>
www/images/logo.jpg"/ style="vertical-align:middle;"> Specs</h1>
	</div>
	<div class="column span-5 last">
		Utilisateur <i><?php 
echo $this->session->userdata('user_name');
コード例 #14
0
/*
 * Created on 06/04/2010
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
if ($this->session->userdata('user_id') == null) {
    redirect('welcome/index');
}
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un projet');
?>

</head>
<body>

<div class="container">  
	<div class="prepend column span-15">
		<h1><img src="<?php 
echo base_url();
?>
www/images/logo.jpg"/ style="vertical-align:middle;"> Specs</h1>
	</div>
	<div class="column span-5 last">
		Utilisateur <i><?php 
echo $this->session->userdata('user_name');
コード例 #15
0
<?php

/*
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Detail');
?>

</head>
<body>

<div class="container">  
	<div id="header">
		<div class="span-18">
			<img src="<?php 
echo base_url() . "www/images/logo.png";
?>
" style="vertical-align:middle;">
		</div>
		<div class="column span-5 last" id="identification">
			Utilisateur <i><?php 
echo $this->session->userdata('user_name');
コード例 #16
0
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
$this->load->helper('views');
if ($this->session->userdata('user_name') == "") {
    redirect('welcome/index');
}
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un %%(self.displayName)%%');
?>
</head>
<body>

<!-- Start: page-top-outer -->
<div id="page-top-outer">    

<!-- Start: page-top -->
<div id="page-top">

	<!-- start logo -->
	<div id="logo">
	<a href=""><img src="<?php 
echo base_url();
?>
コード例 #17
0
 /**
  * @brief List permissions of the module
  */
 function procModuleAdminModuleGrantSetup()
 {
     $module_srls = Context::get('module_srls');
     if (!$module_srls) {
         return new Object(-1, 'msg_invalid_request');
     }
     $modules = explode(',', $module_srls);
     if (count($modules) < 1) {
         return new Object(-1, 'msg_invalid_request');
     }
     $oModuleController = getController('module');
     $oModuleModel = getModel('module');
     $columnList = array('module_srl', 'module');
     $module_info = $oModuleModel->getModuleInfoByModuleSrl($modules[0], $columnList);
     $xml_info = $oModuleModel->getModuleActionXml($module_info->module);
     $grant_list = $xml_info->grant;
     $grant_list->access = new stdClass();
     $grant_list->access->default = 'guest';
     $grant_list->manager = new stdClass();
     $grant_list->manager->default = 'manager';
     $grant = new stdClass();
     foreach ($grant_list as $grant_name => $grant_info) {
         // Get the default value
         $default = Context::get($grant_name . '_default');
         // -1 = Sign only, 0 = all users
         $grant->{$grant_name} = array();
         if (strlen($default)) {
             $grant->{$grant_name}[] = $default;
             continue;
             // Users in a particular group
         } else {
             $group_srls = Context::get($grant_name);
             if ($group_srls) {
                 if (!is_array($group_srls)) {
                     if (strpos($group_srls, '|@|') !== false) {
                         $group_srls = explode('|@|', $group_srls);
                     } elseif (strpos($group_srls, ',') !== false) {
                         $group_srls = explode(',', $group_srls);
                     } else {
                         $group_srls = array($group_srls);
                     }
                 }
                 $grant->{$grant_name} = $group_srls;
             }
             continue;
         }
         $grant->{$group_srls} = array();
         // dead code, too??
     }
     // Stored in the DB
     foreach ($modules as $module_srl) {
         $args = new stdClass();
         $args->module_srl = $module_srl;
         $output = executeQuery('module.deleteModuleGrants', $args);
         if (!$output->toBool()) {
             continue;
         }
         // Permissions stored in the DB
         foreach ($grant as $grant_name => $group_srls) {
             foreach ($group_srls as $val) {
                 $args = new stdClass();
                 $args->module_srl = $module_srl;
                 $args->name = $grant_name;
                 $args->group_srl = $val;
                 $output = executeQuery('module.insertModuleGrant', $args);
                 if (!$output->toBool()) {
                     return $output;
                 }
             }
         }
     }
     $this->setMessage('success_registed');
     if (!in_array(Context::getRequestMethod(), array('XMLRPC', 'JSON'))) {
         if (Context::get('success_return_url')) {
             $this->setRedirectUrl(Context::get('success_return_url'));
         } else {
             global $lang;
             htmlHeader();
             alertScript($lang->success_registed);
             closePopupScript();
             htmlFooter();
             Context::close();
             exit;
         }
     }
 }
コード例 #18
0
ファイル: login.php プロジェクト: raydouglass/synccit
                $session->setID($id);
                $session->setPHPSession();
                //redirect to homepage
                header("Location: index.php");
            } else {
                $error = "database error. try again";
            }
        } else {
            //password wrong
            $error = "username or password wrong";
        }
    } else {
        $error = "username or password wrong";
    }
}
htmlHeader("login - synccit");
?>
<div class="fourcol">
    <h2>login</h2>
</div>
<div class="fourcol">

	<span class="error"><?php 
echo $error;
?>
</span><br /><br />
	<form action="<?php 
echo LOGINURL;
?>
" method="post">
	
コード例 #19
0
<?php

/*
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un Utilisateur');
?>

</head>
<body>


<div class="container">
	<div id="header">
		<img src="<?php 
echo base_url() . "www/images/logo.png";
?>
" style="vertical-align:middle;">
		<?php 
echo htmlNavigation($this->session->userdata('user_id') == 0);
?>
		<div class="span-12"><h2><img src="<?php 
コード例 #20
0
/*
 * Created on 03/04/2010
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
if ($this->session->userdata('user_id') == null) {
    redirect('welcome/index');
}
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un cas d\'utilisation');
?>

</head>
<body>

<div class="container">  
	<div class="prepend column span-15">
		<h1><img src="<?php 
echo base_url();
?>
www/images/logo.jpg"/ style="vertical-align:middle;"> Specs</h1>
	</div>
	<div class="column span-5 last">
		Utilisateur <i><?php 
echo $this->session->userdata('user_name');
コード例 #21
0
<?php

/*
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un Objet');
?>

</head>
<body>


<div class="container">
	<div id="header">
		<img src="<?php 
echo base_url() . "www/images/logo.png";
?>
" style="vertical-align:middle;">
		<?php 
echo htmlNavigation($this->session->userdata('user_id') == 0);
?>
		<div class="span-12"><h2><img src="<?php 
コード例 #22
0
/*
 * Created on 03/04/2010
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
if ($this->session->userdata('user_id') == null) {
    redirect('welcome/index');
}
?>

<html>
<head>
<?php 
echo htmlHeader('Selection d\'une règle de gestion');
?>

<script>
function annule(){
	document.location.href="<?php 
echo base_url();
?>
index.php/editcdu/index/<?php 
echo $cdu->cduidcdu;
echo isset($prjidprj) ? "/" . $prjidprj : "";
?>
";
}
function termine(){
	document.forms["selectRdg"].submit();
コード例 #23
0
ファイル: index.php プロジェクト: balooval/osm_overpass
<?php

require_once dirname(__FILE__) . '/libs/init.php';
echo getJsPois();
echo htmlHeader();
?>
	<div id="header">
		POIs viewer
	</div>
	<div id="mainContainer">
		<div id="mapTools">
			
		</div>
		<div id="mapContainer">
		</div>
		<div id="console">
			<div id="consoleHeader" onclick="showConsole( false );" title="hide console">
				&gt;&gt;&gt;&gt;
			</div>
			ready
		</div>
		
		
		<div id="consoleReveal" onclick="showConsole( true );">
			<img src="img/console.png" alt="console" title="view console" />
		</div>
	</div>
	
	
	<div style="color:#FFF;">
		
コード例 #24
0
/*
 * Created on 06/04/2010
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
if ($this->session->userdata('user_id') == null) {
    redirect('welcome/index');
}
?>

<html>
<head>
<?php 
echo htmlHeader('Editer une règle de gestion');
?>

</head>
<body>

<div class="container">  
	<div class="prepend column span-15">
		<h1><img src="<?php 
echo base_url();
?>
www/images/logo.jpg"/ style="vertical-align:middle;"> Specs</h1>
	</div>
	<div class="column span-5 last">
		Utilisateur <i><?php 
echo $this->session->userdata('user_name');
コード例 #25
0
 /**
  * layout copy
  * @return void
  */
 function procLayoutAdminCopyLayout()
 {
     $sourceArgs = Context::getRequestVars();
     if ($sourceArgs->layout == 'faceoff') {
         return $this->stop('not supported');
     }
     if (!$sourceArgs->layout_srl) {
         return $this->stop('msg_empty_origin_layout');
     }
     $oLayoutModel = getModel('layout');
     $layout = $oLayoutModel->getLayout($sourceArgs->layout_srl);
     if (!$sourceArgs->title) {
         $sourceArgs->title = array($layout->title . '_' . $this->_makeRandomMid());
     }
     if (!is_array($sourceArgs->title) || count($sourceArgs->title) == 0) {
         return $this->stop('msg_empty_target_layout');
     }
     $output = $oLayoutModel->getLayoutRawData($sourceArgs->layout_srl, array('extra_vars'));
     $args = new stdClass();
     $args->extra_vars = $output->extra_vars;
     $extra_vars = unserialize($args->extra_vars);
     if ($layout->extra_var_count) {
         $reg = "/^.\\/files\\/attach\\/images\\/([0-9]+)\\/(.*)/";
         if ($extra_vars) {
             foreach ($extra_vars as $key => $val) {
                 if ($layout->extra_var->{$key}->type == 'image') {
                     if (!preg_match($reg, $val, $matches)) {
                         continue;
                     }
                     $image_list[$key]->filename = $matches[2];
                     $image_list[$key]->old_file = $val;
                 }
             }
         }
     }
     $oModuleController = getController('module');
     $layout_config = new stdClass();
     $layout_config->header_script = $extra_vars->header_script;
     // Get information to create a layout
     $args->site_srl = (int) $layout->site_srl;
     $args->layout = $layout->layout;
     $args->layout_type = $layout->layout_type;
     if (!$args->layout_type) {
         $args->layout_type = "P";
     }
     $oDB =& DB::getInstance();
     $oDB->begin();
     if (is_array($sourceArgs->title)) {
         foreach ($sourceArgs->title as $key => $value) {
             if (!trim($value)) {
                 continue;
             }
             $args->layout_srl = getNextSequence();
             $args->title = $value;
             if (is_array($image_list)) {
                 foreach ($image_list as $key => $val) {
                     $new_file = sprintf("./files/attach/images/%s/%s", $args->layout_srl, $val->filename);
                     FileHandler::copyFile($val->old_file, $new_file);
                     $extra_vars->{$key} = $new_file;
                 }
                 $args->extra_vars = serialize($extra_vars);
             }
             // for header script
             $oModuleController->insertModulePartConfig('layout', $args->layout_srl, $layout_config);
             // Insert into the DB
             $output = $this->insertLayout($args);
             if (!$output->toBool()) {
                 $oDB->rollback();
                 return $output;
             }
             // initiate if it is faceoff layout
             $this->initLayout($args->layout_srl, $args->layout);
             // update layout info
             $output = $this->updateLayout($args);
             if (!$output->toBool()) {
                 $oDB->rollback();
                 return $output;
             }
             $this->_copyLayoutFile($layout->layout_srl, $args->layout_srl);
         }
     }
     $oDB->commit();
     $this->setMessage('success_registed');
     if (!in_array(Context::getRequestMethod(), array('XMLRPC', 'JSON'))) {
         global $lang;
         htmlHeader();
         alertScript($lang->success_registed);
         reload(true);
         closePopupScript();
         htmlFooter();
         Context::close();
         exit;
     }
 }
コード例 #26
0
<?php

/*
 * Created by generator
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Editer un Etat');
?>

</head>
<body>


<div class="container">
	<div id="header">
		<img src="<?php 
echo base_url() . "www/images/logo.png";
?>
" style="vertical-align:middle;">
		<?php 
echo htmlNavigation($this->session->userdata('user_id') == 0);
?>
		<div class="span-12"><h2><img src="<?php 
コード例 #27
0
 /**
  * Update a group of selected memebrs
  * @return void|Object (void : success, Object : fail)
  */
 function procMemberAdminUpdateMembersGroup()
 {
     $member_srl = Context::get('member_srl');
     if (!$member_srl) {
         return new Object(-1, 'msg_invalid_request');
     }
     $member_srls = explode(',', $member_srl);
     $group_srl = Context::get('group_srls');
     if (!is_array($group_srl)) {
         $group_srls = explode('|@|', $group_srl);
     } else {
         $group_srls = $group_srl;
     }
     $oDB =& DB::getInstance();
     $oDB->begin();
     // Delete a group of selected members
     $args = new stdClass();
     $args->member_srl = $member_srl;
     $output = executeQuery('member.deleteMembersGroup', $args);
     if (!$output->toBool()) {
         $oDB->rollback();
         return $output;
     }
     // Add to a selected group
     $group_count = count($group_srls);
     $member_count = count($member_srls);
     for ($j = 0; $j < $group_count; $j++) {
         $group_srl = (int) trim($group_srls[$j]);
         if (!$group_srl) {
             continue;
         }
         for ($i = 0; $i < $member_count; $i++) {
             $member_srl = (int) trim($member_srls[$i]);
             if (!$member_srl) {
                 continue;
             }
             $args = new stdClass();
             $args->member_srl = $member_srl;
             $args->group_srl = $group_srl;
             $output = executeQuery('member.addMemberToGroup', $args);
             if (!$output->toBool()) {
                 $oDB->rollback();
                 return $output;
             }
         }
     }
     $oDB->commit();
     $this->_deleteMemberGroupCache();
     $this->setMessage('success_updated');
     if (!in_array(Context::getRequestMethod(), array('XMLRPC', 'JSON'))) {
         global $lang;
         htmlHeader();
         alertScript($lang->success_updated);
         reload(true);
         closePopupScript();
         htmlFooter();
         Context::close();
         exit;
     }
 }
コード例 #28
0
<?php

/*
 * Created by JC 11/06/2010
 *
 */
$this->load->helper('form');
$this->load->helper('url');
$this->load->helper('template');
?>

<html>
<head>
<?php 
echo htmlHeader('Specs - login');
?>

</head>
<body>

<div class="container"> 
	<h1><img src="<?php 
echo base_url();
?>
www/images/logo.jpg"/ style="vertical-align:middle;"> Specs</h1>
	<hr>
	<div class="prepend-1 colborder">
	<div class="span-7 last" style="float: right;"><?php 
echo $this->session->flashdata('message');
?>
</div>
コード例 #29
0
<?php

require __DIR__ . '/init.php';
htmlHeader();
// create a client instance
$client = new Solarium\Client($config);
// get a select query instance
$query = $client->createSelect();
// add distributed search settings
// see http://wiki.apache.org/solr/DistributedSearch#Distributed_Search_Example for setting up two solr instances
$distributedSearch = $query->getDistributedSearch();
$distributedSearch->addShard('shard1', 'localhost:8983/solr');
$distributedSearch->addShard('shard2', 'localhost:7574/solr');
// this executes the query and returns the result
$resultset = $client->select($query);
// display the total number of documents found by solr
echo 'NumFound: ' . $resultset->getNumFound();
// show documents using the resultset iterator
foreach ($resultset as $document) {
    echo '<hr/><table>';
    // the documents are also iterable, to get all fields
    foreach ($document as $field => $value) {
        // this converts multivalue fields to a comma-separated string
        if (is_array($value)) {
            $value = implode(', ', $value);
        }
        echo '<tr><th>' . $field . '</th><td>' . $value . '</td></tr>';
    }
    echo '</table>';
}
htmlFooter();
コード例 #30
0
ファイル: plugin.php プロジェクト: raydouglass/synccit
<?php

include "config.php";
include "functions.php";
include "session.php";
include "userclass.php";
$loggedin = $session->isLoggedIn();
htmlHeader("Get the synccit apps - synccit - reddit history/link sync", $loggedin);
?>

<div class="fourcol appdiv">
    <h2>Browsers</h2>

    <br />

    <a href="https://chrome.google.com/webstore/detail/synccit-for-reddit/djgggkkgpoeknlpdllmhdagbfnhaigmd" target="_blank"><img src="<?php 
echo BASEURL;
?>
images/chrome.png" alt="chrome" /></a>
    <br />
    <span class="appname"><a href="https://chrome.google.com/webstore/detail/synccit-for-reddit/djgggkkgpoeknlpdllmhdagbfnhaigmd" target="_blank">Chrome</a></span>

    <br /><br />

    <a href="https://addons.mozilla.org/firefox/addon/synccit/" target="_blank"><img src="<?php 
echo BASEURL;
?>
images/firefox.png" alt="firefox" /></a>
    <br />
    <span class="appname"><a href="https://addons.mozilla.org/firefox/addon/synccit/" target="_blank">Firefox</a></span>