Dataset Viewer (First 5GB)
Auto-converted to Parquet Duplicate
code
stringlengths
1
2.01M
language
stringclasses
1 value
<?php function sitemap_after_process() { if (isset ( $_GET ['p'] ) && $_GET ['p'] == 'sitemap.xml') { global $main_menu; $out = '<?xml version="1.0" encoding="UTF-8"?>'; $out .= '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">'; foreach ( $main_menu->items as $item ) { $out.="<url>"; ...
PHP
<li class="<?php if ($this->active) echo "active" ?>"> <a href="<?php echo $this->link?>"><?php echo $this->title ?></a> </li>
PHP
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html dir="ltr" xmlns="http://www.w3.org/1999/xhtml" lang="en-US"> <head> <title>Gelsheet: The opensource web spreadsheet</title> <meta http-equiv="Content-Type" content="text/html; charset=UT...
PHP
<?php include_once 'header.php' ?> <div id="main_content" class="fix" > <div class="content fix"> <?php $page->output() ;?> </div> <!-- end .content --> </div> <?php include_once 'footer.php' ?>
PHP
<li> <a class="wintrolink wanchorLink <?php if ($this->active) echo "active" ?>" href="<?php echo $this->link?>"><?php echo $this->title ?></a> </li>
PHP
<!DOCTYPE html> <html lang="en"> <head> <title>Zero query - No Database CMS</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <!--[if IE]> <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script> <![endif]--> <!--[if IE 7]> <l...
PHP
<?php get_header()?> <h2>Not found</h2> <?php get_footer()?>
PHP
<?php get_header() ?> <?php get_page() ?> <?php get_footer() ?>
PHP
<header> Zero query Mobile </header> <?php get_page() ?> <footer> <?php get_footer() ?> </footer>
PHP
<?php /** * Mobile Detect * $Id: Mobile_Detect.php 44 2012-05-03 21:45:00Z serbanghita@gmail.com $ * * @usage require_once 'Mobile_Detect.php'; * $detect = new Mobile_Detect(); * $detect->isMobile() or $detect->isTablet() * * For more specific usage see the do...
PHP
<?php // TODO Move all core functions to here and deprecate plugin_engine function baseurl() { $protocol = ! empty ( $_SERVER ['HTTPS'] ) ? "https" : "http"; return rtrim ( $protocol . "://" . $_SERVER ['HTTP_HOST'] . dirname ( $_SERVER ['SCRIPT_NAME'] ), "/" ); } function load_libraries() { global $CON...
PHP
<?php function get_header() { global $page ; if ( file_exists(TEMPLATE_PATH."header.php") ){ include_once TEMPLATE_PATH."header.php"; } } function get_footer() { global $page ; if ( file_exists(TEMPLATE_PATH."footer.php") ){ include_once TEMPLATE_PATH."footer.php"; } } function get_s...
PHP
<?php function fire($event){ global $CONF ; if (!empty($CONF['plugins'])){ foreach ($CONF['plugins'] as $plgname) { include_once ROOT."/plugins/".$plgname.".php"; $functionName = $plgname."_".$event; if ( function_exists($functionName) ) { return call_user_func($functionName); } } } }
PHP
<?php session_start(); global $CONF ; global $page ; define ('TEMPLATES_PATH',"templates/") ; define ('TEMPLATE_PATH', TEMPLATES_PATH."/".$CONF['template']."/") ; define ('BASE_URL', baseurl()); load_libraries(); fire('before_process'); $pages_dir = "content/pages/" ; $content = new Content (...
PHP
<?php /** * * Enter description here ... * @author pepe * */ class Content { /** * * Enter description here ... * @var Page */ var $current_page = null ; /** * * Enter description here ... * @var unknown_type */ var $home = null ; /** * * Enter descrip...
PHP
<?php class Page { var $path ; var $alias ; var $id ; var $css = null ; var $content ; function __construct($path = null , $alias = null, $id = null ) { $this->alias = $alias ; $this->path = "content/pages/$path/"; $this->id = ($id) ? $id : $alias ; } function outp...
PHP
<?php class Menu { var $output ; /** * * Enter description here ... * @var unknown_type */ var $items = array (); /** * Identifier of the menu */ var $name = null ; private $_items_index = array (); function output() { if ($this->output) return $this->output...
PHP
<?php class MenuItem { /** * * Enter description here ... * @param MenuItem $a * @param MenuItem $b */ static function compare($a, $b ) { if ($a->order == $b->order) { return 0; } return ($a->order < $b->order) ? -1 : 1; } /** * Identifier like 'home' , 'abo...
PHP
<?php $CONF['home']= "home" ; $CONF['cleanurls'] = true ; $CONF['template'] = 'portfolio' ; $CONF['plugins'] = array('sitemap'); $CONF['libraries'] = array('Mobile_Detect');
PHP
<?php /* * @author Ignacio Vazquez - ivazquez at adooxen.com * @version 1.4 Beta * */ define ('ROOT',dirname(__FILE__)); include_once "config.php" ; include_once 'core/functions.php'; include_once 'core/classes/Content.class.php'; include_once "core/classes/MenuItem.class.php" ; include_o...
PHP
<?php function sitemap_after_process() { if (isset ( $_GET ['p'] ) && $_GET ['p'] == 'sitemap.xml') { global $main_menu; $out = '<?xml version="1.0" encoding="UTF-8"?>'; $out .= '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">'; foreach ( $main_menu->items as $item ) { $out.="<url>"; ...
PHP
<li class="<?php if ($this->active) echo "active" ?>"> <a href="<?php echo $this->link?>"><?php echo $this->title ?></a> </li>
PHP
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html dir="ltr" xmlns="http://www.w3.org/1999/xhtml" lang="en-US"> <head> <title>Gelsheet: The opensource web spreadsheet</title> <meta http-equiv="Content-Type" content="text/html; charset=UT...
PHP
<?php include_once 'header.php' ?> <div id="main_content" class="fix" > <div class="content fix"> <?php $page->output() ;?> </div> <!-- end .content --> </div> <?php include_once 'footer.php' ?>
PHP
<li> <a class="wintrolink wanchorLink <?php if ($this->active) echo "active" ?>" href="<?php echo $this->link?>"><?php echo $this->title ?></a> </li>
PHP
<!DOCTYPE html> <html lang="en"> <head> <title>MinCMS - The easyest way to build your site</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <!--[if IE]> <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script> <![endif]--> <!--[if...
PHP
<?php get_header()?> <h2>Not found</h2> <?php get_footer()?>
PHP
<?php get_header() ?> <?php get_page() ?> <?php get_footer() ?>
PHP
<?php function baseurl() { $protocol = !empty($_SERVER ['HTTPS']) ? "https" : "http"; return rtrim($protocol . "://" . $_SERVER ['HTTP_HOST'] .dirname($_SERVER ['SCRIPT_NAME']),"/"); }
PHP
<?php function get_header() { global $page ; if ( file_exists(TEMPLATE_PATH."header.php") ){ include_once TEMPLATE_PATH."header.php"; } } function get_footer() { global $page ; if ( file_exists(TEMPLATE_PATH."footer.php") ){ include_once TEMPLATE_PATH."footer.php"; } } function get_s...
PHP
<?php function fire($event){ global $CONF ; if (!empty($CONF['plugins'])){ foreach ($CONF['plugins'] as $plgname) { include_once ROOT."/plugins/".$plgname.".php"; $functionName = $plgname."_".$event; if ( function_exists($functionName) ) { return call_user_func($functionName); } } } }
PHP
<?php global $CONF ; global $page ; define ('TEMPLATES_PATH',"templates/") ; define ('TEMPLATE_PATH', TEMPLATES_PATH."/".$CONF['template']."/") ; define ('BASE_URL', baseurl()); fire('before_process'); $pages_dir = "content/pages/" ; $content = new Content (); $main_menu = new Menu(); $mai...
PHP
<?php /** * * Enter description here ... * @author pepe * */ class Content { /** * * Enter description here ... * @var Page */ var $current_page = null ; /** * * Enter description here ... * @var unknown_type */ var $home = null ; /** * * Enter descrip...
PHP
<?php class Page { var $path ; var $alias ; var $id ; var $css = null ; var $content ; function __construct($path = null , $alias = null, $id = null ) { $this->alias = $alias ; $this->path = "content/pages/$path/"; $this->id = ($id) ? $id : $alias ; } function outp...
PHP
<?php class Menu { var $output ; /** * * Enter description here ... * @var unknown_type */ var $items = array (); /** * Identifier of the menu */ var $name = null ; private $_items_index = array (); function output() { if ($this->output) return $this->output...
PHP
<?php class MenuItem { /** * * Enter description here ... * @param MenuItem $a * @param MenuItem $b */ static function compare($a, $b ) { if ($a->order == $b->order) { return 0; } return ($a->order < $b->order) ? -1 : 1; } /** * Identifier like 'home' , 'abo...
PHP
<?php $CONF['home']= "home" ; $CONF['cleanurls'] = true ; $CONF['template'] = 'portfolio' ; $CONF['plugins'] = array('sitemap');
PHP
<?php /* * @author Ignacio Vazquez - ivazquez at adooxen.com * @version 1.4 Beta * */ define ('ROOT',dirname(__FILE__)); include_once "config.php" ; include_once 'core/functions.php'; include_once 'core/classes/Content.class.php'; include_once "core/classes/MenuItem.class.php" ; include_o...
PHP
<li class="<?php if ($this->active) echo "active" ?>"> <a href="<?php echo $this->link?>"><?php echo $this->title ?></a> </li>
PHP
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html dir="ltr" xmlns="http://www.w3.org/1999/xhtml" lang="en-US"> <head> <title>Gelsheet: The opensource web spreadsheet</title> <meta http-equiv="Content-Type" content="text/html; charset=UT...
PHP
<?php include_once 'header.php' ?> <div id="main_content" class="fix" > <div class="content fix"> <?php $page->output() ;?> </div> <!-- end .content --> </div> <?php include_once 'footer.php' ?>
PHP
<li> <a class="wintrolink wanchorLink <?php if ($this->active) echo "active" ?>" href="<?php echo $this->link?>"><?php echo $this->title ?></a> </li>
PHP
<!DOCTYPE html> <html lang="en"> <head> <title>MinCMS - The easyest way to build your site</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <!--[if IE]> <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script> <![endif]--> <!--[if...
PHP
<?php get_header()?> <h2>Not found</h2> <?php get_footer()?>
PHP
<?php get_header() ?> <?php get_page() ?> <?php get_footer() ?>
PHP
<?php function get_header() { global $page ; if ( file_exists(TEMPLATE_PATH."header.php") ){ include_once TEMPLATE_PATH."header.php"; } } function get_footer() { global $page ; if ( file_exists(TEMPLATE_PATH."footer.php") ){ include_once TEMPLATE_PATH."footer.php"; } } function get_sidebar(){} functi...
PHP
<?php global $CONF ; global $page ; define ('TEMPLATES_PATH',"templates/") ; define ('TEMPLATE_PATH', TEMPLATES_PATH."/".$CONF['template']."/") ; $pages_dir = "content/pages/" ; $content = new Content (); $main_menu = new Menu(); $main_menu->name = "mainMenu" ; // Scan pages files $fir...
PHP
<?php /** * * Enter description here ... * @author pepe * */ class Content { /** * * Enter description here ... * @var Page */ var $current_page = null ; /** * * Enter description here ... * @var unknown_type */ var $home = null ; /** * * Enter descrip...
PHP
<?php class Page { var $path ; var $alias ; var $id ; var $css = null ; var $content ; function __construct($path = null , $alias = null, $id = null ) { $this->alias = $alias ; $this->path = "content/pages/$path/"; $this->id = ($id) ? $id : $alias ; } function outp...
PHP
<?php class Menu { var $output ; /** * * Enter description here ... * @var unknown_type */ var $items = array (); /** * Identifier of the menu */ var $name = null ; private $_items_index = array (); function output() { if ($this->output) return $this->output...
PHP
<?php class MenuItem { /** * * Enter description here ... * @param MenuItem $a * @param MenuItem $b */ static function compare($a, $b ) { if ($a->order == $b->order) { return 0; } return ($a->order < $b->order) ? -1 : 1; } /** * Identifier like 'home' , 'a...
PHP
<?php $CONF['home']= "home" ; $CONF['cleanurls'] = true ; $CONF['template'] = 'portfolio' ; $CONF['autoSitemap'] = true ; //TODO will be available on future versions
PHP
<?php /* * @author Pepe - pepe at phpepe.com */ include_once "config.php" ; include_once 'core/classes/Content.class.php'; include_once "core/classes/MenuItem.class.php" ; include_once "core/classes/Menu.class.php" ; include_once "core/classes/Page.class.php" ; include_once "core/template_eng...
PHP
<?php $dbhost = 'localhost:3306'; $dbuser = 'root'; $dbpw = 'root'; $dbname = 'china100'; $database = 'mysql'; $pconnect = '0'; $charset = 'utf8'; ?> <?php //$dbhost = '121.15.221.95:3306'; //$dbuser = 's510437db0'; //$dbpw = 'g53vzqta'; //$dbname = 's510437db0'; //$database = 'mysql'; //$pconnect = '0...
PHP
<?php return array ( 'sys_name'=>'中国百分百网', 'fr_theme' => 'simple', 'cookpifix'=>'100china_' );
PHP
<?php define('DR', dirname(__FILE__)); require 'include/front.php'; ?>
PHP
<?php class Welcome extends AdminAction{ function index(){ $sysinfo = loadData('sysinfo.php'); $this->data['title'] = $sysinfo['sys_name'].' - 登入'; template('welcome',$this->data); } function login(){ $db = $this->getDB(); $username = P('username'); $userpass = P('userpass'); $rember...
PHP
<?php class Article extends AdminAction{ function alist(){ $this->data['selectitem'] = 'article'; template('art_alist',$this->data); } }
PHP
<?php include incTemplate('panel_top.php'); ?> <?php print_r($HTTP_COOKIE_VARS);?> <?php include incTemplate('panel_bottom.php'); ?>
PHP
<?php include incTemplate('header.php'); ?> <script type="text/javascript"> $(function(){ $(".sp_btn").button(); $(".sp_btn").click(function(){ var username = getVal("username"); var userpass = getVal("userpass"); var rember = getAttr("rember","checked")=="checked"?1:0; $.post('admin.php/welcome/logi...
PHP
<div class="menulist"> <div class="menu"> <ul> <li <?php if($selectitem == 'control'){?>class="top"<?php }?>> <div class="menu-img control "></div> <div class="toggle" id="tg_control"></div> <?php if($selectitem == 'control'){ ?> <div class="menu-arrow"><div></div></div> <a class="itemselect">控制板...
PHP
<?php include incTemplate('header.php'); ?> <script type="text/javascript"> var menuarray ='<?php echo $menulist;?>'; var menuadds = '<?php echo $menulist;?>'; var cookpifix = '<?php echo $sysinfo['cookpifix'];?>'; var menulist = '<?php echo $menulist;?>'; $(function(){ $(".menu ul li").hover( function ()...
PHP
<?php include incTemplate('panel_top.php'); ?> <?php print_r($_COOKIE);?> <?php include incTemplate('console_panel.php'); ?> <?php include incTemplate('panel_bottom.php'); ?>
PHP
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head> <base href="<?php echo HH;?>" /> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title><?php echo $title;?></ti...
PHP
<?php print_r($_COOKIE); //phpinfo();
PHP
<?php define('DR', dirname(__FILE__)); require 'include/admin.php';
PHP
<?php class Welcome extends FrontAction{ function index(){ template('index',$this->data); } }
PHP
<?php function loadAdmin($action){ require 'admin/'.$action.'.php'; $action = ucfirst($action); $act = new $action();; return $act; } function template($page,$data=null){ if(sizeof($data)>=1){ extract($data); } if(is_array($page)){ foreach($page as $p){ require 'admin/template/'.$p.'.php';...
PHP
<script type="text/javascript"> var jumpnum = 1; function setJumpNum(jump){ jumpnum = jump; } </script> <?php class PageSplit{ function getPageCount($pagesize,$rownums){ $pagecount = (int)($rownums%$pagesize==0?(int)($rownums/$pagesize):(int)(($rownums/$pagesize)+1)); return $pagecount; } function...
PHP
<?php class AdminAction{ public $data; public $lang; function __construct(){ $this->loadData(); $this->init(); } function init(){ $this->getMenuList(); } function loadData(){ global $sysinfo; $this->data = array(); $this->data['sysinfo'] = $sysinfo; } function getMenuLis...
PHP
<?php class FrontAction{ public $data; function __construct(){ $this->data = array(); } function getDB(){ require 'config/db.php'; require 'inc/mysql.php'; return $db = new mysql($dbhost, $dbuser, $dbpw, $dbname, $pconnect,$charset); } }
PHP
<?php !defined('HH') && exit('Forbidden'); class mysql{ private $db_host; //数据库主机 private $db_user; //数据库用户名 private $db_pwd; //数据库用户名密码 private $db_database; //数据库名 private $conn; //数据库连接标识; private $result; //执行query命令的结果资源标识 private $sql; //sql执行语句 private $row; //返...
PHP
<?php session_start(); function P($key){ return $_POST["$key"]; } function G($key){ return $_GET["$key"]; } function getSession($key){ return $_SESSION[$key]; } function setSession($key,$value){ $_SESSION[$key] = $value; } function setCk($name,$value,$expire){ global $sysinfo; setcookie($sysinfo['...
PHP
<?php session_start(); define('HH','http://'.$_SERVER['HTTP_HOST'].'/'); define('HT',HH.'admin/template/'); require 'include/fun.php'; require 'include/admin_fun.php'; require 'include/admin_action.php'; $sysinfo = loadData('sysinfo.php'); $nav=$_SERVER['REQUEST_URI']; $script=$_SERVER['SCRIPT_NAME']; $...
PHP
<?php session_start(); define('HH','http://'.$_SERVER['HTTP_HOST'].'/'); require DR.'/include/fun.php'; require DR.'/include/front_fun.php'; require DR.'/include/front_action.php'; /*加载必要的系统信息*/ $sysinfo = loadData('sysinfo.php'); $nav=$_SERVER['REQUEST_URI']; $nav=str_replace('.html','',$nav); $script=...
PHP
<?php /*前台方法*/ /** * 加载ACTION文件 * @param $action * @return 加载ACTION的实例 */ function loadAction($action){ require DR.'/require/'.$action.'.php'; $action = ucfirst($action); if (class_exists($action)) { $act = new $action();; return $act; } } function template($page,$data=null){ global $sysin...
PHP
<?php session_start(); $_SESSION['re_code']=''; $type = 'gif'; $width= 38; $height= 18; header("Content-type: image/".$type); srand((double)microtime()*1000000); $randval = randStr(4,"ALL"); if($type!='gif' && function_exists('imagecreatetruecolor')){ $im = @imagecreatetruecolor($width,$height); }else{ ...
PHP
<?php class File{ function uploadfile($filename,$loacation){ $ftype = getSuffix($_FILES[$filename]["name"]); $attachid = uuid2(); $fname = $attachid.$ftype; $datestr = date('Y-m-d'); if(!file_exists(DR.'/'.$loacation.'/'.$datestr)){ mkdir(DR.'/'.$loacation.'/'.$datestr); } $floc = DR.'/'....
PHP
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Keep It Simple</title> <base href="<?php echo HT;?>" /> <link r...
PHP
<?php include 'configure.php'; $func = $_POST['func']; if($func == "addNum") { $id = $_POST['id']; $result = mysql_query("select * from components where uid = $id"); if($row = mysql_fetch_array($result)) { $num = $row["num"]; $num++; $query = "update components set num = $num where uid ...
PHP
<?php include "configure.php"; htmlhead("添加元件"); htmlheadend(); ?> <?php if(isset($_GET['posted'])) { if($_GET['posted'] == "insert") { if($_GET['type'] == "new") { $query = "insert into comptype (name) values ('$_GET[newcomptype]')"; if(!mysql_query($query)) die("dabiaozi,databas...
PHP
<?php define('ABSPATH', dirname(dirname(__FILE__)) . '\\'); $domain = ""; $jquerylib = $domain . "jQuerylib/jquery-1.4.4.min.js"; $jqueryui = $domain . "jQuerylib/jquery-ui-1.8.9.custom.min.js"; $jslib = $domain . "js"; $jqueryuitheme = $domain . "css/custom-theme3/jquery-ui-1.8.10.custom.css"; ...
PHP
<?php include "configure.php"; htmlhead("117元件管理系统"); addjs("control.js"); htmlheadend(); ?> <img src="css/pic/logo.jpg" /><br> <a href='addcomp.php' title='添加元件' class='yage_button'>添加</a> <a href='inport.php' title='导入csv文件' class='yage_button'>导入</a> <a href="export.php" title="导出csv文件" ...
PHP
<?php /******************************** * function: jumphtml * paraments: html location * return none */ function jumphtml($location) { echo "<script type='text/javascript'>window.location.replace('" . $domain . $location . "');</script>"; } function htmlhead($title="undefined",$ui="nui"...
PHP
<?php include "configure.php"; $Date = date("Y-m-d"); $Filename = $Date.".csv"; header("Content-type:application/vnd.ms-excel"); header("Content-Disposition:filename=".$Filename); $query = "select * from comptype"; $result = mysql_query($query); while ($row = mysql_fetch_array($result)) $typ...
PHP
<?php /* * Load sample data */ include 'data.php'; /* * Results array */ $results = array(); /* * Autocomplete formatter */ function autocomplete_format($results) { foreach ($results as $result) { echo $result[0] . '|' . $result[1] . "\n"; } } /* * Search for term if it is given */ if (isset...
PHP
<?php $data = array( "Great Bittern" => "Botaurus stellaris", "Little Grebe" => "Tachybaptus ruficollis", "Black-necked Grebe" => "Podiceps nigricollis", "Little Bittern" => "Ixobrychus minutus", "Black-crowned Night Heron" => "Nycticorax nycticorax", "Purple Heron" => "Ardea purpurea", "Wh...
PHP
<?php require_once('include/header.php'); require_once('dao/ImagenesDAO.php'); require_once('logic/ImagenesLogic.php'); require_once('search/ImagenesSearchCriteria.php'); $logic = new ImagenesLogic($_POST); // obtener action $action = $_GET['action']; if ($action == null){ $action = $_POST['action']; ...
PHP
<?php require_once('search/SearchCriteria.php'); Class ImageSearchCriteria extends SearchCriteria{ private $idItem; private $fecha; private $table; function getIdItem() { return $this->idItem; } function getFecha() { return $this->fecha; } function getTable() { return $this->table; } func...
PHP
<?php require_once('search/SearchCriteria.php'); Class AvisosSearchCriteria extends SearchCriteria{ private $fecha = null; private $search = null; public function getFecha(){ return $this->fecha; } public function setFecha($fecha){ $this->fecha = $fecha; } public function getSearch()...
PHP
<?php Class SearchCriteria{ private $id; private $inicio = 1; private $fin; private $activo; private $borrado = 0; private $orderby; private $order; function getId(){ return $this->id; } function setId($id){ $this->id = $id; } function getInicio(){ return $this->inicio; } ...
PHP
<?php require_once('search/SearchCriteria.php'); require_once('plugin/UtilsPlugin.php'); class NoticiasSearchCriteria extends SearchCriteria { private $titulo = null; private $tags = null; private $fechaFrom = null; private $fechaTo = null; private $categoria = null; private $seccion = null; pri...
PHP
<?php require_once('search/SearchCriteria.php'); Class ClientesSearchCriteria extends SearchCriteria{ private $nombre = null; private $ciudad = null; private $active = null; private $fecha = null; private $search = null; public function getNombre(){ return $this->nombre; } public funct...
PHP
<?php require_once('search/SearchCriteria.php'); Class UsuarioSearchCriteria extends SearchCriteria{ private $username = null; private $rol = null; public function getUsername(){ return $this->username; } public function setUsername($username){ $this->username = $username; } public...
PHP
<?php require_once('search/SearchCriteria.php'); Class ImagenesSearchCriteria extends SearchCriteria{ private $idItem; private $fecha; private $table; function getIdItem() { return $this->idItem; } function getFecha() { return $this->fecha; } function getTable() { return $this->table; } f...
PHP
<?php require_once('search/SearchCriteria.php'); Class ContenidoSearchCriteria extends SearchCriteria{ private $search = null; private $titulo = null; public function getTitulo(){ return $this->titulo; } public function setTitulo($titulo){ $this->titulo = $titulo; } public function ge...
PHP
<?php require_once('search/SearchCriteria.php'); Class ContactoSearchCriteria extends SearchCriteria{ private $empresa = null; private $nombre = null; public function getEmpresa(){ return $this->empresa; } public function setEmpresa($empresa){ $this->empresa = $empresa; } public funct...
PHP
<?php require_once('include/header.php'); require_once('vo/ContenidoVO.php'); require_once('search/ContenidoSearchCriteria.php'); require_once('logic/ContenidoLogic.php'); require_once('logic/ImagenesLogic.php'); require('conf/configuration.php'); $logic = new ContenidoLogic($_POST); $imagenesLogic = new Ima...
PHP
<?php // Include include_once('plugin/LoginPlugin.php'); // Chequea si el usuario ya esta logueado if (LoginPlugin::isLogged()) { LoginPlugin::logout(); } header( 'Location: index.php' ); exit;
PHP
<?php include_once('plugin/LoginPlugin.php'); include_once('plugin/AppConfigPlugin.php'); include_once('plugin/CommonPlugin.php'); $rol = LoginPlugin::getRol(); $menuItems = AppConfigPlugin::getMenuItems($rol); $scriptPhp = $menuItems[0][script]; header('Location: contenido.php'); ?>
PHP
End of preview. Expand in Data Studio

PHP-Code-Large

PHP-Code-Large is a large-scale corpus of PHP source code comprising more than 12 million lines of PHP code. The dataset is designed to support research in large language model (LLM) pretraining, code intelligence, software engineering automation, and static program analysis for the PHP ecosystem.

By providing a high-volume, language-specific corpus, PHP-Code-Large enables systematic experimentation in PHP-focused model training, domain adaptation, and downstream code understanding tasks.

PHP-Code-Large addresses the need for a dedicated PHP-only dataset at substantial scale, enabling focused research across backend systems, CMS platforms, APIs, and full-stack PHP environments.

1. Dataset Composition

Programming Language: PHP Total Size: 12M+ lines of PHP code File Format: .jsonl Primary Content: PHP source code files

Each JSONL entry contains structured information about a single PHP code.

Content Types

The dataset includes a wide variety of PHP constructs and paradigms, such as:

  • Functions (declarations, anonymous functions, arrow functions)

  • Object-Oriented Programming (classes, traits, interfaces)

  • Namespaces and autoloading patterns

  • Composer-based dependency structures

  • MVC architecture patterns

  • REST API implementations

  • Database interaction (PDO, MySQLi)

  • Form handling and validation

  • Session and cookie management

  • Middleware patterns

  • Error and exception handling

  • Legacy PHP (5.x style) and modern PHP (7.x / 8.x) features

  • Type declarations and strict typing

  • Templating integrations

  • Security-related patterns (sanitization, hashing, authentication logic)

  • PHPDoc comments

  • CMS and framework-style architecture patterns

2. Intended Research Applications

2.1 Pretraining

  • Training PHP code foundation models from scratch

  • Continued pretraining of existing LLMs

  • PHP-specialized language modeling

  • Tokenizer training for PHP ecosystems

  • Domain adaptation for backend-focused models

2.2 Fine-Tuning and Adaptation

  • Code completion systems

  • Intelligent IDE assistants

  • Automated refactoring tools

  • Conversational programming agents

  • PHP-specific copilots

  • Framework-aware coding assistants

2.3 Code Intelligence Tasks

  • Code summarization

  • Code-to-text generation

  • Documentation generation

  • Bug detection

  • Security vulnerability detection

  • Clone detection

  • Code similarity modeling

  • Dead code detection

  • Static and structural analysis

  • Legacy-to-modern PHP migration modeling

2.4 Software Engineering Research

  • Empirical studies of PHP coding patterns

  • Analysis of backend architecture styles

  • Framework usage studies

  • Dependency and autoloading modeling

  • AST-based experimentation

  • Cross-version PHP evolution analysis

  • Security practice analysis in web applications

3. Ecosystem Coverage

PHP-Code-Large spans a broad range of PHP application domains, including:

  • Backend web applications

  • RESTful APIs

  • CMS-based architectures

  • E-commerce platforms

  • CLI tools

  • Microservices

  • Full-stack PHP projects

The dataset captures both legacy monolithic architectures.

Thanks to open source community for all the guidance & support!!

Downloads last month
129

Collection including Ujjwal-Tyagi/PHP-Code-Large