当前位置: 首页>>代码示例>>PHP>>正文


PHP print_head函数代码示例

本文整理汇总了PHP中print_head函数的典型用法代码示例。如果您正苦于以下问题:PHP print_head函数的具体用法?PHP print_head怎么用?PHP print_head使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了print_head函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: begin_mini_page

function begin_mini_page($nav = FALSE)
{
    echo "<!DOCTYPE html>";
    echo "<html lang=\"en\">";
    print_head();
    echo "<body>";
    //  print_scripts();
    //  print_iescriptblocks();
    echo "<div class=\"nojs-display-none oldie-display-none\">";
    if ($nav) {
        print_navbar();
    }
    echo "<div class=\"container\">";
}
开发者ID:amoschou,项目名称:acet,代码行数:14,代码来源:pagefunctions.php

示例2: head_init

function head_init($user, $dbc, $login)
{
    // Get the number of tweets by this user
    $query = "SELECT count(tweet_id) FROM tweet WHERE sending_user = '{$user}'";
    $result = mysqli_query($dbc, $query) or die('Query failed: ' . mysqli_error($dbc));
    $tple = mysqli_fetch_row($result);
    //  or die("User $user not found!");
    // Get number of followers
    $query2 = "SELECT count(followed) FROM following WHERE followed = '{$user}'";
    $result2 = mysqli_query($dbc, $query2) or die('Query failed: ' . mysqli_error($dbc));
    $tple2 = mysqli_fetch_row($result2);
    //  or die("User $user not found!");
    // Get number of users that this user is following
    $query3 = "SELECT count(follower) FROM following WHERE follower = '{$user}'";
    $result3 = mysqli_query($dbc, $query3) or die('Query failed: ' . mysqli_error($dbc));
    $tple3 = mysqli_fetch_row($result3);
    //  or die("User $user not found!");
    // Get attributes of the user
    $query4 = "SELECT name, email, join_date, birthday FROM user WHERE user_id = '{$user}'";
    $result4 = mysqli_query($dbc, $query4) or die('Query failed: ' . mysqli_error($dbc));
    $tple4 = mysqli_fetch_array($result4, MYSQL_ASSOC);
    //  or die("4User $user not found!");
    $queryquery = "SELECT count(user_id) FROM favorited WHERE user_id = '{$user}'";
    $resultresult = mysqli_query($dbc, $queryquery) or die('Query failed: ' . mysqli_error($dbc));
    $tupletuple = mysqli_fetch_row($resultresult);
    print_head($user, $tple, $tple2, $tple3, $tple4, $tupletuple, $login);
}
开发者ID:mikoblume,项目名称:uchicago-databases,代码行数:27,代码来源:ffollower_feed.php

示例3: print_foot

    echo $name;
    ?>
" /></td>
    </tr>
    </table>
    </td>
    </tr>
    </table><br />
    <div align="center">
    <input type="submit" value="Continue" />
    </div>
    <?php 
    print_foot();
    exit;
}
print_head();
?>
Installation complete!<br />
<br />
Please make sure OBMConfig.php is not writable anymore now.<br />
<br />
<font color="#003399"><i>
$ chown -R someuser:someuser <?php 
echo $GO_CONFIG->root_path;
?>
<br />
$ chmod 755 <?php 
echo $GO_CONFIG->root_path;
?>
<br />
$ chmod 644 <?php 
开发者ID:BackupTheBerlios,项目名称:hpt-obm-svn,代码行数:31,代码来源:install.php

