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
6b049d0f18018a006221cd1a9410b3e58e076ecd
PHP
WPPlugins/custom-fields-for-many-dates
/custom-fields-for-many-dates.php
UTF-8
16,804
2.671875
3
[]
no_license
<?php /* Plugin Name: Custom Fields for Many Dates Description: This plugin will allow a user to add/edit/delete dates and date titles for posts as custom meta values. Version: 1.0 Author: Chris J. Sanders Author URI: http://www.cjsand.com License: GNLv3 This program is free software: you can redistribute ...
true
9e6a8d58a129afd95f449702ada6ff02895e8427
PHP
zliusha/fenxiao
/service/DbFrame/DataBase/HcityShardDb.php
UTF-8
686
2.515625
3
[]
no_license
<?php /** * @Author: binghe * @Date: 2018-07-09 17:13:49 * @Last Modified by: binghe * @Last Modified time: 2018-08-21 16:10:41 */ namespace Service\DbFrame\DataBase; use Service\DbFrame\Db; use Service\DbFrame\Protocol\IShardNodeHandler; /** * database */ class HcityShardDb extends Db implements IShardNodeHa...
true
25b768d18b5bcd8a78ba5c5d5ebfcab5bdcc7f39
PHP
M4RC3L05/fp-php
/tests/lists/XprodTest.php
UTF-8
1,113
2.9375
3
[ "MIT" ]
permissive
<?php namespace Tests\Lists; use PHPUnit\Framework\TestCase; use function FPPHP\Lists\xprod; class XprodTest extends TestCase { public function test_it_shoudl_return_a_list_with_all_possible_combination_between_2_arrays() { $res = xprod([1, 2])(["a", "b"]); $this->assertEquals([[1, 'a'], [1,...
true
ef69850ea8f9a6345ec7be7a11d1e2f7f7935e14
PHP
ptuchik/omnipay-yandex
/src/Message/AbstractRequest.php
UTF-8
979
2.5625
3
[]
no_license
<?php namespace Omnipay\Yandex\Message; use Omnipay\Common\Http\ClientInterface; use Omnipay\Common\Message\AbstractRequest as BaseAbstractRequest; use Omnipay\Yandex\Helpers\ParametersTrait; use Symfony\Component\HttpFoundation\Request as HttpRequest; use YandexCheckout\Client; /** * Class AbstractRequest * @pack...
true
f32a0b31556a51d57e9aa1c1ad3bda1045d07809
PHP
Jandelson/quiz
/app/Http/Controllers/AnswersController.php
UTF-8
1,369
2.5625
3
[]
no_license
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Models\Quiz; use App\Models\Question; use App\Models\Answer; use App\Models\Result; class AnswersController extends Controller { public function index($id) { $quiz = Quiz::findOrFail($id); $question = Question::where('...
true
b0db1d5d28c4697ba6a8432f8e309208e8e3c4bf
PHP
tracebs/amoapiV0
/amoapi/modules/leads/leads_Get.php
UTF-8
2,023
2.890625
3
[]
no_license
<?php /** * Получение сделок * * @author Vlad Ionov <vlad@f5.com.ru> */ class leads_Get extends get { /** * Хранение данных */ private $data = array(); /** * Хранение ID для получения */ private $ids = array(); /** * Поиск сделок */ public function search( $query, $name = false, $max = 0 ){ ...
true
701f13b4bd0c4833a33f251f7a7c99448402d592
PHP
temamawelu/qurban-commerce
/app/Http/Livewire/AddAnimal.php
UTF-8
631
2.5625
3
[ "MIT" ]
permissive
<?php namespace App\Http\Livewire; use Livewire\Component; use App\Models\Animal; class AddAnimal extends Component { public $name; public $price; public $weight; public $rules = [ 'name' => 'required|min:6', 'price' => 'required', 'weight' => 'required' ]; public...
true
fcafc4bb21f467726b810fc56873839123059498
PHP
BrayanDeveloper/turnos-master
/controllers/conexion.php
UTF-8
366
2.671875
3
[]
no_license
<?php /** * */ class Conexion { function Conectar(){ $host = "mysql:dbname=digiturno_db; host=localhost;"; $user = "root"; $pass = ""; try { $pdo = new PDO($host, $user, $pass); //echo "<script>console.log('conexion de base exitosa');</script>"; return $pdo; } catch (Exceptio...
true
4ae729f5cc71757d65d9eba021f2228cebec9f0f
PHP
basantashubhu/futsal-management-system
/app/Models/BaseModel.php
UTF-8
1,084
2.515625
3
[]
no_license
<?php namespace App\Models; use Illuminate\Database\Eloquent\Model; class BaseModel extends Model { protected $guarded = []; public function edit($params) { $old_record = $this->__toString(); $old_id = $this->id; $this->fill($params)->save(); $this->audit($old_id,$old_rec...
true
c9424653f9b8822dffae57d3e1f8700a4ea1f39e
PHP
neskoc/mvc
/test/Controller/ControllerYatzyTest.php
UTF-8
1,617
2.78125
3
[]
no_license
<?php declare(strict_types=1); namespace neskoc\Controller; use PHPUnit\Framework\TestCase; use Psr\Http\Message\ResponseInterface; /** * Test cases for the controller Sample. */ class ControllerYatzyTest extends TestCase { /** * Try to create the controller class. */ public function testCreateT...
true
09e3ec3634b2fa00a8a4ac80b0001b7f495dc186
PHP
librewind/marketplace-analytics
/src/Infrastructure/DataFixtures/ProductFixtures.php
UTF-8
1,540
2.640625
3
[]
no_license
<?php declare(strict_types=1); namespace App\Infrastructure\DataFixtures; use App\Sales\Entity\Product; use Bezhanov\Faker\Provider\Commerce; use Doctrine\Bundle\FixturesBundle\Fixture; use Doctrine\Persistence\ObjectManager; use Faker\Factory; use Faker\Generator; final class ProductFixtures extends Fixture { ...
true
8f97087f0215af28709f0046865ef5fdb08a0fe4
PHP
nszabika2007/vegleges
/Symfony/src/Diff/LoginBundle/Diff/UserBundle/Entity/User.php
UTF-8
1,568
2.578125
3
[ "MIT", "BSD-3-Clause" ]
permissive
<?php namespace Diff\UserBundle\Entity; use Doctrine\ORM\Mapping as ORM; /** * User * * @ORM\Table(name="user", uniqueConstraints={@ORM\UniqueConstraint(name="userName", columns={"userName"}), @ORM\UniqueConstraint(name="email", columns={"email"})}) * @ORM\Entity */ class User { /** * @var integer ...
true
1c6a84bb010ee26443358128c1e9fdec3417c460
PHP
sergiolg99/guevaramotorsport
/admin/products/updateStock.php
UTF-8
665
2.5625
3
[]
no_license
<?php require_once('../recursos/conexionBD.php'); $id = $_POST['id_producto']; $action = $_POST['action']; $buscaStock = "SELECT `stock` FROM `productos` WHERE id_producto = $id"; $resultado = mysqli_query($conexion, $buscaStock); $datos = mysqli_fetch_array($resultado); $stockMas = $datos['stock'] +1; $stockMenos =...
true
bac7ba1076cdaf24babcec7371687c44d211ce43
PHP
jasonbdaniels/parking
/nearby/index.php
UTF-8
2,211
2.8125
3
[]
no_license
<?php //Gets the parking spaces nearby. //http://localhost/parking/api/nearby/?lat=39.0991&lng=-84.5127 header("Content-Type: application/json"); include_once "../parking_util_functions.php"; if(!isset($_GET["lat"]) || !isset($_GET["lng"])){ echo createInvalidMessage("Require both lat and lng values."); ...
true
a6a12db8464bcf604893c658f05937a47ea46227
PHP
dkonst/mmslides
/server/Projects.php
UTF-8
49,007
2.65625
3
[]
no_license
<?php /* * Projects.php * * Copyright (c) 2012 Hendrik Holtmann * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * Redistributions of source code must retain the above copyright n...
true
c23d79acdcced2b278d096a67af1925b6fb95679
PHP
adalwin-hofmann/CouponOpering
/app/SOE/Helpers/CouponsRss.php
UTF-8
3,951
2.84375
3
[ "MIT" ]
permissive
<?php class CouponsRss { public function __construct() { // construct as needed } public function build($type, $page = 0, $limit = 0) { $merchants = $this->get_merchants($type); $xml = new \SimpleXMLElement('<rss></rss>'); $xml->addAttribute('version', '2.0'); $channel = $xml->addChi...
true
4f0503c271b51dd2ead59142786998021dc85679
PHP
ImanolAtienza/SistemasWeb
/lab2B/php/InsertarPreguntaConFoto.php
UTF-8
1,388
2.703125
3
[]
no_license
<?php include "configurar.php"; if(!($bdPreguntas = mysqli_connect($host, $user, $pass, $bd))) die("Fallo al conectar a MySQL: " . $bdPreguntas->connect_error); // Si la imagen no esta vacia y que sea de unos tipos determinados if($_FILES["imagen"]["size"] > 0 && in_array($_FILES["imagen"]["type"], array("im...
true
596198abdfc6122b744e12eeae9ca49c8bc318f7
PHP
Raulkg/PHPLibrary
/src/Gshape/Square.php
UTF-8
1,579
3.25
3
[ "MIT" ]
permissive
<?php /** * This file is part of the Gshape package. * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. * * @license MIT License */ namespace Gshape; use Gshape\AbstractQuadrilateral; /** * @author Rahulkumar Gaddam<rgaddam@syr.edu> ...
true
67d2280daebc6cffb31d371edd7c516ddbefc2bb
PHP
G2yoshy/ContornosDesenvolvemento
/PracticaCode/PHP/division.php
UTF-8
262
3.578125
4
[]
no_license
<?php echo "Introduzca un número: "; $numero1 = stream_get_line(STDIN, 1024, PHP_EOL); echo "Introduzca un número: "; $numero2 = stream_get_line(STDIN, 1024, PHP_EOL); echo "La division de " . $numero1 . "/" . $numero2 . " = " . ($numero1/$numero2); ?>
true
680fcc5e43df40493f9a1c9e2e916158aa65153b
PHP
quantrocket/planlogiq
/rliq/protected/pages/ImageManager/ImageAssetManager.php
UTF-8
4,581
2.546875
3
[]
no_license
<?php /** * ImageAssetManager class file. * * @author Wei Zhuo <weizhuo[at]gmail[dot]com> * @link http://www.pradosoft.com/ * @copyright Copyright &copy; 2005-2007 PradoSoft * @license http://www.pradosoft.com/license/ * @version $Id$ * @package xlab6 */ /** * ImageAssetManager class. * * TO...
true
b38147c0f9737100d3435e50a61f5bdd53c8bf38
PHP
sbarbat/SyliusSagepayPlugin
/lib/classes/util.php
UTF-8
9,335
2.9375
3
[ "MIT" ]
permissive
<?php defined('SAGEPAY_SDK_PATH') || exit('No direct script access.'); define("MASK_FOR_HIDDEN_FIELDS", "..."); /** * Common utilities shared by all Integration methods * * @category Payment * @package Sagepay * @copyright (c) 2013, Sage Pay Europe Ltd. */ class SagepayUtil { /** * The associa...
true
cb1889aa69cdecb4f168e8562a0d985cd0ca5468
PHP
Arsslensoft/TachyonFX
/Core/ErrorHandler.php
UTF-8
2,012
2.8125
3
[]
no_license
<?php namespace Core; class ErrorHandler { public static function getErrorCode($code) { if($code == 400) return array("Code" => 400 , "Title" => "Malformed Request", "Message" => "The server cannot or will not process the request due to an apparent c...
true
9e783a95d2fb41ec0bcd0a2bb405be3ec1fd8de7
PHP
sebastianheuer/phpughh-june-2019
/parallel/src/TaskFailedResult.php
UTF-8
602
2.78125
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace ParallelPhp; class TaskFailedResult implements TaskResult { /** * @var int */ private $id; /** * @var string */ private $errorMessage; public function __construct(int $id, string $errorMessage) { $this->id = $id; $th...
true
cfe3225adf186c542ef3fd9928a213e611044193
PHP
tradesouthwest/details
/lib/user/tsw_activate.php
UTF-8
1,713
2.546875
3
[ "MIT" ]
permissive
<?php /** * file name tsw_activate */ if (isset($_GET['username']) && isset($_GET['active']) ) { include '../../inc/dbh.php'; $username = $_GET['username']; $active = $_GET['active']; $default = (int)0; // find row where username is not activated $stmt = $dbh->prepare("SELECT username, active, email FROM ts...
true
af67971a4ec46670073c54a1704cf780fae90bc1
PHP
SocialiteProviders/Manager
/src/OAuth2/AbstractProvider.php
UTF-8
2,543
2.5625
3
[ "MIT" ]
permissive
<?php namespace SocialiteProviders\Manager\OAuth2; use Illuminate\Support\Arr; use Laravel\Socialite\Two\AbstractProvider as BaseProvider; use Laravel\Socialite\Two\InvalidStateException; use SocialiteProviders\Manager\ConfigTrait; use SocialiteProviders\Manager\Contracts\OAuth2\ProviderInterface; use SocialiteProvid...
true
b34617d8bf60536397ce3b964dc97aa0c615f47c
PHP
edums12/CarrinhoCompras
/Funcoes.php
UTF-8
283
2.578125
3
[]
no_license
<?php class Funcoes { public static function findProd($pArray, $pId) { foreach ($pArray as $key => $prod) { if( $prod->GetId() == $pId ) { return $prod; } } return NULL; } }
true
0eb8cb3e120415d503b77957277f72c72cecb29f
PHP
Learnosity/learnosity-qti
/src/Commands/DefaultCommand.php
UTF-8
972
2.671875
3
[ "MIT" ]
permissive
<?php namespace LearnosityQti\Commands; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; class DefaultCommand extends Command { protected function configure() { $this ->setName('mo') ...
true
48838d03bf21a1d22de461137322878e13d34a77
PHP
IvailoH/Homework
/zad4.php
UTF-8
82
2.8125
3
[]
no_license
<?php $BGN=100; $USD=$BGN*1.71504; echo"The value of $BGN BGN in USD is $USD"; ?>
true
98b06ed6017c2db80c5ed4e9c9712479c107a031
PHP
nyeholt/relapse
/views/issue/csv.php
UTF-8
1,439
2.953125
3
[]
no_license
ID,Title,Description,Status,Severity,Type,Created By,Assigned To,Last Updated,Project,Notes <?php // figure out what date range we're looking at so we know what 'old' status we should be looking at $previousDate = strtotime("-7 days"); ?> <?php foreach ($this->issues as $issue) { $this->csv($issue->id); echo ","...
true
ccb8e4b6eef10d65d5c590b8633b2534423d48cc
PHP
tobias-reuter-rocket/clean-code-session
/SOLID/I.php
UTF-8
1,229
2.75
3
[]
no_license
<?php // Interface segregation principle // Many client-specific interfaces are better than one general-purpose interface. interface LoadableResource { public function load(); } interface PersistableResource { public function persist(); } class Settings implements LoadableResource, PersistableResource { ...
true
d6d7291b44ba3e3bbda3d2ba85b8913d0d383008
PHP
gromax/exercices_marionette
/php/class/RouteController/exams.php
UTF-8
3,130
2.875
3
[]
no_license
<?php namespace RouteController; use ErrorController as EC; use BDDObject\Fiche; use BDDObject\Exam; use BDDObject\Logged; class exams { /** * paramères de la requète * @array */ private $params; /** * Constructeur */ public function __construct($params) { $this->p...
true
c445dcffacec8edd8a0d13522e10a48accba8f4b
PHP
Quantical-Solutions/package-quantic-reactnative
/src/Commands/Workers.php
UTF-8
1,112
2.828125
3
[ "MIT" ]
permissive
<?php namespace Quantic\ReactNative\Commands; use Quantic\ReactNative\Jobbers\Compiler; use Quantic\ReactNative\Jobbers\Creater; use Quantic\ReactNative\Jobbers\Url; class Workers { private string $arg; public array $response; public function __construct($method, $arg) { $this->arg = ($arg =...
true
58c344b01e341d72400a923035945c741bd5786a
PHP
FloKnapp/faulancer
/src/View/Helper/FlashMessage.php
UTF-8
1,079
2.765625
3
[ "MIT" ]
permissive
<?php namespace Faulancer\View\Helper; use Faulancer\Exception\ServiceNotFoundException; use Faulancer\Session\SessionManager; use Faulancer\Translate\Translator; use Faulancer\View\AbstractViewHelper; /** * Class FlashMessage * * @package Faulancer\View\Helper * @author Florian Knapp <office@florianknapp.de> ...
true
69f8e9244fa3498eba90e57fb5fa52076c177283
PHP
EricLi404/Droplara
/app/controllers/BaseController.php
UTF-8
951
2.78125
3
[ "MIT" ]
permissive
<?php /** * Created by PhpStorm. * User: EricLi * Date: 2018/1/11 * Time: 20:30 */ use \services\View; use \services\Mail; /** 所有控制器的基类 * Class BaseController */ class BaseController { /** * @var */ protected $view; /** * @var */ protected $mail; /** * BaseControll...
true
2ee69339f3a9f5d7c68bd0135ac3aa0f0bb5018c
PHP
aybarsalvarci/laravel-api
/app/Repositories/Timezones/TimezonesRepository.php
UTF-8
1,466
2.53125
3
[]
no_license
<?php declare(strict_types=1); namespace App\Repositories\Timezones; use App\Models\Timezone; use App\Repositories\EloquentRepository; use App\Repositories\Timezones\Contracts\TimezonesRepositoryContract; class TimezonesRepository extends EloquentRepository implements TimezonesRepositoryContract { /** * get mod...
true
80ecc2a67af4dc9049afe566aa07ef9332866130
PHP
polcarlo/expense-managemeent
/database/seeds/RoleTableSeeder.php
UTF-8
456
2.5625
3
[ "MIT" ]
permissive
<?php use App\User; use Spatie\Permission\Models\Role; use Illuminate\Database\Seeder; class RoleTableSeeder extends Seeder { /** * Run the database seeds. */ public function run() { $admin = User::find(1); $user = User::find(2); Role::create(['name' => 'administrator']...
true
5da1aa5088c7dc582adc859c691c5f637fd71200
PHP
desarrollandoAmericaLatina/PuntoSeguro
/plugins/sfMapFishPlugin/data/generator/sfMapFishModule/default/parts/createAction.php
UTF-8
924
2.640625
3
[ "MIT", "BSD-3-Clause" ]
permissive
<?php echo ' /** * Creates new '.$this->getModelClass().'(s) from FeatureCollection * * @param sfWebRequest $request */ ';?> public function executeCreate(sfWebRequest $request) { $features = GeoJSON::load($request->getContent()); $c = Doctrine_Manager::getInstance()->getCurrentConnection(); ...
true
76db2b9665b12eda612a8af90f82df7eac093143
PHP
oliver021/x2core
/src/X2Core/Logger/Handlers/DatabaseHandler.php
UTF-8
1,260
3.03125
3
[]
no_license
<?php namespace X2Core\Logger\Handlers; use Monolog\Handler\AbstractProcessingHandler; use Monolog\Logger; use X2Core\Preset\Contracts\DatabaseManager; /** * Class DatabaseHandler * @package X2Core\Logger\Handlers */ class DatabaseHandler extends AbstractProcessingHandler { /** * @var DatabaseManager ...
true
77a88c886eb6531b2d233141851292a612d738f1
PHP
yasch-kub/yasch-kub-map.com
/application/model/place_model.php
UTF-8
3,136
2.796875
3
[]
no_license
<?php class place_model { /** * @return array */ public static function getAllPlace() { $db = Db::getConnection(); $query = "SELECT place.id, place.name, place.address, category.name AS category, place.info, icon, longtitude, altitude, mark FROM place JOIN category ON p...
true
7bc2f46f2afff925b51e13c67d1b8ed60b036b41
PHP
shreshthkant101/register
/register.php
UTF-8
1,683
2.515625
3
[]
no_license
<html> <head> <title>Register an Account</title> <link rel="stylesheet" type="text/css" href="style.css"> </head> <body> <form class="box" action="register.php" method="POST"> <img src="logo.jpg" style="width:160px;height:54px;"> <h1>Register</h1> <input type="text" name="username" placeholder="Register username" id="...
true
a1f63df90a548b0e94a5851d337b157011773a28
PHP
jstewmc/rtf-token
/tests/TextTest.php
UTF-8
1,217
3
3
[ "MIT" ]
permissive
<?php /** * The file for the text token tests * * @author Jack Clayton <clayjs0@gmail.com> * @copyright 2016 Jack Clayton * @license MIT */ namespace Jstewmc\RtfToken; use Jstewmc\TestCase\TestCase; /** * Tests for a text token */ class TextTest extends TestCase { /** * __construct() should...
true
bdfb1fccccd5d76738a63453530f0d26658a0c4f
PHP
fahrulputra40/framework
/tests/Test/HttpClient/resources/server.php
UTF-8
1,886
2.671875
3
[ "MIT" ]
permissive
<?php require __DIR__ . '/../../../../vendor/autoload.php'; use Neutrino\Http\Standards\Method; use Neutrino\Http\Standards\StatusCode; use Neutrino\HttpClient\Uri; $uri = new Uri($_SERVER['REQUEST_URI']); $parts = explode('/', trim($uri->path, '/')); $httpCode = !empty($parts[0]) ? $parts[0] : 200; $httpMessage...
true
216a48078acd3cead6838db162c165379a6db948
PHP
ferretwithaberet/atestat
/profilepanel.php
UTF-8
7,267
2.75
3
[]
no_license
<?php //Get nume elev function getNumeElev(){ $idElev = $_GET["idElev"]; $con = mysqli_connect("localhost","Radoi","admin","mydb"); // Check connection if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } $numeElev = NULL; $result = mysqli_query($c...
true
db324c68d84e018859db0cbb3ff8684d005a7f88
PHP
robinmin/swale
/sys/core/mvc.php
UTF-8
7,403
2.796875
3
[]
no_license
<?php /** * base_ctrl : class definition of base_ctrl */ class base_ctrl{ /** * $_content_type : Comtent tyep * @var string */ public $content_type = ''; /** * $_data : page data * @var array */ protected $_data = array(); public function __construct(){} public...
true
8ea04792f6cc6e71d7062991469660082ecc17dd
PHP
Le-Quynh-29/php-kethua
/Triangle/index.php
UTF-8
109
3.046875
3
[]
no_license
<?php include_once ("Triangle.php"); $triangle = new Triangle("Tam giac",1,2,9); echo $triangle->toString();
true
72f22787d8724032f0fa25bd5e499f2deddf6ede
PHP
atulagarwal100/youtube.demo
/api.php
UTF-8
3,012
2.84375
3
[]
no_license
<?php header('Access-Control-Allow-Origin: *'); session_start(); //good $servername = "localhost"; $username = "root"; $password = ""; $dbname = "ocl"; // Create connection $conn = new mysqli($servername, $username, $password, $dbname); // Check connection if ($conn->connect_error) { die("Connection failed:...
true
430b9123f29861667b8c20b00f85fcdc98a688a0
PHP
ShubhamT85/assignment
/reg_form.php
UTF-8
8,759
2.796875
3
[]
no_license
<?php session_start(); $Fname = $Lname = $Email = $Contact = $Age = $Password = $ConfirmPassword = $Pimage = ''; $FnameErr = $LnameErr = $EmailErr = $ContactErr = $AgeErr = $PasswordErr = $ConfirmPasswordErr = $PimageErr = ''; if ($_SERVER["REQUEST_METHOD"] == "POST") { if (!empty($_POST["Fname"])) { $f...
true
8d882943fcc7c0c33130ef194f1564c5f911037a
PHP
Mantvis1/databasesProject
/DB/libraries/arena.class.php
UTF-8
2,350
2.796875
3
[]
no_license
<?php class arena { private $arenas_table = ''; private $zaidzia_table =''; public function __construct() { $this->arenas_table = config::DB_PREFIX . 'arena'; $this->zaidzia_table = config::DB_PREFIX. 'zaidzia'; } public function getBrandList($limit = null, $offset = ...
true
d67897d10b15a904653208a1ab29430e04813fb0
PHP
rkulesza9/MastersDatabaseCoursework
/CPS5745-Study02/php/GetStates.php
UTF-8
594
2.8125
3
[]
no_license
<?php function make_connection(){ include 'dbconfig.php'; $conn = new mysqli($db_server, $db_username, $db_password, $db_database); if($conn->connect_errno){ echo "[ 'status' : 'error', 'description' : ${$conn -> connect_error}"; exit(); } return $conn; } function get_data($conn){ $query = "select disti...
true
9567f441c588b39b048942d07529f72aa3bb764a
PHP
ismbnc/challenge-api
/app/Models/Deneme/Purchase.php
UTF-8
631
2.546875
3
[ "MIT" ]
permissive
<?php /** * Generated file */ namespace App\Models\Deneme; /** * Class Purchase * * @property string $client_token * @property string $hash * @property int $durum * @property \Carbon\Carbon $kayit_zamani * * @package App\Models\Deneme */ class Purchase extends \Illuminate\Database\Eloquent\Model { pro...
true
1a216ddca65f32fb13cf3cc17aa65141ced2c332
PHP
marscore/hhvm
/hphp/test/zend/good/ext/standard/tests/image/image_type_to_extension.php
UTF-8
1,814
2.640625
3
[ "Zend-2.0", "PHP-3.01", "MIT" ]
permissive
<?php $constants = array( "IMAGETYPE_GIF" => IMAGETYPE_GIF, "IMAGETYPE_JPEG" => IMAGETYPE_JPEG, "IMAGETYPE_PNG" => IMAGETYPE_PNG, "IMAGETYPE_SWF" => IMAGETYPE_SWF, "IMAGETYPE_PSD" => IMAGETYPE_PSD, "IMAGETYPE_BMP" => IMAGETYPE_BMP, ...
true
79a25e6ef4e26da6232e03846f32dce2bd9aee5e
PHP
tychovbh/laravel-resource-mapper
/tests/feature/ResourceMapperTest.php
UTF-8
5,220
2.5625
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace Tychovbh\Tests\ResourceMapper\Feature; use Faker\Provider\Company; use Faker\Provider\Person; use Tychovbh\ResourceMapper\RawResource; use Tychovbh\ResourceMapper\ResourceMapper; use Tychovbh\Tests\ResourceMapper\TestCase; class ResourceMapperTest extends TestCase { /** ...
true
216ad7ad38fa2b2df2ec928e783395142ffb3036
PHP
MikePap/xml_html
/XML/SimpleXML/addChild.php
UTF-8
1,863
2.953125
3
[]
no_license
<!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>addChild</title> <style type="text/css"> h1{ color: #00F; font-size:24...
true
0ae65d6bd09dcaf37863810af501834f6965123f
PHP
lasellers/ApiBlade
/app/County.php
UTF-8
1,568
2.765625
3
[]
no_license
<?php namespace App; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Facades\DB; class County extends Model { public $timestamps = false; protected $casts = [ 'state' => 'string', ]; // append accessors protected $appends = [ 'dropdown_name', ]; public st...
true
e9cb0a9e60ab2ca6f1a7a4299e50d22b51341084
PHP
Ammar-pr/unit
/htdocs/file_up.php
UTF-8
4,390
2.640625
3
[]
no_license
<?php session_start(); require_once 'units_requests.php'; require_once 'users.php'; class uplad_file { protected $path = "../attachments/"; public function check_captcha () { if(!empty($_POST['captcha_code'])){ //get captcha code from session $captchaCode = $_SESSION['captchaCode'];...
true
181a669e321fc162f4e61d627725c751f92634bb
PHP
isxoq/lms_texnomart
/frontend/models/BecomeTeacherForm.php
UTF-8
2,272
2.640625
3
[]
no_license
<?php namespace frontend\models; use backend\models\EducationLevel; use yii\base\Model; use common\models\User; class BecomeTeacherForm extends Model { public $firstname; public $lastname; public $email; public $phone; public $age; public $education_level_id; public $gender; public...
true
25bc150f8bd0e8fc23a51c8194110358dfa0d8ca
PHP
rezasetiabudi/teamatik
/application/controllers/Employee.php
UTF-8
4,854
2.578125
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference", "GPL-3.0-only", "GPL-1.0-or-later" ]
permissive
<?php defined('BASEPATH') or exit('No direct script access allowed'); class Employee extends CI_Controller { function __construct() { parent::__construct(); /* Standard Libraries of codeigniter are required */ $this->load->database(); $this->load->helper('ur...
true
65a9439e86b8cb8671d69e5fa87120eb395fc5a5
PHP
veltzer/demos-php
/exercises/Lecture4/ex4.php
UTF-8
261
3.65625
4
[]
no_license
<?php class myclass { var $myproperty; function mymethod() { echo "\$myproperty is: {$this->myproperty}"; /*this will output: * $myproperty is: ... */ } } $myobject = new myclass; $myobject->myproperty = 'Hello, World!'; $myobject->mymethod(); ?>
true
b4a0818aa1b57c108e1852a32da5f58b9e29c705
PHP
shi429101906/sihe-log
/src/Monolog/LogManager.php
UTF-8
3,345
2.53125
3
[]
no_license
<?php namespace Sihe\Log\Monolog; use Throwable; use Illuminate\Log\Logger; use Monolog\Logger as Monolog; use Sihe\Log\Contracts\Logging\Log; use Illuminate\Log\LogManager as Manager; class LogManager extends Manager implements Log { /** * @var array */ protected $logger = []; /** * Notes: 重写获取日志...
true
ae7c5de13a0c6fbcd69e0065b6e7a2ea3e2aaa1e
PHP
arimolzer/ifttt-webhook
/src/Channels/IftttWebhookChannel.php
UTF-8
1,985
2.75
3
[ "MIT" ]
permissive
<?php namespace Arimolzer\IftttWebhook\Channels; use Arimolzer\IftttWebhook\Exceptions\IftttWebhookException; use Illuminate\Notifications\Notification; /** * Class IftttWebhookChannel * @package Arimolzer\IftttWebhook\Channels */ class IftttWebhookChannel { /** @var string $key */ protected $key; /*...
true
b80ae640d342936160558d8845acb21af64f4d44
PHP
MichaelJamesParsons/MetroPublisher-PHP-SDK
/src/Common/Serializers/DeserializedValueFactory.php
UTF-8
564
2.84375
3
[ "MIT" ]
permissive
<?php namespace MetroPublisher\Common\Serializers; /** * Class DeserializedValueFactory * @package MetroPublisher\Common\Serializers */ class DeserializedValueFactory { public static function getValue($value, $type) { switch ($type) { case "int": return intval($value); ...
true
f2796a0205a29b7618425eaf9a87d67541c88686
PHP
gere/pocket_calculator
/app/Http/Controllers/BacklogController.php
UTF-8
1,353
2.84375
3
[]
no_license
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use Illuminate\Http\Response; /** * class to handle frontend requests for user * backlogs. It's possible to save one, or get all. * Responses are always JSON. * Thanks to Laravel authentication middleware if a guest * user try to access one of t...
true
14aec28f6bf00400ade53210f655bbbcd24cd960
PHP
mercierjo/STI-projet1
/site/html/modifyuser.php
UTF-8
4,849
2.734375
3
[]
no_license
<?php /** * Page qui permet de modifier un utilisateur * @author Mercier Jordan, Vogel Maximilian */ require_once('./utils.php'); session_start(); if(!isset($_SESSION['username']) && $_SESSION['role'] != 2){ header('Location: ./index.php'); exit(); } if(!isset($_GET['usern...
true
6d37537eb100d50ba2a8e22462b935d037fb53c4
PHP
muhamadariefb/lsp-pelatihan
/krs_dosen/ubah.php
UTF-8
1,980
2.71875
3
[]
no_license
<?php require 'function.php'; //untuk mengambil ID dari keywoard yang dikirim melalui url $getID=$_GET['id']; //untuk menampilkan data pada form sesuai ID $getData=query("SELECT * FROM t_krs_dosen WHERE id='$getID'"); if(isset($_POST["ubah"])) { if(ubah($_POST)>0) { //echo "Berhasil!"; echo "...
true
e9a3b225470e8641c75056abf6d24b97c0a719b4
PHP
beerent/cosmos_server
/web/live/challenge/ChallengeManager.php
UTF-8
12,048
2.609375
3
[]
no_license
<?php $include = $_SERVER['DOCUMENT_ROOT']; $include .="/database/DatabaseManager.php"; include_once($include); $include = $_SERVER['DOCUMENT_ROOT']; $include .="/live/challenge/ChallengeLeaderboardEntry.php"; include_once($include); $include = $_SERVER['DOCUMENT_ROOT']; $include .="/live/challenge/SelectedAnswer...
true
6f20deb48db3074809f1b17c78ed517f89187e98
PHP
rubencherbit/adress_book
/adress_book/src/AppBundle/Entity/Contact.php
UTF-8
4,807
2.578125
3
[ "MIT", "BSD-3-Clause" ]
permissive
<?php namespace AppBundle\Entity; use Doctrine\ORM\Mapping as ORM; /** * @ORM\Entity * @ORM\Table(name="contact") */ class Contact { /** * * @ORM\Column(name="id", type="integer") * @ORM\Id * @ORM\GeneratedValue(strategy="AUTO") */ private $id; /** * @ORM\Column(type="string...
true
8424b8b60fc35d19ab5ba8ffca0f2d89eb8296b7
PHP
fileGetContents/laravel54cn
/vendor/laravel/framework/src/Illuminate/Notifications/Messages/NexmoMessage.php
UTF-8
1,481
2.921875
3
[ "MIT" ]
permissive
<?php namespace Illuminate\Notifications\Messages; class NexmoMessage { /** * The message content. * * 消息内容 * * @var string */ public $content; /** * The phone number the message should be sent from. * * 应该从电话号码中发出信息 * * @var string */ publi...
true
347323562450a0da6614762e46b40a117a8a95d0
PHP
braican/braican.com
/wp/themes/braican-api/lib/Endpoints/Base.php
UTF-8
687
2.96875
3
[]
no_license
<?php /** * Abstract class to build endpoints off of. * * @package BraicanApi */ namespace BraicanApi\Endpoints; /** * Sets up a wrapper for endpoints. */ abstract class Base { /** * Init this endpoint. * * @param string $route The path to the endpoint. */ public function __construct( $route ) { reg...
true
c59b9c91f163dc6b3afdacd8abcd5312349bb0dd
PHP
TPETb/has-spinner
/src/HAS/SpinnerBundle/Document/Category.php
UTF-8
1,889
2.640625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: BK * Date: 06.01.2015 * Time: 3:58 */ namespace HAS\SpinnerBundle\Document; use Doctrine\ODM\MongoDB\Mapping\Annotations as MongoDB; use Doctrine\ODM\MongoDB\Mapping\Annotations\ReferenceMany; /** * Class Category * @package HAS\SpinnerBundle\Document * @MongoDB\Docum...
true
a960504f6c84fa404c96e780afc60c49d606a6e6
PHP
jigius/forms
/src/Field/Type/CaptchaField.php
UTF-8
328
2.546875
3
[ "MIT" ]
permissive
<?php namespace jigius\forms\Field\Type; use jigius\forms\Field; class CaptchaField extends CFormField { public $type = 'captcha'; public function getInput() { return "<input />"; } public function getLayout() { return "<p class={$this->type}>" . $this->getInput() . "</p"; ...
true
76f471dc81525e715776197ebf302d854867d6ef
PHP
elhadjimalick-dieye/bniass
/projet2/ajout.php
UTF-8
1,447
2.625
3
[]
no_license
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Document</title> </head> <body> <section> <form action="" method="post" class="form"> <d...
true
7061855e0997fb3971cc50b9f1ead66dbb62a913
PHP
totalcrm/odata-dbal
/src/config/ODataOptions.php
UTF-8
668
2.71875
3
[ "MIT" ]
permissive
<?php class ODataOptions{ public $allowAnyOrigin; public $enableOptionsRequest; public $clients; public $allowQueryMethodModifiers; public $defaultAllowedMethods; function __construct() { $this->allowAnyOrigin=false; $this->enableOptionsRequest=true; $this->clients=...
true
dfb3e606ea79d7ff19d548c69a7b2b1631d9a7b9
PHP
Suharsh329/hourglass
/src/Helpers/Helper.php
UTF-8
4,604
3.1875
3
[ "MIT" ]
permissive
<?php namespace App\Helpers; class Helper { protected $db; public function __construct(Database $db) { $this->db = $db; } /** * Returns the number of days till task is due * @param string $due * @return string */ public function getRemainingDays(string $due): str...
true
6491654e87af9153224e79c56a16a807963ca59f
PHP
HaidarAliN/Intro-to-PHP
/Exercise3.php
UTF-8
275
3.671875
4
[]
no_license
<?php $arr = [5,1,8,9,2]; $max= $arr[0]; $min=$arr[0]; foreach($arr as $value) { if ($value<$min) { $min = $value;//update minimum } else if($value>$max) { $max=$value;//update maximum } } echo "The min value is: $min\n"; echo "The max value is: $max"; ?>
true
01cf705a822a6650038ede996cd7c596bf630df1
PHP
samstyle321/student
/special/del.php
UTF-8
1,027
2.671875
3
[]
no_license
<!DOCTYPE html> <html> <head> <title>Delete</title> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <link rel="stylesheet" type="text/css" href="../asset/stylesheets/add.css"> </head> <body> <center> <div class="main"> <h1>Remove Student</h1> <form ...
true
ce7bcd5e18e43d126cac8c74c60cb676947c5799
PHP
jasonschaad/cosc360Project
/edituser_process.php
UTF-8
6,314
3.09375
3
[ "MIT" ]
permissive
<?php // Start the session session_start(); include 'head.php'; // Confirm we have a POST request if ($_SERVER["REQUEST_METHOD"] == "POST") { // collect value of input fields $username = $_POST['username']; $firstName = $_POST['firstName']; $lastName = $_POST['lastName']; $email = $_POST['email']; $us...
true
7ff3aa25642c7a0daf1db674e612895f502e5aec
PHP
Jack-Tsai4689/exam
/app/Http/Controllers/QueController.php
UTF-8
47,658
2.578125
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Http\Requests; use App\Ques; use URL; //use Auth; const UPLOAD_DIR = "uploads/que"; class QueController extends TopController { /** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ ...
true
6668fb787beade599cfcd554776071342c2e91b8
PHP
Yoskaldyr/cmf_core
/upload/library/CMF/Core/DataWriter/Node.php
UTF-8
3,131
2.609375
3
[ "Unlicense" ]
permissive
<?php /** * Data writer for all node types. * Dynamic proxy class * * @package CMF_Core * @author Yoskaldyr <yoskaldyr@gmail.com> * * @method array getUnserialize($key, $onlyArray = false) * @method boolean _validateSerializedArray(&$data) * @method CMF_Core_Model_Node _getNodeModel() */ class CMF_Core_DataW...
true
d299169101d15403fe4e4f5d39a47e91cff88309
PHP
PublicDesignWorkshop/FoodParent2.0
/server/tree.php
UTF-8
6,748
2.734375
3
[]
no_license
<?php header("Cache-Control: no-store, no-cache, must-revalidate, max-age=0"); header("Cache-Control: post-check=0, pre-check=0", false); header("Pragma: no-cache"); include_once 'functions.php'; sec_session_continue(); // Our custom secure way of starting a PHP session. switch($_SERVER['REQUEST_METHOD'...
true
48ddeee52ecf214f9e40cd12850aec6a213e3596
PHP
simplepayment/simplepayment
/examples/php/SimplePayment.php
UTF-8
2,089
2.78125
3
[ "Apache-2.0" ]
permissive
<?php class SimplePayment { const SANDBOX_URL = 'https://staging.simplepayment.solutions/'; const PRODUCTION_URL = 'https://api.simplepayment.solutions/'; public static function encrypt( $json_data, $secret ) { return hash_hmac('sha256', base64_encode($json_data), $secret); } public static function s...
true
af15d392021a15cf407966b9e691131250ef3955
PHP
JohnABC/weiqinghe
/protected/components/WFunc.php
UTF-8
8,323
2.796875
3
[]
no_license
<?php class WFunc { private static function _getParam($key, $default = Null, $isGet = True) { $func = $isGet ? 'getQuery' : 'getPost'; if (is_array($key)) { $rtn = array(); foreach ($key as $k => $v) { if (is_int($k)) { $rtn[$v] = Y...
true
d86cd7896ff81bb60793297a7d94d4f2849ba634
PHP
Christophvh/TDDForum
/tests/Feature/ThreadTest.php
UTF-8
2,434
2.640625
3
[]
no_license
<?php namespace Tests\Feature; use Tests\TestCase; use Illuminate\Foundation\Testing\DatabaseMigrations; class ThreadTest extends TestCase { use DatabaseMigrations; private $thread; public function setUp() { parent::setUp(); $this->thread = factory( 'App\Thread' )->create(); } /** @test */ p...
true
8e8ce682ce60b0e95aef8b279858dfe4baaa9e21
PHP
yatinmcs/php-recruitment-test_new
/src/Controller/ImportAction.php
UTF-8
2,962
2.671875
3
[]
no_license
<?php namespace Snowdog\DevTest\Controller; use Snowdog\DevTest\Model\PageManager; use Snowdog\DevTest\Model\UserManager; use Snowdog\DevTest\Model\WebsiteManager; use Bartwind\SitemapImporter\SitemapImporter; class ImportAction { const PARAM_IMPORT_TYPE = 'import_type'; const PARAM_XML_URL = 'xml_url'...
true
49998eb43e1a1a57c3676aa512a83410e9f9ee3e
PHP
rela589n/event-sourcing-example
/app/Policies/MessagePolicy.php
UTF-8
582
2.53125
3
[]
no_license
<?php declare(strict_types=1); namespace App\Policies; use App\Models\User\Eloquent\User; use App\Services\Message\Commands\DeleteMessage; use App\Services\Message\Commands\EditMessage; use App\Services\Message\Commands\WriteMessage; final class MessagePolicy { public function writeMessage(?User $user, WriteMes...
true
0a0be3dd3919f714e9229ad15ae68dc00b9af5ad
PHP
madhuwantha/coffee-shop-management-system
/src/Entity/CoverPhoto.php
UTF-8
1,153
2.640625
3
[]
no_license
<?php namespace App\Entity; use App\Repository\CoverPhotoRepository; use Doctrine\ORM\Mapping as ORM; use Symfony\Component\HttpFoundation\File\UploadedFile; use Symfony\Component\Validator\Constraints as Assert; /** * @ORM\Entity(repositoryClass=CoverPhotoRepository::class) */ class CoverPhoto { /** * @...
true
aa496bc351771f8f4b833887ed2d364fe7e2232f
PHP
ckwong2001/CSCI3100-201920-Group33-Habitracker
/admin_delete_goal.php
UTF-8
4,127
2.53125
3
[]
no_license
<?php function deleteGoal($conn, $goal_id) { // remove goal $sql = "delete from goals where goal_id = ?"; $stmt = mysqli_stmt_init($conn); if (!mysqli_stmt_prepare($stmt, $sql)) { header("Location: admin_index.php?error=sqlerror"); exit(); } el...
true
0e774f151fe38cbf20f71cbe01acdd31d985cf41
PHP
jpyeah/SwooleDistributed-docker
/app/vendor/protobuf-php/protobuf/tests/Binary/SizeCalculatorTest.php
UTF-8
7,434
2.578125
3
[ "MIT" ]
permissive
<?php namespace ProtobufTest\Binary; use Protobuf\Stream; use ProtobufTest\TestCase; use Protobuf\Binary\StreamWriter; use Protobuf\Binary\SizeCalculator; class SizeCalculatorTest extends TestCase { /** * @var \Protobuf\Binary\SizeCalculator */ protected $calculator; /** * @var \Protobuf\...
true
f160684569697cac9b1f79ce830a9b9988fcb581
PHP
beletsky/restorandoma
/admin/inc/func_news.inc.php
WINDOWS-1251
3,454
2.578125
3
[]
no_license
<? ################################################################################ # # # Project name # # ...
true
7f3f448e024a17d485c7ee2c75e74648eff40f05
PHP
cabelodomato/AuroraPHPFramework
/Framework/Router.php
UTF-8
2,028
3.15625
3
[]
no_license
<?php namespace Aurora; class Router { public function __construct(array $routeMap) { //$this->method = $this->getMethod(); //$this->requestedPath = $this->getRequestPath(); $this->attributes = $this->getAttributes(); $this->mapping = $this->getParseMap($routeMap); } ...
true
ae243f71cdad6592ff5c91f0cdf2842ec88cd0cd
PHP
Scylla126/Support
/installer/app/lib/helper.php
UTF-8
6,785
2.59375
3
[]
no_license
<?php if(!function_exists("_e")){ function _e($string, $parameter = null, $_ = null) { $args=func_get_args(); if(!empty($args[0])){ echo call_user_func_array("__",$args); }else{ echo $args[0]; } } } if(!function_exists("_n")){ function _n($number) ...
true
2ee2a8e8825d966a3b36702e59d02bba3e57fcaa
PHP
yaroslavlutz/corporate.laravel.loc
/database/migrations/2018_02_05_224949_add_foreign_key_to_table_articles.php
UTF-8
1,699
2.59375
3
[ "MIT" ]
permissive
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class AddForeignKeyToTableArticles extends Migration { /** * Run the migrations. * * @return void */ public function up() { if( Schema::hasTable(...
true
144378dfe252351582862f0d9a2c2464ed8db29e
PHP
chudniy/exchange-rate
/src/Command/UpdateExchangeRateCommand.php
UTF-8
2,921
2.765625
3
[]
no_license
<?php namespace App\Command; use App\Entity\Currency; use App\Entity\CurrencyPair; use App\Services\ExchangeService; use Symfony\Bridge\Doctrine\RegistryInterface; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputInterface; use ...
true
9c6e8ca50ff9b9769fd7fada2acbbf621442f984
PHP
KrasimiraGeorgieva/Programming-Basics-with-PHP-January-2018
/4. Complex-Conditions/02. Small Shop.php
UTF-8
1,144
2.859375
3
[ "MIT" ]
permissive
<?php $product = strtolower(readline()); $town = strtolower(readline()); $quontity = floatval(readline()); if ($town == "sofia"){ if ($product == "coffee") echo $quontity * 0.50; elseif ($product == "water") echo $quontity * 0.80; elseif ($product == "beer") echo $quontity * 1.20; ...
true
1079de730e1d8428b9bdb2dea92ef33947905581
PHP
kvitajin/VIS
/Farabuk/server/src/repository/UzivatelRepository.php
UTF-8
4,555
2.765625
3
[ "GLWTPL" ]
permissive
<?php require_once __DIR__ . "/../repository/Repository.php"; require_once __DIR__ . "/../data/Uzivatel.php"; require_once __DIR__ . "/../repository/SkupinaRepository.php"; require_once __DIR__ . "/../repository/SkupinaUzivatelRepository.php"; require_once __DIR__ . "/../repository/ObecRepository.php"; use Connection...
true
6744f0fe93e09516cd32840c24a8ee1a911f3898
PHP
huangbin2018/dbmq
/src/Consumer/Status.php
UTF-8
297
2.5625
3
[ "MIT" ]
permissive
<?php namespace DBMQ\Consumer; /** * 消费者状态 * @author Huangbin <huangbin2018@qq.com> */ class Status { /** * 等待运行 */ const WAITING = 0; /** * 运行中 */ const RUNNING = 1; /** * 停止 */ const STOP = 2; }
true
ecca5e58ef4722fefddd1830a7232bed2b028ddb
PHP
liujieyan/question-list
/model/SqlHelper.php
UTF-8
941
3.265625
3
[]
no_license
<?php class SqlHelper extends mysqli{ private $host = "localhost"; private $account = "root"; private $password = ""; private $db = "zero_demo"; private $port = "3306"; public $isConnectError = false; public function __construct(){ parent::__construct($this->host,$this->accou...
true
ad018eb4742234faeab83444963309b66135b27e
PHP
Trismegiste/AppMicroWiki
/tests/Entity/DocumentTest.php
UTF-8
4,404
2.796875
3
[]
no_license
<?php use PHPUnit\Framework\TestCase; use Trismegiste\MicroWiki\Document; use Trismegiste\MicroWiki\Sentence; class DocumentTest extends TestCase { /** @var Document */ protected $sut; protected function setUp(): void { $this->sut = new Document(); } protected function tearDown(): v...
true
386745d7db5828b3b356e5e3eee0f9f59eb9fd88
PHP
anujjaha/angels
/app/Controller/MemorialsController.php
UTF-8
4,592
2.546875
3
[]
no_license
<?php App::uses('AppController', 'Controller'); /** * Memorials Controller * * @property Memorial $Memorial * @property PaginatorComponent $Paginator * @property SessionComponent $Session */ class MemorialsController extends AppController { /** * Components * * @var array */ public $components = array('Pagi...
true
99fb31e5b70db181764bdb03c9d1e760e27c145f
PHP
laytoneverson/client-planstin
/app/Services/PasswordService.php
UTF-8
1,166
2.953125
3
[]
no_license
<?php /** * File: PasswordService.php * Project: planstin * Author: @laytoneverson <layton.everson@gmail.com> */ namespace App\Services; use App\Utils\UsesEntityManagerTrait; use Doctrine\ORM\EntityManagerInterface; use \Illuminate\Contracts\Hashing\Hasher; use App\Entities\User; class PasswordService { use ...
true
4244dab1a281b1c78eb1e084dc27e2b00f313985
PHP
SylvainBaillet/Back
/WF3/POO/06_abstraction_finalisation_surcharge_trait/surcharge.php
UTF-8
1,166
3.625
4
[]
no_license
<?php // une surcharge (override) permet de surcharger une methode, de l'ameliorer class A { public function calcul() { return 10; } } //--------------------------------------------------------------- class B extends A { public function calcul() //redefinition...
true