Beispiel #1
0
function menuHeader($logged, $nick, $role)
{
    $header = '<div class="Header"> 
					<table class="Cabecera">
						<tr>
							<td class="Title">
								<h1>Bigou</h1>
							</td>
							<td>';
    if (!$logged) {
        $header = $header . notLogged();
    } else {
        $header = $header . logged($nick);
    }
    $header = $header . '</td>
						</tr>
						<tr>
							<td class="Menu" colspan="2">
								<a href="main.php"><button class="Basic Menu" name="main">Inicio</button></a><!--';
    if ($logged) {
        $header = $header . '--><a href="new_album.php"><button class="Basic Menu" name="newAlbum">Crear Álbum</button></a><!--
							   --><a href="new_photo.php"><button class="Basic Menu" name="newPhoto">Subir Foto</button></a><!--';
    }
    $header = $header . '--><a href=".html"><button class="Basic Menu" name="credits.php">Créditos</button></a>
						</td>
					</tr>
				</table>
			</div>';
    return $header;
}
Beispiel #2
0
function menuHeader($logged, $nick, $role)
{
    $header = '<div class="Header"> 
					<table class="Cabecera">
						<tr>
							<td class="Title">
								<h1>Bigou</h1>
							</td>
							<td>';
    if (!$logged) {
        $header = $header . notLogged();
    } else {
        $header = $header . logged($nick);
    }
    $header = $header . '</td>
						</tr>
						<tr>
							<td class="Menu" colspan="2">
								<a href="main.php"><button class="Basic Menu" name="main">Inicio</button></a><!--';
    if ($logged) {
        if ($role == "partner") {
            $header = $header . '--><a href="albums.php"><button class="Basic Menu" name="albums">Mis Álbumes</button></a><!--
								   --><a href="albums.php"><button class="Basic Menu" name="albums">Otros Álbumes</button></a><!--
								   --><a href="albums.php"><button class="Basic Menu" name="albums">Etiquetas</button></a><!--
								   --><a href="albums.php"><button class="Basic Menu" name="albums">Usuarios Registrados</button></a><!--';
        } else {
            $header = $header . '--><a href="albums.php"><button class="Basic Menu" name="albums">Administrar Álbumes</button></a><!--
								   --><a href="administrate_users.php"><button class="Basic Menu" name="administrate_users">Administrar Usuarios</button></a><!--
								   --><a href="users.php"><button class="Basic Menu" name="view_users">Usuarios Registrados</button></a><!--';
        }
    }
    $header = $header . '--><a href="credits.php"><button class="Basic Menu" name="credits">Créditos</button></a>
						</td>
					</tr>
				</table>
			</div>';
    return $header;
}
Beispiel #3
0
<?php
include('config.php');
include('functions.php');
include('classes/client.class.php');
include('classes/security.class.php');
include('classes/securitycollection.class.php');
//check, if client is already logged in.
login();
if(!logged())
{
  include('login_header.php');  
}
else
{
  $collection = new SecurityCollection();
  $securities = $collection->getSecurities(1);
  include($templates.'menu.html');
  include($templates.'show_securities.php');
  include($templates.'footer.html');
}
//  include('templates/index.html');  


//login
 /* 
 */ 

?>
Beispiel #4
0
<?php

include_once "models/user.php";
//Including information about registered users.
$cookie = hasCookie($_COOKIE['login'], $users);
if ($cookie) {
    $current_user = $cookie;
}
$home = "index.php";
$logged = logged($current_user);
$allusers = "allusers.php";
$maps = "maps.php";
$about = "Impossible-Octopus-Fitness/Impossible-Octopus-Fitness.php";
?>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Twitter clone</title>
    <link rel="icon" href="img/favicon.ico">
    <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700' rel='stylesheet' type='text/css'>
    <link rel="stylesheet" href="css/style.css" type="text/css">
    <script src="js/sticky_smart_header.js"></script>
    <script src="js/weather.js"></script>
</head>
<body>
<!--Begin main container-->
<div class="container">
<?php 
include "views/header.php";
?>
Beispiel #5
0
            <li><?php 
    echo anchor('profile', 'Perfil', array('title' => 'Visualizar meu perfil'));
    ?>
</li>
            <?php 
} else {
    ?>
            <li><?php 
    echo anchor('cadastro', 'Cadastre-se', array('title' => 'Cadastre-se'));
    ?>
</li>
			<?php 
}
?>
            <li><?php 
echo anchor('inicio', 'Login', array('title' => 'Login'));
?>
</li>
            <?php 
if (logged()) {
    ?>
                <li><?php 
    echo anchor('inicio/sair', 'Sair', array('title' => 'Sair do sistema'));
    ?>
</li>
            <?php 
}
?>
        </ul>

Beispiel #6
0
  <body>
  <div id='page-wrap'>
	<header class='main' id='h1'>
		<?php 
if (isset($user)) {
    echo '<a href="logOut.php">Logout</a>';
} else {
    echo '<a href="registro.html">Registrarse</a>
					  <a href="login.html">Login</a>';
}
?>
		<h2>Quiz: el juego de las preguntas</h2>
    </header>
		<?php 
