421,407 results for 'php empty repo:ilyabazhenov/speakplace' (1119 ms)
readme.md https://gitlab.com/hecto932/mejorandolaravel_america.git | Markdown | 865 lines
121 122The Carbon class is [inherited](http://php.net/manual/en/keyword.extends.php) from the PHP [DateTime](http://www.php.net/manual/en/class.datetime.php) class. 123 149 150There are several different methods available to create a new instance of Carbon. First there is a constructor. It overrides the [parent constructor](http://www.php.net/manual/en/datetime.construct.php) and you are best to read about the first parameter from the PHP manual and understand the date/time string formats it accepts. You'll hopefully find yourself rarely using the constructor but rather relying on the explicit static methods for improved readability. 151 212 213`createFromFormat()` is mostly a wrapper for the base php function [DateTime::createFromFormat](http://php.net/manual/en/datetime.createfromformat.php). The difference being again the `$tz` argument can be a DateTimeZone instance or a string timezone value. Also, if there are errors with the format this function will call the `DateTime::getLastErrors()` method and then throw a `InvalidArgumentException` with the errors as the message. If you look at the source for the `createXX()` functions above, they all make a call to `createFromFormat()`. 214 421 422The PHP function `__isset()` is implemented. This was done as some external systems (ex. [Twig](http://twig.sensiolabs.org/doc/recipes.html#using-dynamic-object-properties)) validate the existence of a property before using it. This is done using the `isset()` or `empty()` method. You can read more about these on the PHP site: [__isset()](http://www.php.net/manual/en/language.oop5.overloading.php#object.isset), [isset()](http://www.php.net/manual/en/function.isset.php), [empty()](http://www.php.net/manual/en/function.empty.php). 423 799 800Change the `readme.src.md` and then use the `readme.php` to generate the new `readme.md` file. It can be run at the command line using `php readme.php` from the project root. Maybe someday I'll extract this out to another project or at least run it with a post receive hook, but for now its just a local tool, deal with it. 801common.php https://gitlab.com/thejuskrishna/xmec.git | PHP | 472 lines
1<?php 2 if ( defined( "_COMMON_PHP" ) ) return; 43 // handle configs that have register_globals turned off. 44 // we use $PHP_SELF as the test since it should always be there. 45 // We might need to consider not using globals soon. 45 // We might need to consider not using globals soon. 46 if(!isset($PHP_SELF)) { 47 include ("./include/register_globals.php"); 150 151 // passed to array_walk in read.php and list.php 152 // **TODO: replace using array_flip 379 // include abstraction layer and check if its defined 380 if(!defined("PHORUM_ADMIN") && (empty($PHORUM["dbtype"]) || !file_exists("./db/$PHORUM[dbtype].php"))){ 381 echo "<html><head><title>Phorum Error</title></head><body>Something is wrong. You need to edit common.php and select a database.</body></html>"; 461 while($plugindirname = readdir($dir)) { 462 if($plugindirname[0] != "." && @file_exists("./plugin/$plugindirname/plugin.php") && !empty($PHORUM["plugins"][$plugindirname])){ 463 include("./plugin/$plugindirname/plugin.php");common.php https://gitlab.com/thejuskrishna/xmec.git | PHP | 469 lines
1<?php 2 if ( defined( "_COMMON_PHP" ) ) return; 42 // handle configs that have register_globals turned off. 43 // we use $PHP_SELF as the test since it should always be there. 44 // We might need to consider not using globals soon. 44 // We might need to consider not using globals soon. 45 if(!isset($PHP_SELF)) { 46 include ("./include/register_globals.php"); 149 150 // passed to array_walk in read.php and list.php 151 // **TODO: replace using array_flip 376 // include abstraction layer and check if its defined 377 if(!defined("PHORUM_ADMIN") && (empty($PHORUM["dbtype"]) || !file_exists("./db/$PHORUM[dbtype].php"))){ 378 echo "<html><head><title>Phorum Error</title></head><body>Something is wrong. You need to edit common.php and select a database.</body></html>"; 458 while($plugindirname = readdir($dir)) { 459 if($plugindirname[0] != "." && @file_exists("./plugin/$plugindirname/plugin.php") && !empty($PHORUM["plugins"][$plugindirname])){ 460 include("./plugin/$plugindirname/plugin.php");common.php https://gitlab.com/thejuskrishna/xmecorg.git | PHP | 469 lines
1<?php 2 if ( defined( "_COMMON_PHP" ) ) return; 42 // handle configs that have register_globals turned off. 43 // we use $PHP_SELF as the test since it should always be there. 44 // We might need to consider not using globals soon. 44 // We might need to consider not using globals soon. 45 if(!isset($PHP_SELF)) { 46 include ("./include/register_globals.php"); 149 150 // passed to array_walk in read.php and list.php 151 // **TODO: replace using array_flip 376 // include abstraction layer and check if its defined 377 if(!defined("PHORUM_ADMIN") && (empty($PHORUM["dbtype"]) || !file_exists("./db/$PHORUM[dbtype].php"))){ 378 echo "<html><head><title>Phorum Error</title></head><body>Something is wrong. You need to edit common.php and select a database.</body></html>"; 458 while($plugindirname = readdir($dir)) { 459 if($plugindirname[0] != "." && @file_exists("./plugin/$plugindirname/plugin.php") && !empty($PHORUM["plugins"][$plugindirname])){ 460 include("./plugin/$plugindirname/plugin.php");common.php https://gitlab.com/thejuskrishna/xmec.git | PHP | 472 lines
1<?php 2 if ( defined( "_COMMON_PHP" ) ) return; 43 // handle configs that have register_globals turned off. 44 // we use $PHP_SELF as the test since it should always be there. 45 // We might need to consider not using globals soon. 45 // We might need to consider not using globals soon. 46 if(!isset($PHP_SELF)) { 47 include ("./include/register_globals.php"); 150 151 // passed to array_walk in read.php and list.php 152 // **TODO: replace using array_flip 379 // include abstraction layer and check if its defined 380 if(!defined("PHORUM_ADMIN") && (empty($PHORUM["dbtype"]) || !file_exists("./db/$PHORUM[dbtype].php"))){ 381 echo "<html><head><title>Phorum Error</title></head><body>Something is wrong. You need to edit common.php and select a database.</body></html>"; 461 while($plugindirname = readdir($dir)) { 462 if($plugindirname[0] != "." && @file_exists("./plugin/$plugindirname/plugin.php") && !empty($PHORUM["plugins"][$plugindirname])){ 463 include("./plugin/$plugindirname/plugin.php");config.inc.php https://gitlab.com/Tavousi/PrestaShop.git | PHP | 238 lines
1<?php 2/* 26 27require_once(dirname(__FILE__).'/defines.inc.php'); 28$start_time = microtime(true); 32 33/* Improve PHP configuration to prevent issues */ 34ini_set('upload_max_filesize', '100M'); 43/* No settings file? goto installer... */ 44if (!file_exists(_PS_ROOT_DIR_.'/config/settings.inc.php')) 45{ 76 { 77 if (basename($_SERVER['SCRIPT_NAME']) == 'index.php' && empty($_SERVER['QUERY_STRING'])) 78 $_SERVER['REQUEST_URI'] = dirname($_SERVER['SCRIPT_NAME']).'/'; 132$locale = strtolower(Configuration::get('PS_LOCALE_LANGUAGE')).'_'.strtoupper(Configuration::get('PS_LOCALE_COUNTRY')); 133/* Please do not use LC_ALL here http://www.php.net/manual/fr/function.setlocale.php#25041 */ 134setlocale(LC_COLLATE, $locale.'.UTF-8', $locale.'.utf8');common.php https://gitlab.com/thejuskrishna/xmecorg.git | PHP | 472 lines
1<?php 2 if ( defined( "_COMMON_PHP" ) ) return; 43 // handle configs that have register_globals turned off. 44 // we use $PHP_SELF as the test since it should always be there. 45 // We might need to consider not using globals soon. 45 // We might need to consider not using globals soon. 46 if(!isset($PHP_SELF)) { 47 include ("./include/register_globals.php"); 150 151 // passed to array_walk in read.php and list.php 152 // **TODO: replace using array_flip 379 // include abstraction layer and check if its defined 380 if(!defined("PHORUM_ADMIN") && (empty($PHORUM["dbtype"]) || !file_exists("./db/$PHORUM[dbtype].php"))){ 381 echo "<html><head><title>Phorum Error</title></head><body>Something is wrong. You need to edit common.php and select a database.</body></html>"; 461 while($plugindirname = readdir($dir)) { 462 if($plugindirname[0] != "." && @file_exists("./plugin/$plugindirname/plugin.php") && !empty($PHORUM["plugins"][$plugindirname])){ 463 include("./plugin/$plugindirname/plugin.php");common.php https://gitlab.com/thejuskrishna/xmecorg.git | PHP | 472 lines
1<?php 2 if ( defined( "_COMMON_PHP" ) ) return; 43 // handle configs that have register_globals turned off. 44 // we use $PHP_SELF as the test since it should always be there. 45 // We might need to consider not using globals soon. 45 // We might need to consider not using globals soon. 46 if(!isset($PHP_SELF)) { 47 include ("./include/register_globals.php"); 150 151 // passed to array_walk in read.php and list.php 152 // **TODO: replace using array_flip 379 // include abstraction layer and check if its defined 380 if(!defined("PHORUM_ADMIN") && (empty($PHORUM["dbtype"]) || !file_exists("./db/$PHORUM[dbtype].php"))){ 381 echo "<html><head><title>Phorum Error</title></head><body>Something is wrong. You need to edit common.php and select a database.</body></html>"; 461 while($plugindirname = readdir($dir)) { 462 if($plugindirname[0] != "." && @file_exists("./plugin/$plugindirname/plugin.php") && !empty($PHORUM["plugins"][$plugindirname])){ 463 include("./plugin/$plugindirname/plugin.php");common.php https://gitlab.com/thejuskrishna/xmecorg.git | PHP | 472 lines
1<?php 2 if ( defined( "_COMMON_PHP" ) ) return; 43 // handle configs that have register_globals turned off. 44 // we use $PHP_SELF as the test since it should always be there. 45 // We might need to consider not using globals soon. 45 // We might need to consider not using globals soon. 46 if(!isset($PHP_SELF)) { 47 include ("./include/register_globals.php"); 150 151 // passed to array_walk in read.php and list.php 152 // **TODO: replace using array_flip 379 // include abstraction layer and check if its defined 380 if(!defined("PHORUM_ADMIN") && (empty($PHORUM["dbtype"]) || !file_exists("./db/$PHORUM[dbtype].php"))){ 381 echo "<html><head><title>Phorum Error</title></head><body>Something is wrong. You need to edit common.php and select a database.</body></html>"; 461 while($plugindirname = readdir($dir)) { 462 if($plugindirname[0] != "." && @file_exists("./plugin/$plugindirname/plugin.php") && !empty($PHORUM["plugins"][$plugindirname])){ 463 include("./plugin/$plugindirname/plugin.php");readme.md https://gitlab.com/vineethkrishnan/Laravel-Eloquent-Relationship-Example.git | Markdown | 865 lines
121 122The Carbon class is [inherited](http://php.net/manual/en/keyword.extends.php) from the PHP [DateTime](http://www.php.net/manual/en/class.datetime.php) class. 123 149 150There are several different methods available to create a new instance of Carbon. First there is a constructor. It overrides the [parent constructor](http://www.php.net/manual/en/datetime.construct.php) and you are best to read about the first parameter from the PHP manual and understand the date/time string formats it accepts. You'll hopefully find yourself rarely using the constructor but rather relying on the explicit static methods for improved readability. 151 212 213`createFromFormat()` is mostly a wrapper for the base php function [DateTime::createFromFormat](http://php.net/manual/en/datetime.createfromformat.php). The difference being again the `$tz` argument can be a DateTimeZone instance or a string timezone value. Also, if there are errors with the format this function will call the `DateTime::getLastErrors()` method and then throw a `InvalidArgumentException` with the errors as the message. If you look at the source for the `createXX()` functions above, they all make a call to `createFromFormat()`. 214 421 422The PHP function `__isset()` is implemented. This was done as some external systems (ex. [Twig](http://twig.sensiolabs.org/doc/recipes.html#using-dynamic-object-properties)) validate the existence of a property before using it. This is done using the `isset()` or `empty()` method. You can read more about these on the PHP site: [__isset()](http://www.php.net/manual/en/language.oop5.overloading.php#object.isset), [isset()](http://www.php.net/manual/en/function.isset.php), [empty()](http://www.php.net/manual/en/function.empty.php). 423 799 800Change the `readme.src.md` and then use the `readme.php` to generate the new `readme.md` file. It can be run at the command line using `php readme.php` from the project root. Maybe someday I'll extract this out to another project or at least run it with a post receive hook, but for now its just a local tool, deal with it. 801register.php https://gitlab.com/VoyaTrax/vtCMS2.git | PHP | 342 lines
1<?php 2/** 20 21include __DIR__ . '/header.php'; 22 23if ($GLOBALS['xoopsUser']) { 24 header('location: userinfo.php?uid= ' . $GLOBALS['xoopsUser']->getVar('uid')); 25 exit(); 28if (!empty($_GET['op']) && in_array($_GET['op'], array('actv', 'activate'))) { 29 header('location: ./activate.php' . (empty($_SERVER['QUERY_STRING']) ? '' : '?' . $_SERVER['QUERY_STRING'])); 30 exit(); 37$GLOBALS['xoopsConfigUser'] = $config_handler->getConfigsByCat(XOOPS_CONF_USER); 38if (empty($GLOBALS['xoopsConfigUser']['allow_register'])) { 39 redirect_header('index.php', 6, _US_NOREGISTER); 200// If the last step required SAVE or if we're on the last step then we will insert/update user on database 201if ($current_step > 0 && empty($stop) && (!empty($steps[$current_step - 1]['step_save']) || !isset($steps[$current_step]))) { 202 if ($GLOBALS['xoopsModuleConfig']['profileCaptchaAfterStep1'] == 1 && $current_step > 1) {expedition.class.php https://gitlab.com/ziyahan/dolibarr.git | PHP | 1,181 lines
1<?php 2/* Copyright (C) 2003-2008 Rodolphe Quiedeville <rodolphe@quiedeville.org> 29require_once(DOL_DOCUMENT_ROOT."/core/class/commonobject.class.php"); 30if ($conf->propal->enabled) require_once(DOL_DOCUMENT_ROOT."/comm/propal/class/propal.class.php"); 31if ($conf->commande->enabled) require_once(DOL_DOCUMENT_ROOT."/commande/class/commande.class.php"); 105 106 if (empty($conf->global->EXPEDITION_ADDON_NUMBER)) 107 { 110 111 $file = $conf->global->EXPEDITION_ADDON_NUMBER.".php"; 112 316 // Check parameters 317 if (empty($id) && empty($ref) && empty($ref_ext) && empty($ref_int)) return -1; 318 1129 $url=''; 1130 if (file_exists(DOL_DOCUMENT_ROOT."/includes/modules/expedition/methode_expedition_".strtolower($code).".modules.php") && ! empty($this->tracking_number)) 1131 {tasks.php https://gitlab.com/ziyahan/dolibarr.git | PHP | 349 lines
1<?php 2/* Copyright (C) 2005 Rodolphe Quiedeville <rodolphe@quiedeville.org> 27require ("../main.inc.php"); 28require_once(DOL_DOCUMENT_ROOT."/projet/class/project.class.php"); 29require_once(DOL_DOCUMENT_ROOT."/projet/class/task.class.php"); 29require_once(DOL_DOCUMENT_ROOT."/projet/class/task.class.php"); 30require_once(DOL_DOCUMENT_ROOT."/lib/project.lib.php"); 31require_once(DOL_DOCUMENT_ROOT."/lib/date.lib.php"); 108 { 109 Header("Location: ".DOL_URL_ROOT.'/projet/tasks/index.php'.(empty($_REQUEST["mode"])?'':'?mode='.$_REQUEST["mode"])); 110 exit; 120 { 121 if (empty($_GET["id"]) && empty($_POST["id"])) 122 { 123 // We go back on task list 124 Header("Location: ".DOL_URL_ROOT.'/projet/tasks/index.php'.(empty($_REQUEST["mode"])?'':'?mode='.$_REQUEST["mode"])); 125 exit;document.php git://github.com/Dolibarr/dolibarr.git | PHP | 191 lines
1<?php 2/* Copyright (C) 2003-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org> 29require '../main.inc.php'; 30require_once DOL_DOCUMENT_ROOT.'/core/lib/order.lib.php'; 31require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; 31require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; 32require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; 33require_once DOL_DOCUMENT_ROOT.'/core/lib/sendings.lib.php'; 33require_once DOL_DOCUMENT_ROOT.'/core/lib/sendings.lib.php'; 34require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; 35require_once DOL_DOCUMENT_ROOT.'/expedition/class/expedition.class.php'; 107 // Shipment card 108 $linkback = '<a href="'.DOL_URL_ROOT.'/expedition/list.php?restore_lastsearch_values=1'.(!empty($socid) ? '&socid='.$socid : '').'">'.$langs->trans("BackToList").'</a>'; 109 155 156 $linkback = '<a href="'.DOL_URL_ROOT.'/expedition/list.php'.(!empty($socid) ? '?socid='.$socid : '').'">'.$langs->trans("BackToList").'</a>'; 157info.php git://github.com/Dolibarr/dolibarr.git | PHP | 236 lines
1<?php 2/* Copyright (C) 2003-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org> 29require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; 30require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php'; 31require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; 120 121$linkback = '<a href="'.DOL_URL_ROOT.'/fourn/commande/list.php'.(!empty($socid) ? '?socid='.$socid : '').'">'.$langs->trans("BackToList").'</a>'; 122 195{ 196 if (!empty($user->rights->agenda->myactions->create) || !empty($user->rights->agenda->allactions->create)) 197 { 197 { 198 print '<a class="butAction" href="'.DOL_URL_ROOT.'/comm/action/card.php?action=create'.$out.'&backtopage='.urlencode($_SERVER["PHP_SELF"].'?id='.$object->id).'">'.$langs->trans("AddAction").'</a>'; 199 } 211 $param = '&id='.$object->id; 212 if (!empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param .= '&contextpage='.$contextpage; 213 if ($limit > 0 && $limit != $conf->liste_limit) $param .= '&limit='.$limit;footer.inc.php https://github.com/gerrywastaken/phpmyadmin-GitHubed.git | PHP | 221 lines
1<?php 2/* vim: set expandtab sw=4 ts=4 sts=4: */ 43 * @uses file_exists() 44 * @version $Id: footer.inc.php 11403 2008-07-15 19:03:11Z lem9 $ 45 */ 45 */ 46if (! defined('PHPMYADMIN')) { 47 exit; 52 */ 53require_once './libraries/relation.lib.php'; 54 54 55if (! PMA_isValid($_REQUEST['no_history']) && empty($GLOBALS['error_message']) 56 && ! empty($GLOBALS['sql_query'])) { 199// profiling deactivated due to licensing issues 200if (! empty($GLOBALS['cfg']['DBG']['php']) 201 && ! empty($GLOBALS['cfg']['DBG']['profile']['enable'])) {staffpanel.php https://github.com/delete66/sikevux-s-tracker.git | PHP | 336 lines
116 117 if (!is_file($file_name.'.php') && !empty($file_name) && !preg_match('/.php/', $file_name)) 118 $errors[] = 'Inexistent php file.'; 289 <td align="left"> 290 <a href="/<?php echo rawurlencode($arr['file_name']); ?>.php" title="<?php echo safechar($arr['page_name']); ?>"><?php echo safechar($arr['page_name']); ?></a><br /><font class="small"><?php echo safechar($arr['description']); ?></font> 291 </td> 292 <td> 293 <a href="/userdetails.php?id=<?php echo (int)$arr['added_by']; ?>"><?php echo $arr['username']; ?></a> 294 </td> 306 { 307 ?><b>[</b><a href="<?php echo $_SERVER['PHP_SELF']; ?>?action=edit&id=<?php echo (int)$arr['id']; ?>" title="Edit">E</a><b>]</b><?php 308 } 311 { 312 ?><b>[</b><a href="<?php echo $_SERVER['PHP_SELF']; ?>?action=delete&id=<?php echo (int)$arr['id']; ?>" title="Delete">D</a><b>]</b><?php 313 }readme.md https://github.com/aaronbullard/Litmus.git | Markdown | 865 lines
121 122The Carbon class is [inherited](http://php.net/manual/en/keyword.extends.php) from the PHP [DateTime](http://www.php.net/manual/en/class.datetime.php) class. 123 149 150There are several different methods available to create a new instance of Carbon. First there is a constructor. It overrides the [parent constructor](http://www.php.net/manual/en/datetime.construct.php) and you are best to read about the first parameter from the PHP manual and understand the date/time string formats it accepts. You'll hopefully find yourself rarely using the constructor but rather relying on the explicit static methods for improved readability. 151 212 213`createFromFormat()` is mostly a wrapper for the base php function [DateTime::createFromFormat](http://php.net/manual/en/datetime.createfromformat.php). The difference being again the `$tz` argument can be a DateTimeZone instance or a string timezone value. Also, if there are errors with the format this function will call the `DateTime::getLastErrors()` method and then throw a `InvalidArgumentException` with the errors as the message. If you look at the source for the `createXX()` functions above, they all make a call to `createFromFormat()`. 214 421 422The PHP function `__isset()` is implemented. This was done as some external systems (ex. [Twig](http://twig.sensiolabs.org/doc/recipes.html#using-dynamic-object-properties)) validate the existence of a property before using it. This is done using the `isset()` or `empty()` method. You can read more about these on the PHP site: [__isset()](http://www.php.net/manual/en/language.oop5.overloading.php#object.isset), [isset()](http://www.php.net/manual/en/function.isset.php), [empty()](http://www.php.net/manual/en/function.empty.php). 423 799 800Change the `readme.src.md` and then use the `readme.php` to generate the new `readme.md` file. It can be run at the command line using `php readme.php` from the project root. Maybe someday I'll extract this out to another project or at least run it with a post receive hook, but for now its just a local tool, deal with it. 801DooValidator.php http://doophp.googlecode.com/svn/trunk/ | PHP | 1,222 lines
1<?php 2/** 78 * <?php 79 * //in protected/config/forms/example.php 80 * return array( 129 /** 130 * Use PHP empty method to test for required (or optional) 131 */ 131 */ 132 const REQ_MODE_NULL_EMPTY = 'nullempty'; 133 322 323 $vIsEmpty = ($this->requireMode == DooValidator::REQ_MODE_NULL_EMPTY && ($v === null || $v === '') || 324 $this->requireMode == DooValidator::REQ_MODE_NULL_ONLY && $v === null) ? true : false; 923 /** 924 * Validate Not Empty. Input cannot be empty. 925 *pagecompiler._wc http://openconstructor.googlecode.com/svn/trunk/ | Unknown | 655 lines
214 foreach($objects as $id => $obj) 215 if($obj['observer'] && $obj['type'] == 'phpcallback' && $obj['block'] != '') 216 $phpcallback[] = sprintf("\$ctx->_attachEventListener('%s', %s);", $obj['block'], PageCompiler::_getCreateObserverStatement($id)); 385 foreach($objects as $id => $obj) 386 if($obj['block'] == 'PRE' && ($obj['type'] == 'phpinclude' || $obj['type'] == 'phpcallback')) 387 $pre[] = "\$ctx->objects[$id]->run();"; 499 $url = parse_url("http://{$_SERVER['HTTP_HOST']}{$page->location}"); 500 if(substr($url['path'], -10) == '/index.php' && empty($url['fragment'])) { 501 $uri = substr($url['path'], 0, -9); 512 } 513 } elseif(($p = utf8_strpos($url['path'], '/index.php/')) !== false && empty($url['fragment'])) { 514 $uri = utf8_substr($url['path'], 0, $p + 1); 618 'phpcallback'=>'/phpsource/phpcallback._wc', 619 'phpinclude'=>'/phpsource/phpinclude._wc', 620 'gballmessages'=>'/guestbook/gballmessages._wc',