blob_id
stringlengths
40
40
language
stringclasses
1 value
repo_name
stringlengths
5
116
path
stringlengths
2
241
src_encoding
stringclasses
31 values
length_bytes
int64
14
3.6M
score
float64
2.52
5.13
int_score
int64
3
5
detected_licenses
listlengths
0
41
license_type
stringclasses
2 values
text
stringlengths
14
3.57M
download_success
bool
1 class
bad328b7878eed4cbf6c64af2aec523525d71a39
PHP
PierreThiollent/Mini-CMS-with-Symfony
/src/Controller/ArticlesController.php
UTF-8
1,413
2.59375
3
[]
no_license
<?php namespace App\Controller; use App\Entity\Articles; use Doctrine\ORM\EntityManagerInterface; use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\Routing\Annotation\Route; class Artic...
true
d414cd3a0dc0a1338fc31d4dca00299b631446f1
PHP
bezoerb/generator-shopware
/generators/theme/templates/_common/_private/smarty/function.img.php
UTF-8
4,301
2.765625
3
[ "MIT" ]
permissive
<?php /** * Builds either an picture element or an image with srcset based on the params. * The params array knows the following key: * - image: * - desktop: explicit desktop image * - mobile: explicit mobile image * - className: optional className * - alt: optional alt tag * - breakpoint: optional breakpoint f...
true
eb613e0d2206fa21f434695cc8d2bf8ea8963f8c
PHP
tamalsarker/eye2016
/inc/widgets/eye-header-right.php
UTF-8
2,757
2.6875
3
[]
no_license
<?php /** * @package WordPress * @subpackage bseye * @version 1.0.0 * * Custom Theme Widgets * Created by TemplateEYE * */ class EYE_HeaderRightWidget extends WP_Widget { /** constructor */ function EYE_HeaderRightWidget() { parent::WP_Widget(false, $name = 'Header - Right'); } /** @s...
true
cecb2fdb493d6203fdde50a152573cfddb5b1e77
PHP
gallobone/curso-php
/POO/exemplo-4.php
UTF-8
1,862
3.875
4
[]
no_license
<?php //Aula sobre MÉTODOS MÁGICOS. /* MÉTODO CONSTRUTOR: É executado sempre que você instancia um objeto de uma classe. No PHP é considerado um "MÉTODO MÁGICO" Uma regra antiga para definir que um método era um "método construtor", era que o método tivesse o mesmo nome da Classe No PHP, você podia fazer desta form...
true
4d8ebd4087f7d39c20823ac8f703fc2c38983c11
PHP
point-red/point
/app/Console/Commands/Hub/ResetHubDatabase.php
UTF-8
1,212
2.609375
3
[ "MIT" ]
permissive
<?php namespace App\Console\Commands\Hub; use Illuminate\Console\Command; use Illuminate\Support\Facades\Artisan; class ResetHubDatabase extends Command { /** * The name and signature of the console command. * * @var string */ protected $signature = 'hub:database:reset {db_name?}'; /...
true
8f2e135eef81cbaa60274d2ab5e5a0ada737fe61
PHP
IgnacioCharlin/ProgramacionWeb2
/charlin-ignacio-tp2/ejercicio-6/datos.php
UTF-8
1,605
3.109375
3
[]
no_license
<?php include_once ('../header.php'); if (isset($_POST['nombre']) && isset($_POST['planeta'])) { $nombre = $_POST['nombre']; $planeta = $_POST['planeta']; $file = 'visitantes.json'; $contadorVisitantesNoTierra=0; //Leemos lo que tiene el archivo json $datos_client...
true
5a69944805aecbe518652eac430577c3ddc06016
PHP
daniloaugusto0212/rede_social
/painel/pages/calendario.php
UTF-8
4,392
2.5625
3
[]
no_license
<?php $mes = isset($_GET['mes']) ? (int)$_GET['mes'] : date('m', time()); $ano = isset($_GET['ano']) ? (int)$_GET['ano'] : date('Y', time()); // $mes = date('m',time()); // $ano = date('Y',time()); if ($mes > 12) { $mes = 12; } if ($mes < 1) { $mes = 1; } $numeroDi...
true
83a0189ee00d8855ccaa28976cf6343eec7119fc
PHP
JayCreations/XSS-Example
/Comments.php
UTF-8
1,676
3.203125
3
[ "MIT" ]
permissive
<?php /** * Class Presentation on XSS * * @package XSS * @version 0.1 * @author Juan "JayCreations" Hernandez * @license MIT * @copyright 2011 Juan J. Hernandez * @link https://github.com/JayCreations/XSS-Example */ // No direct access. if (!defined('XSS')) die('Direct access not allowed.'); class Com...
true
2be3e982076d87491d2f3d9b1b57ef4d69daf062
PHP
pechatnov/bitrix-skeleton-fork
/app/autoload/Core/Traits/DiamondPacket/ImportDiamondPacketCleanTrait.php
UTF-8
1,398
2.796875
3
[]
no_license
<?php namespace App\Core\Traits\DiamondPacket; use App\Models\Catalog\HL\DiamondPacket; use App\Models\Catalog\HL\PacketAdditionalInfo; /** * Trait ImportDiamondPacketCleanTrait * Трейт удаления записей из таблиц diamond_packet (HL: DiamondPacket) и packet_additional_info (HL: PacketAdditionalInfo). * Для импорта...
true
20cdf639872b40d3fab9ddc598a31e2e04e0a987
PHP
YaroslavOrlov/Time2Read
/models/Author.php
UTF-8
1,390
2.875
3
[]
no_license
<?php class Author { public static function getAuthorBooks($id) { $db = Db::getConnection(); $query = "SELECT b1.BookId, b1.Name, COUNT(m1.BookId), SUM(m1.Mark) FROM Books b1 RIGHT JOIN Marks m1 ON b1.BookId = m1.BookId ...
true
84a046ff1ce86572eee982dd29f5da77de38d347
PHP
qianfunian/fandian
/library/Msd/Service/Cmcc/Encrypt.php
UTF-8
1,450
2.609375
3
[]
no_license
<?php /** * 中国移动12580接口的加密解密 * * @author pang * */ class Msd_Service_Cmcc_Encrypt extends Msd_Service_Cmcc_Base { protected static function EncUrl() { $config = &Msd_Config::cityConfig(); $url = $config->service->v12580->encrypt->url; return $url; } protected static function De...
true
e1f8061ac02c977a5ace070731def281950a17dd
PHP
DevTeamSpace/dentamatch-php
/database/migrations/2019_01_28_110217_create_jobseeker_profiles_table.php
UTF-8
2,334
2.515625
3
[ "MIT" ]
permissive
<?php use App\Enums\SignupSource; use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; class CreateJobseekerProfilesTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('jobseeker_profiles', function(Blueprint $t...
true
274421d04bfb0bee8769c267bb9754e42a8f514b
PHP
slavahawk/Ananas
/yii-application/console/migrations/m200626_120028_create_category_women_table.php
UTF-8
1,541
2.625
3
[]
no_license
<?php use yii\db\Migration; /** * Handles the creation of table `{{%category_woman}}`. */ class m200626_120028_create_category_women_table extends Migration { /** * {@inheritdoc} */ public function safeUp() { $this->createCategoryWomen(); } /** * {@inheritdoc} */ ...
true
818e709ee737fb0a2f5ae380e1a707c8dbd692ec
PHP
moraeszz/php-aula25-02-21
/php-introducao/variaveis.php
UTF-8
394
3.640625
4
[]
no_license
<?php /** exibir o nome de usuário e seu ano de nascimento * * * Exemplo: Olá, fulano de tal, você nasceu em 1988 * */ $nome = "Rafaela"; $idade = 17; $calculoNascimento = (2021 - $idade); /** ou $calculoNascimento = date("Y") - $idade; **/ echo "<h1>Olá, $nome, você nasceu em $calculoNascimento</h1>"; /** ...
true
dd5fa358de57a8e9c843e31545550059449b60ac
PHP
ssi-irsalvador/ipay
/classes/admin/appauth.class.php
UTF-8
4,123
2.515625
3
[]
no_license
<?php class AppAuth { var $userID; var $userType; var $userName; var $user_status; var $user_email; var $user_emailpass; var $user_smtp; var $user_port; var $conn; var $Data; var $user_comp_list; var $user_comp_list2; var $user_branch_list; var $user_branch_list2; var $user_paygroup_list; var $user_p...
true
79e4bf92a48f30b2d2483cb929c0c3a399e8fcef
PHP
willogura/CTV-Mobile-App-Slideshow-Editor
/mobile_app/textForm/submit.php
UTF-8
957
2.9375
3
[]
no_license
<?php // Saving data from form in text file in JSON format // From: http://coursesweb.net/php-mysql/ // check if all form data are submited, else output error message // adds form data into an array $formdata1 = array( 'title'=> $_POST['title'], 'image'=> $_POST['imageTitle'], 'cat...
true
b0fe547b51d470c04d0d2111b81702ebddc52f6c
PHP
abrahamrossano/plataforma-de-geolocalizacion
/libreria/consulta.php
UTF-8
5,395
2.609375
3
[]
no_license
<?php class consulta{ private $sql; private $datos= array("nombre"=>"", "ape_p"=>"", "ape_m"=>"","mail"=>"","empresa"=>"","id_user"=>""); function consulta($sql){ $this->sql = $sql; } function setDatos($dat){ foreach($this->datos as $k =>$v) $this->datos[$k]= $dat[$k]; } function getInfoCho($usu...
true
f3a9c0a2d20057849a6bf90f34995a1915ba1000
PHP
PiyushNagwani/PHP-Projects
/6_select.php
UTF-8
676
2.9375
3
[]
no_license
<?php //connecting to the databse $servername="localhost"; $username="root"; $password=""; $database="notes"; //creating a connection $conn=mysqli_connect($servername,$username,$password,$database); if(!$conn) { die("connection can't be made".mysqli_connect_error); } $sql="SELECT * FROM `Notes`"; $result=mysq...
true
eca66b70cbb49108b076f1e71e36fa8a03612939
PHP
kamslosarz/crud
/src/Controller/UserController.php
UTF-8
3,129
2.734375
3
[]
no_license
<?php namespace App\Controller; use Core\Component\Controller; use Entity\User; use Symfony\Component\Form\Extension\Core\Type\FormType; use Symfony\Component\Form\Extension\Core\Type\TextType; use Symfony\Component\Form\Form; use Symfony\Component\Form\FormBuilder; use Symfony\Component\HttpFoundation\RedirectRespon...
true
482460191b2a68b4921f5a6e4366cdb8822bece7
PHP
NayeemHasan807/Summer_2020_Webtech
/PHP_TASK_05[Lab_Exam]/changepassword.php
UTF-8
2,234
2.640625
3
[]
no_license
<?php session_start(); if(!empty($_SESSION)) { if(empty($_SESSION['status'])) { header('location:login.html'); } } else { if(empty($_COOKIE['status'])) { header('location:Login.html'); } } ?> <!DOCTYPE html> <html> <head> <title>Change Passwoed</title> </head> <body> <fieldset> <legend>Chan...
true
289cfab0dabaf73709d565f494d3db8a41b9632c
PHP
pstruggle/lucky_shop
/app/push/controller/Worker.php
UTF-8
3,958
2.546875
3
[ "Apache-2.0" ]
permissive
<?php namespace app\push\controller; use think\worker\Server; class Worker extends Server { protected $socket = 'websocket://wenwen.xhmlxw.com:2346'; protected $workers = []; protected $users = array(); protected $merchants = array(); /** * 初始化 * */ protected function init() { ...
true
2f94a44cbde574aa305f8bdaf9966f021ebf676c
PHP
bbroger/livro-php-fontes
/PHPOO/Conceitos/interfaces/interface.dbdriver.php
UTF-8
868
3.234375
3
[]
no_license
<?php //interface.dbdriver.php interface DBDriver { public function connect(); public function execute($sql); } /* Interfaces de Objetos permite a criação de código que especifica quais métodos e variáveis uma classe deve implementar, sem ter que definir como esses métodos serão tratados. Interfaces são definidas us...
true
c491bda940ed536e5cf848c71bd64c6715179f8d
PHP
byaxaxa/l10n-ru
/wp-plugins/simplelogin/includes/compat.php
UTF-8
2,155
2.640625
3
[]
no_license
<?php /* Last Update: 2.0 */ if ( !function_exists('is_ssl') ) : function is_ssl() { if ( isset($_SERVER['HTTPS']) ) { if ( 'on' == strtolower($_SERVER['HTTPS']) ) return true; if ( '1' == $_SERVER['HTTPS'] ) return true; } elseif ( isset($_SERVER['SERVER_P...
true
c2708b1899a7a0b12053644e02b0b3e52ccd0872
PHP
Gazuka/outils
/src/OutilsAffichage.php
UTF-8
2,094
2.828125
3
[]
no_license
<?php namespace Gazuka\Outils; use Symfony\Component\HttpFoundation\Response; class OutilsAffichage { private $twig; private $parametresTwig = array(); private $redirection; private $parametresRedirection = array(); public function __construct() { //Constructeur à garder même vi...
true
40160502029c03468153a7ddb7855a958cf16652
PHP
bryanrite/horde
/framework/Text_Filter/test/Horde/Text/Filter/Html2textTest.php
UTF-8
12,155
2.546875
3
[]
no_license
<?php /** * Horde_Text_Filter_Html2text tests. * * @author Michael Slusarz <slusarz@horde.org> * @category Horde * @license http://www.horde.org/licenses/lgpl21 LGPL 2.1 * @package Text_Filter * @subpackage UnitTests */ class Horde_Text_Filter_Html2textTest extends PHPUnit_Framework_TestCase { ...
true
3c6feaedb61469346b19f33d1b45cfb9027a3127
PHP
MarieYu/doctrine_tp
/form/before.php
UTF-8
389
2.6875
3
[]
no_license
<?php //before.php require('../bootstrap.php'); session_start(); //bien mettre le session_start après le bootstrap //utilisateur est déjà en session ici, on doit indiquer à Doctrine que c'est un objet doctrine if (isset($_SESSION['user'])){ $user = $entityManager->merge(unserialize($_SESSION['user']));//transforme...
true
94b8c396ab9384ac6ad44de6fd6297b9434f3bfe
PHP
Irthir/Travaux_Web_R.S._F2
/Rendu Technique/WEB/SI_SERVICE_BIBLIOTHEQUE/PHP/FonctionAffichage.php
UTF-8
1,072
3.234375
3
[]
no_license
<?php function AfficheTable($table, $Conn) //BUT : Afficher une table d'une BDD. //ENTREE : Le nom de la table. //SORTIE : La table affichée. { $mareq='SELECT * FROM '.$table.';'; $statement=$Conn->prepare($mareq); $statement->execute(); $nb=$statement->rowcount(); if ($nb>0) { $result = $statement-...
true
f4b1aa1c094dc668779319fc0750fdb58113877d
PHP
nikatlas/endofcodes
/helpers/flash.php
UTF-8
348
2.546875
3
[ "MIT" ]
permissive
<?php function flash( $message, $type = 'success' ) { switch ( $type ) { case 'error': case 'warning': case 'success': $_SESSION[ 'alert' ] = [ 'message' => $message, 'type' => $type ]; ...
true
ed3361b9f006598df4fcd5265a3aae3611667c50
PHP
juhaidah05/testing
/application/models/_template_model.php
UTF-8
2,859
2.75
3
[]
no_license
<?php /* Tarikh Cipta : ? * Programmer : Haezal Musa * Tujuan Aturcara : Model Class bagi .. * Pengubahsuai : 1. Mohd. Hafidz Bin Abdul Kadir * Perubahan : * (30 Sept 2015) : 1. Indent semula snippet code * 2. Buang semua comment yang tidak perlu * ...
true
70f62c64405beaafdd81be385e345e62b75808aa
PHP
MinStenve/https_query
/ErrorHandle.class.php
UTF-8
3,820
2.890625
3
[]
no_license
<?php class ErrorHandle { protected $output_format = 'json'; public function __construct () { //系统设置 ini_set( "display_errors", 0 ); ini_set( "memory_limit", "128M" ); ini_set( "date.timezone", "PRC" ); //错误和异常捕获 ...
true
2a1f5c1e999bcb6c9feb482ad415133805469766
PHP
tristan-laroubine/ProjetWebPHP
/Controleurs/ControllerRecherche.php
UTF-8
869
2.59375
3
[]
no_license
<?php require_once('Views/View.php'); class ControllerRecherche { private $_recetteModel; private $_view; public function recherche() { $connecter = false; if (isset($_SESSION['id'])) { $connecter = true; } $motsClee = null; if (isset($_PO...
true
06aa4e65cf8037258a9ae7b9dd0b9720b573f47f
PHP
huycanh14/php_olds
/baitap/baithi/dangnhap.php
UTF-8
2,332
2.703125
3
[ "Apache-2.0" ]
permissive
<?php session_start(); $error = $dung = null; $username = 'admin'; $password = 'admin'; if (isset($_POST['submit'])){ if ($_POST['username'] == $username && $_POST['password'] == $password && $_POST['remember'] == 'remember'){ $dung = 'Xin chào, admin '; $cookie_name = $username; $cookie_password = $password; ...
true
2db5eab49583f892529fdc491b68812aee502b84
PHP
dmoses/islandora_form_builder
/FormBuilderInterface.inc
UTF-8
393
2.75
3
[]
no_license
<?php // $Id$ /* * @file * Provides an interface for users of this module should they choose to create thier own form builders. */ /** * Provides an interface for users of this module should they choose to create thier own form builders. */ interface FormBuilderInterface { public function createForm(); publ...
true
af34cd535abb91fa72e54b2dffd23d513e04db23
PHP
AnuoDaDa/xhu-Graduation-project
/src/common/doubanData.php
UTF-8
4,006
2.640625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: Administrator * Date: 2019/4/7 0007 * Time: 21:05 */ class doubanData { //页面链接地址 private $url = ''; //页面获取内容 private $content =''; //基础链接 private $baseurl = 'https://movie.douban.com'; /*页面匹配正则*/ private static $regArr = array( /*电...
true
f70a4fdc696c5dc06af97d11ba236804e6289f63
PHP
id0612/openapi-sdk-php
/src/NAS/V20170626/CPFSDescribeFileSystems.php
UTF-8
2,173
2.625
3
[ "Apache-2.0", "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php namespace AlibabaCloud\NAS\V20170626; use AlibabaCloud\Client\Request\RpcRequest; /** * Request of CPFSDescribeFileSystems * * @method string getFsId() * @method string getPageSize() * @method string getPageNumber() */ class CPFSDescribeFileSystems extends RpcRequest { /** * @var string */...
true
fd828a13e9e0347ac3a442e74abfd11a77b41f4a
PHP
cornernote/yii2-boilerplate
/src/components/console/Request.php
UTF-8
2,090
2.8125
3
[ "BSD-3-Clause" ]
permissive
<?php namespace app\components\console; /** * Console Request */ class Request extends \yii\console\Request { private $_queryParams; public function getQueryParams() { if ($this->_queryParams === null) { return []; } return $this->_queryParams; } public fu...
true
631317fd1f06a38a93dba5aa6500c3498d32af41
PHP
fanfreeman/xbdev
/yii/sites/public/protected/models/biz/bizStorage.php
UTF-8
2,619
2.796875
3
[ "BSD-3-Clause" ]
permissive
<?php // test: $id = bizStorage::add(__FILE__, 'test.php'); class bizStorage { const STORAGE_URL = 'http://storage.atomdev.com'; /** * add 上传一个文件 * $strFile : 本机文件路径 * $strFileName : 文件名称(选填) * @return mix 成功返回文件id,否则为false */ public static function add($strFile, $strFileName =...
true
fac0f8c2e473879c508c4dcbba7491335f98d454
PHP
f104/avtorazbor64
/core/Components/Form/Form.php
UTF-8
23,122
2.765625
3
[]
no_license
<?php namespace Brevis\Components\Form; class Input { public $options = ['id' => null, 'name' => null, 'type' => 'text', 'class' => 'form-control']; public $template = ' <div class="{$wrapperClass}"> {$label} <input {$options}> <div class="text-...
true
2bfe6dc43ad9059beacf465d4d44863bd064f9cc
PHP
VaidasRuskys/StockCrawler
/code/src/AppBundle/Logger/DataDogLogger.php
UTF-8
751
2.703125
3
[ "BSD-3-Clause", "MIT" ]
permissive
<?php namespace AppBundle\Logger; use Okvpn\Bundle\DatadogBundle\Client\DatadogClient; use Psr\Log\AbstractLogger; use Psr\Log\LoggerInterface; class DataDogLogger extends AbstractLogger implements LoggerInterface { /** @var DatadogClient */ private $dataDogClient; /** * DataDogLogger constructor. ...
true
5d379d7065b00a72a569a97324e7ba0b2b976870
PHP
Fabsolute/CouchDB2-PHP-Client
/src/Fabs/CouchDB2/Response/LuceneResponseElement.php
UTF-8
896
2.53125
3
[ "MIT" ]
permissive
<?php /** * Created by PhpStorm. * User: ahmetturk * Date: 30/06/2017 * Time: 12:19 */ namespace Fabs\CouchDB2\Response; use Fabs\Serialize\SerializableObject; class LuceneResponseElement extends SerializableObject { /** @var float */ protected $score = 0.0; /** @var string */ protected $id = ...
true
1d9b38bfba37b01318b3289b2901ccd013282698
PHP
cuijunling/SVN_ROOT
/apinew/app/models/MidCityTree.php
UTF-8
1,673
2.578125
3
[]
no_license
<?php use Phalcon\Mvc\Model\Behavior\Timestampable; class MidCityTree extends \Phalcon\Mvc\Model { /** * * @var integer */ public $id; /** * * @var string */ public $name; /** * * @var string */ public $enname; /** * * @var string ...
true
33f831bf8ed7cf9090e16645f06ec7bf2783ee22
PHP
felipemantoan/pjbank-evil-php-sdk
/src/Boleto/BoletoManager.php
UTF-8
1,190
2.796875
3
[ "MIT" ]
permissive
<?php namespace PJBank\Boleto; use PJBank\Client\PJBankInterface; class BoletoManager implements BoletoManagerInterface { /** * Instância de PJBank\Client\PJBank. * * @var \PJBank\Client\PJBank */ protected $pjBank; public function __construct(PJBankInterface $pjBank) { $...
true
5df0a3be99bf38ede0c54447a25e35498d6bc224
PHP
lastprogger/PbxSchemeService
/app/Domain/Entity/PbxScheme/PbxScheme.php
UTF-8
1,420
2.515625
3
[ "MIT" ]
permissive
<?php namespace App\Domain\Entity\PbxScheme; use Carbon\Carbon; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Relations\HasMany; use Illuminate\Database\Eloquent\SoftDeletes; use Ramsey\Uuid\Uuid; /** * App\Entity\CarBrand * * @property string $id * @prop...
true
6ef06bcbf8555faf16d9ac8e0c801e9543c1388f
PHP
402918014/ok_php_base
/src/Util/FileUtil.php
UTF-8
1,208
2.890625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: qinjx * Date: 16/2/7 * Time: 上午10:56 */ namespace OK\Util; use OK\PhpEnhance\Constant\Enum\ChecksumTypeEnum; class FileUtil { /** * @param string $hash * @return string */ static public function getHashedFilePath($hash) { return substr...
true
fb4a367cd8e97a8da677dc42e9a228fd901ea02b
PHP
jammrav/sf_truck_challenge
/foodTruckChallenge/server/FoodTruckController.php
UTF-8
4,335
2.984375
3
[]
no_license
<?php include("Database.php"); Class FoodTruckController { private $db; function __construct() { $this->db = Database::connect(); } /** * getFoodTruckNearestLocation -- This method returns JSON data of all foodtrucks in a partular La...
true
624b9e7dce3446f62dccf93f85451dfa3625abf3
PHP
terdia/game-of-life-php
/tests/GameOfLife/LiveNeighbourFinderTest.php
UTF-8
2,611
2.75
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace Tests\GameOfLife; use App\GameOfLife\Cell; use App\GameOfLife\Config\LiveCell; use App\GameOfLife\Factory\GridFactory; use App\GameOfLife\LiveNeighbourFinderIgnoreEdge; use App\GameOfLife\LiveNeighbourFinderWrapAroundEdge; use PHPUnit\Framework\TestCase; class LiveNeighbourFi...
true
1ad6702f771839131e41943995f82b7efb4b69f3
PHP
Arasaac/dockerizePHPApp
/php/plugins/html2ps/xhtml.utils.inc.php
UTF-8
11,850
2.75
3
[ "MIT" ]
permissive
<? // $Header: /cvsroot/html2ps/xhtml.utils.inc.php,v 1.27 2005/10/17 16:04:25 Konstantin Exp $ function close_tag($tag, $sample_html) { return preg_replace("!(<{$tag}(\s[^>]*[^/>])?)>!si","\\1/>",$sample_html); }; function make_attr_value($attr, $html) { return preg_replace("#(<[^>]*\s){$attr}(\s|>|/>)#si","\\1{...
true
ff02e8fa9b088e76016690a60bc3a37ad880431c
PHP
juniorriau/simple-php-fw
/system/classes/DUser.php
UTF-8
918
3.0625
3
[]
no_license
<?php /** * Description of DUser * * @author Misbahul D Munir <misbahuldmunir@gmail.com> * @since 1.0 */ class DUser { public $id; private $_profile = []; public function __construct() { session_start(); if (isset($_SESSION['__identity'])) { $this->id = $_SESSION['__id...
true
bc103a06f93849a49c683207afdf2d3cb2c7e1d1
PHP
Metadrop/redsys-query-php
/src/Client/RedsysException.php
UTF-8
1,147
3.1875
3
[ "MIT" ]
permissive
<?php namespace RedsysConsultasPHP\Client; use RedsysConsultasPHP\Client\RedsysErrorInfo; /** * Exception that it's thrown when there is a problem with redsys during requests. */ class RedsysException extends \Exception { /** * Error code. * * @var string */ protected $errorCode; ...
true
80ee610c98d43f111dcb65974680e6ba185f16f3
PHP
spacenikki/CI-Courses
/application/models/course.php
UTF-8
1,213
2.9375
3
[]
no_license
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); // model give command to database , work on data class Course extends CI_Model { // select all course to show function get_all_courses() { // fetch all data return $this->db->query('SELECT * FROM courses')->result_array(); } // find ma...
true
10e6a34129168cf42811cad82a431bd9988bf2d3
PHP
VTS2018/PHPDemo
/013_OOP/3.3.01.php
UTF-8
1,214
3.703125
4
[]
no_license
<?php /* * 学习要点 * 1.构造函数和析构函数 * 2.__construct * 3.__destruct:析构函数不能带参数 * 4.思考对象的生命周期 * * 5.子类继承父类之后 * 知识点:PHP不会自动调用父类的构造函数(不支持构造函数重载),必须使用parent关键字显式地调用 * 当然也可以调用与该实例没有任何关系的其它类的构造函数。只需在__construct()前加上类名即可。如:otherClassName::__construct(); */ class base { function __construct() { echo 'This i...
true
66a74f71e2c7d927f81188c22a8cddd2d95b1b0d
PHP
glgoodwin/cs111
/ggoodwin/public_html/cs304/hwk4tests/postit.php
UTF-8
530
2.859375
3
[]
no_license
<html> <head> <title> test post </title> </head> <body> <form method="POST" action="<?php echo $_SERVER['PHP_SELF']?>"> <input type = "textbox" name="text"> </br> </br> This is what was just in the textbox: <?php $textvalue = $_POST['text']; //? $_POST['text'] : null); echo $textvalue; echo "</br>"; if($textval...
true
5eaa586b79ebe21bd3de6f89155fd3afc484c004
PHP
rodrigoprestesmachado/whiteboard
/pages/bases/PageDefinitionDom.php
UTF-8
4,895
2.921875
3
[ "Apache-2.0" ]
permissive
<?php /** * Copyright 2011 - Nucleo de Informatica na Educacao Especial (NIEE) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENS...
true
992caaaa3282f4ddb5db753863502d9880dc1927
PHP
nikita2206/bumblebee
/src/Compilation/AssignVariable.php
UTF-8
666
3.109375
3
[]
no_license
<?php namespace Bumblebee\Compilation; class AssignVariable implements Expression { /** * @var ExpressionAssignable */ protected $var; /** * @var Expression */ protected $expression; public function __construct(ExpressionAssignable $var, Expression $expression) { ...
true
f8c66ad22bf4fd945d72476801526b62abb0b0fe
PHP
ukisoft/procon
/AntBook_php/LabyrinthGuide.php
UTF-8
4,073
3.078125
3
[]
no_license
<?php namespace ProCon; class LabyrinthGuide { public static function findShortestStep($mapData) { $labyrinthMap = new LabyrinthMap($mapData); $stepStockQueue = new \SplQueue(); $stepStockQueue->enqueue($labyrinthMap->getStartStep()); while (count($stepStockQueue) > 0) { ...
true
8ccf7e0608b53236db2b02818cf821efde67dbf3
PHP
baranidze/test_task
/DBWorker/getCountries.php
UTF-8
352
2.609375
3
[]
no_license
<?php include_once "getMethods.php"; $countriesList = getCountries(); ?> <select name = "country"> <option><?php echo $selectedCountry; ?></option> <?php foreach ($countriesList as $country): ?> <?php if($selectedCountry == $country['name']) continue;?> <option><?php echo $country['name'];?></option>...
true
0713a80be0bd78c41b6f49738f4715bae603e111
PHP
1930469/Laboratoire4Laravel
/app/Http/Controllers/ListeController.php
UTF-8
1,104
2.671875
3
[]
no_license
<?php namespace App\Http\Controllers; use App\Models\Produit; use Illuminate\Http\Request; class ListeController extends Controller { /** * Handle the incoming request. * * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View|\Illu...
true
9e0dee01292f86f8d0d02b4592f9a914d4618ecc
PHP
dvtikhonov/foresttrailLite
/app/Console/Commands/CalculateUsersVector.php
UTF-8
1,051
2.75
3
[]
no_license
<?php namespace App\Console\Commands; use App\Interfaces\UserVectorsInterface; use Illuminate\Console\Command; class CalculateUsersVector extends Command { protected $userVectors; /** * The name and signature of the console command. * * @var string */ protected $signature = 'calculat...
true
0d4de819cb4b59a601161e9c5cf99e8683dd8200
PHP
MickPoletti/SQLWeb
/Code/submit.php
UTF-8
5,772
2.625
3
[ "MIT" ]
permissive
<?php $link = mysqli_connect('localhost:3307','root','Gayasfuck21!','carrental2019'); if(mysqli_connect_errno()) { printf("\n\nDatabase Connection Failed: %s\n", mysqli_connect_error()); } ?> <?php if(isset($_POST['customer'])){ $name = $_POST["name"]; $phone = $_POST["phone"]; $sql1 = " ...
true
8c597a4d735312a1994e27bf4853317064f0050b
PHP
Dranile/TPCache
/index.php
UTF-8
1,667
2.875
3
[]
no_license
<?php ini_set('display_errors', 'On'); require_once 'extractData.php'; ?> <!DOCTYPE html> <!-- To change this license header, choose License Headers in Project Properties. To change this template file, choose Tools | Templates and open the template in the editor. --> <html> <head> <meta charset="UTF-8"> ...
true
d29696ea4d457e37464e3bdf1efd132b6fbe324f
PHP
izmaylov2207/weather
/src/exporter/WeatherDataExporterInterface.php
UTF-8
334
2.875
3
[]
no_license
<?php namespace App\exporter; use App\dto\WeatherDataDto; interface WeatherDataExporterInterface { /** * Creates file and saves it * * @param WeatherDataDto $weatherDataDto * @return string - path to created file * @throws */ public function export(WeatherDataDto $weatherDataDt...
true
68583d0d4ed1f4649696d1a68db7090a246aa6c1
PHP
trazzos/cd_vue
/Modules/Project/Repositories/Implementation/ProjectRepository.php
UTF-8
517
2.546875
3
[]
no_license
<?php namespace Modules\Project\Repositories\Implementation; use App\Repositories\Implementation\BaseRepository; use Modules\Project\Models\Project; use Modules\Project\Repositories\Interfaces\ProjectRepositoryInterface; /** * Class ProjectRepository * @package Modules\Project\Repositories\Implementation */ class...
true
7d44f26cd07728da24044c88d11b077e868e7922
PHP
Dpham181/CPSC-463
/user/regular_display.php
UTF-8
1,214
2.765625
3
[]
no_license
<?php require_once('../HOST/configRE.php'); // echo "Success: A proper connection to MySQL was made! The my_db database is great." . PHP_EOL; // echo "Host information: " . mysqli_get_host_info($link) . PHP_EOL; $dataArray = array(); if ($someQryObject = $link->query("SELECT BRAND, PRICE, QUANTIT...
true
037410335e04bb0cf94fff987f0a85a01eaec7f6
PHP
Aviithapa/Shopee
/app/Modules/Backend/Website/Cart/Policies/CartPolicy.php
UTF-8
1,375
2.578125
3
[ "MIT" ]
permissive
<?php namespace App\Modules\Backend\Website\Cart\Policies; use App\Models\Auth\User; use Illuminate\Auth\Access\HandlesAuthorization; class CartPolicy { use HandlesAuthorization; /** * Checks the user permission to READ site settings * @param User $user * @return bool */ public fu...
true
2c673512c5298c21f920c74b55121481423f52ca
PHP
janephp/janephp
/src/Component/OpenApi3/Tests/fixtures/issue-445/expected/Model/SearchFieldCount.php
UTF-8
2,634
2.953125
3
[ "MIT" ]
permissive
<?php namespace PicturePark\API\Model; class SearchFieldCount { /** * @var array */ protected $initialized = array(); public function isInitialized($property) : bool { return array_key_exists($property, $this->initialized); } /** * The number of fields created in the sea...
true
f017f855fa02372bcf76b071d06645df1b1f7ba1
PHP
mmaseraj/MySQLManager
/mysqlmanager.php
UTF-8
18,017
2.984375
3
[ "CC0-1.0" ]
permissive
<?php /** * * MySQL managment Class * Managing select, update, drop, delete, truncate, create ..etc * Part of Onyx framework * * @author Mohd Mansour Seraj <mmaseraj@gmail.com>, <mmaseraj.com> * @copyright ( c ) 2014, Mohammed Seraj * @version 1.0 * */ class MySQLManager { /** * @access private ...
true
5b894460d4e6612e17f11e6d97102f03520acb03
PHP
xk314/php
/article/index.php
UTF-8
2,384
2.703125
3
[]
no_license
<?php header("content-type:text/html;charset=utf8"); include "common.php"; $sql = "select count(*) from article"; $res = mysql_query($sql, $link); $res1 = mysql_fetch_row($res); $total_row = $res1[0]; // die($total_row); $total_page_num = ceil($total_row/$PAGE_SIZE); // die($total_page_num); $now_page_index =...
true
8628ac9ad4711fc3cb96b0445d0a246cc4b86052
PHP
EduardTrayan/odesk-task
/app/CustomApplication.php
UTF-8
1,048
2.859375
3
[]
no_license
<?php use Symfony\Component\Console\Application; use Symfony\Component\Console\Input\InputInterface; use Eduardtrayan\Commands\PrintArrayCommand; class CustomApplication extends Application { /** {@inheritdoc} */ protected function getCommandName(InputInterface $input) { return 'array:print'; ...
true
53185acea5833160f1953b8b8bdbb15286ac0c87
PHP
Sergey-Web/minimizerUrl
/src/Entity/ShortUrl.php
UTF-8
1,968
2.75
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace App\Entity; use App\Repository\ShortUrlRepository; use DateTime; use Doctrine\ORM\Mapping as ORM; use Doctrine\ORM\Mapping\OneToOne; /** * @ORM\Entity(repositoryClass=ShortUrlRepository::class) */ class ShortUrl { /** * @ORM\Id() * @ORM\GeneratedValue() ...
true
458eb3dd8d1898dea5b4264312d251f7aa0f104e
PHP
xualumni/cslp
/plugins/Bootstrap/src/View/Helper/BootstrapNavbarHelper.php
UTF-8
11,142
2.734375
3
[ "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
<?php /** * Bootstrap Navbar Helper * * * PHP 5 * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * * @copyright Copyright (c) Mikaël C...
true
1bb6a08ef4802149ed27f3976aff01186b5e5676
PHP
danielc279/Up2DateProject
/application/attendance-update-process.php
UTF-8
1,198
3
3
[]
no_license
<?php // This file will be used to process the add shows form. include 'libraries/form.php'; include 'libraries/database.php'; include 'libraries/login-check.php'; // 1. check that the form has been sent. if ($_SERVER['REQUEST_METHOD'] !== 'POST') { exit('You have no access to this...
true
21aa9b6d01124c5c6d82b04858863eca322b10a8
PHP
joshtsch/kbra-coding-test
/tests/clock-test.php
UTF-8
2,766
3.359375
3
[]
no_license
<?php // Load dependencies use PHPUnit\Framework\TestCase; // Initialize ClockTests as a TestCase class ClockTests extends TestCase { private $clock; // Initialize a Clock object protected function setUp() { $this->clock = new Clock(); } // Unset Clock object upon test completion ...
true
26b63e13453f99f4147cbf58b3f61afaa88c6f5a
PHP
Yehezrusli/Website-Akreditasi-Back-End
/public_html/application/controllers/Welcome.php
UTF-8
1,566
2.546875
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php defined('BASEPATH') OR exit('No direct script access allowed'); class Welcome extends CI_Controller { /** * Index Page for this controller. * * Maps to the following URL * http://example.com/index.php/welcome * - or - * http://example.com/index.php/welcome/index * - or - * Since this contro...
true
d1284b2acb701fcabe24df58390bd2b6db4e9f12
PHP
justfachry/fpapl
/apps/modules/loweffortgooglecalendar/application/ScheduleMapper.php
UTF-8
880
2.9375
3
[]
no_license
<?php namespace loweffortgooglecalendar\Application; use loweffortgooglecalendar\Domain\Model\User; use loweffortgooglecalendar\Domain\Model\Schedule; use loweffortgooglecalendar\Domain\Model\ScheduleId; use loweffortgooglecalendar\Domain\Model\Date; class ScheduleMapper { /** * @var Schedule[] */ ...
true
5996985526fcabbf5e8d7c06799ee28a8de61f3c
PHP
mdestafadilah/traffictower-cms
/application/models/shared/user_model.php
UTF-8
5,351
2.8125
3
[ "Apache-2.0" ]
permissive
<?php /** * LICENSE: Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, softw...
true
e610029a3c43a11e132fbb8dd6b07bac9252c5cb
PHP
linhntaim/laravel-starter
/app/Utils/HandledFiles/StorageManager/StrictStorageManager.php
UTF-8
669
2.625
3
[]
no_license
<?php /** * Base - Any modification needs to be approved, except the space inside the block of TODO */ namespace App\Utils\HandledFiles\StorageManager; use App\Exceptions\AppException; use App\Utils\HandledFiles\Storage\Storage; class StrictStorageManager extends StorageManager { /** * @param Storage $st...
true
06fdb49d40b0bb45893a496f01c01f36f12438c5
PHP
Kompaneytsev/fsm
/public/index.php
UTF-8
1,100
2.875
3
[]
no_license
<?php require_once __DIR__ . '/../src/functions/extractFirstWord.php'; require __DIR__ . '/../vendor/autoload.php'; use App\Models\StateMachine; use App\Models\States\{ AbstractHandler, IsStateTransitions, NotStateTransitions, StartTransitions, SubjectStateTransitions }; $sm = new StateMachine(); $positive_adj...
true
d02784e6fb5281eb7c8f4b6fb87cd7db3273379c
PHP
lecfy/library
/system/Common.php
UTF-8
2,547
2.796875
3
[]
no_license
<?php /* * Common/helper functions */ use system\Auth; /* * shortcut function for Auth::user */ function auth($column = false) { return Auth::user($column); } /* * redirects if not authenticated */ function auth_only() { if (!Auth::user()) { redirect('home/login'); } } /* * redirects to a...
true
c644d2c0f0729cf149d2e60d18ae0cb06d829cf7
PHP
dowson12345/phpgame
/applications/Game/Protocols/WebSocket.php
UTF-8
2,418
2.90625
3
[]
no_license
<?php /** * * @author walkor <worker-man@qq.com> */ class WebSocket { public static function encode($buffer) { $len = strlen($buffer); if($len<=125) { return "\x81".chr($len).$buffer; } else if($len<=65535) { return "\x81".chr(126).pa...
true
ca7cce5163e96b3ee82417480e79fcc179052629
PHP
mardo89/zantepay
/back-end/app/Console/Commands/ResetVerification.php
UTF-8
1,115
2.71875
3
[ "MIT" ]
permissive
<?php namespace App\Console\Commands; use App\Models\DB\Verification; use App\Models\Services\VerificationService; use Illuminate\Console\Command; class ResetVerification extends Command { /** * The name and signature of the console command. * * @var string */ protected $signature = 'veri...
true
308778bbd9821e98768442e3476726b6213fb7fa
PHP
DASPRiD/shoutirc-php-client
/src/ShoutIrc/Client.php
UTF-8
11,751
2.625
3
[ "BSD-2-Clause" ]
permissive
<?php namespace ShoutIrc; /** * Simple client for ShoutIRC. * * This client supports all commands but those which require to actively become * the current DJ. */ class Client { /** * Disable SSL. */ const SSL_DISABLE = 0; /** * Enable SSL, but fall back to unencrypted connection. ...
true
e2e0dfe430fdf775e4b0a1634de033f1cf341b4f
PHP
codedsultan/hifymart
/app/Http/Requests/SettingRequest.php
UTF-8
1,971
2.515625
3
[ "MIT" ]
permissive
<?php namespace App\Http\Requests; use Mews\Purifier\Facades\Purifier; use Illuminate\Foundation\Http\FormRequest; class SettingRequest extends FormRequest { /** * Determine if the user is authorized to make this request. * * @return bool */ public function authorize() { return true; } /**...
true
979f3efe7859afb7f5d583ad3de811a05eefceac
PHP
kennethlorrell/Forum
/tests/Feature/ManageRepliesTest.php
UTF-8
2,366
2.546875
3
[ "MIT" ]
permissive
<?php namespace Tests\Feature; use Illuminate\Foundation\Testing\RefreshDatabase; use Illuminate\Foundation\Testing\WithFaker; use Tests\TestCase; class ManageRepliesTest extends TestCase { use RefreshDatabase; /** @test */ public function a_guest_can_not_leave_a_reply() { $thread = factory(...
true
122c6998ca7ee228a369508b42b780a0471bf4ab
PHP
WilliamStam/UpdateScript
/update/_.php
UTF-8
1,766
2.828125
3
[]
no_license
<?php namespace update; abstract class _ { function __construct(){ $cfg = array(); $root_folder = dirname(dirname(__FILE__)); chdir($root_folder); $root_folder = $root_folder . DIRECTORY_SEPARATOR; $errorFolder = $root_folder . "update" . DIRECTORY_SEPARATOR . "logs"; $errorFile = $errorFolder . DIRECT...
true
1e795c85d7dfaebcfe5f548f25a485d0fc967729
PHP
OpenCiv/Server
/php/game/endturn.php
UTF-8
4,143
2.734375
3
[ "MIT" ]
permissive
<?php require '../init.php'; get_player(); $db->execute('UPDATE players SET finished = 1 WHERE id = ?', 'i', $playerId); // Check if other players still need to finish their turn $query = $db->first('SELECT EXISTS (SELECT * FROM players WHERE finished = 0 AND id = ?)', 'i', $gameId); if ($query[0]) { send_result(f...
true
ba9e3f0010daa5c8e39e781e42dca9d0430601b7
PHP
nananauma/sns_post
/programs/callback_insta.php
UTF-8
2,145
2.59375
3
[]
no_license
<?php session_start(); //設定ファイル require_once(dirname(__FILE__) . '/../programs/class/class_instapost.php'); require_once(dirname(__FILE__) . '/../config/config_facebook_insta.php'); if (isset($_GET["code"])) { //アクセストークンを取得してセッションに保存する処理を追加 //$_SESSION['facebook_access_token'] = (string) $accessToken; //echo htmls...
true
1003db71234edcd5eb019669d35faeb8ed5448c5
PHP
php2015/hsshop
/app/S/Vote/EnrollInfoService.php
UTF-8
5,911
2.65625
3
[]
no_license
<?php namespace App\S\Vote; use App\S\S; use App\Lib\Redis\EnrollInfoRedis; use DB; class EnrollInfoService extends S{ protected $redis; public function __construct() { parent::__construct('EnrollInfo'); $this->redis = new EnrollInfoRedis(); } /** * [获取全部数据信息] * @return [array] $list [banner数据]...
true
a5230488c6b2609c2ea0d5773400baa7f9a96421
PHP
myagoo/Hello-PHP
/helpers/html.helper.php
UTF-8
949
3.078125
3
[]
no_license
<?php class html{ public function anchor($url, $label, $attributes = array()){ $html = '<a href="'; if(preg_match('@^(?:http://)?([^/]+)@i', $url)){ $html .= $url; } else { if(substr($url,0,1) == '/'){ $html .= BASE_URL.$url; } else { $html .= BASE_URL.'/'.$url; } } $html .= '"'; if(!...
true
b78d1287005074cbaf0caf2fd6af8a98deac377c
PHP
Ardakilic/Telebot2
/app/Http/Controllers/BotController.php
UTF-8
3,308
2.71875
3
[ "MIT" ]
permissive
<?php /** * Telebot2 * https://github.com/Ardakilic/Telebot2. * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. * * @link https://github.com/Ardakilic/Telebot2 * * @copyright 2016 Arda Kilicdagi. (https://arda.pw/) * @licen...
true
723f40512acf7a6b2e24461260f379bcc4ee7c41
PHP
stilero/plg_stileospfacebookgroup
/library/fblibrary/oauth/encryption.php
UTF-8
3,332
2.828125
3
[]
no_license
<?php /** * Encryption Class * Contains general static methods that are mainly used for encryptions * * @version 1.1 * @package Stilero * @subpackage Class FB * @author Daniel Eliasson (joomla@stilero.com) * @copyright (C) 2013-aug-02 Stilero Webdesign (www.stilero.com) * @license GNU General Public License ...
true
ff532610aa3b1c716dd73c68087493bcf40dcecd
PHP
flebon/JobBundle
/Services/TaskBuilder.php
UTF-8
883
2.640625
3
[]
no_license
<?php namespace Tessi\JobBundle\Services; class TaskBuilder { protected $_doctrine; public function __construct($doctrine) { $this->_doctrine = $doctrine; } public function getDoctrine() { return $this->_doctrine; } /** * Create a task */ public function crea...
true
68f5d53d08f35968c4e76860b970332390a5de19
PHP
KDragos/POSM4
/PHP Project/editItem.php
UTF-8
1,330
2.9375
3
[]
no_license
<?php require_once('initialize.php'); $item_id = $_GET['id']; try { if ($_SERVER['REQUEST_METHOD'] == 'POST') { $update = DB::prepare(' UPDATE item SET name= :name, price= :price WHERE item_id= :item_id '); $update_values = [ ":name" => $_POST["name"], ":price" => $_POST["price"], ":...
true
2f644691129d73c696070129e7d8060288a18756
PHP
AsisTeam/csob-bc
/src/Enum/UploadModeEnum.php
UTF-8
544
2.671875
3
[ "MIT" ]
permissive
<?php declare(strict_types = 1); namespace AsisTeam\CSOBBC\Enum; final class UploadModeEnum { public const INCLUDE_INCORRECT = 'IncludeIncorrect'; public const ONLY_CORRECT = 'OnlyCorrect'; public const ALL_OR_NOTHING = 'AllOrNothing'; public const SIGNED_ALL_OR_NOTHING = 'SignedAllOrNothing'...
true
4312d663576b46e73e7993f220fd33d50bd53a6b
PHP
jackschofield96/groupProject
/cakephp-2.2.4/app/Model/Staff.php
UTF-8
4,954
2.671875
3
[]
no_license
<?php App::uses('AppModel', 'Model'); /** * Staff Model * * @property ProjectAllocation $ProjectAllocation */ class Staff extends AppModel { /** * Use table * * @var mixed False or table name */ public $useTable = 'staff'; /** * Primary key field * * @var string */ public $primaryKe...
true
0fdaa382a4b4c8f7e5bdb38ec893f9ed079b9d63
PHP
ian4hu/samplecode
/sample3/www/app/library/Redis/Adapter.php
UTF-8
645
3.125
3
[]
no_license
<?php namespace Redis; abstract class Adapter { protected function __construct() { } /** * 读取缓存 * 当$name为string时获取单个值,为array时批量获取 * * @param string|array $name * 要读取的key(s) * @return string|array */ public abstract function get($name); /** * 设置缓存 * 当$name为array时进行批量设置(批量设置时值不支持数组) ...
true
d7e34b5cf6f6118f0dc18af7bd503c3a0e53d0c0
PHP
czareks2000/budgetstat
/app/Http/Controllers/ExpenseController.php
UTF-8
5,771
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers; use App\Expense; use App\Category; use App\Account; use Carbon\Carbon; use Illuminate\Http\Request; class ExpenseController extends Controller { /** * Store a newly created resource in storage. * * @param \Illuminate\Http\Request $request * @return ...
true
51a1606b7799e9efdf2ed391c58a10007490680f
PHP
mayamazaki/simpleapi
/src/Controller/Student/UsersController.php
UTF-8
14,677
2.546875
3
[]
no_license
<?php namespace App\Controller\Student; use App\Controller\Student\AppController; use Cake\Auth\DefaultPasswordHasher; /** * Users Controller * * @property \App\Model\Table\UsersTable $Users * * @method \App\Model\Entity\User[]|\Cake\Datasource\ResultSetInterface paginate($object = null, array $settings = []) *...
true
81a4b64a175afc6680cb52916d0ddf8a72b81945
PHP
xiezi1772/enhui
/language.php
UTF-8
350
2.53125
3
[]
no_license
<?php $default_lang = 'cn'; // 默认语言 if($l = $_GET['l']) { $default_lang = in_array($l, array('cn','en'))?$l:$default_lang; } setcookie('language',$default_lang); if ($_SERVER['SERVER_PORT'] == 443) { $scheme = 'https'; } else { $scheme = 'http'; } $siteurl = $scheme . '://' . $_SERVER['HTTP_HOST']; header('Loca...
true
f1ced5ec3692a961aa46818b5427fd3ee8f890cc
PHP
ibogood/pusher
/src/Ibogood/Restful/Response.php
UTF-8
928
2.859375
3
[ "MIT" ]
permissive
<?php namespace Ibogood\Restful; /** * Interface Response * * @package Clarence\Restful */ interface Response { /** * 应答的内容 * @return mixed */ public function content(); /** * 原始应答 * @return mixed */ public function raw(); /** * 返回JS...
true
8885ccf2e0490081a9ab1ce44c49214203782512
PHP
chrometoasters/silverstripe-blurhash
/src/Extensions/BlurhashImageExtension.php
UTF-8
1,727
2.609375
3
[ "BSD-3-Clause", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php namespace Chrometoaster\Blurhash\Extensions; use SilverStripe\Assets\Image; use SilverStripe\Core\Config\Config; use SilverStripe\ORM\DataExtension; use kornrunner\Blurhash\Blurhash; /** * Class BlurhashImageExtension * * An extension adding blurha.sh data to an image via onBeforeWrite hook. */ class Blurh...
true