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
3e44b7370ee93d3a3e4d5cab1d7f7841e09756d1
PHP
metaaa/pizza_full_oop
/models/Dbconfig.php
UTF-8
1,290
3.328125
3
[]
no_license
<?php class Dbconfig { private $serverName; private $dbName; private $dbUsername; private $dbPassword; private static $instance; private $connection; /** * Get an instance of the Database and return it * * @return Dbconfig */ public static function getInstance() ...
true
a296b61d0e495cf3a97e6c0526207cbda49be281
PHP
frankluongo/wp-plugin-from-scratch
/app/wordpress/wp-content/plugins/frankluongo-plugin/frankluongo-plugin.php
UTF-8
2,471
2.65625
3
[]
no_license
<?php /** * @package frankluongoplugin */ /* Plugin Name: Frankluongo Plugin Plugin URI: https://frankluongo.com Description: My first Plugin Version: 1.0.0 Author: Frank Luongo Author URI: https://frankluongo.com License: GPLv2 or later Text Domain: frankluongo-plugin */ // FIRST: Check to see that...
true
116d2f8a15ec6738b52c4278de2c5e264883f371
PHP
RuslanKozin/TrainingSiteKAnk
/recentjokes(Chapter12)/generate.php
UTF-8
2,301
2.671875
3
[]
no_license
<?php $srcurl = 'http://trainingsitekank/recentjokes(Chapter12)/controller.php'; $tempfilename = $_SERVER['DOCUMENT_ROOT'] . '/recentjokes(Chapter12)/tempindex.html'; $targetfilename = $_SERVER['DOCUMENT_ROOT'] . '/recentjokes(Chapter12)/index.html'; if (file_exists($tempfilename)) { //file_exists - проверяе...
true
9f314d83c843df8cdb5ac0199789cb5d74376562
PHP
vickyromadon/marketplacepenyewaanbarang
/app/Helpers/MailFailure.php
UTF-8
646
2.546875
3
[]
no_license
<?php namespace App\Helpers; use Illuminate\Support\Facades\Mail; use App\Models\MailQueue; class MailFailure { /** * Sending message. * * @param string $to * @param string $name * @param string $subject * @param mail $body */ public static function mail_failure($to, $n...
true
a42f00b04ee91ec5b87d3d61b07536e14fdfd23d
PHP
ziggles/ZigPHP
/system/session.php
UTF-8
1,641
2.828125
3
[]
no_license
<?php /* | ====================================================================== | ZigPHP Session Class | ====================================================================== | | This class makes handling session variables a lot easier by | streamlining the usage in the controller and models. | */ cl...
true
15ee187892836644aa3f5717d7ea66b385577c6e
PHP
becauseme/theembroideryshoppe
/app/code/local/Symmetrics/InvoicePdf/Model/Pdf/Items/Default.php
UTF-8
3,646
2.515625
3
[]
no_license
<?php /** * Symmetrics_InvoicePdf_Model_Pdf_Items_Default * * @category Symmetrics * @package Symmetrics_InvoicePdf * @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de> * @copyright symmetrics gmbh * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) *...
true
2d345a128f79de715263715ca4c8e12414ec17ac
PHP
hankly/elife
/weather.php
UTF-8
1,824
2.5625
3
[]
no_license
<?php function getWeatherInfo($cityName){ if ($cityName == "" || (strstr($cityName, "+"))) { return "发送天气+城市,例如'天气深圳'"; }//用户查询天气,回复关键词 规则 $url = "http://api.map.baidu.com/telematics/v3/weather?location=".urlencode($cityName)."&output=json&ak=44f199aa72feabaa17cccdc3923f30ca";//构建通过百度车联A...
true
427cb2c41a5e3f2063057adc1774789737fdd73d
PHP
AdrianWii/EconomistBlog
/src/AppBundle/Entity/Register.php
UTF-8
5,937
2.609375
3
[ "BSD-3-Clause", "MIT" ]
permissive
<?php namespace AppBundle\Entity; use Symfony\Component\Validator\Constraints as Assert; use Doctrine\ORM\Mapping as ORM; /** * Description of Register * * @author adrian * * * @ORM\Table(name="registration") * @ORM\Entity() * */ class Register { /** * * @ORM\Column(name="id", type="integer"...
true
c36e04123b999dbcf05dcd5050d7a6ed7b99d87c
PHP
edsonrodsilva/bravi_api
/app/Repositories/ContactRepository.php
UTF-8
2,622
2.875
3
[]
no_license
<?php namespace App\Repositories; use App\Http\Requests\ContactRequest; use App\Http\Resources\ContactResource; use App\Http\Resources\ContactResourceCollection; use App\Interfaces\ContactInterface; use App\Traits\ResponseAPI; use App\Models\Contact; class ContactRepository implements ContactInterface { // Use R...
true
c004e20b3f9fc57136271fd3f95fc092036cb5a9
PHP
AVBLANCO/ConDomino
/Back/dao/entities/DetalleexistenciabodegaDao.php
UTF-8
7,166
2.84375
3
[]
no_license
<?php /* -------Creado por------- \(x.x )/ Anarchy \( x.x)/ ------------------------ */ // Todos los animales son iguales, pero algunos animales son más iguales que otros \\ include_once realpath('../dao/interfaz/IDetalleexistenciabodegaDao.php'); include_once realpath('....
true
bd544b74d2148d6dcd40031e9b10e91ba4482e33
PHP
alexandrewavelet/musikeole
/modeles/ManagerAlbums.php
UTF-8
2,747
2.96875
3
[]
no_license
<?php /** * Manager de la galerie photos en front-end */ class ManagerAlbums { protected $connexion; /** * Constructeur */ function __construct() { $this->connexion = new ConnexionBDD(); } public function getManifestation($id) { $reqManif = $this->connexion->getConnexion()->prepare(...
true
659ff366e0a7c71fc8ecc58cdc98ec5e2177e8d4
PHP
plamenyankov/northstyle
/app/Module/Core/DataObject/ObjectValue.php
UTF-8
783
2.796875
3
[]
no_license
<?php namespace Northstyle\Module\Core\DataObject; use Northstyle\Common\DataObject; use Northstyle\Module\Core\DataObject\Id; class ObjectValue extends DataObject { public $object_type = ''; public $object_id = null; public $name = ''; public $value = ''; public function _init($data = array()) { if (!is...
true
5d39880c7af0900a365803a14489e7375f4dfa1f
PHP
Zaggoware/Framework
/src/Zaggoware/Exceptions/InvalidArgumentTypeException.php
UTF-8
877
2.828125
3
[ "MIT" ]
permissive
<?php namespace Zaggoware\Exceptions; use Zaggoware\Reflection\Type; class InvalidArgumentTypeException extends \InvalidArgumentException { /** * @param string $argumentName * @param mixed $argument * @param Type|string|object $expectedTypes */ public function __construct($argumentName, $...
true
357d27b6caf0d97e8b1de7902091d273900cf9e6
PHP
rossilfossil/PawnHub
/auctionver5/admin/remove_item.php
UTF-8
996
2.734375
3
[]
no_license
<?php include "../connect_to_pms.php"; if (!isset($_SESSION['item_stack'])){ $_SESSION['item_stack'] = array(); } $item = $_POST['itemID']; if(($key = array_search($item, $_SESSION['item_stack'])) !== false) { unset($_SESSION['item_stack'][$key]); if (empty($_SESSION['item_stack'])) unset($_SES...
true
68b4381cc10513e3be3aa13a132e218a1540fe7f
PHP
Hor123Fourmies/PHP-strUtils
/indexCorrige.php
UTF-8
314
2.640625
3
[]
no_license
<?php include "classes/StrUtilsCorrige.php"; $strUtilsCorrige = new StrUtilsCorrige ("ceci est un test"); // $strUtilsCorrige->test(); //echo $strUtilsCorrige->bold(); echo "<br>"; //echo $strUtilsCorrige->italic(); echo "<br>"; //echo $strUtilsCorrige->underline(); echo "<br>"; echo $strUtilsCorrige->uglify();
true
a231b095bd156cfe21b86ec15a85088eefc64df6
PHP
natepage/Symplify
/packages/coding-standard/src/Rules/NoEmptyRule.php
UTF-8
714
2.53125
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace Symplify\CodingStandard\Rules; use PhpParser\Node; use PhpParser\Node\Expr\Empty_; use PHPStan\Analyser\Scope; /** * @see \Symplify\CodingStandard\Tests\Rules\NoEmptyRule\NoEmptyRuleTest */ final class NoEmptyRule extends AbstractManyNodeTypeRule { /** * @var stri...
true
17eb2a82a041b1a9874e45c9e3334aa49a0987b1
PHP
hrushikeshliya/Shingar-Plastic
/api/user/authenticate.php
UTF-8
1,547
2.65625
3
[]
no_license
<?php // required headers header("Access-Control-Allow-Origin: *"); header("Access-Control-Allow-Headers: access"); header("Access-Control-Allow-Methods: GET"); header("Access-Control-Allow-Credentials: true"); header('Content-Type: application/json'); // include database and object files include_once '../config/data...
true
7376dbe917a3663560b7579cb75d37d19f12ae96
PHP
2021-Winter-HTTP-5202-A/ChopperForceFive
/Models/WeaponQualification.php
UTF-8
3,119
2.765625
3
[]
no_license
<?php ini_set('display_startup_errors', 1); ini_set('display_errors', 1); error_reporting(-1); class WeaponQualification{ public function getAllWeaponQualification($db, $weaponId){ $sql = "SELECT wq.id, wq.user_id, u.rank, wc.weapon_name, CONCAT(u.first_name, ' ', u.last_name) AS 'fu...
true
827ff3268517a94e02c7655511cb389d79a6f9f3
PHP
weddingjuma/trade
/app/Repositories/RealTimeRepository.php
UTF-8
3,031
2.84375
3
[ "MIT" ]
permissive
<?php namespace App\Repositories; use Illuminate\Filesystem\Filesystem; /** * *@author: Tiamiyu waliu kola *@website : www.crea8social.com */ class RealTimeRepository { protected $types = [ 'chat', 'update' ]; //current type working on protected $type; ...
true
cbd829c49da689fa7463de8ca472bfb05a084cd0
PHP
joyhooei/pincong-wecenter
/system/class/cls_format.inc.php
UTF-8
4,564
2.625
3
[]
no_license
<?php /* +-------------------------------------------------------------------------- | WeCenter [#RELEASE_VERSION#] | ======================================== | by WeCenter Software | © 2011 - 2014 WeCenter. All Rights Reserved | http://www.wecenter.com | ======================================== | Support...
true
eaf52e65f7deb129f970039a9df4cbba2b509874
PHP
paradite/TableDashServer
/checkin.php
UTF-8
1,604
2.578125
3
[]
no_license
<?php include_once "base.php"; //function checkin(user_id,tag_id,duration) if (($_SERVER["REQUEST_METHOD"] == "POST") && (!empty($_POST["user_id"])) && (!empty($_POST["tag_id"]))) { //$user_id = strtolower($user_id); $user_id = mysqli_real_escape_string($con, $_POST['user_id']); $tag_id = mysqli_real_escape_string(...
true
5382faafb5674ac0f41ece8163eb23c85c7e6c3e
PHP
LuchoK90/BubbleTravel
/excursionCreada.php
UTF-8
935
2.5625
3
[]
no_license
<?php session_start(); if ( isset( $_SESSION["Usuario"] ) ) { include("conexion.php"); $nombre=$_POST["nombre"]; $fechaInicio=$_POST["fechaInicio"]; $valor=$_POST["valor"]; $idViaje=$_POST["viaje"]; $idUsuario=$_SESSION['Usuario']['id']; echo $nombre; echo $fechaInicio; echo $valor; echo $idViaje; echo $idUsuario; $...
true
71c819307a033c8363eb2220574cfea805878c3e
PHP
sebadorn/aestas3
/sitemap.php
UTF-8
1,381
2.5625
3
[]
no_license
<?php require_once( 'core/autoload.php' ); require_once( 'core/config.php' ); $filterPages = array( 'WHERE' => 'pa_status = :status AND pa_datetime <= :date', 'LIMIT' => '0, 9999', // +1 root URL 'ORDER BY' => 'pa_datetime DESC' ); $paramsPages = array( ':status' => ae_PageModel::STATUS_PUBLISHED, ':date' => dat...
true
de14317e6fa3bff4c1119cddf692a226a857c458
PHP
vakst/quiz
/src/Words/QuizBundle/Entity/UserTranslationMistakeLog.php
UTF-8
2,471
2.65625
3
[]
no_license
<?php namespace Words\QuizBundle\Entity; /** * UserTranslationMistakeLog */ class UserTranslationMistakeLog { /** * @var \DateTime */ private $createdDate = 'now()'; /** * @var integer */ private $id; /** * @var \Words\QuizBundle\Entity\User */ private $user; ...
true
b4aebf4ef700d3280800a04d673dfced384a006a
PHP
Leacae/MI
/database/migrations/2016_06_22_040441_create_advert_table.php
UTF-8
693
2.640625
3
[ "MIT" ]
permissive
<?php use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateAdvertTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('advert', function (Blueprint $table) { $tab...
true
0df8413f51cb661bb464e3a1735ccbf7b154851f
PHP
ArthurPatriot/onvif-ptz-php
/UnrecognizedPolicyRequestFaultType.php
UTF-8
777
2.703125
3
[]
no_license
<?php class UnrecognizedPolicyRequestFaultType extends BaseFaultType { /** * @var QName[] $UnrecognizedPolicy */ protected $UnrecognizedPolicy = null; /** * @param string $any * @param \DateTime $Timestamp */ public function __construct($any, \DateTime $Timestamp) { ...
true
5ff5e0a2c8435a1a813b95e8242c177f5a9e90cc
PHP
dangchuong/handle_text_api
/app/Repositories/TextRepositoryInterface.php
UTF-8
831
2.828125
3
[ "MIT" ]
permissive
<?php namespace App\Repositories; interface TextRepositoryInterface { /** * Get current text * * @return \App\Text */ public function getFirst(); /** * Change color of cup * * @param $request Request * * @return \App\Text */ public function changeCol...
true
28e21cfd344da55468c2e0b0604932e0c519d95d
PHP
frankenState/workspace
/sys/helper.php
UTF-8
4,786
2.9375
3
[]
no_license
<!-- booting up the helper --> <?php /* * Owner: Frank Lou A. UBay * Version: 1.0.1 * Date: June 15, 2017, September 23, 2017 */ /* * Table of Contents * * F1, Line 27 = execQuery($query) * F2, Line 48 = queryData([SQL query]) * F3, Line 72 = getData([identifier of the data in associative array], [table nam...
true
2a69d6cb9f18b76f4b89ab17fc535dea2ed21bc5
PHP
Dheia/c57-oc
/plugins/grcote7/c57/components/GitlabPageLink.php
UTF-8
801
2.546875
3
[ "MIT" ]
permissive
<?php namespace GrCOTE7\C57\Components; use Cms\Classes\ComponentBase; use Cms\Classes\Controller; class GitLabPageLink extends ComponentBase { public $gitLabPageLink; public function componentDetails() { return [ 'name' => 'GitLabPageLink', 'description' => 'Get the Git...
true
c9f1be386d1ebfa664dee7c2df5f676b5a00b419
PHP
isabella232/market
/app/modules/Users/actions/RegisterAction.class.php
UTF-8
6,006
2.671875
3
[]
no_license
<?php /** * Register action * * PHP version 5 * * @category Xamin * @package Market * @author fzerorubigd <fzerorubigd@gmail.com> * @copyright 2012 fzerorubigd * @license Custom <http://xamin.ir> * @version GIT: $ * @link http://xamin.ir */ /** * Register action * * @category Xamin ...
true
d6ae76b3b6807186ba6b352e21bfcc1bfadef399
PHP
Drboris1/the-clinick
/Modele/ExamenModele/Examen.php
UTF-8
2,146
3.046875
3
[]
no_license
<?php /* * 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. */ class Examen{ private $idexamen; private $idcategorie; private $idconsultation; private $montantexam; priv...
true
6f319e16535e7cd5a6c4bbd97ec7e8f79e3ca630
PHP
damian10001/Przychodnia
/application/models/DbTable/GodzinyPrzyjec/Row.php
UTF-8
1,881
2.640625
3
[]
no_license
<?php class Application_Model_DbTable_GodzinyPrzyjec_Row extends Zend_Db_Table_Row { //nadpisana metoda magiczna, która po wywołaniu obiektu zwraca to, co poniżej public function __toString() { return (string) $this->getLekarz() . ' ' . $this->dzien_tygodnia . ' ' . $this->godzina_od . ' ' . $this->...
true
b691c262b71a7b916b83d619f778ab7b673a465f
PHP
DeveloperBiplob/Blog_website
/app/Mail/SendNewPostMailToSubscriber.php
UTF-8
822
2.53125
3
[ "MIT" ]
permissive
<?php namespace App\Mail; use App\Models\Post; use App\Models\Subscriber; use Illuminate\Bus\Queueable; use Illuminate\Contracts\Queue\ShouldQueue; use Illuminate\Mail\Mailable; use Illuminate\Queue\SerializesModels; class SendNewPostMailToSubscriber extends Mailable { use Queueable, SerializesModels; publ...
true
e4b1db3e45d778305fec9b30de7f2d4b123d6115
PHP
CNAWebDevCP2420/labs-datkanz093
/Lab1/InterestArray.php
UTF-8
913
3.140625
3
[]
no_license
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Interest Array</title> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /> </head> <body> <?php $InterestRate1 = .0725; $Int...
true
7284157f02756fc3e498868ab116e68dd7107b85
PHP
CODAME/codame-website
/src/admin/edit-single.php
UTF-8
10,033
2.65625
3
[ "MIT" ]
permissive
<? include('partials/head.php'); include('partials/form-submit.php'); $action = $_GET['action']; $table = $_GET['table']; $slug = $_GET['slug']; $noun = ucfirst(substr($table, 0, -1)); // noun for what is being edited. artist, etc if( $action == "edit" ){ $content = get_row($table,'slug',$slug); $pic =...
true
00615d8feba7bdb8d9fea97990b74643c1817054
PHP
borazslo/miserend.hu
/webapp/tests/UserTest.php
UTF-8
1,067
2.578125
3
[]
no_license
<?php class UserTest extends \PHPUnit_Framework_TestCase { /** * @dataProvider providerTestUserUser */ public function testUserUser($input, $output) { $user = new User($input); if ($output == array()) { $this->assertEquals($output, (array) $user); } else ...
true
5aba97386074c34e3935abd6e2a86f5726caf169
PHP
phpstan/phpstan-src
/tests/PHPStan/Analyser/data/bug-8008.php
UTF-8
1,039
3.125
3
[ "MIT" ]
permissive
<?php namespace Bug8008; use function \PHPStan\Testing\assertType; /** * @template TValue */ class Collection { /** * @param array<TValue> $items */ public function __construct( public array $items, ) { } /** * @return array<TValue> */ public function all() { return $this->items; } } /** * @t...
true
a498ff436c274e279a937b62161f3d87c881c137
PHP
sergeykotenkogithub/phpShop
/models/repositories/RegistrationRepository.php
UTF-8
1,075
2.75
3
[]
no_license
<?php namespace app\models\repositories; use app\engine\App; use app\models\entities\User; use app\models\Repository; class RegistrationRepository extends Repository { public static function registration($login, $pass, $pass_hash, $check) { if (isset($login) && isset($pass)) { if ($check) {...
true
5004573f3bb50b2989023f1005b2da26c53578d9
PHP
falknerdominik/scr4_forum
/src/BusinessLogic/AuthenticationManager.php
UTF-8
1,154
2.96875
3
[]
no_license
<?php namespace BusinessLogic; use \DataLayer\DataLayerFactory; final class AuthenticationManager { private function __construct() { } const SESSION_USER_ID = 'userId'; public static function authenticate($username, $password) { $user = DataLayerFactory::getUserDataLayer()->getUserForUsernameAn...
true
227eb76330829ca299bd410a1733a2e3c2df5d22
PHP
juggernautt/dead-poets-society
/www/index.php
UTF-8
5,410
2.5625
3
[]
no_license
<?php $title = "Index"; require_once($_SERVER['DOCUMENT_ROOT'].'/../includes/init.php'); require_once('templates/header.php'); require_once('lib/businessLogic.php'); is_logged_in(); $relationship = null; //other user's index page if (isset($_GET['u_id'])) { $user = selectUser($_GET['u_id']); $mineProfile = ...
true
4cbf20a65b43532aa5b2e22fc2f8a52e8be794b1
PHP
SeleneAbraldez/Progamacion-III
/4- Parciales/Primer Parcial/0 - PP REAL/Aliens/clases/Ufologo.php
UTF-8
3,604
3.53125
4
[]
no_license
<?php class Ufologo{ //atributos privados (país, legajo y clave) private $_pais; private $_legajo; private $_clave; //constructor (que inicialice los atributos) public function __construct($pais, $legajo, $clave) { $this->_pais = $pais; $this->_legajo = $legajo; $t...
true
cc1e3247fce322ab074d55932f06917c372dced3
PHP
uwetews/smarty4
/lib/Smarty/Method/RegisterClass.php
UTF-8
960
2.96875
3
[]
no_license
<?php /** * Smarty Extension * Smarty class methods * * @package Smarty\Extension * @author Uwe Tews */ /** * Class for registerClass method * * @package Smarty\Extension */ class Smarty_Method_RegisterClass { /** * Registers static classes to be used in templates * * @api * * @...
true
f92fbf4fe9298d7a2fb8765aa64def029f43f134
PHP
sajalmustafiz/my_cart
/core/function/users.php
UTF-8
6,929
2.671875
3
[]
no_license
<?php require_once 'admin_panel/core/function/admin.php'; /** * This Class is Dedicated For Users In This Class I will Creat methods only for Users */ Class Users Extends General{ //This Function inserdata into users table :-) public function register_array($register_array){ $fields = '`'.implode('`,`', array_k...
true
e4068fe06ddfe98085a10c27165fa366b6797399
PHP
dipcode-software/php-form
/tests/unit/Widgets/NumberInputTest.php
UTF-8
592
2.546875
3
[ "MIT" ]
permissive
<?php namespace PHPForm\Unit\Widgets; use PHPUnit\Framework\TestCase; use PHPForm\Widgets\NumberInput; class NumberInputTest extends TestCase { public function testGetContext() { $widget = new NumberInput(); $context = $widget->getContext("name", 10); $this->assertEquals($context["typ...
true
0ef68957637fdd050eeaea3c83207391b59972a7
PHP
gapczar/web-camp-EVSU-Ormoc
/web/signup.php
UTF-8
1,430
2.546875
3
[]
no_license
<html> <?php include('connect.php'); ?> <head> <title>EVSU-OCC</title> </head> <body> <form method="post" action="signup.php"> First name<input type="text" name="name" autocomplete="off" /><br/> Middle name<input type="text" name="middle" autocomplete="off" /><br/> Last name<input type="text" name="last" autocomp...
true
ae88f8a4f2211be16eefc7e9ca18bdf707024dbf
PHP
skergoat/DW10
/5-boucles.php
UTF-8
350
3.828125
4
[]
no_license
<?php // while $loop = 0; while($loop <= 10) { echo "nous revoilà une fois de plus ! <br>"; $loop++; } // concatenation $loop = 1; while($loop <= 10) { echo "nous revoilà pour la " . $loop. "eme fois ! <br>"; $loop++; } // for for($i = 1; $i <= 10 ; $i++) { echo "nous revoilà pour la " . ...
true
3ccba96170829793b276591c89648bc365bea242
PHP
aurora-php/ncurses
/libs/app.php
UTF-8
7,526
2.765625
3
[]
no_license
<?php /* * This file is part of the 'octris/ncurses' package. * * (c) Harald Lapp <harald@octris.org> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace octris\ncurses { /** * Ncurses application class. * ...
true
d962232dff741285bac456910c10e464f338a439
PHP
elliot-sawyer/silverstripe-nzstreets
/src/Controller/NZStreetAddressController.php
UTF-8
2,669
2.796875
3
[ "BSD-3-Clause" ]
permissive
<?php namespace ElliotSawyer\NZStreets; use SilverStripe\Control\Controller; use SilverStripe\Core\Convert; use ElliotSawyer\NZStreets\NZStreetAddress; class NZStreetAddressController extends Controller { //required by SilverStripe 4 when using a "bare" controller private static $url_segment = 'address'; ...
true
761da823e4f9de43e84e18c58d2f633729ead2b3
PHP
jnparry/cs313-php
/web/clean/insert.php
UTF-8
4,483
2.75
3
[]
no_license
<?php session_start(); if (!isset($_SESSION['user'])) { header("Location: /clean/signin.php"); die(); } if (!isset($_SESSION['userId'])) { header("Location: /clean/signin.php"); die(); } if (!isset($_SESSION['project'])) { header("Location: /clean/signin.php"); die(); } $projectId = $_SESSI...
true
09fd2d2bf977397bc74c74caa57b9b91726b2599
PHP
th0masm/bikes
/bike/controllers/ResultsController.php
UTF-8
3,086
2.6875
3
[]
no_license
<?php class ResultsController extends Zend_Controller_Action { /** * * Instancia del modelo para los resultados * @var Db_Table */ private $_table; /** * * Guarda el titulo del controlador * @var String */ private $_titulo; /** * * Guarda el nombre del controlador...
true
a961624203baba317d0ad6a414c22ce495fc908a
PHP
HASHBRASIL/ws
/application/modules/material/models/Bo/Marca.php
UTF-8
895
2.53125
3
[]
no_license
<?php /** * @author Ellyson de Jesus Silva * @since 10/04/2013 */ class Material_Model_Bo_Marca extends App_Model_Bo_Abstract { /** * @var Material_Model_Dao_Marca */ protected $_dao; public function __construct() { $this->_dao = new Material_Model_Dao_Marca(); ...
true
0b74ad7844bec7f57a83d61c64b8429e26f7401b
PHP
alexshipil/bitrix.simple.module
/lib/remote/connection.php
UTF-8
315
2.640625
3
[]
no_license
<? namespace \simple\module\Remote; class Connection { private $host; private $curl; public function __construct($host) { $host = trim($host); if(empty($host)) throw new \InvalidArgumentException("Error host"); $this->host = $host; } public function send($url) { return 'some content'; } } ?>
true
476f16d5d33c1c57f9972baf07a0237b98d818cb
PHP
WebTehnologijeETF/dosedTV
/php/read.php
UTF-8
1,701
2.796875
3
[]
no_license
<?php function get_news(){ $dir="news"; $files=scandir("$dir"); $txt_files=array(); foreach ($files as &$file){ if(strlen($file)>3){ if(strcmp(substr($file,-4),'.txt')==0){ array_push($txt_files,"news/".$file); } } } $i=0; $j=0; $break=false; $shor...
true
de63f26ee84224d0a9a6f429c4635baedaffae5e
PHP
lhl/bestof
/htdocs/track.php
UTF-8
7,444
2.53125
3
[]
no_license
<?php header('Content-type: audio/mpeg'); /* TODO: We could assign and check $_SESSION['bestof'] if we wanted to */ // Discourage abuse... if($_SERVER['HTTP_REFERER'] && strpos($_SERVER['HTTP_REFERER'], 'https://randomfoo.net/') !== 0) $exit++; if(strpos($_SERVER['HTTP_USER_AGENT'], 'Mozilla/') === FALSE) $exit++; i...
true
ada4ec4660a73c7516207add571c6d2b71d163ff
PHP
baodenho0/do_an_android
/app/Helper/CallApIHelper.php
UTF-8
625
2.515625
3
[]
no_license
<?php namespace App\Helper; class CallApIHelper { public function Call($url,$method){ try { $curl = curl_init($url); curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLOPT_HTTPHEADER, array( 'Content-Type: application/js...
true
5c3aab4c37ec73fac053d6a448edd726c83d5092
PHP
freshcells/state-inspector
/tests/TestObject.php
UTF-8
896
2.96875
3
[ "MIT" ]
permissive
<?php namespace Freshcells\StateInspector\Test; class TestObject { private string $prop; private \DateTime $dateTime; private array $collection; /** * TestObject constructor. * @param string $prop * @param \DateTime $dateTime * @param array $collection */ public function...
true
f8bf52c23005c7554eacc4b2bbf1cd45b1c0f6f3
PHP
lizhiweier/wanyu
/Application/Admin/Model/RoleModel.class.php
UTF-8
1,052
2.546875
3
[]
no_license
<?php namespace Admin\Model; use Think\Model; //角色模型 class RoleModel extends Model{ //设置允许接收的字段 protected $insertFields = 'role_name,role_note,role_auth_ids'; //设置表单数据的验证规则 protected $_validate = array( array('role_name','require','角色名称不能为空',1), ); public function savaRoleData($role_data){ //1,将...
true
983be16cc2fde2061d3b1bd379db52983761aa27
PHP
dwizzel-dev/planificateur-cyclable
/public_html/dev/class/mailer.php
UTF-8
9,216
2.640625
3
[]
no_license
<?php /** @auth: Dwizzel @date: 00-00-0000 @info: file to process all sent form or action on posted data @bugs: desc: bug with double returned line in heades \r\n\r\n line 223 date: 08-09-2017 */ //define("LIBR", "\n"); // use a "\r\n" if you have problems define("LIBR", "\r\n"); // use a "\r\n" if you have probl...
true
86a607a7c64a073e7af7f677e8c6f099050c1b6f
PHP
jofner/Twitch-SDK
/src/jofner/SDK/TwitchTV/Methods/User.php
UTF-8
2,404
2.9375
3
[ "MIT" ]
permissive
<?php namespace jofner\SDK\TwitchTV\Methods; use jofner\SDK\TwitchTV\TwitchSDKException; use jofner\SDK\TwitchTV\TwitchRequest; /** * Users method class for TwitchTV API SDK for PHP * * @author Josef Ohnheiser <jofnercz@gmail.com> * @license https://github.com/jofner/Twitch-SDK/blob/master/LICENSE.md MIT * @hom...
true
57438e30af946e8e3b906153796dbb6fbdae808e
PHP
rubyqorn/socket
/src/Actions/SocketConnector.php
UTF-8
728
2.890625
3
[]
no_license
<?php namespace Qonsillium\Actions; use Qonsillium\Actions\Connections\ConnectionFactory; class SocketConnector extends AbstractSocketAction { /** * Initiate SocketConnector constructor method * @param string $method * @param string $type * @return void */ public function __const...
true
bb460d15d8b61b58ecfe0caca622496bbe147260
PHP
RevenantParagon/StarWebPlanning
/back/function/users_function.php
UTF-8
2,246
2.703125
3
[ "MIT" ]
permissive
<?php require_once('../config.php'); function criaCombobox($connect, $campus) { $q = mysqli_query($connect, "SELECT camID, concat(camCampus,'-',camSigla) 'Campus' FROM tb_campus"); if (mysqli_num_rows($q) > 0) { while ($row = mysqli_fetch_array($q)) { if(isset($campus)){ if...
true
0806ab04f66fcdb79ba6eba95bb14f2b9a033b32
PHP
Alexanderdivv/datangin_backend
/app/Http/Livewire/ProfileLivewire.php
UTF-8
2,743
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Http\Livewire; use App\Models\Meeting; use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Auth; use App\Models\User; use Exception; use Illuminate\Support\Facades\Hash; class ProfileLivewire extends BaseLivewireComponent { public $model = Meeting::class; // public $na...
true
228c4e937bd0a7b6a8c717a63f11e9dfdb0cc633
PHP
kckoay1297/FYP-ver-3
/sem_similarity.php
UTF-8
268
2.796875
3
[]
no_license
<?php function similarity($str,$str1){ file_put_contents('java/file.txt', $str); file_put_contents('java/file2.txt', $str1); $returnCode = shell_exec("java -jar JavaApplication27.jar ".$str." ".$str1." "); //print_r($returnCode); return $returnCode; } ?>
true
c22d7aecb22afd17de469e86468d9a11ad19d918
PHP
rfmcube/rfmcube-magento2-customapi
/Data/OrderItemWrapper.php
UTF-8
22,192
2.625
3
[ "MIT" ]
permissive
<?php namespace Rfmcube\Customapi\Data; class OrderItemWrapper { /** * @var \Magento\Sales\Model\Order */ protected $item; /** * @var \Rfmcube\Customapi\Data\CategoryInfo[] */ protected $categories; /** * @var \Rfmcube\Customapi\Data\Attribute[] */ protected $a...
true
030e41b8835732f19bf31dca7e0f46453e74b512
PHP
Neopibox/NeopiboxBlog
/model/news/news_details.php
UTF-8
631
2.890625
3
[]
no_license
<?php function check_id_news($id_news) { global $db; //Request execution $request = $db->prepare("SELECT * FROM news WHERE id=:id"); $request->bindParam(':id', $id_news, PDO::PARAM_INT); $request->execute(); if($request->fetch()) return true; else return false; } function get_news($id_news) { global $...
true
6a3f3adac79fcf3b23945e266fa4e4a7eae49a8c
PHP
HephepTeam/BoToto
/src/Config.php
UTF-8
784
2.765625
3
[]
no_license
<?php namespace BoToto; class Config { protected $config; protected static $instance; public function __construct() { $this->config = require __DIR__ . '/config/config.php'; } public function get(string $configKey) { $keys = explode('.', $configKey); return $thi...
true
4a2e9d9b6162c31ff2e2ebc46b8c61729bce84d7
PHP
wutiyang/v3
/application/models/countryshippmodel.php
UTF-8
1,520
2.65625
3
[]
no_license
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * @desc country shipping rule model * @author Administrator * */ class Countryshippmodel extends CI_Model { //private $memcache; public function __construct(){ parent::__construct(); //$this->memcache = new CI_Memcache(); } ...
true
45aa5d176170c8a548393cab90ca8c7f186fdf42
PHP
pntraining2020/JeromeBurce
/database/migrations/2020_02_06_012919_create_data_tables.php
UTF-8
844
2.59375
3
[ "MIT" ]
permissive
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateDataTables extends Migration { /** * Run the migrations. * * @return void */ public function up() { schema::create('clockdetails',fun...
true
696bffce31a79612e5fa23c3d6c65acc2a194aa1
PHP
aw-t-daigo/werewolves
/app/Http/Middleware/CheckGameOver.php
UTF-8
1,701
2.65625
3
[]
no_license
<?php namespace App\Http\Middleware; use App\Events\PunishmentReceived; use App\Models\Player; use App\Models\RoleMst; use Closure; class CheckGameOver { use GameOverTrait; private $player; private $roleMst; public function __construct(Player $player, RoleMst $roleMst) { $this->player =...
true
075a340692801042f22b1a291e39a52ce7b9d42c
PHP
PhurpaSherpa16/Online_party_Booking
/website/website/thrash/k.php
UTF-8
3,379
2.546875
3
[]
no_license
<? $codeNo = $_POST['codeNo']; ?> <? if ($_POST['search']) { $db = mysql_connect("192.168.121.11", "me", "me0311") or die ("Unable to connect to MySQL server."); mysql_select_db("QC",$db) or die ("Unable to select requested database."); $sql = "SELECT * FROM EQUIPMENT WHERE E_CODE='$codeNo'"; $result = ...
true
4608c4b93b4f891f7e437f814180811e1008a209
PHP
Ore00/SecureSite
/vendor/mailBoxLayer.php
UTF-8
2,904
2.859375
3
[]
no_license
<?php class mailBoxLayer{ protected $email; protected $key; function mailBoxLayer($email){ require_once("web_settings.php"); $this->setApiKey(mailBoxLayerKey); $this->setEmail($email); } function setApiKey($key){ // set API Access Key $this->key = $key; } function getApiKey(){ ...
true
8a9877a6ee99d503e5f7a1c50161e82b21108f68
PHP
victormanuelantacastro/Proyecto
/Contenido/proyecto/vista/iniciarSesion.php
UTF-8
3,792
2.671875
3
[]
no_license
<?php $alert=''; session_start(); //Si existe sesión enviar a página de inicioUsuario en caso de no ser administrador, y a inicioAdmin en caso de ser administrador if(!empty($_SESSION['activo'])){ if ($_SESSION['isAdmin'] == 0 ) { header('location: inicioUsuario.php'); }else{ header('location...
true
cdf8d7d1408a35340e7043c077047451260d0d80
PHP
polishdeveloper/design_patterns
/src/Patterns/Mediator/Example.php
UTF-8
407
2.609375
3
[]
no_license
<?php namespace Mediator; class Example extends \PatternExample { public function execute() { $input = new InputElement(); $input->addFilter(new EmptyFilter()) ->addFilter(new TrimFilter()) ->addFilter(new HtmlEntitiesFilter()); $input->setValue(' this is a tes...
true
3a5000a010add17b2e5d3bc22bef57daf19e2dc0
PHP
ariefbudiyono/dga
/app/Http/Controllers/Backend/purchaseorderdetail/PurchaseorderdetailsController.php
UTF-8
4,973
2.5625
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers\Backend\purchaseorderdetail; use App\Models\purchaseorderdetail\Purchaseorderdetail; use Illuminate\Http\Request; use App\Http\Controllers\Controller; use App\Http\Responses\RedirectResponse; use App\Http\Responses\ViewResponse; use App\Http\Responses\Backend\purchaseorderdetail\C...
true
643f2fbc0591d0c5134526e0fd04677d336d5918
PHP
jasaj316/PHP_A2
/delete-admin.php
UTF-8
1,085
2.78125
3
[]
no_license
<?php require "header.php"; require "session-auth.php"; //checks if user is allowed to go here echo "<a href='pages.php'>Back to list of pages</a><br>"; //Link back to pages list if user has error $adminId = $_GET["user"]; require "db.php"; $sqlCheck = "SELECT `userId` FROM `cms_users` WHERE `userId` = :adminId"; $cmdC...
true
05a428491dafde9114d14a261d9e3687d86f088b
PHP
Junartuss/ForumDev
/Controllers/CompteController.php
UTF-8
3,522
2.59375
3
[]
no_license
<?php namespace Controllers; use Models\Repository\CategorieRepository; use Models\Entity\User; use Models\Repository\UserRepository; class CompteController{ public function index(){ $categories = New CategorieRepository(); $user = new UserRepository(); $categorieAll = $catego...
true
e257192b30c8869f588fc95bd21849fe9d3f508c
PHP
alamgirweb11/PHP7-PRACTICE
/Operators/null_coalescing_operators.php
UTF-8
303
3.375
3
[]
no_license
<?php // Null coalescing operators // Example of if...else statements if(isset($_POST['action'])){ $action=$_POST['action']; }else{ $action="Default"; } echo $action,"<br>"; // convert the statement in null coalescing operators $action=$_POST['action']??"Default value"; echo $action;
true
bf6bedc636271eb1bb0fb3778c6042a5e3c7929a
PHP
thiagogaldiano/doctors
/app/Http/Controllers/SpecialtiesController.php
UTF-8
3,739
2.625
3
[]
no_license
<?php namespace App\Http\Controllers; use App\Http\Requests\CreateSpecialtiesRequest; use App\Http\Requests\UpdateSpecialtiesRequest; use App\Repositories\SpecialtiesRepository; use App\Http\Controllers\AppBaseController; use Illuminate\Http\Request; use Flash; use Response; class SpecialtiesController extends AppBa...
true
3f9b0b50a6690a144c0d64928ed69de17d1cebaf
PHP
alina80/TDD-Exercises
/1_Exercises/Day_1/1_PHPUnit/exercise4.php
UTF-8
2,316
3.9375
4
[]
no_license
<?php declare(strict_types=1); class Calculator { public $operationHistory = []; public function __construct() { } public function add(int $num1, int $num2): int { $result = $num1 + $num2; $this->addOperationHistory("added $num1 to $num2 got $result"); return $result...
true
4fb950a278350146c4188b29865525dd7056bd1b
PHP
robertjh17/MAD
/opdrachten/programminglanguage/functions/project.php
UTF-8
2,662
2.875
3
[]
no_license
<?php /** * weergave van alle rijen van de database */ function index($message='') { $statement = selectFromDB('SELECT * FROM projecten'); $content = $message.'<table border="1"> <tr> <td>Naam</td> <td>Datum</td> </t...
true
de221a7c001222e5467e610ed111a94be5a5d185
PHP
atmanegara/bansos
/backend/models/RefHibah.php
UTF-8
1,910
2.515625
3
[]
no_license
<?php namespace backend\models; use Yii; /** * This is the model class for table "ref_hibah". * * @property int $id * @property string $nm_hibah * @property int $id_ref_skpd * @property string $aktif * @property string $create_date * * @property DataPemohonHibah[] $dataPemohonHibahs * @property DokSyaratHi...
true
cd6bcc685129aca5cf9e4e58c8145b3289bf1bc1
PHP
johnykvsky/spisywarka
/src/CommandHandler/DeleteLoanCommandHandler.php
UTF-8
1,346
3
3
[ "MIT" ]
permissive
<?php namespace App\CommandHandler; use App\Command\DeleteLoanCommand; use App\Repository\LoanRepository; use Symfony\Component\Messenger\MessageBusInterface; use App\CommandHandler\Exception\LoanNotDeletedException; use Psr\Log\LoggerInterface; class DeleteLoanCommandHandler implements CommandHandlerInterface { ...
true
817b6f970ef1c0f11a39cdfdfc80d3561b77e16b
PHP
JonasDae/FruitOfThing
/api/measurements/createTestData.php
UTF-8
3,771
2.9375
3
[]
no_license
<?php require '../connect.php'; $module_id = intval($_GET['module_id']); $battery_level = mt_rand(1,100); // Start date $date = '2020-01-01 00:00:00'; // End date $end_date = '2020-02-26 00:00:00'; if(isset($module_id) && !empty($module_id)) { // Set timezone date_default_timezone_set('Europe/Brussels'); ...
true
a96cb3d8ba4955f7e0ded420c0a7b65894fc9877
PHP
ramadhanrezza/av
/app/Http/Controllers/UserController.php
UTF-8
3,215
2.640625
3
[]
no_license
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use JWTAuth; use App\User; class UserController extends Controller { protected $user; function __construct() { $this->user = JWTAuth::parseToken()->authenticate(); } public function index() { return $this->user ...
true
00eacd2f939cf6491b738c6e042cd12882a01ff6
PHP
gugglegum/abstract-entity
/tests/entities/MandatoryEntity.php
UTF-8
2,288
2.890625
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace gugglegum\AbstractEntity\tests\entities; use gugglegum\AbstractEntity\EntityInterface; use gugglegum\AbstractEntity\EntityTrait; use gugglegum\AbstractEntity\GettersAndSettersTrait; use gugglegum\AbstractEntity\PlainObjectTrait; class MandatoryEntity implements EntityInterfa...
true
c0a622976a264ec715c64da2d8cc0ab0f7b13dc8
PHP
ruvaler/php-ddd-example
/tests/Mooc/Courses/Application/Create/CreateCourseCommandMother.php
UTF-8
951
2.59375
3
[]
no_license
<?php declare(strict_types=1); namespace CodelyTv\Tests\Mooc\Courses\Application\Create; use CodelyTv\Mooc\Courses\Application\Create\CreateCourseCommand; use CodelyTv\Mooc\Courses\Domain\CourseDuration; use CodelyTv\Mooc\Courses\Domain\CourseName; use CodelyTv\Mooc\Shared\Domain\Courses\CourseId; use CodelyTv\Tests...
true
83dd462de4577d5ce1960181397a84762246bfdd
PHP
jmfeurprier/perf-current-url-retriever
/test/unit/lib/perf/Http/Url/CurrentUrlRetrieverTest.php
UTF-8
1,861
2.671875
3
[ "MIT" ]
permissive
<?php namespace perf\Http\Url; /** * */ class CurrentUrlRetrieverTest extends \PHPUnit_Framework_TestCase { /** * */ protected function setUp() { $this->retriever = new CurrentUrlRetriever(); } /** * */ public function testCreate() { $result = Curren...
true
e872d84086759c6911d67e27dd24201df05c216a
PHP
chiuthecoder/php-mvc-ci-user-dashboard
/application/models/dashboard.php
UTF-8
4,206
2.703125
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); class Dashboard extends CI_Model { public function createNewUser($postData) { //make first user automatticaly addmin, normal thereafter $query = "INSERT INTO users (first_name, last_name, email, password, user_level, created_at, updated_...
true
b36604a42b132ef15daa06f26a03ea43c39bc0cf
PHP
sam-despain/cs313-php
/web/removeItems.php
UTF-8
845
2.859375
3
[]
no_license
<?php include 'header.html'; session_start(); ?> <html> <body> <h1>Your Cart</h1> <form action="viewCart.php" method="post"> <?php $item=$_POST['item']; while (list ($key1,$val1) = @each ($item)) { echo $key1.", ".$val1."<br>"; unset($_SESSION['cart'][$val1]); } function testInput($data) { ...
true
87d34a539f23f803b4b717b3c07257baab60c64c
PHP
hbea2014/microblog
/src/Models/User.php
UTF-8
2,998
3.3125
3
[]
no_license
<?php namespace Microblog\Models; class User extends Model { /** * @var int The ID of the user */ private $id; /** * @var string The username of the user */ private $username; /** * @var string The password of the user */ private $password; /** * @var ...
true
8acba9677010e4e8eff176db169e0f8d8d0690a3
PHP
bairinc0/Study
/php/oop-study/lesson2/homework/Car.php
WINDOWS-1251
1,014
3.546875
4
[]
no_license
<?php // Car - abstract class Car{ private $model;// private $weight;// private $speed; // protected $gasolinePrice=40;// // public function setGasolinePrice($gasolinePrice){ $this->gasolinePrice=$gasolinePrice; } public function setModel($model){ $this->model=$model; } public func...
true
b3dc165dc9204b190531edd787ab787df760bded
PHP
Exost/TDWEB
/view/voiture/viewUpdateVoiture.php
UTF-8
1,647
2.578125
3
[]
no_license
<?php //require_once("{$ROOT}{$DS}view{$DS}header.php"); //$titreFormulaire = "Modification d'une voiture" ; if ( $choixAction == "update" ) { $choixAction = "readonly"; // Pour modifier l'accès à un champs de formulaire $titreFormulaire = "Modification d'une voiture" ; $champAction = "updated" ; $...
true
c542f1f3e2122e8d77cebe232b3028659afbb559
PHP
pimpmypixel/confirmit-authoring
/src/StructType/RandomCategorySelection.php
UTF-8
3,098
2.78125
3
[]
no_license
<?php namespace Confirmit\Authoring\StructType; use \WsdlToPhp\PackageBase\AbstractStructBase; /** * This class stands for RandomCategorySelection StructType * @subpackage Structs */ class RandomCategorySelection extends PredefinedScriptBase { /** * The NumberOfItems * Meta informations extracted fr...
true
7f0ca1193e6e18e6965718bfd69a663b416cf536
PHP
air-media/coding-standard
/tests/fixed/InlineTypeHintAssertion.php
UTF-8
978
2.703125
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace Tests; use function assert; use function is_int; use function is_resource; use function is_string; /** * @psalm-type PsalmType = array<string, string> */ class InlineTypeHintAssertion { public function do(): void { $type = $this->expression(); asser...
true
8cd443e56add5d8bea069d056fa1b16ac1d41ee3
PHP
sobirjonovs/tophp-framework
/bootstrap/Commands/MigrationCommand.php
UTF-8
375
2.546875
3
[]
permissive
<?php namespace Bootstrap\Commands; class MigrationCommand extends CommandAbstract { public function execute() { if ($this->hasOption($this->env)) { $options = current($this->getOptionValues($this->env)); if ($options === "--table") { echo "\e[32mMigration was ...
true
a6056e6851caeba9348f108491775ad8a80e9838
PHP
zhan3333/note
/leetcode/设计/202_快乐数.php
UTF-8
1,316
4.125
4
[ "MIT" ]
permissive
<?php // 编写一个算法来判断一个数是不是“快乐数”。 // //一个“快乐数”定义为:对于一个正整数,每一次将该数替换为它每个位置上的数字的平方和,然后重复这个过程直到这个数变为 1,也可能是无限循环但始终变不到 1。如果可以变为 1,那么这个数就是快乐数。 // //示例:  // //输入: 19 //输出: true //解释: //12 + 92 = 82 //82 + 22 = 68 //62 + 82 = 100 //12 + 02 + 02 = 1 // //来源:力扣(LeetCode) //链接:https://leetcode-cn.com/problems/happy-number //著作权归领扣网...
true
717d4cbf932f9c18a66136d98f1726250834739e
PHP
marco-a/punit
/biz/arg/use-php-ini.php
UTF-8
398
2.625
3
[ "MIT" ]
permissive
<?php namespace punit; return (function() { return function($php_ini) { try { $real_php_ini = safe\realpath($php_ini); } catch (\Error $e) { return "$php_ini: no such file or directory."; } if (!\is_file($real_php_ini)) { return "$php_ini: not a file."; } else if (!\is_readable($real_php_ini)) { ...
true
08820d4a9a47d310f13dcb9625eeafbd1b66dfee
PHP
htmlacademy-yii/234035-task-force-1
/src/Actions/RefuseAction.php
UTF-8
415
2.546875
3
[]
permissive
<?php namespace TaskForce\Actions; class RefuseAction extends AbstractAction { public function getActionName(): string { return 'Отказаться'; } public function getActionInnerName(): string { return 'refuseAction'; } public function checkAccessRights(int $customerID, int $...
true
031c9e0ecd7337e867f588402b0a8aa3654b73e3
PHP
apexpl/apex_v1
/src/app/codegen/crud.php
UTF-8
14,633
2.546875
3
[ "MIT", "LicenseRef-scancode-public-domain" ]
permissive
<?php declare(strict_types = 1); namespace apex\app\codegen; use apex\app; use apex\libc\{db, redis, debug, components}; use apex\app\pkg\pkg_component; use Symfony\Component\Yaml\Yaml; use Symfony\Component\Yaml\Exception\ParseException; use Symfony\Component\String\Inflector\EnglishInflector; use apex\app\exception...
true
ff29df15005b21e03dc64ebc80b5e7499fcf6fac
PHP
csabadobai/svcourse2017
/src/Api/Controllers/UserLoginController.php
UTF-8
2,251
2.5625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: Alex * Date: 3/11/2017 * Time: 4:07 PM */ namespace Course\Api\Controllers; use Course\Api\Exceptions\Precondition; use Course\Api\Exceptions\PreconditionException; use Course\Api\Model\UserModel; use Course\Services\Http\Exceptions\HttpException; use Course...
true