示例4: money_format

    $amount = money_format('%.2n', $amount);
    $success = "Successfully recorded deposit of {$amount}.";
}
if (array_key_exists('withdrawal-amount', $_POST)) {
    $amount = round(max($_POST['withdrawal-amount'], 0), 2);
    limbo_deposit($_SESSION['id'], -$amount);
    limbo_deposit(0, $amount);
    $amount = money_format('%.2n', $amount);
    $success = "Successfully recorded withdrawal of {$amount}.";
}
?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
<?php 
print_head('Limbo');
?>
		<link rel="stylesheet" href="/lib/css/selectize.css" />
		<script type="text/javascript" src="/lib/js/jquery.min.js"></script>
		<script type="text/javascript" src="/lib/js/selectize.min.js"></script>
		<script type="text/javascript">// <![CDATA
			var items = [
<?php 
$result = $pdo->prepare('SELECT `name`, `count`, `price`, `description` FROM `items` ORDER BY `name`, `price`');
$result->execute();
$items = array();
while ($row = $result->fetch(PDO::FETCH_ASSOC)) {
    if (!array_key_exists($row['name'], $items)) {
        $items[$row['name']] = array('prices' => array(), 'description' => '');
    }
    $price = (int) round($row['price'] * 100);
开发者ID:blacker-hovse,项目名称:limbo,代码行数:31,代码来源:index.php

示例5: foreach

<!-- Mostrar alertas-->
<?php 
$title = null;
foreach ($Cirugias as $cirugia) {
    ?>

<?php 
    if ($cirugia->getCancelada() != 1) {
        if ($cirugia->getStatus() != $title) {
            ?>
  <td colspan="11"><h3 style="padding-top: 11px;"><?php 
            echo $cirugia->getVerboseStatus();
            ?>
</h3></td>
  <?php 
            echo print_head();
            ?>
  <?php 
            $title = $cirugia->getStatus();
        }
        include_partial('agendaQuirofano', array('cirugia' => $cirugia, 'slug' => $Quirofano->getSlug()));
    }
}
?>


<!-- agregado -->

</table>

开发者ID:eddypre,项目名称:Quirofano,代码行数:29,代码来源:_menuShow.php

示例6: print_head

<?php

include __DIR__ . '/../../lib/class/Mole.class.php';
include __DIR__ . '/../../lib/include.php';
include __DIR__ . '/../include.php';
?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
<?php 
print_head('Nametag');
?>
	</head>
	<body>
		<div id="main">
			<h1>Nametag</h1>
			<h2>Automagic</h2>
			<div>
<?php 
$pdo = new PDO('sqlite:../hovselist.db');
$statement = <<<EOF
SELECT *
FROM `moles`
WHERE `alley` <> 'Social'
EOF;
$result = $pdo->prepare($statement);
$result->execute();
while ($row = $result->fetchObject('Mole')) {
    generate_nametag($pdo, $row);
}
$result = $pdo->prepare($statement);
开发者ID:blacker-hovse,项目名称:blacker,代码行数:31,代码来源:index.php

示例7: connection_db

<?php

require "./php/basefunction.php";
require "./php/print.php";
$conn = connection_db();
print_head("log in - Ac2mms");
print_header();
print_menu();
//session_start();
print_path("<a href=\"index.php\">Home</a> &gt;&gt; Log in");
session_control_login();
?>
<div id="form">
				<h1>Accedi all'area riservata</h1>
				<h2>Inserisci login e password (Servizio offerto ai soli soci)</h2>
<?php 
if (isset($_SESSION['redirect'])) {
    if ($_SESSION['redirect'] == 'true') {
        $messaggio = "utente e/o password errati";
        echo "<p id='error-immission'>" . $messaggio . "</p>";
    } else {
        $messaggio = "devi effettuare l'accesso per andare nell'area riservata";
        echo "<p id='error-immission'>" . $messaggio . "</p>";
    }
    unset($_SESSION['redirect']);
} else {
    if (isset($_SESSION['error'])) {
        echo "<p id=\"error-immission\">Login o password errate</p>";
        session_destroy();
    }
    //else
开发者ID:EduBic,项目名称:Il-Fagiolo-Ac2mms,代码行数:31,代码来源:login.php

示例8: header

        header('Location: ' . $url);
        die;
    }
    if (@$_POST['u'] and $url = filter_input(INPUT_POST, 'u', FILTER_SANITIZE_URL)) {
        if (!preg_match('/^\\w+:\\/\\//', $url)) {
            $url = 'http://' . $url;
        }
        $short = blink_short($url);
    }
}
?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
<?php 
print_head('Blink');
?>
	</head>
	<body>
		<div id="main">
			<h1>Blink</h1>
<?php 
$subtitles = array('Baby Shoes', 'Beats TinyURL', 'Gracious Links', 'Less is More', 'Malcolm Gladwell', 'Oven Aye', 'Short and Sweet', 'Shortens Links', 'Size Matters', 'Suck it TinyURL', "Vive l'Anarchie", 'Welcome FBI');
$subtitle = $subtitles[mt_rand(0, count($subtitles) - 1)];
echo <<<EOF
\t\t\t<h2>{$subtitle}</h2>

EOF;
if (isset($_GET['list'])) {
    echo <<<EOF
\t\t\t<div>
开发者ID:blacker-hovse,项目名称:blink,代码行数:31,代码来源:index.php

示例9: connection_db

<?php

require "./php/basefunction.php";
require "./php/print.php";
$conn = connection_db();
print_head("Cosa facciamo - Ac2mms");
print_header();
print_menu();
print_path("<a href=\"index.php\">Home</a> &gt;&gt; Cosa facciamo");
$query = "SELECT * FROM evento";
$risultato = mysql_query($query, $conn);
print_maincontent2("event", $risultato);
print_footer();
print_close();
开发者ID:EduBic,项目名称:Il-Fagiolo-Ac2mms,代码行数:14,代码来源:cosafacciamo.php

示例10: header

        $page = $path;
    }
}
if ($page == 'error') {
    header('HTTP/1.1 404 Not Found');
    header('Status: 404 Not Found');
} else {
    header('HTTP/1.1 200 OK');
    header('Status: 200 OK');
}
?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
<?php 
print_head(ucwords(strtr($page, '_.', ' :')));
?>
	</head>
	<body>
