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


PHP PrintPage函数代码示例

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


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

示例1: WfsArticle

			fclose($fp);
		}
	}

        echo "<tr><td>".$maintext."<br /><br /><br /><hr /><br />";
        echo "<small><b>"._WFS_DATE."</b>&nbsp;".$datetime."<br /><b>"
        ._WFS_TOPICC."</b>&nbsp;".$story->categoryTitle()."<br /><b>"
        ._WFS_URLFORSTORY."</b>&nbsp;".XOOPS_URL."/modules/".$xoopsModule->dirname()."/article.php?articleid=".$story->articleid()
        ."</small><br /></td></tr>";
        echo "</td></tr></table></td></tr></table>\n
            </td></tr></table>
            </body>
            </html>
            ";
}
// --------------------------------------------------------

// main routine

// bug fix : you can print some articles you should NOT see
// PrintPage($articleid);
include_once XOOPS_ROOT_PATH . '/modules/' . $xoopsModule->dirname() .'/include/groupaccess.php';
$article = new WfsArticle($articleid);
if (checkAccess($article->groupid)) 
{	PrintPage($articleid);}
else
{	redirect_header("index.php", 2, _NOPERM);
	exit();
}

?>
开发者ID:severnaya99,项目名称:Sg-2010,代码行数:31,代码来源:print.php

示例2: define

<?php

define("ROOTPATH", "../");
include ROOTPATH . "includes/common.inc.php";
include "language/" . $sLan . ".php";
include "includes/photo.inc.php";
//定义模块名和页面名
PageSet("photo", "memberphoto");
//输出
PrintPage();
开发者ID:noikiy,项目名称:cxe,代码行数:10,代码来源:memberphoto.php

示例3: str_replace

    echo '<title>' . $xoopsConfig['sitename'] . '</title>';
    echo '<meta name="AUTHOR" content="' . $xoopsConfig['sitename'] . '" />';
    echo '<meta name="COPYRIGHT" content="Copyright (c) 2001 by ' . $xoopsConfig['sitename'] . '" />';
    echo '<meta name="DESCRIPTION" content="' . $xoopsConfig['slogan'] . '" />';
    echo '<meta name="GENERATOR" content="' . XOOPS_VERSION . '" />';
    echo '<body bgcolor="#ffffff" text="#000000" onload="window.print()">
    	<table border="0"><tr><td align="center">
    	<table border="0" width="640" cellpadding="0" cellspacing="1" bgcolor="#000000"><tr><td>
    	<table border="0" width="640" cellpadding="20" cellspacing="1" bgcolor="#ffffff"><tr><td align="center">
    	<img src="' . XOOPS_URL . '/images/logo.gif" border="0" alt="" /><br /><br />
    	<h3>' . $story->title() . '</h3>
    	<small><b>' . _NW_DATE . '</b>&nbsp;' . $datetime . ' | <b>' . _NW_TOPICC . '</b>&nbsp;' . $story->topic_title() . '</small><br /><br /></td></tr>';
    echo '<tr valign="top" style="font:12px;"><td>' . $story->hometext() . '<br />';
    $bodytext = $story->bodytext();
    $bodytext = str_replace("[pagebreak]", "<br style=\"page-break-after:always;\">", $bodytext);
    if ($bodytext != '') {
        echo $bodytext . '<br /><br />';
    }
    echo '</td></tr></table></td></tr></table>
	<br /><br />';
    printf(_NW_THISCOMESFROM, $xoopsConfig['sitename']);
    echo '<br /><a href="' . XOOPS_URL . '/">' . XOOPS_URL . '</a><br /><br />
    	' . _NW_URLFORSTORY . ' <!-- Tag below can be used to display Permalink image --><!--img src="' . XOOPS_URL . '/modules/' . $xoopsModule->dirname() . '/images/x.gif" /--><br />
    	<a href="' . XOOPS_URL . '/modules/' . $xoopsModule->dirname() . '/article.php?storyid=' . $story->storyid() . '">' . XOOPS_URL . '/article.php?storyid=' . $story->storyid() . '</a>
    	</td></tr></table>
    	</body>
    	</html>
    	';
}
PrintPage($storyid);
开发者ID:amjadtbssm,项目名称:website,代码行数:30,代码来源:print.php

