本文整理汇总了PHP中inc函数的典型用法代码示例。如果您正苦于以下问题:PHP inc函数的具体用法?PHP inc怎么用?PHP inc使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了inc函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: MakeView
function MakeView()
{
$this->sp_PortfolioItemView();
if ($this->returnedRows()) {
inc('site/skills.class.php');
$SkillsClass = new Skills();
$SkillsArray = array();
$RowCount = $this->NumberOfRowsInResultSet();
for ($i = 1; $i <= $RowCount; $i++) {
$row = $this->fetchRow();
$SkillsArray[] = $row['skill'];
if ($i == $RowCount) {
extract($row);
$Skills = $SkillsClass->returnSkillsList($SkillsArray);
require $this->TemplatePath('portfolio.viewitem');
}
}
} else {
?>
<h4>Page Not Found</h4>
<p>The item you requested could not be found. Please check your spelling or <a href="mailto: contact@rhodgson.co.uk">contact me</a> if you think something is missing.</p>
<p>You requested <a href="/Portfolio/<?php
echo htmlentities($_GET['label']);
?>
">rhodgson.co.uk/Portfolio/<?php
echo htmlentities($_GET['label']);
?>
</a></p>
<?php
}
}
示例2: __construct
public function __construct($gets = null, $return = true)
{
if (DEBUG) {
alert("Controlador instanciado");
}
if (is_null($gets)) {
$gets = Oraculum_Request::gets();
$modulo = isset($gets[BASE]) && $gets[BASE] != "" ? $gets[BASE] : 'index';
$acao = isset($gets[BASE + 1]) && $gets[BASE + 1] != "" ? $gets[BASE + 1] : 'home';
// Carregando a classe de metodos que devem ser executados sempre
new Controller(array('default', 'start'), false);
} else {
$modulo = isset($gets[0]) && $gets[0] != "" ? $gets[0] : 'index';
$acao = isset($gets[1]) && $gets[1] != "" ? $gets[1] : 'home';
}
// Definicao dos arquivos das classes relacionadas aos modulos
$controldir = "./apps/" . PROJECT . "/controllers/modulos/";
$viewsdir = "./apps/" . PROJECT . "/views/modulos/";
$this->_control = $controldir . $modulo . "/" . $acao . ".php";
$this->_view = $viewsdir . $modulo . "/" . $acao . ".shtml (ou html, ou php)";
$this->_viewphp = $viewsdir . $modulo . "/" . $acao . ".php";
$this->_viewshtml = $viewsdir . $modulo . "/" . $acao . ".shtml";
$this->_viewhtml = $viewsdir . $modulo . "/" . $acao . ".html";
$inccontrol = inc($this->_control);
if ($inccontrol) {
// Determina que a classe do controlador segue o padrao AcaoModulo
$ofcontrol = ucwords($acao) . ucwords($modulo);
$ofobj = new $ofcontrol();
$ofreturn = $ofobj->{$acao}($gets);
} else {
$inccontrol = inc($controldir . "default/home.php");
// Defermina que sera utilizada a classe padrao
$ofcontrol = "HomeDefault";
$ofobj = new $ofcontrol();
$ofreturn = $ofobj->home($gets);
}
// Incluindo view e fazendo verificacao se existe
if ($return) {
if (file_exists($this->_viewshtml)) {
include $this->_viewshtml;
} else {
if (file_exists($this->_viewhtml)) {
include $this->_viewhtml;
} else {
if (file_exists($this->_viewphp)) {
include $this->_viewphp;
} else {
if ($ofcontrol == "HomeDefault") {
include "./apps/" . PROJECT . "/views/modulos/default/home.shtml";
} else {
if (DEBUG) {
alert("Arquivo <u>" . $this->_view . "</u> nao encontrado");
}
}
}
}
}
}
}
示例3: TClients_base
function TClients_base()
{
global $str, $actions;
TTable::TTable();
# Языковые константы. #
$str[get_class_name($this)] = array_merge($str[get_class_name($this)], array('title' => array('Работа с клиентами', 'Clients'), 'email' => array('E-mail', 'E-mail'), 'system_info' => array('Системная информация', 'System Information'), 'company_info' => array('Информация о компании', 'Company information'), 'crm' => array('Меню', 'Menu'), 'client_info' => array('Информация о Клиенте', 'Client Information'), 'fullname' => array('Полное имя', 'fullname'), 'bill' => array('Состояние счёта', 'Balance'), 'id' => array('Клиент ID', 'Client ID'), 'client_id' => array('Клиент ID', 'Client ID'), 'recieve_bills' => array('Получено счетов', 'Recieve bills'), 'paid_bills' => array('Оплачено счетов', 'Paid bills'), 'paid_bills_sum' => array('Сумма оплаченных счетов', 'Sum of paid bills'), 'bonus' => array('Количество бонусов', 'Bonuses'), 'bonus_sum' => array('Сумма бонусов', 'Sum of bonuses'), 'orders' => array('Всего заказов', 'Orders'), 'ready_orders' => array('Выполнено заказов', 'Closed orders'), 'orders_sum' => array('Сумма выполненных заказов', 'Sum of orders'), 'title_' => array('Клиент #', 'Client #'), 'name' => array('Имя', 'Name'), 'lname' => array('Фамилия', 'Last name'), 'addr' => array('Адрес', 'Address'), 'cell_phone' => array('Мобильный телефон', 'Cell phone'), 'phone' => array('Телефон', 'Phone'), 'pass1' => array('Новый пароль', 'New password'), 'pass2' => array('Повторите пароль', 'Re-enter password'), 'fax' => array('Факс', 'Fax'), 'comp_name' => array('Компания', 'Company Name'), 'comp_fname' => array('Полное имя компании', 'Full company name'), 'comp_inn' => array('ИНН', 'INN'), 'comp_kpp' => array('КПП', 'KPP'), 'comp_zip' => array('Индекс', 'ZIP'), 'comp_addr' => array('Юридический адрес', 'Company adress'), 'comp_paddr' => array('Фактический адрес', 'Company adress'), 'comp_phone' => array('Рабочий телефон', 'Work Phone'), 'comp_fax' => array('Рабочий факс', 'Work fax'), 'comp_email' => array('Рабочий e-mail', 'Work e-mail'), 'comp_bank' => array('Наименования банка', 'Bank name'), 'comp_bik' => array('БИК', 'BIK'), 'comp_ks' => array('Кор. счёт', 'KS'), 'comp_rs' => array('Рассчётный счёт', 'RS'), 'tname' => array('Отчество', 'Surname'), 'login' => array('Логин', 'Login'), 'email' => array('E-mail', 'E-mail'), 'balance' => array('Баланс', 'Balance'), 'group' => array('Группа', 'Group'), 'count' => array('Кол-во', 'Count'), 'sum' => array('Сумма', 'Sum'), 'header' => array('Информация', 'Information'), 'saved' => array('Успешно сохранено!', 'Succesfully Saved!'), 'passwords_neq' => array('Пароли не совпадают!', 'Passwords are not equal!'), 'error' => array('Ошибка!', 'Error!'), 'reg_date' => array('Дата регистрации', 'Register date'), 'allow' => array('Включен', 'Aviable'), 'active' => array('Активен', 'Active'), 'inactive' => array('Заблокирован', 'Blocked'), 'last_access' => array('Дата последнего входа', 'Last access time'), 'requests' => array('Участие в тендерах', 'Tender requests'), 'subscribe' => array('Подписан', 'Subscribed'), 'prod_types' => array('Скидки', 'Discounts'), 'discnow' => array('Текущая скидка', 'Discount'), 'discount' => array('Скидка', 'Discount'), 'discount_group' => array('Скидочная группа', 'Discount group'), 'briz_club' => array('Участник Бриз клуба', 'briz club'), 'otkat' => array('Жесткая скидка', 'Discount')));
# actions.. #
$actions[$this->name] = array('save' => array('Сохранить', 'Save', 'link' => 'cnt.mySubmit(\'' . $this->name . '\')', 'img' => 'icon.save.gif', 'display' => 'none'), 'edit' => &$actions['table']['edit'], 'create' => &$actions['table']['create'], 'delete' => array('Удалить', 'Delete', 'link' => 'cnt.deleteItems(\'' . $this->name . '\')', 'img' => 'icon.delete.gif', 'display' => 'none'));
# crm_menu #
$this->client_id = $this->GetClientID();
require_once inc('modules/' . $this->name . '/config.php');
}
示例4: TCheckConstants
function TCheckConstants()
{
global $actions, $str;
TTable::TTable();
$str[get_class_name($this)] = array_merge($str[get_class_name($this)], array('title' => array('Поиск неиспользуемых констант', 'Check constants'), 'go' => array('Начать поиск', 'Start'), 'delete' => array('Удалить выбранные', 'Delete selected'), 'check_all' => array('Выделить все', 'Check all'), 'uncheck_all' => array('Снять выделение', 'UnCheck all')));
$ini_file = 'modules/' . $this->name . '/module.ini';
if (!is_file($ini_file)) {
$ini_file = inc($this->name . '/module.ini');
}
$config = ini_read($ini_file);
if (isset($config) && isset($config['exclude']) && !empty($config['exclude'])) {
$this->exclude = array_keys($config['exclude']);
}
}
示例5: TCheckFiles
function TCheckFiles()
{
global $actions, $str;
TTable::TTable();
$str[get_class_name($this)] = array_merge($str[get_class_name($this)], array('title' => array('Поиск неиспользуемых файлов', 'Check files'), 'go' => array('Начать поиск', 'Start'), 'delete' => array('Удалить выбранные', 'Delete selected'), 'move' => array('Переместить выбранные в папку ', 'Move selected into'), 'check_all' => array('Выделить все', 'Check all'), 'uncheck_all' => array('Снять выделение', 'UnCheck all'), 'pause' => array('Остановить поиск', 'Pause'), 'play' => array('Продолжить поиск', 'Play'), 'clear_cache' => array('Сбросить кеш', 'Clear cache')));
$ini_file = 'modules/' . $this->name . '/module.ini';
if (!is_file($ini_file)) {
$ini_file = inc($this->name . '/module.ini');
}
$config = ini_read($ini_file);
if (isset($config) && isset($config['exclude_tables']) && !empty($config['exclude_tables'])) {
$this->exclude_tables = array_keys($config['exclude_tables']);
}
$actions[$this->name] = array();
}
示例6: die
the Free Software Foundation, Inc.,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
or check http://www.gnu.org/copyleft/gpl.html
*/
include "inc/parseconf.php";
include "inc/lib.php";
if (!is_file('etc/localis.conf')) {
die("localis.conf not found<br>Maybe you need to copy localis.conf.dist");
}
$conf = parseconf('etc/localis.conf');
$page = $HTTP_GET_VARS['page'] ? $HTTP_GET_VARS['page'] : 'index';
$lang = $HTTP_GET_VARS['lang'] ? $HTTP_GET_VARS['lang'] : $conf['general']['lang'];
$mode = $HTTP_GET_VARS['mode'] ? $HTTP_GET_VARS['mode'] : $conf['general']['mode'];
if ($HTTP_GET_VARS['lang']) {
$glob['query'] .= "&lang={$lang}";
$glob['input'] .= "<input type=\"hidden\" name=\"lang\" value=\"{$lang}\">";
}
if ($HTTP_GET_VARS['mode']) {
$glob['query'] .= "&mode={$mode}";
$glob['input'] .= "<input type=\"hidden\" name=\"mode\" value=\"{$mode}\">";
}
$tpl_path = $conf[general][tpl_path] . "/{$mode}";
if (is_file("{$tpl_path}/{$lang}/globals.php")) {
include "{$tpl_path}/{$lang}/globals.php";
}
$glob["lang{$lang}"] = "selected";
echo inc("head");
echo inc("search");
echo inc("{$page}");
echo inc("foot");
示例7: inc
<?php
inc('molecule', 'block-inset');
?>
</div>
<div class="gi">
<?php
inc('molecule', 'block-inset');
?>
</div>
</div><!--end 3up-->
<hr />
<div class="l-two-col">
<div class="l-main">
<?php
inc('organism', 'latest-posts');
?>
</div>
<div class="l-sidebar">
<?php
inc('organism', 'recent-tweets');
?>
</div>
</div>
</div><!--End role=main-->
<?php
inc('organism', 'footer');
示例8: sqr
<html>
<body>
<?php
function sqr($par)
{
return $par * $par;
}
function inc(&$par)
{
++$par;
}
$txt1 = "Hello World!";
$txt2 = "What a nice day!";
$txt = $txt1 . " " . $txt2;
echo $txt . "<br>" . strlen($txt) . '\\n' . strpos($txt, "World") . '<br>';
echo sqr(5) . '<br>';
$par = 5;
inc($par);
echo $par;
?>
</body>
</html>
示例9: set_time_limit
<?php
// def_text_inspector - оборачивает функцию, так что можно следить за её
// вызовом, переданными аргументами и возвращаемыми значениями
set_time_limit(1);
def('inc', function ($i) {
echo "Increment {$i}\n";
return $i + 1;
});
def_text_inspector('inc');
echo inc(3, 'hello');
?>
---
>> Calling 'inc' function with arguments:
>> - 3
>> - hello
Increment 3
>> return value is '4'
4
示例10: inc
<section class="section related-posts">
<h3 class="section-title">Recent Tweets</h3>
<ul class="headline-list">
<li><h4><a href="#">Headline Lorem ipsum dolor sit amet</a></h4> <?php
inc('atom', 'time');
?>
</li>
<li><h4><a href="#">Laborum, molestiae, rerum, dolores eveniet </a></h4> <?php
inc('atom', 'time');
?>
</li>
<li><h4><a href="#">quae est fugit distinctio iure odit minus non ipsum </a></h4> <?php
inc('atom', 'time');
?>
</li>
<li><h4><a href="#">dolorum deserunt omnis voluptates voluptatum</a></h4> <?php
inc('atom', 'time');
?>
</li>
<li><h4><a href="#">nventore dignissimos vel molestiae, rerum, dolore</a></h4> <?php
inc('atom', 'time');
?>
</li>
<li><h4><a href="#"></a></h4></li>
</ul>
<a href="#" class="text-btn">Follow us on Twitter</a>
</section>
示例11: post_class
post_class(null, $blog_page);
?>
>
<div class="row">
<div class="col-xs-6 col-xs-offset-3">
<h2 class="font-cond caps text-center pg-tag"><?php
echo get_the_title($blog_page);
?>
</h2>
</div>
</div>
<?php
get_sidebar();
?>
<?php
inc('post-list-grid', 'blog');
?>
<?php
inc('social-feed', 'blog');
?>
</article>
</div>
<!-- Container end -->
<?php
get_footer();
示例12: inc
<?php
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/general.include.php';
inc('/site/page.class.php');
$Page = new Page();
$Template->AddStyleSheet('smallbox');
$Template->makeHeader();
$Page->Output();
$Page->traceWindow();
$Template->makeFooter();
示例13: switch
#
#
#
#
#
#
#
#
# get settings
require "../settings.php";
require "../core-settings.php";
# decide what to do
if (isset($_POST["key"])) {
switch ($_POST["key"]) {
case "print":
$OUTPUT = inc($_POST);
break;
case "printsave":
$OUTPUT = save_inc($_POST);
break;
default:
$OUTPUT = view();
}
} else {
# Display default output
$OUTPUT = view();
}
require "../template.php";
# Default View
function view()
{
示例14: XenForo_Dependencies_Public
//$fileDir = realpath('./../forums/');
$fileDir = '/home2/bukkit/public_html/forums/';
require $fileDir . '/library/XenForo/Autoloader.php';
XenForo_Autoloader::getInstance()->setupAutoloader($fileDir . '/library');
XenForo_Application::initialize($fileDir . '/library', $fileDir);
XenForo_Application::set('page_start_time', $startTime);
// Not required if you are not using any of the preloaded data
$dependencies = new XenForo_Dependencies_Public();
$dependencies->preLoadData();
XenForo_Session::startPublicSession();
Log::add('XF initialisation complete!');
// End XenForo
inc('db.php');
inc('content.php');
inc('sidebar.php');
inc('user.php');
inc('template.php');
inc('message.php');
inc('plugin.php');
// Mandatory include-everywhere libraries
inclib('phpmailer/class.phpmailer.php');
// because then we can set defaults here
$mailer = new PHPMailer();
$mailer->SetFrom('donotreply@hrepo.com', 'hRepo System');
$mailer->IsSendmail();
// Now check the user!
User::bootstrap();
foreach (glob(HR_PAGES . '*.php') as $page) {
require $page;
}
template();
示例15: inc
<div class="block block-hero">
<a href="#" class="inner">
<div class="b-thumb">
<?php
inc('atom', 'landscape');
?>
</div>
<div class="b-text">
<h2 class="headline">Headline Text Lorem Ipsum Dolar Samet</h2>
<p class="excerpt">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Iste, eligendi obcaecati delectus ducimus. Excepturi, modi, amet, culpa veritatis magni quidem ducimus consequuntur.</p>
</div>
</a>
</div>