<?php 
print_header();
?>
		<div id="main">
			<div>
<?php 
echo \Michelf\MarkdownExtra::defaultTransform(file_get_contents(__DIR__ . "/src/{$page}.md"));
?>
			</div>
<?php 
if ($page == 'home') {
    echo <<<EOF
开发者ID:blacker-hovse,项目名称:blacker,代码行数:31,代码来源:index.php

示例11: header_config

function header_config()
{
    global $cfg, $error_feedbacks, $info_feedbacks, $params, $detail_config;
    $cfg_password = isset($_POST['cfg_password']) ? $_POST['cfg_password'] : $cfg['cfg_password'];
    $cfg_root = isset($_POST['cfg_root']) ? $_POST['cfg_root'] : $cfg['cfg_root'];
    $db_hostname = isset($_POST['db_hostname']) ? $_POST['db_hostname'] : $cfg['db_hostname'];
    $db_name = isset($_POST['db_name']) ? $_POST['db_name'] : $cfg['db_name'];
    $db_username = isset($_POST['db_username']) ? $_POST['db_username'] : $cfg['db_username'];
    $db_password = isset($_POST['db_password']) ? $_POST['db_password'] : $cfg['db_password'];
    $db_type = 'mysql';
    $db_prefix = '';
    // Process the form
    if (isset($_POST['write']) || isset($_POST['download']) || isset($_POST['view'])) {
        $cfg_path = $cfg_root . '/config.inc.php';
        $tpl_path = $cfg_root . '/config.inc.tpl.php';
        $values = array('cfg_password' => $cfg_password, 'cfg_root' => $cfg_root, 'db_hostname' => $db_hostname, 'db_name' => $db_name, 'db_username' => $db_username, 'db_password' => $db_password, 'db_type' => $db_type, 'db_prefix' => $db_prefix);
        if (isset($_POST['write']) && (!file_exists($cfg_path) || is_writable($cfg_path)) && ($fp = @fopen($cfg_path, "wt")) != FALSE) {
            fwrite($fp, array_to_ini($values));
            fclose($fp);
            // Once we write the config file successfully. Try to use it.
            $_SESSION['logged'] = 0;
            header('Location: ' . $_SERVER['PHP_SELF']);
            return;
        } else {
            $error_feedbacks[] = 'Could not write to config.inc.php. Please check access permission or download it and write it manually';
        }
        if (isset($_POST['download'])) {
            header('Content-Type: text/plain');
            header('Expires: ' . gmdate('D, d M Y H:i:s') . ' GMT');
            header('Content-Disposition: attachment; filename="config.inc.php"');
            header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
            header('Pragma: public, no-cache');
            header('Content-Transfer-Encoding: binary');
            echo array_to_ini($values);
            exit;
        }
        if (isset($_POST['view'])) {
            header('Content-Type: text/plain');
            header('Expires: ' . gmdate('D, d M Y H:i:s') . ' GMT');
            header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
            header('Pragma: public, no-cache');
            header('Content-Transfer-Encoding: binary');
            echo array_to_ini($values);
            exit;
        }
    }
    if (isset($_POST['save'])) {
        $param_names = array('cfg_relative_url', 'cfg_absolute_url', 'cfg_language', 'cfg_title', 'cfg_webmaster_email', 'cfg_tmpdir', 'cfg_max_users', 'cfg_refresh_rate', 'cfg_user_quota', 'cfg_mailer', 'cfg_smtp_port', 'cfg_smtp_server', 'cfg_max_attachment_size', 'cfg_file_storage');
        foreach ($param_names as $name) {
            if (isset($_POST[$name])) {
                $params->params[$name] = $_POST[$name];
            }
        }
        $params->update();
        $params->reload();
    }
    // Okay, you are authenticated
    print_head();
    ?>
<h1><center>Base Configuration</center></h1>
<form action="<?php 
    echo $_SERVER['PHP_SELF'];
    ?>
" method="post">
<table border="0" width="100%">
<tr><td>Config password</td><td><input type="text" name="cfg_password" value="<?php 
    echo $cfg_password;
    ?>
"/></td></tr>
<tr><td>Root path</td><td><input type="text" name="cfg_root" value="<?php 
    echo $cfg_root;
    ?>
"/></td></tr>
<tr><td>Database hostname</td><td><input type="text" name="db_hostname" value="<?php 
    echo $db_hostname;
    ?>
"/></td></tr>
<tr><td>Database name</td><td><input type="text" name="db_name" value="<?php 
    echo $db_name;
    ?>
"/></td></tr>
<tr><td>Database username</td><td><input type="text" name="db_username" value="<?php 
    echo $db_username;
    ?>
"/></td></tr>
<tr><td>Database password</td><td><input type="text" name="db_password" value="<?php 
    echo $db_password;
    ?>
"/></td></tr>
<tr><td colspan="2"><center>
<input type="submit" name="write" value="Write"/>
&nbsp;&nbsp;
<input type="submit" name="download" value="Download"/>
&nbsp;&nbsp;
<input type="submit" name="view" value="View"/></center></td></tr>
</table>

<?php 
    if ($detail_config) {
        ?>
//.........这里部分代码省略.........
开发者ID:BackupTheBerlios,项目名称:hpt-obm-svn,代码行数:101,代码来源:setup.php

示例12: print_head

            } else {
                $error = 'Failed to add video to queue.';
            }
        } else {
            $error = 'Ride detected. Nice try, punk.';
        }
    } else {
        $error = 'Invalid URL or video ID.';
    }
}
?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
<?php 
print_head('Nearer');
?>
	</head>
	<body>
		<div id="main">
			<h1>Nearer</h1>