示例4: translate

            echo "</td></tr><tr><td><br /><br /><br /><hr noshade=\"noshade\" class=\"ongl\" /><br />\n          <p align=\"center\">" . translate("This article comes from") . " {$sitename}<br /><br />\n          <a href=\"{$nuke_url}\">{$nuke_url}</a></p>";
        }
        if ($oper == "static") {
            echo "</p><span style=\"font-size: 10px;\">" . $remp . "</span>";
            echo "</td></tr><tr><td><br /><br /><br /><hr noshade=\"noshade\" class=\"ongl\" /><br />\n          <p align=\"center\">" . translate("This article comes from") . " {$sitename}<br /><br />\n          <a href=\"{$nuke_url}/static.php?op={$sid}&npds=1\">{$nuke_url}/static.php?op={$sid}&npds=1</a></p>";
        }
        echo "</td></tr></table></td></tr></table></td></tr></table></body></html>";
    } else {
        header("location: index.php");
    }
}
if (!empty($sid)) {
    $tab = explode(":", $sid);
    if ($tab[0] == "static") {
        settype($metalang, 'integer');
        settype($nl, 'integer');
        PrintPage("static", $metalang, $nl, $tab[1]);
    } else {
        settype($sid, 'integer');
        if (!$archive) {
            PrintPage("news", "", "", $sid);
        } else {
            PrintPage("archive", "", "", $sid);
        }
    }
} elseif (!empty($lid)) {
    settype($lid, "integer");
    PrintPage("links", $DB, "", $lid);
} else {
    header("location: index.php");
}
开发者ID:Jireck-npds,项目名称:npds_dune,代码行数:31,代码来源:print.php

示例5: translate

          <p class="text-xs-center">' . translate("This article comes from") . ' ' . $sitename . '<br />
          <a href="' . $nuke_url . '/static.php?op=' . $sid . '&npds=1">' . $nuke_url . '/static.php?op=' . $sid . '&npds=1</a></p>';
        }
        echo '
      </div>
   </body>
</html>';
    } else {
        header("location: index.php");
    }
}
if (!empty($sid)) {
    $tab = explode(':', $sid);
    if ($tab[0] == "static") {
        settype($metalang, 'integer');
        settype($nl, 'integer');
        PrintPage("static", $metalang, $nl, $tab[1]);
    } else {
        settype($sid, 'integer');
        if (!$archive) {
            PrintPage("news", '', '', $sid);
        } else {
            PrintPage("archive", '', '', $sid);
        }
    }
} elseif (!empty($lid)) {
    settype($lid, "integer");
    PrintPage("links", $DB, '', $lid);
} else {
    header("location: index.php");
}
开发者ID:npds,项目名称:npds_dune,代码行数:31,代码来源:print.php

示例6: PrintPost

    }
    echo "<p>" . _MD_COMEFROM . "&nbsp;" . XOOPS_URL . "/newbb/viewtopic.php?forum=" . $forum_id . "&amp;topic_id=" . $topic_id . "</p>";
    echo "</div></div>";
    echo "</body></html>";
}
function PrintPost($post_id, $topic_id, $forum_id)
{
    global $xoopsConfig;
    $post_handler =& xoops_getmodulehandler('post', 'newbb');
    $post =& $post_handler->get($post_id);
    if (!($approved = $post->getVar('approved'))) {
        die(_MD_NORIGHTTOVIEW);
    }
    $post_data = $post_handler->getPostForPrint($post);
    echo "<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.01 Transitional//EN'>\n";
    echo "<html>\n<head>\n";
    echo "<title>" . $xoopsConfig['sitename'] . "</title>\n";
    echo "<meta http-equiv='Content-Type' content='text/html; charset=" . _CHARSET . "' />\n";
    echo "<meta name='AUTHOR' content='" . $xoopsConfig['sitename'] . "' />\n";
    echo "<meta name='COPYRIGHT' content='Copyright (c) " . date('Y') . " by " . $xoopsConfig['sitename'] . "' />\n";
    echo "<meta name='DESCRIPTION' content='" . $xoopsConfig['slogan'] . "' />\n";
    echo "<meta name='GENERATOR' content='" . XOOPS_VERSION . "' />\n\n\n";
    echo "<body bgcolor='#ffffff' text='#000000' onload='window.print()'>\n \t\t  <div style='width: 750px; border: 1px solid #000; padding: 20px;'>\n \t\t  <div style='text-align: center; display: block; margin: 0 0 6px 0;'>\n\t      <img src='" . XOOPS_URL . "/modules/newbb/images/xoopsbb_slogo.png' border='0' alt='' />\n\t      <h2 style='margin: 0;'>" . $post_data['subject'] . "</h2></div>\n \t      <div align='center'>" . _POSTEDBY . "&nbsp;" . $post_data['author'] . "&nbsp;" . _ON . "&nbsp;" . formatTimestamp($post_data['date']) . "</div>\n\t\t  <div style='text-align: center; display: block; padding-bottom: 12px; margin: 0 0 6px 0; border-bottom: 2px solid #ccc;'></div>\n\t\t   \t<div style='text-align: left'>" . $post_data['text'] . "</div>\n\t\t\t<div style='padding-top: 12px; border-top: 2px solid #ccc;'></div>\n\t\t\t<p>" . _MD_COMEFROM . "&nbsp;" . XOOPS_URL . "/newbb/viewtopic.php?forum=" . $forum_id . "&amp;topic_id=" . $topic_id . "&amp;post_id=" . $post_id . "</p>\n\t\t    </div>\n            <br />";
    echo "<br /></body></html>";
}
if ($form == 1) {
    PrintPage($topic_id, $forum, $start, $order);
}
if ($form == 2) {
    PrintPost($post_id, $topic_id, $forum);
}
开发者ID:BackupTheBerlios,项目名称:soopa,代码行数:31,代码来源:print.php

