本文整理汇总了PHP中getContent函数的典型用法代码示例。如果您正苦于以下问题:PHP getContent函数的具体用法?PHP getContent怎么用?PHP getContent使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了getContent函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: generateFiles
function generateFiles($sufffix)
{
for ($i = 0; $i < 300; $i++) {
$content = getContent($i . $sufffix);
file_put_contents(dirname(__FILE__) . '/temp/MyClass' . $i . $sufffix . '.class.php', '<?php ' . $content . ' ?>');
}
}
开发者ID:snowjobgit,项目名称:limb,代码行数:7,代码来源:bundle.php
示例2: sendServiceMail
function sendServiceMail($weChartPost)
{
//******************** 配置信息 ********************************
$smtpserver = constant('SMTP_SERVER');
//SMTP服务器
$smtpserverport = constant('SMTP_SERVER_PORT');
//SMTP服务器端口
$smtpusermail = constant('SMTP_USER_MAIL');
//SMTP服务器的用户邮箱
$smtpemailto = constant('SERVICE_MAIL');
//发送给谁
$smtpuser = constant('SMTP_USER');
//SMTP服务器的用户帐号
$smtppass = constant('SMTP_PASS');
//SMTP服务器的用户密码
$mailtitle = '我在照相馆预约信息';
//邮件主题
//$mailcontent = json_encode($weChartPost);//邮件内容
$mailcontent = getContent($weChartPost);
$mailtype = constant('MAIL_TYPE');
//邮件格式(HTML/TXT),TXT为文本邮件
//************************ 配置信息 ****************************
$smtp = new smtp($smtpserver, $smtpserverport, true, $smtpuser, $smtppass);
//这里面的一个true是表示使用身份验证,否则不使用身份验证.
$smtp->debug = false;
//是否显示发送的调试信息
$state = $smtp->sendmail($smtpemailto, $smtpusermail, $mailtitle, $mailcontent, $mailtype);
if ($state == "") {
return $state;
}
return "OK";
}
开发者ID:CodingJason,项目名称:totemvision,代码行数:32,代码来源:appointmentFormPost.php
示例3: showTemplate
function showTemplate()
{
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<meta name="robots" content="noindex,nofollow" />
<meta name="author" content="Aron Heinecke" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="Stylesheet" media="all" type="text/css" href="css/bootstrap.min.css">
<link rel="Stylesheet" media="all" type="text/css" href="css/default.css">
<script src="js/jquery-2.1.4.min.js" type="text/javascript"></script>
<link rel="icon" href="data:;base64,=">
<title>YAYD Frontend demonstration</title>
<?php
if (function_exists('getHead')) {
// include mod exclusive head content if function exists
getHead();
}
?>
</head>
<body>
<!--site-->
<?php
echo getContent();
?>
<!--/site-->
<script src="js/bootstrap.min.js" type="text/javascript"></script>
</body>
</html>
<?php
}
开发者ID:0xpr03,项目名称:yayd-frontend,代码行数:34,代码来源:template.inc.php
示例4: smarty_function_get_url
function smarty_function_get_url($params, &$smarty)
{
// Default options
$opts = array(
'default' => 'Not found',
'fix' => 'src|href|action'
);
$opts = array_merge($opts, $params);
// Make sure they passed a source url
if (isset($opts['url']))
{
$opts['url'] = $opts['url'];
}
else
{
die($opts['default']);
}
$sParam = '';
if (isset($opts['param'])) $sParam = $opts['param'];
// Retrieve the remote file
$content = @getContent($opts, $sParam);
// Make sure we actually got something
// if (!$content) die($opts['default']);
if (!$content);
// Output the contents to the template
return $content;
}
开发者ID:ngduc,项目名称:Thin-PHP-Framework,代码行数:32,代码来源:function.get_url.php
示例5: _moduleContent
function _moduleContent(&$smarty, $module_name)
{
require_once "modules/{$module_name}/libs/contentFreePBX.php";
$smarty->assign("title", _tr("PBX Configuration"));
$smarty->assign("icon", "/modules/{$module_name}/images/pbx_configuration.png");
$salida = getContent($smarty, $module_name, true);
return $salida;
}
开发者ID:hardikk,项目名称:HNH,代码行数:8,代码来源:index.php
示例6: getSomething
function getSomething($selector)
{
$content = getContent();
$features = $content->find($selector);
echo '<hr>';
foreach ($features as $feature) {
echo $feature->plaintext . '<p>';
}
}
开发者ID:vorobeyDjack,项目名称:php_parser,代码行数:9,代码来源:index.php
示例7: renderSidebar
public function renderSidebar()
{
if (!$this->shouldRender()) {
return;
}
startbox();
echo getContent('sbWiki.' . $this->getCurrentPage());
stopbox();
}
开发者ID:CWFranklin,项目名称:lan-party-site,代码行数:9,代码来源:SidebarWiki.php
示例8: getEvent
function getEvent($meeting, $u_ID, $level)
{
$query = mysql_query("select distinct content.e_ID, event.content from content, event, content_user, meeting where content_user.u_ID = '{$u_ID}' and content_user.c_ID = content.c_ID and content.e_ID = event.e_ID and event.m_ID = meeting.m_ID and meeting.meeting = '{$meeting}' order by content.e_ID asc");
while ($ans = mysql_fetch_array($query)) {
if ($level > 2) {
getContent($ans['e_ID'], $u_ID);
}
}
}
开发者ID:nmzfrank,项目名称:LaPitto,代码行数:9,代码来源:export.php
示例9: parseInfo
function parseInfo($post, $ignoreQuotes = true, $deadline)
{
$info = array();
$info['time'] = extractDate($post[0]->childNodes->item(6)->textContent);
$info['daynum'] = getGameDay($post[0]->childNodes->item(6)->textContent, $deadline);
$info['poster'] = $post[0]->childNodes->item(4)->textContent;
$info['content'] = getContent($post[1], $ignoreQuotes);
return $info;
}
开发者ID:ErikRoelofs,项目名称:wordcounter,代码行数:9,代码来源:index.php
示例10: getColor
function getColor($id, $field, $im)
{
$data = getContent($id, $field);
if (!$data) {
die("ERROR: Could not retrieve team color for title id {$id} field {$field}.");
}
$rgb = explode(",", $data);
$color = imagecolorallocate($im, $rgb[0], $rgb[1], $rgb[2]);
return $color;
}
开发者ID:hamilr2,项目名称:rpits,代码行数:10,代码来源:include_old.php
示例11: deleteMassage
function deleteMassage()
{
/* Функция удаления коментария */
if (isset($_POST['remove'])) {
$massage = array_reverse(getContent());
$id = $_POST['remove'];
unset($massage[$id]);
$massageDB = serialize($massage);
file_put_contents("1massage.db", $massageDB);
}
}
开发者ID:AshMorrow,项目名称:homework,代码行数:11,代码来源:libs.php
示例12: upperCaseAuthors
function upperCaseAuthors($xml)
{
do {
$aut = getContent('author', $xml);
if (strlen($aut) > 0) {
$names = explode(',', $aut);
$upperCaseAuthorsXML = '<AUTHOR key="' . $aut . '" SEARCH="' . str_replace(',', ',+', strtoupper(removeAccent(str_replace(' ', '+', $aut)))) . '"><NAME>' . $names[1] . '</NAME><SURNAME>' . $names[0] . '</SURNAME><UPP_NAME>' . strtoupper($names[1]) . '</UPP_NAME><UPP_SURNAME>' . strtoupper($names[0]) . '</UPP_SURNAME></AUTHOR>';
$xml = str_replace('<author>' . $aut . '</author>', $upperCaseAuthorsXML, $xml);
}
} while (strlen($aut) > 0);
return $xml;
}
开发者ID:padlrosa,项目名称:Regional-2,代码行数:12,代码来源:common.php
示例13: getEvent
function getEvent($meeting, $u_ID, $level)
{
$query = mysql_query("select distinct content.e_ID, event.content from content, event, content_user, meeting where content_user.u_ID = '{$u_ID}' and content_user.c_ID = content.c_ID and content.e_ID = event.e_ID and event.m_ID = meeting.m_ID and meeting.meeting = '{$meeting}' order by content.e_ID asc");
while ($ans = mysql_fetch_array($query)) {
$result = getEventCompletion($ans['e_ID']);
echo "<div class='col-lg-12 lv-event'>";
echo "<div class='panel panel-success' style='margin-top:10px;'>";
echo "<div class='panel-heading' style='font-size:2em'>议题: " . $ans['content'] . "<span class='pull-right' style='font-size:0.5em; padding-top:10px;'>实际完成率:{$result['0']}%; 参考完成率: {$result['1']}%;</span></div>";
echo "<div class='panel-body'>";
getContent($ans['e_ID'], $u_ID);
echo "</div></div></div>";
}
}
开发者ID:nmzfrank,项目名称:LaPitto,代码行数:13,代码来源:reloadTable.php
示例14: getEvent
function getEvent($meeting, $u_ID, $level)
{
$query = mysql_query("select distinct content.e_ID, event.content from content, event, content_user, meeting where content_user.u_ID = '{$u_ID}' and content_user.c_ID = content.c_ID and content.e_ID = event.e_ID and event.m_ID = meeting.m_ID and meeting.meeting = '{$meeting}' order by content.e_ID asc");
while ($ans = mysql_fetch_array($query)) {
echo "<div style='border:1px solid #000;padding:5px 15px;margin-top:5px'>";
echo "<h4>议题:</h4> ";
echo $ans['content'];
if ($level > 2) {
getContent($ans['e_ID'], $u_ID);
}
echo "</div>";
}
}
开发者ID:nmzfrank,项目名称:LaPitto,代码行数:13,代码来源:previewByMeeting.php
示例15: processAction
function processAction()
{
$action = assign_input('action', 'R');
$folderID = assign_input('folderID', 'R');
$noteID = assign_input('noteID', 'R');
$parentFolder = assign_input('parentFolder', 'R');
$date = assign_input('date', 'R');
$name = assign_input('name', 'R');
$note = assign_input('note', 'P', 1);
$sortByDate = assign_input('sortByDate', 'R');
switch ($action) {
case 'newFolder':
$res = newFolder($name, $parentFolder);
break;
case 'newNote':
$res = newNote($name, $note, $parentFolder);
break;
case 'toNewFolder':
$res = addToNewFolder($parentFolder, $noteID);
break;
case 'delete':
$res = delete_($noteID ? $noteID : $folderID, $folderID);
break;
case 'rename':
$res = rename_($name, $noteID ? $noteID : $folderID, $folderID);
break;
case 'save':
$res = save($noteID, $note);
break;
case 'get':
$res = getContent($parentFolder, $sortByDate ? 1 : 0);
break;
case 'loadNote':
$res = loadNote($noteID);
break;
case 'search':
break;
default:
$res = array("error" => "no action");
}
/*
if(( isset($res['error']))&&($res['error'])){echo 'Error occured : '.$res['error'].'<br/>';}
if($action=='get'){
echo json_encode($res);
}
*/
echo json_encode($res);
}
开发者ID:louisinhongkong,项目名称:NoteTree,代码行数:50,代码来源:api.php
示例16: createArray
/**
* Function takes data form csv file, proccesses it, creates and modifies array - prepares
* data for futher writing to files by product, returns modified array
*/
function createArray()
{
//$array = array_diff($array, array(''));
//разбили данные на массив -> один продукт - одна строка
$raw_data_1 = explode("\n", getContent());
//создаем массив и записываем каждый товар в подмассив
$raw_data_2 = [];
foreach ($raw_data_1 as $value) {
$value = explode(";", $value);
$value = array_push($raw_data_2, $value);
}
// var_dump($raw_data_2);
// echo "<br><br>";
return $raw_data_2;
}
开发者ID:Atsumoriso,项目名称:Various-Tasks,代码行数:19,代码来源:csv.php
示例17: index
public function index()
{
// session(null);
//检查登录情况
if (checkLogin()) {
$this->assign('log', true);
$this->assign('username', session('name'));
} else {
$this->assign('log', false);
}
//从文本获取首页内容
$arr = getContent();
$this->assign('arr', $arr);
//显示首页
// dump($arr);
$this->display('index');
}
开发者ID:FelixXP,项目名称:CM-CLUB,代码行数:17,代码来源:IndexController.class.php
示例18: parseContenDetail
function parseContenDetail($url, $data, &$x)
{
global $logger, $filename, $conf;
$content = getContent($url);
if ($content != "") {
$row_data = array();
foreach ($data as $key => $value) {
$row_data[] = StringHelper::handleStrNewline(parseTag($value, $content));
}
$row_data[] = $url;
if (trim($row_data[0]) || trim($row_data[1]) || trim($row_data[2])) {
File_CSV::write($filename, $row_data, $conf);
echo "{$x} [Ok].\n";
$logger->log("Get {$url} content.[Ok]");
} else {
echo "{$x} [Fail].\n";
$logger->log("Get {$url} content.[Fail]");
}
$x++;
}
}
开发者ID:BackupTheBerlios,项目名称:flushcms,代码行数:21,代码来源:spide.php
示例19: createComment
/**
* @todo: 新增评论
* @author Saki <[email protected]>
* @date 2014-12-26 下午5:45:28
* @version V1.0
*/
public function createComment($post)
{
$isadd = 0;
$model = D('Admin/ArticleComment');
if ($post['content'] != '') {
$data = $post;
$data['content'] = getContent($data['content']);
$data['name'] = htmlspecialchars($post['name']);
$data['ctm'] = date('Y-m-d H:i:s', time());
try {
$isadd = $model->data($data)->add($data);
if ($isadd) {
//评论数+1
$article_list_model = new \Admin\Model\ArticleListModel();
$article_list_model->addComment($post['aid']);
}
} catch (Exception $e) {
}
}
return $isadd;
}
开发者ID:bushijie,项目名称:500efuma,代码行数:27,代码来源:ArticleCommentModel.class.php
示例20: getTitle
<head>
<meta charset="UTF-8">
<title><?php
echo getTitle();
?>
</title>
<link rel="stylesheet" href="templates/template.php">
<link href="css/night.css" rel="stylesheet" type="text/css">
</head>
<body>
<div class="wraper">
<header>
<section>
<nav>
<?php
echo getMenu();
?>
</nav>
</header>
<article>
<?php
echo getContent();
?>
</article>
</section>
<footer>
@ Remco de Zwart 2016
</footer>
</div>
</body>
</html>
开发者ID:remcodezwart,项目名称:doomla,代码行数:31,代码来源:night.php
注:本文中的getContent函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论