<?php 
if ($error) {
    echo <<<EOF
\t\t\t<div class="error">{$error}</div>

EOF;
}
if ($success) {
    echo <<<EOF
\t\t\t<div class="success">{$success}</div>
开发者ID:blacker-hovse,项目名称:nearer,代码行数:31,代码来源:index.php

示例13: connection_db

<?php

require "./php/basefunction.php";
require "./php/print.php";
$conn = connection_db();
print_head("Mappa sito - Ac2mms", "si");
print_header();
print_menu();
print_path("Mappa sito");
print_map();
print_footer();
print_close();
开发者ID:EduBic,项目名称:Il-Fagiolo-Ac2mms,代码行数:12,代码来源:mappa.php

示例14: connection_db

<?php

require "./php/basefunction.php";
require "./php/print.php";
$conn = connection_db();
print_head("Home - Ac2mms");
print_header();
print_menu();
print_path("Home");
print_slider();
//raccolgo informazioni tramite query
$query = "SELECT evento, dataInizio\nFROM istanzaevento\nWHERE dataInizio=\n(SELECT MIN(dataInizio) AS dataInizio\nFROM istanzaevento\nWHERE dataInizio>CURDATE())\nUNION\nSELECT evento, dataInizio\nFROM istanzaevento\nWHERE dataInizio=\n(SELECT MAX(dataInizio) AS dataInizio\nFROM istanzaevento\nWHERE dataInizio<CURDATE())              \n                ;";
print_sidecontent(mysql_query($query, $conn));
print_maincontent();
print_footer();
print_jquery();
print_close();
开发者ID:EduBic,项目名称:Il-Fagiolo-Ac2mms,代码行数:17,代码来源:index.php

示例15: connection_db

<?php

require "./php/basefunction.php";
require "./php/print.php";
$conn = connection_db();
print_head("Chi Siamo - Ac2mms", "si");
print_header();
print_menu();
print_path("<a href=\"index.php\">Home</a> &gt;&gt; Chi siamo");
print_form();
if (isset($_GET["select"])) {
    $numTappa = $_GET["select"];
    $anno = date('Y');
    $query = "SELECT A.persona, P.nome, P.cognome, P.dataNascita, P.telefono, P.email, P.parrocchia ";
    $query .= "FROM persona P JOIN aderente A ON P.id=A.persona JOIN appartenenza App ON (A.persona=App.aderentePersona && A.anno=App.aderenteAnno)";
    $query .= " WHERE A.ruolo='AR' && App.tappaNumRif={$numTappa} && A.anno={$anno}";
    echo "<p class=\"query\"> {$query} </p>";
    $ris = mysql_query($query, $conn);
    print_maincontent2("def", $ris);
}
print_footer();
print_close();
开发者ID:EduBic,项目名称:Il-Fagiolo-Ac2mms,代码行数:22,代码来源:chisiamo.php


注:本文中的print_head函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。