示例7: die

/*                           2003 chatserv                              */
/*      http://www.nukefixes.com -- http://www.nukeresources.com        */
/************************************************************************/
if (!eregi("modules.php", $_SERVER['PHP_SELF'])) {
    die("You can't access this file directly...");
}
require_once "mainfile.php";
$module_name = basename(dirname(__FILE__));
get_lang($module_name);
if (!isset($sid)) {
    exit;
}
function PrintPage($sid)
{
    global $site_logo, $nukeurl, $sitename, $datetime, $prefix, $db, $module_name;
    $sid = intval($sid);
    $row = $db->sql_fetchrow($db->sql_query("SELECT title, time, hometext, bodytext, topic, notes FROM " . $prefix . "_stories WHERE sid='{$sid}'"));
    $title = stripslashes(check_html($row['title'], "nohtml"));
    $time = $row['time'];
    $hometext = stripslashes($row['hometext']);
    $bodytext = stripslashes($row['bodytext']);
    $topic = intval($row['topic']);
    $notes = stripslashes($row['notes']);
    $row2 = $db->sql_fetchrow($db->sql_query("SELECT topictext FROM " . $prefix . "_topics WHERE topicid='{$topic}'"));
    $topictext = stripslashes($row2['topictext']);
    formatTimestamp($time);
    echo "<html>\n\t    <head><title>{$sitename} - {$title}</title></head>\n\t    <body bgcolor=\"#ffffff\" text=\"#000000\">\n\t    <table border=\"0\" align=\"center\"><tr><td>\n\t\n\t    <table border=\"0\" width=\"640\" cellpadding=\"0\" cellspacing=\"1\" bgcolor=\"#000000\"><tr><td>\n\t    <table border=\"0\" width=\"640\" cellpadding=\"20\" cellspacing=\"1\" bgcolor=\"#ffffff\"><tr><td>\n\t    <center>\n\t    <img src=\"images/{$site_logo}\" border=\"0\" alt=\"\"><br><br>\n\t    <font class=\"content\">\n\t    <b>{$title}</b></font><br>\n\t    <font class=tiny><b>" . _PDATE . "</b> {$datetime}<br><b>" . _PTOPIC . "</b> {$topictext}</font><br><br>\n\t    </center>\n\t    <font class=\"content\">\n\t    {$hometext}<br><br>\n\t    {$bodytext}<br><br>\n\t    {$notes}<br><br>\n\t    </font>\n\t    </td></tr></table></td></tr></table>\n\t    <br><br><center>\n\t    <font class=\"content\">\n\t    " . _COMESFROM . " {$sitename}<br>\n\t    <a href=\"{$nukeurl}\">{$nukeurl}</a><br><br>\n\t    " . _THEURL . "<br>\n\t    <a href=\"{$nukeurl}/modules.php?name={$module_name}&file=article&sid={$sid}\">{$nukeurl}/modules.php?name={$module_name}&file=article&sid={$sid}</a>\n\t    </font>\n\t    </td></tr></table>\n\t    </body>\n\t    </html>";
    die;
}
PrintPage($sid);
开发者ID:BackupTheBerlios,项目名称:domsmod-svn,代码行数:30,代码来源:print.php


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