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
dd3068eb10f83ad024d634432c07aa268924d4b2
PHP
seedgabo/baum
/src/NestedSet/Concerns/WorksWithSoftDeletes.php
UTF-8
2,399
2.65625
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php namespace Baum\NestedSet\Concerns; use Illuminate\Database\Eloquent\SoftDeletingScope; trait WorksWithSoftDeletes { /** * Returns wether soft delete functionality is enabled on the current model * instance or not. * * @return boolean */ public function hasSoftDeletes() { ...
true
d3f630edb88c7d7e331511f2efd53804e9839743
PHP
ace7jae/hunianlengkap
/application/views/Administrator/DataRumah/tabel_kota_report.php
UTF-8
2,031
2.875
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
<?php // Tentukan path yang tepat ke mPDF $nama_dokumen='cetak-report-keberangkatan'; //Beri nama file PDF hasil. define('_MPDF_PATH','./assets/mpdf/'); // Tentukan folder dimana anda menyimpan folder mpdf include(_MPDF_PATH . "mpdf.php"); // Arahkan ke file mpdf.php didalam folder mpdf $mpdf=new mPDF('utf-8'...
true
545681332706c2f72a0daad6088867ec8258a298
PHP
sumeetgopi/startcar
/app/Utility.php
UTF-8
327
2.53125
3
[ "MIT" ]
permissive
<?php namespace App; trait Utility { public function store($inputs = [], $id = null, $multiple = false) { if($id) { $this->find($id)->update($inputs); return $id; } else { if($multiple) { $this->insert($inputs); } else { return $this->create($inputs)->id; } } ...
true
71724c3909b35d5e5ba47f65a8500312a87154f0
PHP
gruevy/project5
/admin/deleteAdmin.php
UTF-8
3,045
2.703125
3
[ "Unlicense" ]
permissive
<!-- Page by: Jazmin Belmonte --> <?php require "config.php"; require "common.php"; if (isset($_GET['user_id'])) { //echo $_GET['id']; try { $connection = new PDO($dsn, $username, $password, $options); $id = $_GET['user_id']; $sql = "DELETE FROM users WHERE user_id = :user_id"; $sta...
true
27d7a8689e22695337a24a0b8474a6d9970e46d8
PHP
NorbertElephant/Exercice_03W
/exo_php_procedural/exo_liste_des_courses/exo_liste_des_courses.php
UTF-8
2,490
3.1875
3
[]
no_license
<?php session_start(); /** * aarray_search * * @param [type] $needle * @param [type] $haystack * @return void */ function aarray_search($needle, $haystack){ foreach ($haystack as $key => $value) { if( $value['art']== $needle){ return $key; } } ...
true
83b40920996dd16547c3f70922c5b5b77b54e2fa
PHP
charilab/geoapi
/ov_tobefixed.php
UTF-8
1,626
2.578125
3
[]
no_license
<?php function build_query_convenience($desc) { $invalid_convenience_names = array( 'セブンイレブン', '7', '[Ss]even', 'セブン・イレブン', '[Ll]awson', 'LAWSON', '[Ff]amily', 'Mini Stop', 'MINI STOP', '[Mm]ini[Ss]top', 'Mini-Stop', '[Cc]ircle', '[Ss]unkus', 'Thankusu', 'SUNKUS', ...
true
dbc33603edf670a635f8e33a98a85635dd16623f
PHP
kL3x/GluecksradBot
/lib/functions.php
UTF-8
3,912
2.875
3
[]
no_license
<?php function rmkdir($path, $chmod = '777') { $exp = explode("/", $path); $way = ''; foreach ($exp as $n) { $way .= $n.'/'; if (!file_exists($way)) mkdir($way, $chmod); } } function iif($expression, $true, $false='') { return ($expression ? $true : $false);...
true
9b363a2b4e68741d42e12091625f3ee76e343d82
PHP
montycheese/RecDawgs
/src/html/php/doEnterMatchScore.php
UTF-8
1,346
2.6875
3
[]
no_license
<?php /** * Created by PhpStorm. * User: montanawong * Date: 4/23/16 * Time: 17:22 */ session_start(); require_once("autoload.php"); use edu\uga\cs\recdawgs\logic\impl\LogicLayerImpl as LogicLayerImpl; $logicLayer = new LogicLayerImpl(); //check to make sure none of the data is null or empty foreach($_POST as $i...
true
8e70a2c343de7fa636c66464e523533e9ce873ec
PHP
ecodevsolution/spk
/backend/models/TblPenggajian.php
UTF-8
903
2.515625
3
[ "BSD-3-Clause" ]
permissive
<?php namespace backend\models; use Yii; /** * This is the model class for table "tbl_penggajian". * * @property integer $idgaji * @property string $idabsensi * @property double $total_gaji * @property string $tgl_gaji */ class TblPenggajian extends \yii\db\ActiveRecord { /** * @inheritdoc */ ...
true
48076fa51c32f113dabc5f02ccd934b214ab5a96
PHP
MckeyHong/mk_gps
/app/Helpers/Website.php
UTF-8
2,078
2.71875
3
[]
no_license
<?php /* 系統常用函數 */ namespace App\Helpers; use Validator; use Config; use Auth; class Website { /** * 取得導頁資料 * @param array $aParam * @param string $sDefaultUrl * @return string */ public static function getRedirect(array $aParam = array(), $sDefaultUrl = '') { if (c...
true
ffc81cecb843800d6f9667fe14e766ce910b7357
PHP
pnikunj353/test
/api.php
UTF-8
1,775
2.515625
3
[]
no_license
<?php include('connection.php'); $jsonString = file_get_contents('php://input'); $jsonObj = json_decode($jsonString, true); $data = $jsonObj; if($data["mode"] == "login") { $name=$data['user_name']; $pass=$data['password']; $result = mysqli_query($mysqli,"SELECT user_id,user_name FROM pro1 where user_na...
true
f6e08d2b9d29c689fbc094fc5c6b3812b84199e2
PHP
capons/clout-cron
/application/models/_network.php
UTF-8
1,187
2.546875
3
[]
no_license
<?php /** * This class processes network business logic. * * @author Al Zziwa <al@clout.com> * @version 1.3.2 * @copyright Clout * @created 05/12/2015 */ class _network extends CI_Model { # add user to the referrer network function add_user_to_referrer_network($userId, $referrerId, $level) { log_message(...
true
648eccdef4e69b0b6bb450d461720d95db15a545
PHP
Odilio/wdo-analytics-API
/examples/get-basic-data-about-opened-gap-market.php
UTF-8
1,177
2.953125
3
[ "MIT" ]
permissive
<?php /** * Recubera dados basicos de dias com uma % maxima ou minimo de GAP de abertura de mercado * * File: get-basic-data-about-opened-gap-market.php * * @var \WDOAPI\WDOAPI $wdo Carrega a classe da API * @var date<yyyy-mm-dd> $startDate Data que comeca de contar os candles * @var date<yyyy-...
true
dc7929f8d91706cc9a41097f085e79b6a5ae1d8e
PHP
GuiemB/PHP-OOD
/OOD_5/student.php
UTF-8
381
3.125
3
[]
no_license
<?php class Student extends Person { private $studyField; public function getstudyField() { return $this->studyField; } public function setStudyField($studyField) { $this->studyField=$studyField; } public function print()//overriding print method from parent class Person { parent::print();//calling print method fr...
true
f2dab33548cf2b655dccc7a0d0e52627ddc012e2
PHP
Daikichibana/colegioFinalDAW
/app/Http/Controllers/AulaController.php
UTF-8
1,312
2.515625
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Models\Aula; use DB; class AulaController extends Controller { public function index(Request $request){ $buscar= $request->buscar; $buscar2= $request->buscar2; if($buscar==''||$buscar2==''){ $Aula=Aula:...
true
f87c30d1598ede414c86867494c2825369f2dd29
PHP
alexperegrina/symfony-skeleton-full
/src/Auth/src/Application/Command/SetName/SetNameHandler.php
UTF-8
789
2.734375
3
[]
no_license
<?php declare(strict_types=1); namespace Auth\Application\Command\SetName; use AlexPeregrina\ValueObject\Domain\Identity\Uuid; use AlexPeregrina\ValueObject\Domain\String\StringVO; use AlexPeregrina\ValueObject\Domain\User\Name; use Core\Domain\Messenger\Handler\CommandHandler; class SetNameHandler implements Comman...
true
a81783c4cb614ccb1ef6fcf9ba8f38f99d8e5fc6
PHP
AaronJan/Housekeeper
/src/Housekeeper/Abilities/Cache/Statically/CacheAdapter.php
UTF-8
3,260
2.5625
3
[ "Apache-2.0" ]
permissive
<?php namespace Housekeeper\Abilities\Cache\Statically; use Housekeeper\Contracts\Repository as RepositoryContract; use Housekeeper\Contracts\Action as ActionContract; use Illuminate\Contracts\Redis\Database as RedisContract; use Housekeeper\Support\SmartHasher; use Housekeeper\Abilities\Cache\Contracts\CacheAdapter ...
true
4fa3d8a617fef7ea18a724844a231d237b41a168
PHP
saltisgood/website
/lib/HTMLOutput.php
UTF-8
5,792
2.5625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: Nick Stephen * Date: 23/09/14 * Time: 2:34 PM */ include_once 'Content.php'; include_once 'Menus.php'; function strStartsWith($haystack, $needle) { $length = strlen($needle); return (substr($haystack, 0, $length) === $needle); } function strEndsWith($haystack, $n...
true
693259d863a88165a30c02bd036ccc5ecb8da68d
PHP
Starbugstone/ADListing
/dumpGroupe.php
UTF-8
4,150
2.640625
3
[]
no_license
<?php header("X-UA-Compatible: IE=Edge"); if(!isset($_SESSION)) { session_start(); } include 'php/config.php'; include 'php/functions.php'; // connect $ldapconn = ldap_connect($ldapserver) or die("Could not connect to LDAP server."); if($ldapconn) { // Adding options ldap_set_option ($ldapconn, LDAP_OPT_REFERRA...
true
788b730a815049e176334563c0ab19a9c625112f
PHP
dxwalter/digital-earners
/service/objects/investment.php
UTF-8
16,662
2.921875
3
[]
no_license
<?php include_once 'BaseFunction.php'; class Investment extends BaseFunction{ public $id; public $userId; public $capital; public $roi; public $binaryDate = 0; public $dateOfUpload; public $timeOfUpload; /** * The profile picture here ...
true
4c83ec57951cbe6ab15292ab0a4f255793aa0cea
PHP
anaya66/mvccode
/tests/UserTest.php
UTF-8
3,569
2.53125
3
[]
no_license
<?php use Illuminate\Foundation\Testing\WithoutMiddleware; use Illuminate\Foundation\Testing\DatabaseMigrations; use Illuminate\Foundation\Testing\DatabaseTransactions; use Tests\TestCase; use App\User; class UserTest extends TestCase { /** * A basic test example. * * @return void */ ...
true
aa7b95314e5e7e9a0af37766d3852af30473fe07
PHP
Awsme/TM-RU
/marathon14/Application.php
UTF-8
2,240
2.6875
3
[]
no_license
<?php /** * Created by JetBrains PhpStorm. * @author vandamm * Date: 15.05.12 * Time: 19:19 */ class Moto_Application { protected $routePrefix; protected $prefix; protected $fromEmail = 'ru@templatemonster.com'; protected $fromName = 'Почтовый робот ТМ Russia'; public function __construct() { //$this->p...
true
97ba73fd8deeace86a586f376eb3b9790a1f29ad
PHP
dbsengineering/GSB
/controleurs/c_enregistreDonn.php
UTF-8
2,745
2.890625
3
[]
no_license
<?php /** * c_enregistreDonn.php */ /** * Controleur qui enregistre, modifie, et rembourse les frais * Suivant le numéro qui est passé en paramètre, une procédure intervient. * En plus, une fonction qui retourne les tarifs. * * PHP version 5.5.12 * * @category Controleurs * @package Controleurs * @au...
true
179071a8873abbe17f9c1d27120adaff305d69a1
PHP
mylow/lucalight
/sidebar.php
UTF-8
637
2.625
3
[]
no_license
<?php if(is_page()) { if($post->post_parent){// check if page is parent... echo '<h3>'.get_the_title($post->post_parent).'</h3>'; echo '<ul>'; wp_list_pages(array('title_li' => '', 'child_of' => $post->post_parent,)); //... list current page e...
true
8f22480379b6a65cd97ccb97fcda0688e5aa5718
PHP
C0mkid/IronBot
/includes/functions_configs.php
UTF-8
821
2.640625
3
[]
no_license
<?php class configs { // @TODO: Rewrite configs class public function loadConfig($name) { global $config, $phpEx, $root_path; include($root_path . 'includes/configs/config_' . $name . '.' . $phpEx); // merge values with arrays together foreach ($config[$name] as $setting => $value) { ...
true
3126817eaf1c3b1a8f85e0119d87a486e00b23f6
PHP
esyede/hexazor
/system/Libraries/Hash/Hash.php
UTF-8
1,589
3.015625
3
[ "MIT" ]
permissive
<?php namespace System\Libraries\Hash; defined('DS') or exit('No direct script access allowed.'); use Exception; class Hash { /** * Buat hash password. * * @param string $value * @param array $options * * @return string */ public function make($value, array $options = [])...
true
753cc47c7dfec31b33a15bc9b19fa7c8093165c8
PHP
technodelight/bytes-in-human
/src/BytesInHuman.php
UTF-8
990
3.25
3
[ "MIT" ]
permissive
<?php namespace Technodelight\BytesInHuman; class BytesInHuman { const BASE = 1024; private $bytes = 0; public static function fromBytes($bytes) { $instance = new self; $instance->bytes = (int) $bytes; return $instance; } public function asString() { swit...
true
d60c2dfb61bd96ed0ed4f6c0440051df347da791
PHP
Kaoxlaw/phpExercicesSeptember
/vtc/models/models.php
UTF-8
1,038
3.125
3
[]
no_license
<?php class Models { public static function getConnection() { try { $bdd = new PDO( 'mysql:host=localhost;dbname=vtc', "afpaphp", "afpaphp" ); } catch (PDOException $e) { print "Erreur"; } return $bdd; } public function findById($id, $table) { $b...
true
1bff3542cef50259d0efb2a1de730382ba02a1a5
PHP
besrabasant/tailwind-issue
/web/app/plugins/github-updater/src/GitHub_Updater/API/Language_Pack_API.php
UTF-8
3,982
2.75
3
[ "GPL-2.0-or-later", "MIT", "GPL-2.0-only" ]
permissive
<?php /** * GitHub Updater * * @author Andy Fragen * @license GPL-2.0+ * @link https://github.com/afragen/github-updater * @package github-updater */ namespace Fragen\GitHub_Updater\API; use Fragen\GitHub_Updater\API; use Fragen\GitHub_Updater\Traits\GHU_Trait; /** * Class Language_Pack_API */ c...
true
ba4bb3d55996ae973e250fe815e3588475c1fb30
PHP
MatviyRoman/php-class
/microtime.php
UTF-8
419
2.953125
3
[]
no_license
<?php $string1 = str_repeat('x', 100); $string2 = str_repeat('y', 100); $string3 = str_repeat('z', 100); $mark = microtime(true); for ($i = 0; $i < 2000; $i++) { ob_start(); for ($j = 0; $j < 2000; $j++) { print $string1 . $string2 . $string3; } ob_get_clean(); } print '<a href="https://pa...
true
9db998acd5325b4e0fa324fc310f843baa1ff181
PHP
Dencina1996/Forohub
/app/Models/ReportThread.php
UTF-8
1,032
2.5625
3
[]
no_license
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; use Carbon\Carbon; use Auth; class ReportThread extends Model { use HasFactory; protected $table = 'threads_reports'; protected $fillable = [ 'created_at', 'up...
true
1d6bbf3a3764f3f425b131cbf985e60a86d06243
PHP
peterwu19881230/Microbial_phenotype_data_mining
/NicholsAnnotationsForOMP/JWstrainSearchAndReplace1.php
UTF-8
6,466
2.59375
3
[]
no_license
<?php /* Correct strain names by search and replace. (1. title change: JWXXXX-number -> JWXXXX 2. Strain info table: strain name: JWXXXX-number ->JWXXXX, synonyms: JWXXXX-number -> JWXXXX) (!) After correcting the pages, they no longer appear in the category page (). I think there will be a way to fix that so I still ...
true
e1d1a9ba9e734213819b94483413a2d9956642ad
PHP
toriworks/IPGroup
/download.php
UTF-8
1,469
2.515625
3
[]
no_license
<?php //function mb_basename($path) { return end(explode('/',$path)); } function utf2euc($str) { return iconv("UTF-8","cp949//IGNORE", $str); } function is_ie() { return isset($_SERVER['HTTP_USER_AGENT']) && strpos($_SERVER['HTTP_USER_AGENT'], 'MSIE') !== false; } // //// 파라미터 수신 $filename = $_REQUEST['filename']; $ofi...
true
fdd91c48bd0a17470c68534d15c7bee3cd458cfe
PHP
vesicd8/quickfood
/database/seeders/UnitSeeder.php
UTF-8
433
2.75
3
[]
no_license
<?php namespace Database\Seeders; use Illuminate\Database\Seeder; use Illuminate\Support\Facades\DB; class UnitSeeder extends Seeder { /** * Run the database seeds. * * @return void */ public function run() { $units = ['mg', 'g', 'kg', 'ml', 'l']; foreach ($units as $...
true
4dfad10f2590d3fa4286dfeba7f2d98bb1794b57
PHP
Zextia/staff-management
/classes/class.mysql_db.php
UTF-8
2,836
3
3
[ "Apache-2.0" ]
permissive
<?php class mysql_db extends database { public $resource; public $num_rows = null; public $valid_resource = false; function __construct() { mysql_connect(HOSTNAME, USERNAME, PASSWORD); mysql_select_db(DATABASE); return $this; } function select($table = '', $conditions...
true
e80f928f9fa4f47c7158fccef4e65de0d02ec4af
PHP
eicesoft/lark
/src/Pool/ObjectPool.php
UTF-8
5,716
2.84375
3
[ "MIT" ]
permissive
<?php namespace Lark\Pool; use Co\Channel; use Lark\Core\Config; use Lark\Core\TSingleton; use Lark\Event\EventManager; use Lark\Event\Local\PoolEvent; /** * Class ObjectPool * @package Lark\Pool * @author kelezyb */ class ObjectPool { use TSingleton; /** * 最大活跃数 * @var int */ public...
true
5bfd200e89f3ee9aba8effb0c44b6fd3b591e6a4
PHP
poojakarthik/my-work
/lib/classes/logic/collection/event/Logic_Collection_Event_Action.php
UTF-8
2,253
2.53125
3
[]
no_license
<?php /** * Description of Collection_Logic_Event_Action * * @author JanVanDerBreggen */ class Logic_Collection_Event_Action extends Logic_Collection_Event { protected $oDO; public function __construct($mDefinition) { if ($mDefinition instanceof Logic_Collection_Event_Instance) { $this->oCollectio...
true
27c3fa7eb2393d1b95a6e83311903537b34d2575
PHP
vlakarados/ReRouter
/src/RouteCollector.php
UTF-8
1,340
2.625
3
[ "MIT" ]
permissive
<?php namespace ReRouter; class RouteCollector extends \FastRoute\RouteCollector { public function addRoute($httpMethod, $route, $handler) { if ($httpMethod == 'REST') { // Make REST methods available // TODO: find a better way to do this witout duplicates with an appended slash character parent::addRoute...
true
525c58cb817658156d7dce3500b38d271b3661b2
PHP
Gregoraz/movie-rental
/admin/receipt.php
UTF-8
1,919
2.515625
3
[]
no_license
<?php require('../connection.php'); session_start(); if(isset($_SESSION["logged"])) { if(isset($_GET["orderID"])) { $sql = ' SELECT orders.orderID, customer.firstname AS cfirstname, customer.lastname AS clastname, customer.email AS cemail, customer.address AS caddress, employee.firstname AS efirstna...
true
5d4caaeff2a98a8399f474834e7d753afa986f34
PHP
shpizel/encounters
/src/Mamba/EncountersBundle/Controller/VariablesController.php
UTF-8
1,787
2.515625
3
[ "MIT" ]
permissive
<?php namespace Mamba\EncountersBundle\Controller; use Mamba\EncountersBundle\Controller\ApplicationController; use Symfony\Component\HttpFoundation\Response; use Core\MambaBundle\API\Mamba; use Mamba\EncountersBundle\EncountersBundle; /** * VariablesController * * @package EncountersBundle */ class VariablesCont...
true
12b921ccf9daa095098e45cd4bd52f62326f6fbf
PHP
durino13/simple-cms
/database/migrations/2016_10_02_204813_soft_deletions.php
UTF-8
1,269
2.640625
3
[]
no_license
<?php use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class SoftDeletions extends Migration { /** * Run the migrations. * * @return void */ public function up() { // Create deleted_at field in these tables $tables = [ ...
true
93d2c445f40fab95e178d5fb420a5992fcfa6d25
PHP
misoks/iTAPS-That
/newAccount.php
UTF-8
3,088
2.8125
3
[]
no_license
<?php session_start(); $page_title = "Create an Account"; include_once('header.php'); if ( isset($_POST['username']) && isset($_POST['password']) && ($_POST['specialization'] != -1) && ($_POST['year'] != -1)){ $u = mysql_real_escape_string($_POST['username']); $p = mysql_real_escape_string($_POST['password']); ...
true
c1af01f124c9c878a6cb2291f4bc68915588bacb
PHP
nurisakbar/Simple-School-Class-System
/app/Http/Controllers/StudentController.php
UTF-8
4,846
2.515625
3
[]
no_license
<?php namespace App\Http\Controllers; use App\Models\Student; use Illuminate\Http\Request; use App\Http\Requests\StudentCreate; use App\Models\StudentClass; use App\Models\TestScores; use Auth; use App\Models\Schedule; use Illuminate\Support\Facades\Hash; class StudentController extends Controller { public $reli...
true
f3c6a9c9dc4c7f21ce2e96d981b74b221e9db3e4
PHP
auliarampit/avam
/2.php
UTF-8
501
3.03125
3
[]
no_license
<?php function ValidasiUsername($user){ $lowercase = preg_match("/^[a-z]*$/", $user); if ($lowercase && strlen($user)==8) { echo "true <br/>"; }else{ echo "false <br/>"; } } function ValidasiPassword($pass){ $bebas = preg_match("/^[a-z || A-Z || 0-9 || @_.=,|+()*&^%$#!'\/-]*$/", $pas...
true
0e53e8bf1f907d7c9cc56878fc3ce193f630f9df
PHP
FarhanLhant/salmanfarhan
/uts/login(complete).php
UTF-8
7,731
3.09375
3
[]
no_license
<?php // Initialize the session session_start(); /* Check if the user is already logged in, if yes then redirect him to welcome page if(isset($_SESSION["loggedin"]) && $_SESSION["loggedin"] === true){ header("location: welcome.php"); exit; }*/ // Include config file include 'config.php'; // D...
true
10cbf9cfb30618963296fb210e15a1b9122e3da7
PHP
canaconruda/Kinsta-site
/themes/freshio/inc/template-functions.php
UTF-8
30,732
2.53125
3
[]
no_license
<?php if (!function_exists('freshio_display_comments')) { /** * Freshio display comments * * @since 1.0.0 */ function freshio_display_comments() { // If comments are open or we have at least one comment, load up the comment template. if (comments_open() || 0 !== intval(get_comments_number())) : comm...
true
7fcd3fc89cf9f646eeccaeb401b3720b2a1cf846
PHP
ledo4ek/NewST
/protected/helpers/CStringHelper.php
UTF-8
1,001
3.0625
3
[]
no_license
<?php class CStringHelper { // Это не универсальный вариант, так что лучше через Yii::t public static function getCase($text, $count) { if (strlen($count) > 2) $count = substr($count, strlen($count) - 2); if ($count > 30) $count = 20 + substr($count, strlen($count) - 1); switch (true) { ...
true
8bec84cf89b9417ba1aa9018eeb6a6eeead77a22
PHP
petebacondarwin/sapphire
/email/Email.php
UTF-8
22,081
2.6875
3
[ "BSD-3-Clause" ]
permissive
<?php /** * @package sapphire * @subpackage email */ if(isset($_SERVER['SERVER_NAME'])) { /** * X-Mailer header value on emails sent */ define('X_MAILER', 'SilverStripe Mailer - version 2006.06.21 (Sent from "'.$_SERVER['SERVER_NAME'].'")'); } else { /** * @ignore */ define('X_MAILER', 'SilverStripe Ma...
true
898900bca44dae82d179be67a12944835ad9a589
PHP
dexcell/CE
/classes/kohana/ce.php
UTF-8
813
2.796875
3
[]
no_license
<?php defined('SYSPATH') or die('No direct access allowed.'); abstract class Kohana_CE { // CE instances protected static $_instance; protected $_config = array(); /** * Singleton pattern * * @return CE */ public static function instance() { if ( ! isset(CE::$_instance)) ...
true
b7302c6badc29096603f58ef7b24087d54e3f92c
PHP
symfony/symfony
/src/Symfony/Component/Scheduler/Trigger/JitterTrigger.php
UTF-8
1,023
2.609375
3
[ "MIT" ]
permissive
<?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@symfony.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Scheduler\Trigger; /** * @author Kevin Bond <kevinbo...
true
6e611720584183cc456e1ad2ac4c4c6476a95d15
PHP
jadob/jadob
/src/Jadob/Bridge/Twig/Extension/PathExtension.php
UTF-8
2,226
2.765625
3
[ "MIT", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
<?php declare(strict_types=1); namespace Jadob\Bridge\Twig\Extension; use Jadob\Router\Exception\RouteNotFoundException; use Jadob\Router\Router; use function ltrim; use Twig\Extension\AbstractExtension; use Twig\TwigFunction; /** * * @author pizzaminded <mikolajczajkowsky@gmail.com> * @license MIT */ class Pat...
true
a8aad16bb877f3e43d8e77fd29455b683b11e87f
PHP
sunkararohith008/Dream-Destination-Tourism-Website
/Transport/rideshare-backend/login.php
UTF-8
1,986
2.828125
3
[]
no_license
<?php //Check to see if there is no session yet if (session_status() == PHP_SESSION_NONE) { //Start the session since there is no session session_start(); } // get the data from the form $email = filter_input(INPUT_POST, 'email', FILTER_VALIDATE_EMAIL); $user_password...
true
98ef2189c4bbbdd3f8deb88ca0d75af663313605
PHP
lorenzen-tonna-services-ltd/verivox-php-lib
/src/request/BenchmarkRequest.php
UTF-8
2,041
2.71875
3
[]
no_license
<?php namespace Verivox\Request; class BenchmarkRequest implements Request { /** * @var int */ private $zipCode; /** * @var string */ private $requestType; /** * @var string */ private $duration; /** * @var string */ private $locationId; /...
true
6800a6fc3d6cb8512a42debee773cc56fcaf07eb
PHP
Peppernwine/aig-site
/app/resource/MandatoryFieldValidation.php
UTF-8
999
3
3
[]
no_license
<?php /** * Created by PhpStorm. * User: arthirajeev * Date: 6/19/2018 * Time: 8:13 AM */ class MandatoryFieldException extends ServerException { private $missingFields ; public function __construct($missingFields) { $this->missingFields = $missingFields; parent::_...
true
4c3ccd7b5dd10a68ad7ab4c302e06a24b666a911
PHP
navarrogabriel/concursos_docentes
/app/Http/Controllers/RequisitoController.php
UTF-8
3,630
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers; use App\DataTables\RequisitoDataTable; use App\Http\Requests; use App\Http\Requests\CreateRequisitoRequest; use App\Http\Requests\UpdateRequisitoRequest; use App\Repositories\RequisitoRepository; use Flash; use App\Http\Controllers\AppBaseController; use Response; class Requisit...
true
ba02b7584b94bf37dee1930da6e9540aa7126d69
PHP
zball/CloudPOS
/src/CloudPOS/Bundle/StoreBundle/Manager/CartManager.php
UTF-8
2,958
2.671875
3
[]
no_license
<?php namespace CloudPOS\Bundle\StoreBundle\Manager; use CloudPOS\Bundle\StoreBundle\Entity\Cart; use CloudPOS\Bundle\StoreBundle\Entity\CartItem; use CloudPOS\Bundle\StoreBundle\Entity\Manageable; use Symfony\Component\HttpFoundation\Request; /** * Class CartManager * @package CloudPOS\Bundle\StoreBund...
true
4f461573ad56995faca5d52a9c9b24a8dc29cb07
PHP
CaoJiayuan/laravel-api
/src/CaoJiayuan/LaravelApi/WebSocket/ServerCommand.php
UTF-8
2,291
2.75
3
[]
no_license
<?php /** * Created by PhpStorm. * User: cjy * Date: 2018/3/2 * Time: 下午5:10 */ namespace CaoJiayuan\LaravelApi\WebSocket; use CaoJiayuan\LaravelApi\WebSocket\Events\WebSocketClosed; use CaoJiayuan\LaravelApi\WebSocket\Events\WebSocketConnected; use CaoJiayuan\LaravelApi\WebSocket\Events\WebSocketMessage; use C...
true
b5ed7fa45cb8dd6a5ccc4948920892e34fc3e468
PHP
vbuck/rootd-wordpress-core
/Rootd/core/Rootd/Element/Form/Abstract.php
UTF-8
874
2.625
3
[]
no_license
<?php class Rootd_Element_Form_Abstract extends Rootd_Element_Abstract { protected $_attributes = array(); protected $_isTypeSet = false; public function _construct() { $this->setTagName('input'); } protected function _beforeRender() { if ($this->getType...
true
e0b91b2f0e8b884a688af096e4c1955fff3d1e67
PHP
Gustavo210/Cine
/projeto_cinema/control/api.php
UTF-8
6,201
2.515625
3
[]
no_license
<?php require_once("config.php"); session_start(); header('Content-Type: application/json'); $response_data = array( "status" => false, "error" => "", "data" => null ); switch($_GET["method"]){ case "getFilmes": { try{ $search = $_GET['search']; $search = '%' . $search ...
true
fc548a5031297cec35b286ba8558133d16bc7e87
PHP
Sergei2014/hospital
/yii/frontend/views/display/csz1.php
UTF-8
14,184
2.53125
3
[]
no_license
<?php use common\models\Schedule; echo '<pre>'; //print_r($doctors); echo '</pre>'; if(isset($_GET['dat'])){ $data = $_GET['dat']; }else{ $data = date('d-m-Y'); } $test = strtotime("$data"); $week_number = date("W", $test); $year = date('Y'); for($day=1; $day<=6; $day++) { if($day == 1){ $datapn = d...
true
12e79e11e58145856d3a540012a4963651fb6448
PHP
DangKien/role-permisson
/src/RolePer/RolePerServiceProvider.php
UTF-8
3,079
2.609375
3
[ "MIT" ]
permissive
<?php namespace DangKien\RolePer; /** * This file is part of DangKien, * a role & permission management solution for Laravel. * * @license MIT * @package DangKien\RolePer */ use Illuminate\Support\ServiceProvider; use Validator, DB; class RolePerServiceProvider extends ServiceProvider { /** * Indicat...
true
bffd24ae3b211877b857838f6294a3416c20c7ce
PHP
Ulll/wxpay
/src/WXPayUtil.php
UTF-8
5,456
3.234375
3
[ "BSD-3-Clause" ]
permissive
<?php namespace WXPay; class WXPayUtil { /** * 将array转换为XML格式的字符串 * @param array $data * @return string * @throws \Exception */ public static function array2xml($data) { $xml = new \SimpleXMLElement('<xml/>'); foreach($data as $k => $v ) { if (is_string($k)...
true
16e3d957579657791eed91c58a08658aa194ef2e
PHP
DayzerCode/inn_form
/app/Services/Api/StatusNpdApi.php
UTF-8
1,212
2.6875
3
[]
no_license
<?php namespace App\Services\Api; use App\Contracts\Services\Api\TaxpayerApi; use DateTimeInterface; use GuzzleHttp\ClientInterface; use GuzzleHttp\Exception\GuzzleException; use Psr\Log\LoggerInterface; /** * Requests to https://statusnpd.nalog.ru/ */ class StatusNpdApi implements TaxpayerApi { private Clien...
true
881784d4574bb52414773929ba7eea05f253fb7c
PHP
afbora/iyzipay-laravel
/src/StorableClasses/Plan.php
UTF-8
3,897
3.015625
3
[ "MIT" ]
permissive
<?php namespace Afbora\IyzipayLaravel\StorableClasses; use Afbora\IyzipayLaravel\Exceptions\Fields\PlanFieldsException; use Afbora\IyzipayLaravel\ProductContract; use Iyzipay\Model\BasketItemType; class Plan extends StorableClass implements ProductContract { /** * The plan's id * * @var string ...
true
8de24323345ca1f8a49008e98ebad49d13c17465
PHP
LuisAgapeP/Prueba_DNA
/Parte01/Problema01.php
UTF-8
1,867
3.515625
4
[]
no_license
<!doctype html> <html> <head> <title>Problema 01</title> </head> <body> <span> <b>Problema 01</b></br> Usando PHP, crear una clase llamada ChangeString que tenga un método llamado build el cual tome un parámetro string que debe ser modificado por el siguiente algoritmo.</br> Reemplazar cada letra de ...
true
9421da15b1261e6d6f8279ffee0509593693e71a
PHP
ysc8620/lephp
/lib/interface/notice.interface.php
UTF-8
2,724
2.625
3
[]
no_license
<?php class interface_notice { /** * 获取未读通知列表 * @param unknown_type $user_id */ static function get_unread($user_id){ $notice_cache_key = self::get_cache_key($user_id); $unread_list = core_cache::pools() -> get($notice_cache_key); if($unread_list === false){ $rt = self::change_unread_...
true
9104b36415fba457483cc2a6446e1ab9a900ef77
PHP
MNAriel/simulacion_sistemas
/models/model.php
UTF-8
615
2.59375
3
[ "MIT" ]
permissive
<?php class Enlaces { static public function enlacesModel($enlaces) { if($enlaces == "inicio" || $enlaces == "integrantes" || $enlaces == "practicas" || $enlaces == "practica1" || $enlaces == "practica2") { $module = ...
true
d2b375a06becc69470296bc99d21fbea67956ba3
PHP
realtruths/captcha-generator
/src/CaptchaGenerator.php
UTF-8
8,771
2.90625
3
[ "MIT" ]
permissive
<?php /* * This file is part of the realtruths/captcha-generator. * * (c) RealTruths <realtruths@126.com> * * This source file is subject to the MIT license that is bundled * with this source code in the file LICENSE. */ namespace RealTruths\Captcha\Generator; /** * Class CaptchaGenerator * @package RealTrut...
true
4b1f92f2b7df95e2b4bfd1b46ffedbe59de912d9
PHP
hamedbaftam/e-wallet
/src/Services/StorageService.php
UTF-8
1,815
2.703125
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace Bavix\Wallet\Services; use Bavix\Wallet\Internal\Exceptions\RecordNotFoundException; use Bavix\Wallet\Internal\LockInterface; use Bavix\Wallet\Internal\MathInterface; use Bavix\Wallet\Internal\StorageInterface; use Illuminate\Cache\CacheManager; use Illuminate\Config\Reposito...
true
e71f8b67f8ea8a8488cb8b88fed90ae075e0b933
PHP
MinchoFB/Proyecto-Ingenieria-II
/cookbook/controller/addStateController.php
UTF-8
1,227
2.734375
3
[]
no_license
<?php chdir('..'); require_once 'index.php'; require_once 'controller/twigLoader.php'; require_once 'model/statesModel.php'; session_start(); if (isset($_SESSION['user'])) { if (!($_SESSION['user']['nombreRol'] == "Admin")) { header('Location: normalUserController.php'); } } else { header('Locatio...
true
6923ee0acbaff6a7f5b5f17e6de1fe6ec1d07c0b
PHP
dawguy/LearningThroughManga
/common/db_lib/get_vocab.php
UTF-8
551
2.546875
3
[]
no_license
<?php require_once( $_SERVER['DOCUMENT_ROOT'] . '/common/functions/db_lib.php' ); function get_vocab( $pk_vocab ) { global $pdo; $pk_vocab = intval( $pk_vocab, 10 ); $statement = "SELECT vocab, manga_context, english, korean, english_definition, korean_definition FROM tb_vocab WHERE vocab = :vocab"; ...
true
0bf9271f6f0a38351a7ceb7524f4d273b699786d
PHP
DenisCampos/frete-internacional
/app/Models/User.php
UTF-8
1,402
2.6875
3
[ "MIT" ]
permissive
<?php namespace App\Models; use Illuminate\Auth\Authenticatable; use Illuminate\Database\Eloquent\Model; use Illuminate\Notifications\Notifiable; use App\Notifications\ResetPasswordNotification; use Illuminate\Auth\Passwords\CanResetPassword; use Illuminate\Contracts\Auth\CanResetPassword as CanResetPasswordContracts...
true
144c632e0d9255ac24b8ee07fd334349f67e7f1f
PHP
kecs/CCE-web
/lib/model/doctrine/base/BaseDevice.class.php
UTF-8
2,171
2.515625
3
[]
no_license
<?php /** * BaseDevice * * This class has been auto-generated by the Doctrine ORM Framework * * @property integer $id * @property string $pan_id * @property string $extended_id * @property Doctrine_Collection $Sensor * * @method integer getId() Returns the current record's "id" value ...
true
96ee7d7cd4fd7d077e45aad9088c6f043c9207fc
PHP
vaseninm/payment-laravel
/src/drivers/tinkoff/Receipt.php
UTF-8
4,152
2.828125
3
[ "MIT" ]
permissive
<?php namespace professionalweb\payment\drivers\tinkoff; use Illuminate\Contracts\Support\Arrayable; /** * Receipt * @package professionalweb\payment\drivers\tinkoff */ class Receipt implements Arrayable { /** * общая СН */ const TAX_SYSTEM_COMMON = 'osn'; /** * упрощенная СН (доходы) ...
true
2e2e2f7732123492b9de00b864ba3bf81a39a322
PHP
OpenClassrooms/CodeGenerator
/tests/Utility/MethodUtilityTest.php
UTF-8
1,761
2.53125
3
[]
no_license
<?php declare(strict_types=1); namespace OpenClassrooms\CodeGenerator\Tests\Utility; use OpenClassrooms\CodeGenerator\Utility\DocCommentUtility; use OpenClassrooms\CodeGenerator\Utility\MethodUtility; use PHPUnit\Framework\TestCase; class MethodUtilityTest extends TestCase { /** * @test */ public ...
true
45a12250f7dc17213f4460d5c28196b3eaea03a5
PHP
FixterSpb/red-black-tree
/src/Node.php
UTF-8
4,273
3.234375
3
[]
no_license
<?php const COLOR_BLACK = "#000"; const COLOR_RED = "#c33"; class Node implements JsonSerializable { private ?Node $parent = null; private ?Node $left = null; private ?Node $right = null; private ?int $value = null; private string $color = COLOR_BLACK; public function __construct(?int $value ...
true
fefe5cf533aa640c402dc405c504211ec4cf03a4
PHP
grizz-it/services
/src/Common/Registry/ServiceRegistryInterface.php
UTF-8
534
2.515625
3
[ "MIT" ]
permissive
<?php /** * Copyright (C) GrizzIT, Inc. All rights reserved. * See LICENSE for license details. */ namespace GrizzIt\Services\Common\Registry; interface ServiceRegistryInterface { /** * Retrieves the definition by a key. * * @param string $key * * @return mixed */ public func...
true
1925e4332b895bfb119d5fdb5f6bd2b48c68db92
PHP
GimmyHchs/PMBook
/app/Project/File/FileEloquent.php
UTF-8
373
2.75
3
[ "MIT" ]
permissive
<?php namespace App\Project\File; use App\Project\ProjectEloquent; /** * File類別核心 */ abstract class FileEloquent extends ProjectEloquent { /** * 所有FileEloquent 必須有類型關聯 */ abstract public function type(); /** * 所有FileEloquent 必須能夠被賦予類型 */ abstract public function assignType($type...
true
d358e81d2d5df515adf53e3886a10e77016bc354
PHP
yakovenkoroman1993/lectern_downgrade
/model/Utils.php
UTF-8
5,676
2.796875
3
[]
no_license
<?php /** * Created by PhpStorm. * Date => 21.05.2016 * Time => 13:10 */ use Entity\Cv; use Entity\Person; class Utils { /** * @param array $list * @param array $data * @param array $prevData * @return array */ public static function arraySerialization(array $list, array $data, a...
true
6a0b339f55ae180db92c150bdb00908a01f4cb7a
PHP
nestauk/DSI4EU
/src/DSI/Controller/CLI/UpdateProjectTagsController.php
UTF-8
2,976
2.859375
3
[]
no_license
<?php namespace DSI\Controller\CLI; use DSI\NotFound; use DSI\Repository\OrganisationRepo; use DSI\Repository\ProjectImpactHelpTagRepo; use DSI\Repository\ProjectRepo; use DSI\Repository\ProjectRepoInAPC; use DSI\UseCase\AddImpactHelpTagToProject; use DSI\UseCase\CalculateOrganisationPartnersCount; use DSI\UseCase\Re...
true
7d5eb9487400ac1629abe19cdb82d49c94512777
PHP
catchup-forks/PackageEws365
/src/ArrayType/EwsArrayOfGroupedItemsType.php
UTF-8
4,763
2.671875
3
[ "MIT" ]
permissive
<?php namespace Ews\ArrayType; use \WsdlToPhp\PackageBase\AbstractStructArrayBase; /** * This class stands for ArrayOfGroupedItemsType ArrayType * @package Ews * @subpackage Arrays * @author WsdlToPhp <contact@wsdltophp.com> */ class EwsArrayOfGroupedItemsType extends AbstractStructArrayBase { /** * Th...
true
d2f5f4943479e03f0e6ae2a364d19e119ca79c20
PHP
ruskov2050/Projet-Synthese-Hypermedia1
/modele/classes/ContactsEntrs.php
UTF-8
904
2.78125
3
[]
no_license
<?php class ContactsEntrs extends Personnes { protected $_NumeroPoste; public function createcontact($prenom,$nom,$numCell,$email,$password,$typeCompte,$numroposte) { $today= MyGenerator::getDateNow(); $this->setId(MyGenerator::getIdGenerated()); $this->setPrenom($prenom); $this...
true
74792077089f2a7c9bd78334a497e4cf04d71c46
PHP
missxiaolin/blog
/Common/Model/AuthRuleModel.class.php
UTF-8
1,732
2.75
3
[]
no_license
<?php namespace Common\Model; use Think\Model; /** * 权限管理 */ class AuthRuleModel extends Model{ // 添加权限 public function addData($data){ // 去除首尾空格 foreach ($data as $k => $v) { $data[$k] = trim($v); } $this->add($data); return true; } /** * 修改数据 * @param array $data 数...
true
6185026db47d3d6859e03bad358f669f13689220
PHP
phachon/kofast
/kofast/extends/ueditor/classes/UEditor/Upload/Base64.php
UTF-8
1,326
2.703125
3
[ "MIT" ]
permissive
<?php /** * UEditor Base64 上传类封装 * @author phachon@163.com */ class UEditor_Upload_Base64 extends UEditor_Upload { /** * execute */ public function execute() { $fileField = $this->_config['fieldName']; $base64Data = $_POST[$fileField]; $img = base64_decode($base64Data); $this->_oriName = $this->_con...
true
6efd0b50926939eac82bbf31a143423d96a315e6
PHP
sistemas3stb/migration
/Core/Server.php
UTF-8
816
3.140625
3
[]
no_license
<?php namespace Migration\Core; /** * Server */ abstract class Server { protected $_session; protected $_host; protected $_port; public function __construct($params) { $this->setPropertyFromArray($params); } public function __set($name,$value) { $property = "_$name"; if(property_exists(get_called_clas...
true
fa89b526a9e17decd5ea58357a448d99938c2156
PHP
john2096/eCommerce-PHP-site
/Sales_search.php
UTF-8
6,984
2.765625
3
[]
no_license
<?php require_once('DB_Conn.php'); require_once('Admin_Class.php'); $A1 = new Admin; session_start(); if(isset($_SESSION['Admin'])) { $A1=$_SESSION['Admin']; echo "Welcome " . $A1 ->getAFirstName(); } if(isset($_POST['Logout'])) { echo "Goodbye " . $A1 ->getAFirstName(); session_d...
true
550411e8fbd7cacf105414b8f4326394275ea1b7
PHP
EzequielSegota/Prog3
/Ejercicios/Ejercicio_13.php
UTF-8
406
2.96875
3
[]
no_license
<?php $arrayAnimales=array(); $arrayAños=array(); $arrayLenguajes=array(); array_push($arrayAnimales,"Perro", "Gato", "Ratón", "Araña", "Mosca"); array_push($arrayAños,1986, 1996, 2015, 78, 86); array_push($arrayLenguajes,"php", "mysql", "html5", "typescript", "ajax"); $arrayFinal=array_merge($arrayAnimales,$arrayAño...
true
ceb2388edc911978585085853a5ff7ceaf5c83ba
PHP
bhandaribandanaa/laravel-project
/database/migrations/2017_04_10_130436_create_doctors_table.php
UTF-8
680
2.703125
3
[ "MIT" ]
permissive
<?php use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateDoctorsTable extends Migration { public function up(){ Schema::create('doctors', function($table){ $table->increments('id'); $table->string('full_name'); $table->st...
true
c4532394f9acf872b401b2183b0f03bdf2bb5abe
PHP
duytc/tagcade-api
/src/Tagcade/Model/Core/BillingConfigurationInterface.php
UTF-8
1,537
2.59375
3
[ "MIT" ]
permissive
<?php namespace Tagcade\Model\Core; use Tagcade\Model\ModelInterface; use Tagcade\Model\User\Role\PublisherInterface; interface BillingConfigurationInterface extends ModelInterface { /** * @param mixed $id * @return self */ public function setId($id); /** * @return PublisherInterface...
true
55f673d49b55348116310cb82992af97302d05f0
PHP
maithemewp/mai-theme-engine
/lib/functions/helpers.php
UTF-8
20,859
2.734375
3
[]
no_license
<?php /** * Helper function to get custom image sizes. * * @access private * @since 1.8.0 * * @return array Image sizes and labels. */ function mai_get_image_sizes() { // Get labels. $labels = mai_get_image_size_labels(); /** * Create the initial image sizes. * @link http://andrew.hedges.name/expe...
true
6e38bb848b56933340a6fe7e4ec3d95869833838
PHP
goreilly/web-connector
/src/Tests/TaskQueueTest.php
UTF-8
2,086
2.609375
3
[ "Apache-2.0" ]
permissive
<?php namespace goreilly\WebConnector\Tests; use goreilly\WebConnector\TaskInterface; use goreilly\WebConnector\TaskQueue; class TaskQueueTest extends \PHPUnit_Framework_TestCase { /** * @return TestTask */ protected function getTask() { return new TestTask(); } public function...
true
267342c9cb976a50f2ad3d312f8ecbf984de3c6d
PHP
martin-helmich/typo3-web2pdf
/Classes/View/PdfView.php
UTF-8
4,765
2.71875
3
[]
no_license
<?php /* * ************************************************************* * Copyright notice * * (c) 2014 Kevin Purrmann <entwicklung@purrmann-websolutions.de> * * All rights reserved * * This script is part of the TYPO3 project. The TYPO3 project is * free software; you can redistribute it and/or modify *...
true
cfdd1b94b700d1da83beed06997e0b75d3bc7782
PHP
akimxtreme/inhrrOldWebsite
/catinhrr/conexion_fns.php
UTF-8
566
2.53125
3
[]
no_license
<!--CONECTOR--> <?php function ConectarBD(){ return mysql_connect("172.16.0.10","acruz","10485"); } ?> <!--EJECUTAR EXEC--> <?php function EjecuteExec1($cx,$sql){ mysql_select_db("bdcatinhrr",$cx); return mysql_query($sql,$cx); } ?> <!--EJECUTAR FETCH--> <?php function ObtenerFila($cx){ return ...
true
06cf93922f186c22184f4bb1f7fcd8eeb727479b
PHP
meeech/expozine
/controllers/components/tidize.php
UTF-8
938
2.78125
3
[]
no_license
<?php /** * Tidize * * Component to generate new ids for a model. * usually useful with importing old data * * @package default * @author Mitchell Amihod */ class TidizeComponent extends Object { /** * Generate uuid for the field on the originals. * * @return void **/ function tid...
true
73b834ef4b75bec644bb9a9fa5632f6aafc6f458
PHP
herrwalter/InterfaceGenerator
/InterfaceObject/PHPInterfaceObject.php
UTF-8
474
3.125
3
[]
no_license
<?php /* * SetlistGenerator project * @author Wouter Wessendorp * */ class PHPInterfaceObject extends AInterfaceObject { public function toString() { $interface = '<?php ' . PHP_EOL; $interface .= 'interface ' .$this->getName() . ' {' . PHP_EOL . PHP_EOL; foreach($this->methods as $...
true
2614c16313325b77b881bc8dd9bae826bc5b1f5a
PHP
dbierer/php-ii-jun-2021
/pdo_with_opts.php
UTF-8
544
2.765625
3
[]
no_license
<?php $dsn = 'mysql:dbname=phpcourse;host=localhost'; $usr = 'vagrant'; $pwd = 'vagrant'; $opts = [PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION]; try { $pdo = new PDO($dsn, $usr, $pwd, $opts); $result = $pdo->query('SELECT * FROM customers AS c JOIN orders AS o ON c.id = o.customer'); $result->setFetchMode(PDO::FETC...
true
ecab93921d83a3bc71e2db7f88a824fb65e50102
PHP
Linkunder/Infosport
/TO/TipoRecinto.php
UTF-8
449
2.53125
3
[]
no_license
<?php class TipoRecinto { private $id_Recinto; private $id_Categoria; function __construct(){} function getId_Recinto() { return $this->id_Recinto; } function getId_Categoria() { return $this->id_Categoria; } function setId_Recinto($id_Recinto) { $this->id_Reci...
true
adcfc9242cac8ba78634d2e8b6dc6893c3d2ad3a
PHP
jbidjeke/zend_expressive
/src/App/Action/AdvertAction.php
UTF-8
1,231
2.53125
3
[]
no_license
<?php namespace App\Action; use Psr\Http\Message\ResponseInterface; use Interop\Container; use Psr\Http\Message\ServerRequestInterface; use Zend\Diactoros\Response\JsonResponse; use Zend\Expressive\Router; use Zend\Expressive\Template; use App\Model\Adverts; class AdvertAction { private $router; private $te...
true
e5648a5a7096b63769895e180a8881830ae69e04
PHP
penguizz/invoice
/database/migrations/2017_07_12_074159_po_detail.php
UTF-8
872
2.546875
3
[ "MIT" ]
permissive
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class PoDetail extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('po_details', function (Bl...
true
4e23a4a9de32fd9ae7218ae66572e541c0e90896
PHP
php-ddd/notification
/tests/ErrorTest.php
UTF-8
678
2.6875
3
[ "MIT" ]
permissive
<?php namespace PhpDDD\Notification; use Exception; use PHPUnit_Framework_TestCase; class ErrorTest extends PHPUnit_Framework_TestCase { /** * @expectedException InvalidArgumentException */ public function testIntegerThrowException() { new Error(100); } /** * @expectedExcep...
true