if (isset($user)) {
    echo logged($tipo);
} else {
    echo notLogged();
}
?>
    <section class="main" id="s1">  
		<div>
		Aqui se visualizan las preguntas y los creditos ...
		</div>
    </section>
	<footer class='main' id='f1'>
		<p><a href="http://es.wikipedia.org/wiki/Quiz" target="_blank">Que es un Quiz?</a></p>
		<a href='https://github.com/mafonso001'>Git Hub</a>
		<?php 
if (!isset($_SESSION['user'])) {
    echo "<a href='logOut.php'>Log Out</a>";
Beispiel #7
0
 function test_layout_alter_view()
 {
     $this->start();
     $l = Layout::make($this->viewLayout());
     $l->parseAll();
     $l->alter(array('. .' => 'new.view'));
     assert($l->blocks[0]->blocks[0]->blocks === array('new.view'));
     $l->alter(array('. scalar' => 'new scalar'));
     assert($l->blocks[0]->blocks[1]->blocks === array('new scalar'));
     // Leading '=' is optional.
     $l->alter(array('=. scalar' => 'replaced'));
     assert($l->blocks[0]->blocks[1]->blocks === array('replaced'));
     // Number of dots (that craete 'empty class reference') doesn't matter.
     $l->alter(array('..... scalar' => 'new-r'));
     assert($l->blocks[0]->blocks[1]->blocks === array('new-r'));
     $l->alter(array('+. scalar' => 'appended'));
     assert($l->blocks[0]->blocks[1]->blocks === array('new-r', 'appended'));
     // Different alter modes.
     $l->alter(array('. nested cl-1.row' => 'replaced'));
     assert($l->blocks[0]->blocks[2]->blocks[0]->blocks === array('replaced'));
     $l->alter(array('+. nested cl-1.row' => 'appended'));
     assert($l->blocks[0]->blocks[2]->blocks[0]->blocks === array('replaced', 'appended'));
     $l->alter(array('^. nested cl-1.row' => 'prepended'));
     assert($l->blocks[0]->blocks[2]->blocks[0]->blocks === array('prepended', 'replaced', 'appended'));
     assert(!static::$logged);
     // Operating on a non-existent view key creates it regardless of match type.
     $l->alter(array('. replace' => 'replaced'));
     assert(!static::$logged);
     assert($l->blocks[0]->blocks[3] instanceof Layout);
     assert($l->blocks[0]->blocks[3]->classes === array('replace'));
     assert($l->blocks[0]->blocks[3]->blocks === array('replaced'));
     $l->alter(array('+. app.end' => 'appended'));
     assert(!static::$logged);
     assert($l->blocks[0]->blocks[4] instanceof Layout);
     assert($l->blocks[0]->blocks[4]->classes === array('app', 'end'));
     assert($l->blocks[0]->blocks[4]->blocks === array('appended'));
     $l->alter(array('^. pre.pe.nd' => 'pre.pen.ded'));
     assert(!static::$logged);
     assert($l->blocks[0]->blocks[5] instanceof Layout);
     assert($l->blocks[0]->blocks[5]->classes === array('pre', 'pe', 'nd'));
     assert($l->blocks[0]->blocks[5]->blocks === array('pre.pen.ded'));
     assert(count($l->blocks[0]->blocks) === 6);
     $l->alter(array('. no nested' => 'creation'));
     logged('No matching block');
     // Automatic variable creation should only work for view blocks.
     $l->alter(array('=none' => 'created'));
     logged('No matching block');
 }
Beispiel #8
0
    $query .= " order by edited_seq,version";
} else {
    if ($mode == "updated") {
        $query .= " and last=1 order by edited_seq,version";
    } else {
        if ($mode == "user") {
            $query .= " and authorID={$author} order by edited_seq,version,entryID";
        }
    }
}
$fquery .= " limit {$start},{$MAX_PAGE}";
$finalresult = mysql_query($squery . $query . $fquery);
$countquery = "select count(*) from subs " . $query;
$result2 = mysql_query($countquery);
$total = mysql_result($result2, 0);
$lock = bd_userIsModerador() || logged() && bd_getFVersionAuthor($id, $fversion) == $_SESSION['userID'];
?>
&nbsp;&nbsp;
<table align="center" width="100%" border="0">
<tr><td align="center">
<?php 
if (!isset($timefrom)) {
    if ($mode == "updated") {
        echo "<input type=\"checkbox\" name=\"updated\" value=\"true\" onchange=\"list('{$start}','','{$slang}');\" checked/>";
    } else {
        echo "<input type=\"checkbox\" name=\"updated\" value=\"true\" onchange=\"list('{$start}','true','{$slang}');\"/>";
    }
} else {
    if ($mode == "updated") {
        echo "<input type=\"checkbox\" name=\"updated\" value=\"true\" onchange=\"apply_filter('{$slang}','','{$start}');\" checked/>";
    } else {