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
d3082aa56471b8185f873e1a18b33b59e1bff67b
PHP
Saramiaa/retour-maternite
/application/controllers/admin/AdminController.class.php
UTF-8
736
2.796875
3
[]
no_license
<?php class AdminController { public function httpGetMethod(Http $http, array $queryFields) { if(array_key_exists('role', $_SESSION) && $_SESSION['role'] === "user") { $http->redirectTo('/user/login'); exit(); } $userModel = new UserModel(); $users = $userModel->getAllU...
true
4170eaf08cfa3157a7555e8f817e7846d6158b4b
PHP
DanielsonSilva/study-php-7
/BasicObjectOrientedProgramming/Engineer.php
UTF-8
723
3.921875
4
[]
no_license
<?php require_once("Person.php"); class Engineer extends Person { public function __construct($example) { parent::__construct($example); } public function __destruct() { echo "An engineer named " . $this->name . " was destroyed!" . PHP_EOL; } public function setDimensions(float $hei, float $wei): void ...
true
c8b01f277e8ed3c540ca8dc0154f6f0728687529
PHP
joserobertopinto/ordenes-trabajo
/common/utils/ModelUtil.php
UTF-8
1,276
2.890625
3
[]
no_license
<?php namespace app\common\utils; use yii\web\HttpException; use yii\base\Model; use yii\helpers\VarDumper; use yii\db\ActiveRecord; use yii\helpers\ArrayHelper; /** * * */ class ModelUtil { /** * si el atributo tiene varios errores, los pone todos juntos en un solo mensaje * @param unknown $model * @...
true
75f2b76a9fe417cb46c79cf5b89aa2438efff404
PHP
omoluabidotcom/Rest_api
/api/Category/Create.php
UTF-8
1,080
2.859375
3
[]
no_license
<?php header('Access-Control-Allow-Origin: *'); header('Content-Type: application/json'); header('Access-Control-Allow-Methods: POST'); header('Access-Control-Allow-Headers: Access-Control-Allow-Headers, Content-Type, Access-Control-Allow-Methods, Authorization, X-Requested-with'); // database connection file and cat...
true
9d4672017ba9f72cd075cd181ce46351a4f1e8e4
PHP
solarphp/core
/tests/Test/Solar/Auth/Logout.php
UTF-8
1,525
2.59375
3
[]
no_license
<?php /** * * Factory class test. * */ class Test_Solar_Auth_Logout extends Solar_Test { /** * * Default configuration values. * * @var array * */ protected $_Test_Solar_Auth_Logout = array( ); /** * * Test -- Constructor. * */ p...
true
ae09a5f188ae42cf2fc4954c8b86cc8372fbd470
PHP
VladimirSolovov/MySQL_lesson
/index.php
UTF-8
531
2.78125
3
[]
no_license
<?php $connection = mysqli_connect('localhost', 'root', '123', 'test'); if ($connection == false) { echo 'не удалось подключиться к базе данных</br>'; echo mysqli_connect_error(); die(); } $result = mysqli_query($connection, 'SELECT * FROM `categories`'); if(mysqli_num_rows($result) == 0) { echo 'Записей не найдено...
true
a38f3842b614ac65cd54cf7f093a4408805207d2
PHP
ahmedabdel3al/table-builder
/src/traits/CanSee.php
UTF-8
569
3.0625
3
[]
no_license
<?php namespace Builder\Traits\TableBuilder; trait CanSee { /** * * Can See Component * @var boolean */ public $canSee = true; /** * Calculate If Attribute Should visible * * @param [bool|Closure] $condition * @return self */ public function showIf($co...
true
2a6c17bf7612195ca421f2abeb6618e5147c1787
PHP
HannaLuniova/practical
/php/a_task7.php
UTF-8
1,570
3.609375
4
[]
no_license
<?php // $a = "123123"; // $b = [1, 2, 3, 1, 2, 3]; // $x = $a[0] + $a[1] + $a[2]; // $y = $b[3] + $b[4] + $b[5]; // if ($x == $y) { // echo "Да"; // } else { // echo "Нет"; // } ?> <br> <?php // $c = []; // for ($i = 1; $i <= 100; $i++) { // $c[] = $i . "<br>"; // } // var_dump($c); ?> <br> <?...
true
488527368203f8c5e7a8014266f459f9e4cf8950
PHP
mundcari26/mundcari26.github.io
/js/conexion.php
UTF-8
1,966
2.921875
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 Connection { /** * Objeto de Conexion. * @access protected * @var Object */ protected $c...
true
44e2a6faebbf366e561707f588948bd7b211466a
PHP
WPPlugins/pronamic-ideal
/vendor/wp-pay-gateways/ogone/src/DirectLink/Integration.php
UTF-8
743
2.515625
3
[]
no_license
<?php class Pronamic_WP_Pay_Gateways_Ogone_DirectLink_Integration extends Pronamic_WP_Pay_Gateways_Ogone_AbstractIntegration { public function __construct() { parent::__construct(); $this->id = 'ogone-directlink'; $this->name = 'Ingenico/Ogone - DirectLink'; } public function get_config_factory_class() { ...
true
1eeecfb9c45d0bb75f2ee49e0c0806b1f64261b0
PHP
M1ke/easy-site-utils
/security.php
UTF-8
828
2.9375
3
[]
no_license
<?php /* simple_encode and simple_decode use openssl_encrypt and openssl_descrypt methods internally. $data - data to be encoded, required param $passwd - a key, use the same key while encoding and decoding, required param $method - aes-128-cbc default $options - 0 default $iv - a non-NULL Init...
true
24cb37a28ad2cd40e8e62961dffe619216aa4b7e
PHP
mikaelgramont/World-Mountainboard-Day
/php/DecoratedMustache.php
UTF-8
1,094
2.703125
3
[]
no_license
<?php class DecoratedMustache extends Mustache { protected $_i18n; public function __construct($translations) { $this->_i18n = new LowLevelDecoratedMustache(null, $translations); parent::__construct(); } public function render($template = null, $view = null, $partials = null) { $view->i18n = $this->_i1...
true
f25dd5d4957288ed5db0b86ff43d1b759ac94860
PHP
AdityaKadam1994/SEO-Crawl-Scripts
/img_crawl.php
UTF-8
735
2.921875
3
[]
no_license
<?php function crawlPage($url) { $dom = new DOMDocument('1.0'); // Loading HTML content in $dom @$dom->loadHTMLFile($url); // Selecting all image i.e. img tag object $node = $dom -> getElementsByTagName('img'); foreach ($node as $element) { ...
true
b341987ae80aa9ab099492ebab0b339643e54ee1
PHP
GhostMaster1573/InfiniteUI
/src/GICore/task/BlockPlaceTask.php
UTF-8
664
2.890625
3
[]
no_license
<?php declare(strict_types=1); namespace GICore\task; use pocketmine\block\Block; use pocketmine\level\Position; use pocketmine\math\Vector3; use pocketmine\scheduler\Task; class BlockPlaceTask extends Task{ /** @var Position */ private $pos; /** @var Block */ private $block; /** * @param Position $pos *...
true
23b64eabeda7da9079930c8ce2a55ce5107c5b49
PHP
ksecurity45/OSWE
/AWAE-PREP-master/Understanding PHP Object Injection/class-serialize.php
UTF-8
326
4.0625
4
[]
no_license
<?php class User { public $age = 0; public $name = ''; public function PrintData() { echo "User ".$this->name." is ".$this->age. " years old."; } } $user = new User(); $user->age = 20; $user->name = "Milton"; $user->PrintData(); // serialize object and print output echo serialize($user)."\n"...
true
07fdf535a0668e5398bd1de33436d4d608435c64
PHP
letscodehu/php-localization
/app/Services/ForgotPasswordService.php
UTF-8
4,232
3
3
[]
no_license
<?php namespace Services; use Exception\SqlException; use mysqli; use Swift_Mailer; use Swift_Message; class ForgotPasswordService { /** * @var mysqli */ private $connection; /** * @var Swift_Mailer */ private $mailer; private $baseUrl; /** * ForgotPasswordService...
true
00499a4c0f5c5e0f81e1a1207e3d751ea7e981ca
PHP
ModernTimes/ModernTimes
/protected/models/relations/CharacterQuests.php
UTF-8
2,559
2.8125
3
[]
no_license
<?php Yii::import('application.models._base.BaseCharacterQuests'); /** * Basic HAS_MANY association model * What is the status of all quests for a given character? * * Is pretty much telecontrolled by Quest * * See BaseCharacterQuests for a list of attributes and related Models * * @see Character * @packa...
true
935db0f55bf744e1639194632b98a92858ea02fe
PHP
arjunnaik/WTA-Lab-Programs
/Lab08/Program8bcd.php
UTF-8
1,756
3.46875
3
[]
no_license
<?php header('Content-Type: text/plain'); $matrix1 = array(array(1, 2), array(2, 1)); $matrix2 = array(array(1, 1), array(3, 2)); echo "\n\n\n"; echo "The order of the matrix A is:" . count($matrix1) . "x" . count($matrix1[0]); echo "\n"; echo "The order of the matrix B is:" . count($matrix2) . "x" . c...
true
6e7b996066edc478e7b2c823d7f0848b7d6bc135
PHP
FriendsOfFlarum/gamification
/src/Api/Serializers/RankSerializer.php
UTF-8
957
2.578125
3
[ "MIT" ]
permissive
<?php /* * This file is part of fof/gamification. * * Copyright (c) FriendsOfFlarum. * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace FoF\Gamification\Api\Serializers; use Flarum\Api\Serializer\AbstractSerializer; use F...
true
17d26da7b2851005fce0b66e530a17af976467ae
PHP
JonnyD/Greetup-API-PHP
/src/GU/GreetBundle/Hydrator/GreetCriteriaHydrator.php
UTF-8
728
2.59375
3
[]
no_license
<?php namespace GU\GreetBundle\Hydrator; use FOS\UserBundle\Model\UserManager; use GU\GreetBundle\Criteria\GreetCriteria; class GreetCriteriaHydrator { /** * @var UserManager */ private $userManager; /** * @param UserManager $userManager */ public function __construct(UserManager...
true
e65f4080bb6c695602b28ab06f77766c4af4d275
PHP
tcheuD/p5
/src/UI/Action/AddAccountAction.php
UTF-8
1,505
2.65625
3
[ "MIT" ]
permissive
<?php namespace App\UI\Action; use App\UI\Action\Interfaces\AddAccountActionInterface; use App\Domain\Repository\AccountRepository; use App\Domain\Factory\UserFactory; use Core\Token; use Core\Twig; use Core\Response; class AddAccountAction implements AddAccountActionInterface { private $accountRepository; p...
true
71ba5d5fe21fcf9a0f594949bbd57f1a87baa31d
PHP
agilepixels/laravel-resource-abilities
/src/ResourceResponse.php
UTF-8
908
2.546875
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php namespace AgilePixels\ResourceAbilities; use Illuminate\Http\JsonResponse; use Illuminate\Http\Request; use Illuminate\Http\Resources\Json\ResourceResponse as Response; class ResourceResponse extends Response { /** * Create an HTTP response that represents the object. We make sure the returned array f...
true
624216b6517102a49c8f35e3070b848edd26404c
PHP
openwears/openwears.org
/web/models/Page.php
UTF-8
15,144
2.859375
3
[]
no_license
<?php require_once dirname(__FILE__) . '/../lib/MarkdownPage.php'; class Page extends MarkdownPage { protected $title = NULL; protected $base_dir = NULL; protected $page_name = NULL; protected $revision = NULL; protected $headers = array(); protected static $version_mrg = NULL; protected ...
true
22f63bc85fce7e5278c683300f3df66a925d6839
PHP
im286er/Simple-MVC-Framework
/application/controller/homeController.php
UTF-8
368
2.59375
3
[ "MIT" ]
permissive
<?php class homeController Extends Controller { protected function init(){} public function index() { /* template variables */ $this->template->title = 'Home - Simple-MVC-Framework'; $this->template->loadTemplate('home'); } public function about(){ $this->template->title = 'About - Simple-MVC-Framework';...
true
e344b5688facb21fdbb1fe414376a71b273181f0
PHP
TimBorowy/stadslab_overdracht
/index.php
UTF-8
6,629
2.640625
3
[]
no_license
<?php require_once('server.php'); require_once('includes/database.php'); require_once('errors.php'); if (isset($_POST['submit'])) { //Postback with the data showed to the user, first retrieve data from 'Super global' $firstname = mysqli_real_escape_string($db, $_POST['firstname']); $studentEmail = m...
true
7a99ad435c003fdcf4cceb696cdc93a0e25a2c0e
PHP
jkavalik/Restful
/src/Drahak/Restful/Mapping/DataUrlMapper.php
UTF-8
1,331
2.75
3
[]
no_license
<?php namespace Drahak\Restful\Mapping; use Drahak\Restful\Resource\Media; use Nette\SmartObject; use Latte\Runtime\Filters; use Nette\Utils\Strings; use Drahak\Restful\InvalidArgumentException; if (!class_exists('Latte\Runtime\Filters')) { class_alias('Nette\Templating\Helpers', 'Latte\Runtime\Filters'); } /** * ...
true
6f85cf591709cafc23820a91cfbe54ae609b4395
PHP
MatiasVargas/IntraWeb
/RellenoBD/Data/Alumno.php
UTF-8
2,166
3.328125
3
[]
no_license
<?php /** * Representa el data de los gastos * almacenados en la base de datos */ require 'DatabaseConnection.php'; class Gastos { // Nombre de la tabla asociada a esta clase const TABLE_NAME = "alumno"; const RUT = "rut"; const NOMBRE = "nombre"; const CONTRASEÑA = "contra...
true
aeda4b3b796b40a1a707258c73ff18cb768d1a5f
PHP
thenlabs/easy-mails
/src/View/MailListItemView.php
UTF-8
465
2.578125
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace ThenLabs\EasyMails\View; use ThenLabs\ComposedViews\AbstractView; use ThenLabs\EasyMails\Mail; class MailListItemView extends AbstractView { protected $mail; public function __construct(Mail $mail) { $this->mail = $mail; } public function getView...
true
05530eecf6ed9a5a9b8472d87ef727b542ede506
PHP
MaslaLT/Commision_task
/src/Currency/IsoCurrency.php
UTF-8
608
3.15625
3
[]
no_license
<?php declare(strict_types=1); namespace Masel\CommissionTask\Currency; class IsoCurrency extends Currency { /** * Iso Number of currency. * * @var int; */ protected $isoNumber; /** * @throws \Exception */ public function setIsoNumber(int $isoNumber) { if (3...
true
2f5071515476161b9959ac4b699e2071875875ba
PHP
iRbAf7/gestor_permisos
/models/Asignaturas/editAsignatura.php
UTF-8
381
2.671875
3
[]
no_license
<?php function editarAsignatura($conexion, $id, $nombre) { try{ $consulta = $conexion->prepare('UPDATE asignaturas SET nombre = :nombre WHERE idAsignaturas = :id'); $parametros = [ 'id' => $id, 'nombre' => $nombre, ]; $consulta->execute($parametros); return false; }catch(PDOExcept...
true
93ca0049c7c13ddeb4fb3ab8ff14337799486ffb
PHP
javierdlahoz/theear-test
/app/app/Http/Resources/CachedBookResource.php
UTF-8
829
2.921875
3
[]
no_license
<?php namespace App\Http\Resources; class CachedBookResource implements ResourceInterface { /** * @param $collection * @return array */ public static function collection($collection) { $array = []; $serializerResource = new CachedBookResource(); foreach ($collection ...
true
56efe9c353714afe9e48faba24757155107e09a1
PHP
IrekYkubov/Personal-account
/action/authorization.php
UTF-8
901
2.828125
3
[]
no_license
<?php $login = trim(filter_var($_POST['login'], FILTER_SANITIZE_STRING)); $password = trim(filter_var($_POST['password'], FILTER_SANITIZE_STRING)); $error = ''; if (strlen($login) <= 2) { $error = 'Введите логин'; } else if (strlen($password) <= 2) { $error = 'Введите пороль'; } if ($error != '...
true
47d4acba6212f78d9032f43e1e99162a08ea9346
PHP
Nartymiak/conways-game
/game.php
UTF-8
5,948
3.640625
4
[]
no_license
<?php /** * Conways game of life * PHP version 5.2.9 * * @author Nick Artymiak **/ include_once('cell.php'); include_once('board.php'); ini_set("auto_detect_line_endings", true); class Game { private $board; private $stepBoard; // holds the new board after one turn. private $filepath; private $fileSiz...
true
bb039aa3aa7427c1800df62ab386a0328edf1935
PHP
sarfraznawaz2005/personal-management-system
/src/Twig/Modules/Schedules/Schedules.php
UTF-8
768
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Twig\Modules\Schedules; use App\Controller\Core\Application; use App\Entity\Modules\Schedules\MyScheduleType; use Twig\Extension\AbstractExtension; use Twig\TwigFunction; class Schedules extends AbstractExtension { /** * @var Application $app */ private $app; public functi...
true
97cc767798fadb5d0abcc489d6298a5165c2b074
PHP
munozv/Piwam-Microlithe
/piwam/plugins/fcLogAnalyzerPlugin/modules/fcLogAnalyzer/actions/.svn/text-base/actions.class.php.svn-base
UTF-8
616
2.703125
3
[ "MIT" ]
permissive
<?php /** * Manage actions of fcLogAnalyzerPlugin * * @author Adrien Mogenet */ class fcLogAnalyzerActions extends sfActions { /** * Display the list of viewable logs * * @param sfWebRequest $request */ public function executeIndex(sfWebRequest $request) { $this->logs = fcL...
true
f1a4d7a6e65175672ea4533edaceabc1f6b30b21
PHP
FernleafSystems/ApiWrappers-WPHashes
/src/Common/BaseRetrieve.php
UTF-8
878
2.75
3
[]
no_license
<?php namespace FernleafSystems\ApiWrappers\WpHashes\Common; use FernleafSystems\ApiWrappers\WpHashes; class BaseRetrieve extends WpHashes\Api { public const ENDPOINT_KEY = ''; public function __construct( $connection = null ) { parent::__construct( $connection ); $this->setType( static::ENDPOINT_KEY ); } ...
true
514c862d733fbdac5ebe5d69ade7164f7cde51d9
PHP
CoryHrycko/PhpOrgChart_01
/orgchart/spec/OrgChart/Employee/TaskCollectionSpec.php
UTF-8
823
2.640625
3
[ "MIT" ]
permissive
<?php namespace spec\OrgChart\Employee; use OrgChart\Employee\TaskCollection; use OrgChart\Employee\Task; use PhpSpec\ObjectBehavior; use Prophecy\Argument; class TaskCollectionSpec extends ObjectBehavior { function it_is_initializable() { $this->shouldHaveType(TaskCollection::class); } func...
true
afc407f3b1e0a1750c4f7bb45321107f82f57d7d
PHP
leonroeterdink/ifcreader
/tests/IFCStepReaderTest.php
UTF-8
2,542
2.84375
3
[ "LicenseRef-scancode-warranty-disclaimer" ]
no_license
<?php /** * Corresponding Class to test YourClass class * * For each class in your library, there should be a corresponding Unit-Test for it * Unit-Tests should be as much as possible independent from other test going on. * * @author yourname */ class IFCStepReaderTest extends PHPUnit_Framework_TestCase{ /** ...
true
87a05cf9699f4f598d0df91607cbcba75919248c
PHP
tindrew/sturdy-waffle
/scratch/Item.php
UTF-8
152
2.734375
3
[]
no_license
<?php class Item { public $name; protected $code = 1234; public function getListingDescription() { return "Item: " . $this->name; } }
true
075b985e23a10d2a5254f68caabe873f5525cc64
PHP
Lischero/Atcoder
/ABC065/q1.php
UTF-8
224
3.734375
4
[]
no_license
<?php fscanf(STDIN, "%d %d %d", $x, $a, $b); $factor = $a-$b; if ($factor >= 0){ print("delicious\n"); } else { if (abs($factor) <= $x){ print("safe\n"); } else { print("dangerous\n"); } } ?>
true
e9ad8b40e2b7aab061c79d6f42bc79d3a68e7dd6
PHP
amber-lab/TascaDaRosaWeb
/app.control/EventFormPage.class.php
UTF-8
7,212
2.578125
3
[]
no_license
<?php class EventFormPage extends AdoPage{ private $form; function __construct(){ parent::__construct(); $this->class = 'container'; //FORM ARTICLE $article = new AdoArticle; $obj = new AdoParagraph('Criar Evento', 'h2'); $article->add($obj); $this->form = new AdoForm('tascaform'); $this->form->s...
true
19afb457a793118f09ee70fe25bf140db990a9f3
PHP
OCjp/CONDO
/classes/DAO.php
UTF-8
1,019
2.578125
3
[]
no_license
<?php require_once 'connect.php'; class UserAccessOJT extends database{ public function userSignup($uname,$email,$pass){ $sql = "INSERT INTO user(`user_name`, user_email, user_password) VALUES ('$uname','$email','$pass')"; $result = $this->conn->query($sql)...
true
8a69afdfe10beb69f92772e2cbb32001c3682487
PHP
Shailendra53/Project-Sum
/summer.php
UTF-8
3,303
2.828125
3
[]
no_license
<?php $servername = "localhost"; $username = "root"; $password = ""; $dbname = "crime"; // Create connection $conn = new mysqli($servername, $username, $password, $dbname); // Check connection if ($conn->connect_error) { die("Connection failed: " . $conn->connect_error); } else{ ...
true
0de57c311bbb95242c1e4fba1ac26c2eaa17c94c
PHP
point-red/point
/app/Exports/Kpi/TemplateExport.php
UTF-8
793
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Exports\Kpi; use App\Model\HumanResource\Kpi\KpiTemplate; use Maatwebsite\Excel\Concerns\FromCollection; use Maatwebsite\Excel\Concerns\WithHeadings; use Maatwebsite\Excel\Concerns\WithTitle; class TemplateExport implements FromCollection, WithTitle, WithHeadings { private $id; public fu...
true
2ef22f63cf33f5ffa9cc91a6711e213374ff78a2
PHP
mmadhuhasa/sms_slim
/app/dbmodels/post_preferences.crud.php
UTF-8
3,942
2.890625
3
[]
no_license
<?php require_once("Constants.php"); class PostPreferenceCRUD { private $db; function __construct($DB_con) { $this->db = $DB_con; } public function create($post_id, $is_private, $is_restricted, $display_author, $display_organization, $allow_likes, $allow_comments) { $response = array(); $...
true
f35868921a13469e201292e4b66bcc17416752ac
PHP
ihediohachidozie/LMSystem
/app/Http/Controllers/ProfileController.php
UTF-8
1,944
2.59375
3
[]
no_license
<?php namespace App\Http\Controllers; use App\Http\Requests\ProfileRequest; use App\Http\Requests\PasswordRequest; use App\Http\Requests\PictureRequest; use Illuminate\Support\Facades\Hash; use Intervention\Image\Facades\Image; use App\User; class ProfileController extends Controller { /** * Show the form f...
true
afaa4c3f85747cd164278c5a2287ab0c2db37db1
PHP
krystal-framework/krystal.framework
/src/Krystal/Image/Tool/AbstractImageManagerFactory.php
UTF-8
1,955
2.625
3
[ "BSD-3-Clause" ]
permissive
<?php /** * This file is part of the Krystal Framework * * Copyright (c) No Global State Lab * * For the full copyright and license information, please view * the license file that was distributed with this source code. */ namespace Krystal\Image\Tool; use Krystal\Image\Tool\ImageManager; use Krystal\Applic...
true
d79c9641701d7b65299e718b4f90251100c2332e
PHP
vinala/kernel
/src/Database/Schemas/Schema.php
UTF-8
8,262
2.984375
3
[ "MIT" ]
permissive
<?php namespace Vinala\Kernel\Database; use Vinala\Kernel\Config\Config; /** * Schema builder class. */ class Schema { //-------------------------------------------------------- // Variables //-------------------------------------------------------- /** * Default schema to use. * * ...
true
679f1876c4592f60e1139d6d18937801efcf88a8
PHP
darkelement1987/d2phpapi
/index.php
UTF-8
2,377
2.703125
3
[]
no_license
<html> <head> <meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"> </head> <body> <?php require_once("functions.php"); require("config.php"); if($apiKey == ''){echo "No Api key in config.php";} else { ?> <b>Find player equipment:</b> <form action="" metho...
true
409adeef5c0afa0f2273fa8e315287d88907b048
PHP
code-creative/nimble
/app/libraries/validation.php
UTF-8
4,430
2.921875
3
[]
no_license
<?php class validation { var $fields = array(); var $errors = array(); public function __construct($nb) { $this->nb = $nb; } public function add($name,$rules) { $this->fields[] = array("name" => $name, "rules" => $rules); } public function validate() { $rules = array(); foreach ($this->fields as ...
true
1ad4d75d255e3b9b48d26c9c44f88c6be2d7646b
PHP
W-CLL/hb
/application/wxapi/controller/Wx.php
UTF-8
11,930
2.671875
3
[ "Apache-2.0" ]
permissive
<?php namespace app\wxapi\controller; use think\Cache; use think\Config; use think\Controller; use think\Db; use think\Session; use think\Validate; /**这个控制器用来做一些,对微信公众号做实际的操作,需要access_token的操作*/ class Wx extends Controller { public function __construct() { parent::__construct(); //加载配置 ...
true
b3344d1a64c453efac67ac038cee872ee14cb414
PHP
gordonKelly1/dbServlet
/WebContent/phpFiles/updateChartData.php
UTF-8
1,066
2.9375
3
[]
no_license
<?php // Set the JSON header class SensorData{ public $room_num = 0; public $temp = 0.00; public $tempLevel = 0; public $heating_currently_on = 0; public $humidity = 0.00; public $lighting_on = 0; public $heating_sw_on = 0; public $als = 0; public $tstamp; } $con=mysqli_connect("localhost","root","miltown1...
true
d8bc6d1f1d44a6175abd66e04d06e53f36d42046
PHP
bastienrc/sweatmore
/config/session.php
UTF-8
321
2.578125
3
[]
no_license
<?php // SESSION START session_start(); // CHERCHER USER ID if (isset($_SESSION['user_id'])){ $requete=$bdd->prepare("SELECT * FROM users WHERE id=:id"); $requete->execute(array( 'id' => $_SESSION['user_id'] )); $user = $requete->fetch(); // print_r($user); // echo $user['pseudo']; } ?...
true
949ffe5b2fd61c18e3c9cc616a567ac133bdc14d
PHP
mohammedzaki/php-40
/error-handler.php
UTF-8
1,139
3.265625
3
[]
no_license
<?php //function handleError($errno, $errstr, $error_file, $error_line) //{ // echo "<b>Error:</b> [$errno] $errstr - $error_file:$error_line"; // echo "<br />"; // echo "Terminating PHP Script"; // die(); //} // //function error_handler($output) //{ // $error = error_get_last(); // $output = ""; // ...
true
657e5809e07ce1045f391f17f9147e9e1add126a
PHP
maxprofs-llcio/Repo
/Capybara/API/Test/views/city/list.php
UTF-8
158
3.03125
3
[]
no_license
<table> <?php foreach($model as $city) { $country=$city->getCountry()->name; print "<tr><td>$city->name</td><td>$country</td><tr>"; } ?> </table>
true
70891290078253deb1e28a771e710d52757e5b73
PHP
TemateuRoslyn/lapaginationphp
/fichier pagination.php
UTF-8
2,112
3.140625
3
[]
no_license
<?php //cette fonction retourne le nombre total de page a afficher function getTotalPages() { include('connecter.php'); if($con) { $nbr = $con->query('SELECT COUNT(*) AS nbre_total FROM invite'); $resultat = $nbr->fetch(); return $resultat['nbre_total']; } return -1; } /*prend en paramètre un nu...
true
45873658a3ad74fb79c720888a3f4ef0a6fbcf49
PHP
reggiestain/asdi
/app/helpers/UploadHelper.php
UTF-8
1,872
2.78125
3
[ "MIT" ]
permissive
<?php use Carbon\Carbon; class UploadHelper { /** * @param $upload * @return array of the added image names */ public static function uploadFile($field,$folder='') { $path = public_path() . '/uploads'; if(!empty($folder)) { if(!file_exists( $path. '/' ....
true
f1a49839dbfcf4ce1d3ea1e59bd3e119651bcf87
PHP
battlecook/DataCooker
/src/DataStore/KeyValue/AbstractKeyValue.php
UTF-8
6,423
2.75
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace battlecook\DataStore\KeyValue; use battlecook\Types\Status; use battlecook\DataCookerException; use battlecook\Types\LeafNode; use battlecook\DataStore\AbstractStore; use battlecook\DataStore\IDataStore; use battlecook\Types\Attribute; abstract class AbstractKeyValue extends ...
true
c6b592cba4ce2fb32f4e8d08b93ab2119ec8cee3
PHP
zhangs919/laravelvip-b2b2c
/database/migrations/2018_04_05_141238_create_images_table.php
UTF-8
1,556
2.5625
3
[ "Apache-2.0" ]
permissive
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateImagesTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('image', function...
true
9fd06cdf56e3f109476ce0de4e8ac079d3b8845a
PHP
bootpress-io/wp-plugin-boilerplate
/bin/bootpress.php
UTF-8
1,532
2.546875
3
[ "MIT" ]
permissive
#!/usr/bin/env php <?php define('BP_CLI_ROOT', realpath(__DIR__ . '/../')); $composer = json_decode(file_get_contents(BP_CLI_ROOT . '/composer.json')); $bp = new Bootpress_CLI(); switch(strtolower($argv[1])) { case 'setup': echo 'Setup' . PHP_EOL; break; case 'phplint': echo 'Linting the files' . PHP_EOL; fo...
true
086ecf7e1f8009129caffb60782a9f4c76b24645
PHP
williams-jhalt/connectship-connector-php
/src/ProcessResultList.php
UTF-8
536
2.796875
3
[]
no_license
<?php namespace Williams\ConnectShip; class ProcessResultList { /** * @var ProcessResult[] $item */ protected $item = null; public function __construct() { } /** * @return ProcessResult[] */ public function getItem() { return $this->item; } ...
true
ddcf08fc9bfc5cede103ab3a6fd7046d4f11b00b
PHP
Megaandriani/tugas1-musicplayer
/app/user.php
UTF-8
1,981
2.734375
3
[]
no_license
<?php namespace app; class user extends controller { public function __construct() { parent::__construct(); } public function tambah() { $nama = $_POST['nama_user']; $password = password_hash($_POST['pass'], PASSWORD_DEFAULT); $em = $_POST['email']; $adr = $_POST['alamat']; $sql = "INSERT INTO tb_...
true
31c6c236ced94c2037e8f8273a14acae1128e7f2
PHP
SoleneRamis/Music
/application/controllers/Artist.php
UTF-8
2,155
2.78125
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); class Artist extends CI_Controller { /** * Index Page for this controller. * * Maps to the following URL * http://example.com/index.php/welcome * - or - * http://example.com/index.php/welcome/index * - or - * Since this con...
true
72411860b7829fcacfbdf6ff4b66b5c15e600b16
PHP
xander-mbaka/momentum
/domain/Protocol.php
UTF-8
1,489
3.1875
3
[]
no_license
<?php require_once 'FifthDimension.php'; /*A protocol refers to a type of event*/ class ProtocolReference { public $referredProtocol; function __construct(Protocol $referredProtocol) { $this->referredProtocol = $referredProtocol->protocolId; } } class ProtocolDependency { public $masterPro...
true
506b8c2967c02b8f921bd907b3055317afea203d
PHP
zonascript/stoktabunghendri
/customer_transaksiA.php
UTF-8
567
2.53125
3
[]
no_license
<?php include 'db/pdo.php'; $nama_cust = $_GET['nama_cust']; $customers = getDataCustomer($nama_cust); //var_dump($barangs); foreach ($customers as $row): ?> <div> <span>Nama Customer : </span><span><input type="text" name="nama_cust" value="<?php echo $row['nama_cust']; ?>"/></span> </div> <div> <span>Alamat : </s...
true
80e9f2c5a9399bf594018917fa09beb95b1c89af
PHP
infvarun/php-training
/handson_3.php
UTF-8
959
3.328125
3
[ "MIT" ]
permissive
<?php /* * Author : Varun * Date : 07-Nov-2014 * Title : PHP Hands-on - 3 * Desc : DiveIn (Constant, Control Structures, Array) */ /* * Write a PHP code to create a quiz. Implement Double-Dip logic * Double-Dip Means : User can choose two answers. He will win if any of the 2 answer is correct. * Store Answer in ...
true
84275e18be707caa49c90690ff7f1c1ebe262c04
PHP
swoole/swoole-src
/examples/php/func.php
UTF-8
139
2.765625
3
[ "Apache-2.0" ]
permissive
<?php declare(ticks=10); function test() { echo "start\n"; $i = 0; while ($i < 10000) { $i++; } echo "end\n"; }
true
74a9773a05345ff9ea73b33f0ffcda8e389c3ea0
PHP
Raju875/hrm_system
/database/migrations/2018_03_19_163209_create_employee_personal_infos_table.php
UTF-8
1,070
2.546875
3
[ "MIT" ]
permissive
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateEmployeePersonalInfosTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('e...
true
49292bede76ec475f5addc07f209510faab99a97
PHP
Pablogbellido/tienda
/src/indexBundle/Controller/LoginController.php
UTF-8
1,720
2.625
3
[ "BSD-3-Clause", "MIT" ]
permissive
<?php namespace indexBundle\Controller; use Symfony\Bundle\FrameworkBundle\Controller\Controller; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Session\Session; class LoginController extends Controller { public function loginAction(Request $request) { if($request-...
true
ae5e41a3766931c72e41aa166cfe38206c6e7095
PHP
phossa2/shared
/src/Shared/Debug/DebuggableTrait.php
UTF-8
1,824
2.65625
3
[ "MIT" ]
permissive
<?php /** * Phossa Project * * PHP version 5.4 * * @category Library * @package Phossa2\Shared * @copyright Copyright (c) 2016 phossa.com * @license http://mit-license.org/ MIT License * @link http://www.phossa.com/ */ /*# declare(strict_types=1); */ namespace Phossa2\Shared\Debug; use Psr\Log\Log...
true
87da941fcaf07d604a9e89b8e19685ee252f8133
PHP
asfand-yar/cloud-drain
/uploader.php
UTF-8
820
2.5625
3
[]
no_license
<?php $username =$_POST["username"]; $password =$_POST["password"]; $target_path = "$username"."/"; $target_path = $target_path . basename( $_FILES['uploadedfile']['name']); if(move_uploaded_file($_FILES['uploadedfile']['tmp_name'], $target_path)) { echo "The file ". basename( $_FILES['uploadedfile']['name'])...
true
282dff7cc33f54ee26eb3e2b7852591d455fc0c2
PHP
Sicaine/dashi
/src/Dashi/DashboardBundle/Entity/Dashboard.php
UTF-8
1,322
2.6875
3
[]
no_license
<?php namespace Dashi\DashboardBundle\Entity; use Doctrine\Common\Collections\ArrayCollection; use Doctrine\ORM\Mapping\Entity; use Doctrine\ORM\Mapping\Table; use Doctrine\ORM\Mapping\Id; use Doctrine\ORM\Mapping\GeneratedValue; use Doctrine\ORM\Mapping\Column; use Doctrine\ORM\Mapping\OneToMany; /** * @Entity * ...
true
a632f0c4d6095d52a63329c49f396ffbaec35faf
PHP
rozinCodes/school-management
/API/application/controllers/api/Student.php
UTF-8
5,133
3.03125
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php require APPPATH.'libraries/REST_Controller.php'; class Student extends REST_Controller{ public function __construct(){ parent::__construct(); //load database $this->load->database(); $this->load->model(array("api/student_model")); $this->load->library(array("form_validation")); $this...
true
c198554c0c3ab18155f2a9e558004fb55da80f78
PHP
FannyBaulu/BlogSymfony
/src/Domain/Controller/RegistrationController.php
UTF-8
1,330
2.515625
3
[]
no_license
<?php namespace App\Domain\Controller; use App\Application\Entity\User; use App\Domain\Form\UserType; use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\Routing\Annotation\Route; use Symfo...
true
51d8963ad721675ca450098fb9957fb419161c27
PHP
steveshogren/Loan-Tracker
/updateLoan.php
UTF-8
4,525
2.609375
3
[]
no_license
<?php error_reporting( E_ERROR ); Zend_Session::start(); set_include_path( get_include_path() . PATH_SEPARATOR . '/usr/share/php/libzend-framework-php/' ); $GLOBALS['testing'] = true; if (isset($_REQUEST["loanId"])) { $Factory = new Factory(); $MainPage = new MainPage($Factory); $post['loanId'] ...
true
c4f08b889ea659e815f6eb4cc05881c393df90bb
PHP
Trigex/Freeshare
/include/classes/Channel.php
UTF-8
1,089
3.046875
3
[]
no_license
<?php class Channel { static function get() { $sql = "SELECT * FROM `channels` ORDER BY `channel_sort_order` ASC"; $channels = DB::fetch($sql); if (! $channels) { return false; } $channels_all = array(); foreach ($channels as $chan...
true
5b8f1d0e97146a288a7fb9b47ba8bd20965f3847
PHP
zhougen/tp666
/application/index/controller/Common.php
UTF-8
1,914
2.546875
3
[ "Apache-2.0" ]
permissive
<?php namespace app\index\controller; use think\Controller; use think\Request; class Common extends Controller { public function __construct(Request $request = null) { parent::__construct($request); //读取网站配置 $webset = $this->websetload(); $this->assign('webset',$webset); ...
true
f6d43cd89464ffad7746b9a222b44ac38fa5264a
PHP
Jahuauto/filemanager
/index.php
UTF-8
328
2.59375
3
[]
no_license
<?php require 'lib/Filemanager.php'; use lib\Filemanager; $fileManager = new Filemanager(); echo "<pre>"; echo $fileManager->isFileExist('filename.txt'); $dirName = __Dir__; $fileName = __Dir__ . '/tmp.txt'; $fileManager->createDir([$dirName . '/test1', $dirName . '/test2']); $fileManager->deleteDirectory($di...
true
b6604a0804bcfe7b4b62193a55aaa5d31d957ae7
PHP
slava2018/slavaandleonid
/app/classes/Cmenu.php
UTF-8
268
2.59375
3
[]
no_license
<?php namespace app\classes; class Cmenu extends Mmenu { public function getMenu() { $result = $this->prepareMenu(); while ($row = mysqli_fetch_assoc($result)) { $menu[] = $row; } return $menu; } }
true
21de63af6750e11eb34fd1f630b52e4398c18c32
PHP
Linwentao-tech/Hospital-Page
/updateHospital.php
UTF-8
608
2.703125
3
[]
no_license
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Update page</title> </head> <body> <?php include 'connectdb.php'; ?> <h1>hospital name updated!</h1> <ol> <?php $newName = $_POST["newHospital"]; $hospitalCode = $_POST["hospitalName"]; $query= 'Update hospital SET hospitalName ="' . $newName. '" w...
true
c10fb3dbb2ff4b7ebe9acb4225bd4172aba360a6
PHP
crouchj3/Trading3
/modules/game/leaderboard/leaderboardModel.php
UTF-8
1,230
2.859375
3
[]
no_license
<?php class leaderboardModel extends gameModel { var $tradedb; var $userdb; function __construct() { $this->tradedb = dataClass::load("tradedb"); $this->userdb = dataClass::load("userdb"); } function getRankings($gameId, $start, $amt) { $sql = "SELECT `player_id`,`portfolio_value` FROM `game_user` WHE...
true
5379d9e04d0e4c3915d48c7256c789c13109c3dd
PHP
adrianreyes5/CableUnet
/PHP/Admin/confg_admin/programacion_db.php
UTF-8
1,871
2.703125
3
[]
no_license
<?php $id_canal=$_POST['canal_nombre']; $array_p=$_POST['progra_id']; $GLOBALS['existe_progamacion'] = false; foreach ($array_p as $key) { $progra[] = $key; } $programa = implode(",",$progra); try { $base=new PDO("mysql:host=localhost; dbname=cableunet", 'root', ''); $base->setAttribute(...
true
2ae23206747ab5f7b8dc2e25b785a9901091cb6d
PHP
roberiofagundes2021/crud_select_html_postgresql
/CadastrarVendas.php
UTF-8
2,936
2.609375
3
[]
no_license
<?php error_reporting(E_ALL); ini_set("display_errors", 1); require_once 'Venda.php'; ?> <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title class="titulo">cadastrar vendas</title> <link rel="stylesheet" type="text/css" href="css/style.css"> </head> <body> <h2>c...
true
1509d4bec25585f64059f7fbfc5cb57f5dd91192
PHP
EneasVVA/hotelbyhours
/src/AppBundle/Controller/BedRoomController.php
UTF-8
4,323
2.625
3
[]
no_license
<?php namespace AppBundle\Controller; use AppBundle\Entity\BedRoom; use DateTime; use Symfony\Bundle\FrameworkBundle\Controller\Controller; use Symfony\Component\HttpFoundation\Request; /** * Bedroom controller. * */ class BedRoomController extends Controller { public function indexAction() { $em ...
true
98438f1043160c4e2a60cc63a551fd9c386f6a53
PHP
artemeon/image
/src/Plugins/ImageScale.php
UTF-8
2,869
2.734375
3
[ "MIT" ]
permissive
<?php /* * This file is part of the Artemeon Core - Web Application Framework. * * (c) Artemeon <www.artemeon.de> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Artemeon\Image\Plugins; /** * Implements an image scalin...
true
bec8b6d0e9a9f78213491e3f64b1e1da2391152a
PHP
sulemankhan1/ci_learning
/application/controllers/Admin.php
UTF-8
3,063
2.671875
3
[]
no_license
<?php class Admin extends CI_Controller { public function __construct() { parent::__construct(); $this->load->model('Admin_model', 'am'); } public function index() { $this->load->view('dashboard'); } public function add_patient() { $this->load->view('patients/add_patient'); } public f...
true
e39e2663736b9165576485097e106657237d0d66
PHP
solemme1987/home
/frontend/models/user.model.php
UTF-8
1,160
2.78125
3
[]
no_license
<?php require_once 'conexion.php'; class UserModel{ <<<<<<< HEAD public static function insertUserModel($tabla,$datos){ ======= public static function inserUserModel($datos,$tabla){ >>>>>>> jdmartin $stmt = Conexion::conectar()->prepare("INSERT INTO $tabla (name,lastname,email,password,termsOfUse,...
true
85d55e43ed291886886d3782a39d0cfa8bf8d2d6
PHP
wells5609/wp-app
/src/Model/StorageInterface.php
UTF-8
1,862
3.171875
3
[]
no_license
<?php namespace WordPress\Model; interface StorageInterface { /** * Returns the storage name/identifier. * * @return string * Identifier for the storage container. */ public function getName(); /** * Locates and returns multiple records. * * @param array $where * * @return array * ...
true
92e5b1f2fa8c020df503e9e4ee32f0cfcedb0daa
PHP
jonathansc92/softblue
/webnar2017/Aula01/exe2.php
UTF-8
299
3.296875
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. */ $x = 4; $soma = 1; for ($i = $x; $i > 1; $i--) { $soma *= $i; } print "<pre>"; print_r($soma);
true
6034e1aab8bb4e24c1d8d4fbcec11f6d66ed7f91
PHP
canteko/carrera_php
/1.php_para_principiantes/estructuras_de_control/while.php
UTF-8
544
3.46875
3
[]
no_license
<!doctype html> <html> <head> <meta charset="utf-8"> <title>Plantilla PHP</title> </head> <body> <?php $num = 10; $respuesta = "Oporto"; $intentos = 1; while($num >= 0) { echo($num); echo("<br>"); $num--; } while($respuesta != "L...
true
05a93d4de37cf6848c761442f84f223c754ac48c
PHP
Teplitsa/vse.to
/modules/shop/acl/classes/controller/backend/privileges.php
UTF-8
2,975
2.59375
3
[]
no_license
<?php defined('SYSPATH') or die('No direct script access.'); class Controller_Backend_Privileges extends Controller_BackendCRUD { /** * Configure actions * @var array */ public function setup_actions() { $this->_model = 'Model_Privilege'; $this->_form = 'Form_Backend_Privile...
true
9aa5598741b75c9a000d595f2ad080936702d884
PHP
susom/redcap-project-monitoring
/util/ProjectMonitoringUtil.php
UTF-8
4,232
2.75
3
[]
no_license
<?php namespace Stanford\ProjectMonitoring; /** @var \Stanford\ProjectMonitoring\ProjectMonitoring $module **/ use REDCap; /** * This function can be called from a cron job or in project context. If this function * is called outside of the module context, give it access to the system settings. * * @param $sys -...
true
72741350ca1ee757e0426f2fab8fbf22cd0683ed
PHP
2codeawebsite/2bucket3
/Logic/facebook-login/login.php
UTF-8
1,599
2.625
3
[]
no_license
<?php session_start(); // https://developers.facebook.com/docs/reference/login/#permissions require 'src/facebook.php'; // Create our Application instance (replace this with your appId and secret). $facebook = new Facebook( array('appId' => '327709837366013', 'secret' => 'a96463e45658ba46a0ba3c6e86030f0f', )); // ...
true
634b6969050395508158e825cee6b8dc342e25bb
PHP
Drumsid/hexlet-trials
/assocArray/buildQueryString.php
UTF-8
2,022
3.3125
3
[]
no_license
<?php // Query String (строка запроса) — часть адреса страницы в интернете содержащая константы и их значения. Она начинается после вопросительного знака и идет до конца адреса. Пример: // # query string: page=5 // https://ru.hexlet.io/blog?page=5 // Если параметров несколько, то они отделяются амперсандом &: // # q...
true
3285f6e5283ae5b640f84500547a8c9b92ba74e0
PHP
stoatally/dom
/src/NodeTypes/ImportableNode.php
UTF-8
203
2.640625
3
[]
no_license
<?php namespace Stoatally\Dom\NodeTypes; interface ImportableNode { /** * Collapse an iterator into a single node that can be imported. */ public function getImportableNode(): Node; }
true
564f321d2a728657a421058d7a624bda1c9318f3
PHP
soyeonapple/telegraph-api-php-client
/src/Page.php
UTF-8
3,334
2.9375
3
[ "MIT" ]
permissive
<?php /** * This file is part of the Telegraph package. * * (c) Arthur Edamov <edamov@gmail.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. * */ declare(strict_types = 1); namespace Telegraph; /** * Class Page * * This ob...
true
b7ec1bafce86147c61694d94cbe4f3ff2f7446e8
PHP
nagyist/Lychee
/app/Models/SymLink.php
UTF-8
7,949
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Models; use App\Facades\Helpers; use App\Models\Extensions\UTCBasedTimes; use Eloquent; use Exception; use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Carbon; use Illuminate\Support\Facades\Storage; /** * App\SymLink. * * @method static ...
true
51afee5302ad03c8dccc685057c3a333c2cc8b27
PHP
davidnorminton/short-url
/app/Http/Controllers/ShortController.php
UTF-8
577
2.765625
3
[]
no_license
<?php declare(strict_types = 1); namespace App\Http\Controllers; use Psr\Http\Message\ResponseInterface as Response; use Psr\Http\Message\ServerRequestInterface as Request; /** * ShortController * */ class ShortController { /** * urlError * Format for api error messages * * @param stri...
true
d57d529cd8da833dfac73493edca3d269b4ee86e
PHP
BrendanJackson/media-library
/inc/functions.php
UTF-8
8,027
3.0625
3
[]
no_license
<?php function get_catalog_count($category = null, $search = null){ $category = strtolower($category); include("connection.php"); try { $sql = "SELECT COUNT(media_id) FROM Media"; if (!empty($search)){ $result = $db->prepare( $sql . " WHERE title LIKE ?" ); $result->bindValue(1,"%".$search."%"...
true
faa1aab0f6a3e152ed01190422b782530a3a2876
PHP
Frank2022/CartesianSpace
/tests/unit/VectorTest.php
UTF-8
2,454
2.96875
3
[]
no_license
<?php /** * Created by PhpStorm. * User: frank * Date: 09.01.19 * Time: 22:27 */ namespace Frank2022\CartesianSpace\tests\unit; use Frank2022\CartesianSpace\Vector; use Frank2022\CartesianSpace\exceptions\DimensionException; use PHPUnit\Framework\TestCase; class VectorTest extends TestCase { private $coordi...
true