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
4595018a4715803cb48c920e67582fd910cdbb00
PHP
phpem/phpemweb
/app/classes/upload/index.php
UTF-8
1,570
2.5625
3
[ "MIT" ]
permissive
<?php /* * jQuery File Upload Plugin PHP Example 5.7 * https://github.com/blueimp/jQuery-File-Upload * * Copyright 2010, Sebastian Tschan * https://blueimp.net * * Licensed under the MIT license: * http://www.opensource.org/licenses/MIT */ error_reporting(E_ALL | E_STRICT); if (strpos(__DIR__, DIRECTORY_SEPA...
true
74e7f041ad0aee3df268087cc1d7d151f642a657
PHP
cerberushealthcare/analytics
/sec/php/data/rec/group-folder/GroupFolder - Copy.php
UTF-8
15,918
2.515625
3
[]
no_license
<?php require_once 'php/data/file/_File.php'; require_once 'php/data/rec/_Rec.php'; require_once 'php/data/rec/cryptastic.php'; // /** * GroupFolder * @author Warren Hornsby */ class GroupFolder { /* can implement AutoEncrypt */ // public $ugid; public $dir; // static $EXT_TO_MIME = array( 'ai' => ...
true
810306494bd89c32cd882681d55f7f45dffa40fb
PHP
itsanti/netology-php-2
/hw/sql/Src/HW1/Application.php
UTF-8
3,985
3.171875
3
[]
no_license
<?php namespace App\HW1; class Application { private static $instance; private $pdo; public static function getInstance() { if (null === static::$instance) { static::$instance = new static(); static::$instance->pdo = \App\Db\Connection::getConnection(include __DIR__.'/...
true
6c4acccbc639bdd24369443e4b2419e2db2e8a9f
PHP
Maevnik/whart.maevnik.ru
/www/prev/core/controller/SheduleController.php
UTF-8
407
2.609375
3
[]
no_license
<?php class SheduleController { private $db; function __construct() { $db = new DataBaseModel(); } function Create() { echo "This is new shedule method"; } function Delete() { echo "This is delete method"; } function Edit() { echo "This is edi...
true
11136e4fec6f69080502d7f7f1ab83079b6a3a85
PHP
devilhookey/dnd
/mod/Monster/Monster.class.php
UTF-8
2,268
2.671875
3
[]
no_license
<?php class Monster { public function __construct() { } static function setMonster($fields, $floor = 1) { $setFields = array(); $num = rand(DNDConf::DND_MONSTER_MIN,DNDConf::DND_MONSTER_MAX); $hasKey = rand(1,$num); if ($num==0) { return array('setFields'=>$setFields,'wallFields'=>$fields)...
true
faf6af8a162436f092fdb05722cac4f4148833f9
PHP
mauro-moreno/scientist
/src/Intern.php
UTF-8
3,116
3.0625
3
[ "MIT" ]
permissive
<?php namespace Scientist; use Exception; use Scientist\Matchers\Matcher; /** * Class Intern * * Interns do all the hard work, naturally. They'll execute an experiment within * the Laboratory, and record the results. * * @package \Scientist */ class Intern { /** * Run an experiment, and retrieve the ...
true
2984d1a63c87d74f03c63a510f4c635b8d1fb318
PHP
Lzmog/task
/src/Classes/Parsedata.php
UTF-8
1,756
3.0625
3
[]
no_license
<?php declare(strict_types=1); require_once "Argument.php"; /** * Class Parsedata */ class Parsedata extends Argument { /** * @var */ private $argv; /** * Parsedata constructor. */ public function __construct() { $this->argv = parent::takeArguments(); } /**...
true
f97ec459d517461bffc1740082749bdf36932eed
PHP
cmdconfig/jh9RobokassaBundle
/Manager/RobokassaManager.php
UTF-8
4,320
2.515625
3
[]
no_license
<?php /** * @author j Alex * Date: 31.10.13 * Time: 15:48 */ namespace jh9\RobokassaBundle\Manager; use jh9\RobokassaBundle\Form\Type\RobokassaPayType; use jh9\RobokassaBundle\Model\PayModel; use jh9\RobokassaBundle\Model\PayResult; use jh9\RobokassaBundle\Model\RobokassaConst; use jh9\RobokassaBundle\Model\Robo...
true
e9854ca28a02ed06fff7aa3b36ef58769167c644
PHP
Believeint/projeto_eventos
/classes/BD.php
UTF-8
521
2.984375
3
[]
no_license
<?php class BD { // configuracao banco private static $host = "localhost"; private static $bd = "NOMEBANCO"; private static $nusuario = "NOMEUSUARIO"; private static $susuario = "SENHAUSUARIO"; public static function getConnection() { $dsn = 'mysql:host=' . BD::$host . ';dbname=' . ...
true
3ba6bca7291b4a3c8d1d6cbe8346b21fd3a443c2
PHP
dzaporozhchenko/test_10_2020
/tests/Unit/Model/TradeInDealTest.php
UTF-8
1,438
2.5625
3
[]
no_license
<?php namespace App\Tests\Unit\Model; use App\Showroom\Model\CarModel\CarModel; use App\Showroom\Model\TradeInDeal\TradeInDeal; use App\Tests\Fixture\CarModelFixture; use PHPUnit\Framework\TestCase; class TradeInDealTest extends TestCase { protected CarModelFixture $carModelFixture; public function setUp()...
true
599e063e11a2c38a446a5d01159bcdc707fd90e9
PHP
alepeino/fluent-interface
/Order.php
UTF-8
689
3.203125
3
[]
no_license
<?php class Order { private $lines = []; private $rush = false; private $builder; public function __construct() { $this->builder = new OrderBuilder($this); } public function clearBuilder() { $this->builder = null; } public function addLine(OrderLine $line) ...
true
e5d8547c14f513880426f9b7f8c1cf80c9a24dc7
PHP
VenkatKaranam/Cricfanatic
/toss.php
UTF-8
2,373
2.5625
3
[]
no_license
<?php session_start(); include 'database.php'; $match=$_SESSION['matchid']; $d=mysqli_query($database,"select * from matches where matchid='$match'"); $e=mysqli_fetch_assoc($d); if($e['schedule']=="scheduled") { header('location:displayid.php'); } ?> <!DOCTYPE html> <html> <head> <title>Create Match</title> ...
true
5b089fd20b1f1759c6767119dac89c43695a118f
PHP
Andrewnetwork/StudentMeetings
/edit_member.php
UTF-8
3,504
2.8125
3
[]
no_license
<?php session_start(); if( !isset( $_SESSION["auth"] ) || $_SESSION["auth"] != true ) { header("Location: login.php"); } $mysqli = new mysqli("localhost", "main", "", "test"); if ($mysqli->connect_errno) { echo "Failed to connect to MySQL: (" . $mysqli->connect_errno . ") " . $mysqli->connect_error; } if( isset( ...
true
040237a113d0667e28cb38319f3106465ea546e5
PHP
wpsmith/ACF
/src/Fields/HiddenField.php
UTF-8
3,719
2.828125
3
[]
no_license
<?php /** * ACF HiddenField Class * * Extends acf_field_text. * * You may copy, distribute and modify the software as long as you track changes/dates in source files. * Any modifications to or software including (via compiler) GPL-licensed code must also be made * available under the GPL along with build & insta...
true
298ae9ef9242c0d54ed282e5990d34f43939c1c0
PHP
singh-preeti/PHP-Code
/formValidity/formvalidation.php
UTF-8
616
2.890625
3
[]
no_license
<html> <head> my php page </head> <body> <?php pre_r($_POST); if(isset($_POST['submit'])) { echo "Fisrt name:" .$_POST['firstname']; echo "Last name:" .$_POST['firstname']; } ?> <form action="" method="POST"> <p>First name: <input type="te...
true
149eedc37ec7594a9a7302fe53cbfbd02dd2de49
PHP
aldobarr/hbe_tools
/database/migrations/2017_03_12_193131_create_planning_table.php
UTF-8
804
2.546875
3
[]
no_license
<?php use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreatePlanningTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('war_planning_threads', function (Blueprint $table) { $table->increments('id')...
true
9c66c6805dcd6d7cf1874a9b446dcb73af327c24
PHP
rajaybhardwaj/assignments
/task2/classes/class.main.php
UTF-8
6,054
2.75
3
[]
no_license
<?php require $_SERVER['DOCUMENT_ROOT'] . "/src/aws/aws-autoloader.php"; class main { private $arrCsv = array(); private $arrMysql = array(); private $arrScp = array(); private $arrAws = array(); public function __construct(){ $this->arrCsv = array(); $this->arrMysql = arra...
true
ce24dc42b75f828a68f51de1195389f2ec8a4a1e
PHP
herve95/GitHub
/suppression_evenement.php
UTF-8
629
2.609375
3
[]
no_license
<?php include('contour.php'); if(isset($_SESSION['pseudo'])) { if(mysql_query('DELETE FROM evenement WHERE id = "'.$_POST['nom_event'].'"')){ $form = false; ?> <section> <br> <div class="message">L\'evenement &agrave &eacute;t&eacute; supprim&eacute;e.<br /> <meta http-equiv="refresh" content="1;url=accue...
true
0362b49d63d19c8ed1dbed9933abb111641dd085
PHP
n1n1du44/api-documents
/src/Command/CreateUserCommand.php
UTF-8
1,948
2.90625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: Antonin * Date: 01/04/2019 * Time: 15:28 */ namespace App\Command; use App\Entity\User; use Doctrine\ORM\EntityManagerInterface; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputInte...
true
4cbbc103d9839c47891b4c3f2eac3e235feae5e0
PHP
Tapfury/Laravel-Phone
/src/PhoneValidator.php
UTF-8
7,895
3.015625
3
[ "MIT" ]
permissive
<?php namespace Propaganistas\LaravelPhone; use Iso3166\Codes as ISO3166; use libphonenumber\NumberParseException; use libphonenumber\PhoneNumberType; use libphonenumber\PhoneNumberUtil; use Propaganistas\LaravelPhone\Exceptions\NoValidCountryFoundException; use Propaganistas\LaravelPhone\Exceptions\InvalidParameterEx...
true
c1b142ed202e3395ca281801c589a450a2a774a3
PHP
slepic/php-value-object
/src/Strings/BoundedMbLengthString.php
UTF-8
551
2.921875
3
[ "MIT" ]
permissive
<?php declare(strict_types=1); namespace Slepic\ValueObject\Strings; abstract class BoundedMbLengthString extends MultiByteString { abstract protected static function minLength(): int; abstract protected static function maxLength(): int; public function __construct(string $value) { $minLength...
true
dbe029e1891a80593fa5d51ff59102c8552652f0
PHP
kevanescence/cakePHP-watchspeak
/app/Controller/CommentsController.php
UTF-8
3,693
2.5625
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. */ App::uses('AppController', 'Controller'); /** * CakePHP CommentsController * @author kremy */ class CommentsController exte...
true
db83374f45d2e4b3b50401a28665909f40e33764
PHP
gabrielknot/exercicio_chronos
/database/migrations/2021_03_28_044021_create_hobbies_table.php
UTF-8
889
2.703125
3
[]
no_license
<?php use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; use Illuminate\Support\Facades\DB; class CreateHobbiesTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { ...
true
4bdee2ece9f16a8a1931a2db302f64a68efb9e00
PHP
elsayed85/ray
/tests/Concerns/ConcernsTest.php
UTF-8
1,150
2.703125
3
[ "MIT" ]
permissive
<?php use Spatie\Ray\Tests\TestClasses\FakeRay; it('sets small and large payload sizes', function () { $ray = new FakeRay(); $ray->small(); expect($ray->getLastSize())->toEqual('sm'); $ray->large(); expect($ray->getLastSize())->toEqual('lg'); expect($ray->getSizeHistory())->toEqual(['sm', '...
true
e1741b40f0fef8642115a3c34e8d0d25867459f8
PHP
Deployee/plugin-filesystemtasks
/src/Utils/RmDir.php
UTF-8
1,140
2.921875
3
[]
no_license
<?php namespace Deployee\Plugins\FilesystemTasks\Utils; class RmDir { /** * @var Rm */ private $rm; /** * RmDir constructor. */ public function __construct() { $this->rm = new Rm(); } /** * @param string $path * @return bool */ public func...
true
60ad86bbb0afec8637306880ec19bbed334fcb49
PHP
KnpLabs/KnpMarkdownBundle
/Twig/Extension/MarkdownTwigExtension.php
UTF-8
782
2.59375
3
[ "MIT" ]
permissive
<?php namespace Knp\Bundle\MarkdownBundle\Twig\Extension; use Knp\Bundle\MarkdownBundle\Parser\ParserManager; use Twig\Extension\AbstractExtension; use Twig\TwigFilter; class MarkdownTwigExtension extends AbstractExtension { private $parserManager; public function __construct(ParserManager $parserManager) ...
true
26a78ccb66751657fdbf7c3da99288851666ef98
PHP
rohitprovident/Provident
/hello.php
UTF-8
454
2.765625
3
[]
no_license
<?php echo "Hello world!"; ?> <html> <body> <table border="2"> <tr> <th>name</th> <th>number</th> </tr> <?php $conn = mysqli_connect("localhost","providentcrm","providentcrm","default"); $q2 = "select * from abc "; $run = mysqli_query($conn, $q2); $row = mysqli_fetch_...
true
d4648233385b9f079acd7c7259a311da621f731c
PHP
nmmmnu/geoproximity
/geosphere.php
UTF-8
2,299
3.28125
3
[]
no_license
<?php trait GeoMath{ private static $DEG_RAD_ = M_PI / 180; public static function rad($deg){ return $deg * self::$DEG_RAD_; } public static function square($a){ return $a * $a; } } class GeoSphere{ use GeoMath; public static $LAT_SIZE = 2 * 90; // -90 to +90 public static $LON_SIZE = 2 * 180; // -1...
true
d8034d63cb206a5b12020c7c8e8f829fe8b77b57
PHP
JoshVelazquez/Hospital
/app/ValidadorLogin.inc.php
UTF-8
1,324
3.140625
3
[]
no_license
<?php include_once "RepositorioUsuarios.inc.php"; include_once "Usuarios.inc.php"; class ValidadorLogin { private $Usuario; private $Error; public function __construct($email, $password, $conexion) { $this -> Error = ""; if (!$this -> variableIniciada($email) || !$this -> variableIni...
true
4f03dff4c6437b6a83cab7dcc677e22da134cadf
PHP
akshaymahesh/WebscrapingProjects
/Angellist/gen_info.php
UTF-8
2,788
2.875
3
[]
no_license
<?php /* GENERAL INFO @ ANGELIST send flag 'startup_id' populates company_url, angellist_url, market tags in db */ class Angellist { /*** GET FLAGS FROM URL ***/ function getFlags() { $startup_id = $_GET['startup_id']; // for test, use 147930 $this->PopulateTables($startup_id, $...
true
72908c6ac1e7c77dd998a91731e6085508225538
PHP
yazanmonshed1/hawas
/app/Http/Controllers/LibraryController.php
UTF-8
1,575
2.5625
3
[]
no_license
<?php namespace App\Http\Controllers; use App\Models\DigitalBook; use App\Models\TextBook; use Illuminate\Http\Request; use Meta; use Helper; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; class LibraryController extends Controller { public function index($type) { if (!in_array($ty...
true
5439ed3540c82b4d384304db52d49f596f847dba
PHP
mavewei/Mandra
/check_data.php
UTF-8
9,324
2.671875
3
[]
no_license
<?php require_once('db/db_config.php'); $dbSelected = mysql_select_db($dbName) or die("Unable to select database: " . mysql_error()); if($dbSelected) { // Validate data for email address. if(!empty($_POST['emailAdd'])) { $emailAdd = $_POST['emailAdd']; $query = "SELECT * FROM userAccounts WHERE emailAdd =...
true
84bf4b08f7ae20dd273523d7edd8d2dda90ed9e7
PHP
kdfwow64/translitor_yii
/common/components/keyStorage/FormWithoutSubmitWidget.php
UTF-8
3,618
2.59375
3
[ "BSD-3-Clause" ]
permissive
<?php namespace common\components\keyStorage; use Yii; use yii\base\InvalidConfigException; use yii\base\Widget; use yii\helpers\ArrayHelper; use yii\helpers\Html; /** * @author Eugene Terentev <eugene@terentev.net> */ class FormWithoutSubmitWidget extends Widget { /** * @var \common\components\keyStorage...
true
4dcafff6efdfd6f8158b78f20d9485cb3ffcbc80
PHP
Ox18/crud-basic-lab12
/utils/Response.php
UTF-8
2,666
3.71875
4
[]
no_license
<?php /** * Response class * Clase estandarizada para recibir respuestas de la API * @Author: Wilmer Delgado - */ class Response{ private $error; private $data; private $message; /** * Constructor * @param $error {bol} Valida si hay un err...
true
c9fac1d47285291852b5ec3e3b2df2c48be96e3a
PHP
carmenrenca/Ejercicios_PHP
/15-ejercicios/ejercicio3.php
UTF-8
501
3.625
4
[]
no_license
<?php /** * Programa que compruebe si una variable está vacia . Y si es vaic rellenarla con texo en minusculay mostrarlo * en mayuscula en negrita */ $texto="sad"; function comprueba($cadena){ var_dump(empty($cadena)); if(empty($cadena)){ $cadena= strtolower('Testo prueba'); ...
true
9d506e52b8aaef2dbc6033dca041bfd837d2a613
PHP
dmitri-seron/world-statistics
/classes/page/Layout.php
UTF-8
3,467
3.09375
3
[]
no_license
<?php namespace classes\page; /** * Layout class. * * @author Dmitri Seron <dmitri.seron@gmail.com> */ abstract class Layout { /** * @var string */ protected string $pageId = ""; /** * @var string */ protected string $title = ""; /** * @var string */ protected string $keywords = ...
true
cf068b363ff63ba203f4010a95c1dd587d5e5028
PHP
Zynski/desafioProspecta
/Server/src/App/Company/CompanyController.php
UTF-8
488
2.796875
3
[]
no_license
<?php namespace App\Company; class CompanyController { private $DAO; public function __construct(){ $this->DAO = new CompanyDAOMySql; } public function getOne(){ return "Teste"; } public function getAll(){ return $this->DAO->showCompanies(); } public function post($obj) { return $this->DAO->i...
true
5b629f91dfbaa91c92008830a401770802525635
PHP
ZacharyKearns/reading-list-app
/includes/templates/search.tpl.php
UTF-8
1,661
2.625
3
[]
no_license
<?php $page_title = 'Search Books'; include('includes/templates/header.tpl.php'); ?> <h1><?php echo $page_title; ?></h1> <?php echo $errors['title']; echo $errors['image_url']; ?> <form action="<?php echo $_SERVER['PHP_SELF']; ?>?action=search" method="post" id="search-form"> <?php echo $errors['search_query']...
true
fd9b5b77c1ae9bbf0d88bb4c11b2e4f62369effe
PHP
Spielberg/simple-api-slim-jwt
/src/routes/api/ventas/delete.func.php
UTF-8
1,304
2.59375
3
[]
no_license
<?php use Slim\App; use Slim\Http\Request; use Slim\Http\Response; return function (Request $request, Response $response, array $args) { $token = $request->getAttribute('decoded_token_data'); // el id del user es obligatorio. $input = $request->getParsedBody(); if (!isset($args['id']) || $args['id'] === ''...
true
e8a400ca260829c3355390bd1075b812fd4da76d
PHP
pachkov-nikita/WebDesign
/PZ 11/index.php
UTF-8
1,178
2.796875
3
[]
no_license
<!DOCTYPE html> <html> <head> <style> .container { font-family: 'Times New Roman'; font-size: 20px; display: flex; flex-direction: column; } </style> </head> <body> <div class="container"> <form action="upload.php" method="post" enctype="multipart/form-data"> ...
true
5a99acdbef57ba77ee40fbad76d50e54651bdbbd
PHP
milenabega1/php
/ejercicio2.php
UTF-8
529
2.53125
3
[]
no_license
<!DOCTYPE html> <html> <head> <title>prueba</title> <meta http-equiv="content-type"content="text/html; charset=ISO-88591"/> </head> <body> <h3>Nombre: </h3> <% echo "Luis Pablo <br />"; //Primer segmento de un programa PHP %> <h3>Apellidos:</h3> <? echo "Perez Jimenez <br />"; //Segundo segmento ...
true
0af746046f9372c3187525b6a66d38a5345d6573
PHP
bitpay/bitpay-checkout-for-woocommerce
/vendorPrefixed/vendor/fidry/console/src/Internal/Generator/TypeMap.php
UTF-8
2,230
2.53125
3
[ "MIT" ]
permissive
<?php /* * This file is part of the Fidry\Console package. * * (c) Théo FIDRY <theo.fidry@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 BitPayVendor\Fidry\Console\Internal\Generator...
true
12a07c1b2a6333fc55beb632ed892476d70e50b9
PHP
sakura2317/HelloPHP-
/if_rensyu08.php
UTF-8
380
3.484375
3
[]
no_license
<!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>無題ドキュメント</title> </head> <body> <?php $A = 6; $B = 9; if ($A == $B){ echo $A."と".$B."は等しい"; }elseif ($A > $B){ echo $A."は".$B."より大きい"; }elseif ($A < $B){ //elseでもいい。 echo $A."は".$B."より小さい"; } ?> </body> </html>
true
12a457024e1536d8f01a26d2e9dd6a00f0976a38
PHP
luisE-dev/LogiDonsPHPMVC
/modele/UserDAO.class.php
UTF-8
6,225
3.0625
3
[]
no_license
<?php include_once('/modele/classes/Database.class.php'); include_once('/modele/classes/User.class.php'); require_once('/modele/classes/Liste.class.php'); class UserDAO { public static function findUser($courriel) { $db = Database::getInstance(); $pstmt = $db->prepare("SELECT * FROM user WHERE courriel =...
true
caa9fabdfd1b96f5500f9923306939d92f522dd7
PHP
atukai/gridly
/src/GridFactory.php
UTF-8
1,935
2.53125
3
[ "MIT" ]
permissive
<?php namespace Gridly; use Doctrine\ORM\EntityManagerInterface; use Gridly\Column\Definition; use Gridly\Column\Definitions; use Gridly\Paginator\PaginatorFactory; use Gridly\Source\Doctrine; use Gridly\Source\Exception; use Gridly\Source\LaminasDbAdapter; use Gridly\Source\Pdo; use Laminas\Db\Adapter\Adapter; use P...
true
d25e9881a2f2d804db910671ffcbc04fef33ba03
PHP
michaeltsui98/kppw_google
/class/sys/prom.php
GB18030
15,147
2.546875
3
[]
no_license
<?php /** * ƹ * Enter description here ... * @author Administrator * */ Keke_lang::load_lang_class('sys_prom'); class Sys_prom { public $_prom_open; public $_prom_period; public $_auth_step; public static function get_instance() { static $obj = null; if ($obj == null) { $obj = new Sys_...
true
e7cc44915fe2de0aa9710621e149c52f9208e17d
PHP
edmunds22/oauth2-adobe-sign
/src/AdobeSign.php
UTF-8
5,640
2.625
3
[ "MIT" ]
permissive
<?php namespace edmunds22\OAuth2\Client; use League\OAuth2\Client\Provider\AbstractProvider; use League\OAuth2\Client\Provider\Exception\IdentityProviderException; use League\OAuth2\Client\Provider\ResourceOwnerInterface; use League\OAuth2\Client\Token\AccessToken; use Psr\Http\Message\ResponseInterface; /** * Cl...
true
41d31242ae35b3bf5e2b3ce6d97a58a73bda0fe0
PHP
patryksz/presentation-orm
/src/AppBundle/Entity/Comment.php
UTF-8
2,482
2.984375
3
[]
no_license
<?php namespace AppBundle\Entity; /** * Comment */ class Comment { /** * @var integer */ private $id; /** * @var string */ private $title; /** * @var string */ private $content; /** * @var \DateTime */ private $createDate; /** * @v...
true
376ec787f9a3f0c441292992b60c97b9a24ef2c6
PHP
rafelangelo/roadrunner-http
/src/HttpWorker.php
UTF-8
3,455
2.515625
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php /** * This file is part of RoadRunner package. * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ declare(strict_types=1); namespace Spiral\RoadRunner\Http; use Spiral\RoadRunner\Payload; use Spiral\RoadRunner\WorkerInterface;...
true
367ca87909ab899f3105ab1c2485b4ead8fb665d
PHP
DavidBasil/book-store
/htdocs/store.php
UTF-8
1,254
2.578125
3
[]
no_license
<?php // store page // start session session_start(); // redirect to login page if user not logged in if (!isset( $_SESSION['user_id'])) { require('login_tools.php'); load(); } // set page title and include header $page_title = 'Store'; include('includes/templates/header.html'); // connect to db require ('../c...
true
030fc225560c750d2c0bf2cb79156774ceceb0c2
PHP
thecodingmachine/safe
/generated/array.php
UTF-8
1,604
3.421875
3
[ "MIT" ]
permissive
<?php namespace Safe; use Safe\Exceptions\ArrayException; /** * Applies the user-defined callback function to each * element of the array. This function will recurse * into deeper arrays. * * @param array|object $array The input array. * @param callable $callback Typically, callback takes on two parameters. *...
true
1d92d8cefefbceedfc7e5755b7f4bc4fce680a5e
PHP
milonga-be/teachers.milonga.be
/frontend/controllers/AgendaController.php
UTF-8
20,858
2.703125
3
[ "BSD-3-Clause" ]
permissive
<?php namespace frontend\controllers; use Yii; use yii\web\Controller; use common\models\User; use common\models\School; use backend\models\Event; use yii\helpers\ArrayHelper; /** * Site controller */ class AgendaController extends Controller{ // public $layout = 'embed'; var $embedded = false; const DEFAULT_FIL...
true
457dd2a5bf5aec8e71cd9059110bfd174d4b57ce
PHP
Egoraizer/Diplom
/src/functions.php
UTF-8
1,975
2.59375
3
[]
no_license
<?php function can_upload_image($file) { if ($file['name'] == '') MessageForUser('danger', 'Вы не выбрали файл.'); elseif ($file['size'] == 0) MessageForUser('danger', 'Файл слишком большой.'); else { $getMime = explode('.', $file['name']); $mime = strtolower(end($getMime)); $types = array('jpg', 'p...
true
7f4a2b798179e1c5c983f621ce4b985291d66245
PHP
dev-scripts/english-nepali-number-converter-php
/src/Convert.php
UTF-8
571
3.234375
3
[]
no_license
<?php namespace DevScripts\EnglishNepaliNumberConverter; class Convert { /** * @param string $string * * @return string */ public static function toNp(string $string): string { $convertToNepali = new ConvertToNepali(); return $convertToNepali->convert($string); } ...
true
930e18f605e4af7d1eb0f537b8a1f61b17ee3eee
PHP
manzgui/ProjetoEstagio
/gerencianz/model/banco.php
UTF-8
583
2.65625
3
[]
no_license
<?php $conn = NULL; class Banco{ public static function getConexao(){ $servername = "127.0.0.1:3306"; $database = "casofa"; $username = "root"; $password = "root"; try{ if($GLOBALS['conn']) $GLOBALS['conn'] = NULL; $GLOBALS['conn'] = new PDO('mysql:host=' . $servername . ';dbname=...
true
fd16ba69733d4a080dfd2206fc22db60dc2f54aa
PHP
wangyongf/ROrder-PHP
/app/Http/Controllers/Api/App/AppController.php
UTF-8
2,843
2.640625
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers\Api\App; use App\Http\Controllers\Controller; use App\Models\App\App\App; use App\Utils\Common\ResponseUtils; use Illuminate\Http\Request; /** * APP信息控制器 * * Class AppController * @package App\Http\Controllers\Api\App * * @author Scott Wang * @version 0.1 * @sinc...
true
4c9878778f755d3209955d2c8643f0bd6a286de7
PHP
AlexHigginsVS/laravel-cookbook
/CookBook/Filters/ProfileOwner.php
UTF-8
752
2.890625
3
[ "MIT" ]
permissive
<?php namespace CookBook\Filters; use Illuminate\Auth\AuthManager; use Illuminate\Routing\Redirector; use CookBook\Recipes\RecipeRepository; class ProfileOwner { /** * @var AuthManager */ protected $auth; /** * @var RecipeRepository */ protected $redirect; /** * @param AuthManager $auth * @pa...
true
f790bdc9f75214768c130cda088f7af7a1fe7e8b
PHP
CaptainKidd33/Proyecto_PHP
/Firmar.php
UTF-8
1,346
2.546875
3
[]
no_license
<?php declare(strict_types=1); use setasign\Fpdi\Tcpdf\Fpdi; require_once('vendor/autoload.php'); session_start(); $cerFile = 'file://'.realpath('uploads_pem/test_cer.crt'); $pemKeyFile = 'file://'.realpath('uploads_pem/test_key.pem'); $passPhrase = $_SESSION['pass'];; // contraseña para abrir la llave ...
true
eb21abfc2b5b836b2d67e8a07f9aea15be0341f8
PHP
EndorphinE19/Logic
/logic/php/registration.php
UTF-8
3,055
3.0625
3
[]
no_license
<?php // подключаемся к бд try { $pdo = new PDO('mysql:host=localhost; dbname=llc', 'root', ''); } catch(PDOException $e) { echo "Error".$e->getMessage(); } class Registration { private $result_key_entry = [ 'error_entry' => 'Пользватель с таким логином или email уже существует', ...
true
bb3cca16e3e4428058235ff111bf4ac6419a06f1
PHP
spatie/laravel-log-dumper
/src/LogDumper.php
UTF-8
3,181
2.703125
3
[ "MIT" ]
permissive
<?php namespace Spatie\LogDumper; use Illuminate\Database\Events\QueryExecuted; use Illuminate\Support\Facades\DB; use Symfony\Component\VarDumper\Cloner\VarCloner; use Symfony\Component\VarDumper\Dumper\CliDumper; class LogDumper { protected VarCloner $cloner; protected CliDumper $dumper; protected bo...
true
91fd10ad0c1186cf8eb145ec05eaa6c8043dc959
PHP
Brille24/psalm
/src/Psalm/Checker/Statements/Block/ForChecker.php
UTF-8
1,404
2.53125
3
[ "MIT" ]
permissive
<?php namespace Psalm\Checker\Statements\Block; use PhpParser; use Psalm\Checker\Statements\ExpressionChecker; use Psalm\Checker\StatementsChecker; use Psalm\Context; use Psalm\Scope\LoopScope; class ForChecker { /** * @param StatementsChecker $statements_checker * @param PhpParser\Node\St...
true
e4ce515cf9d1a2603a15253c45d41a20bedbf1ba
PHP
williamandrieu/AlgoAvance
/algoTri.php
UTF-8
2,662
3.015625
3
[]
no_license
<?php function randomGeneration($nbRandom) { $randTab = []; while (count($randTab) < $nbRandom) { do { $randTab[] = random_int(0, getrandmax()); } while (count($randTab) < $nbRandom); $randTab = array_unique($randTab); } return array_values($randTab); } /* function randomGeneration($nb...
true
82da8987f7f1ed7aa6d017db2cb7b2144f84866e
PHP
sjackson01/2-SimplePHPConverter
/index.php
UTF-8
543
3.6875
4
[]
no_license
<?php /* !Simple Converter! */ $pounds = 140;//Value converted to kilograms $lb_to_kg = 0.453592;//Pounds in a kilogram $kilograms = $pounds * $lb_to_kg;//Convert /* Display pounds converted to kilograms */ echo "Weight: " ; echo $pounds; echo "lb = "; echo $kilograms; echo " kg"; $miles = 2.5; //Value converted ...
true
5f652a4d76c1bbb1b1c152ed93d59ce55995ac18
PHP
php/pecl-database-mysql_xdevapi
/tests/createdrop_schema.phpt
UTF-8
1,927
2.5625
3
[ "PHP-3.01" ]
permissive
--TEST-- mysqlx create/drop schema --SKIPIF-- --INI-- error_reporting=0 --FILE-- <?php require_once("connect.inc"); $session = mysql_xdevapi\getSession($connection_uri); function database_exist($name) { global $session; $db_exist = $session->sql("show databases like '$name'")->execute(); $res = $db_exist->fe...
true
a3a62c2a2744798914352a445064cf12de548a2a
PHP
huping112003/php-swoole-framework
/src/Console/WebSocketCommand.php
UTF-8
3,551
2.640625
3
[]
no_license
<?php /** * * @date: 2017/7/20 16:42 * @version 3.0.0 */ namespace Kerisy\Console; use Kerisy\Exception\InvalidConfigException; use Kerisy\Exception\InvalidParamException; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\Input...
true
cc6768130d980942547ecd22ca3938da3f30a1cf
PHP
ExoSuite/exosuite-users-api
/app/Services/ClassFinder.php
UTF-8
2,564
2.65625
3
[]
no_license
<?php declare(strict_types = 1); /** * Created by PhpStorm. * User: loiclopez * Date: 2019-01-11 * Time: 12:56 */ namespace App\Services; /** * Class ClassFinder * * @package App\Services */ class ClassFinder { //This value should be the directory that contains composer.json private const APP_ROOT =...
true
c2b8350d9cff94cfc746c432c7f78f097f046b44
PHP
Stolz/php-stubs
/res/php/pgsql/functions/pg-set-error-verbosity.php
UTF-8
305
2.546875
3
[ "Apache-2.0", "CC-BY-3.0" ]
permissive
<?php /** * Determines the verbosity of messages returned by and . * * @phpstub * * @param resource $connection * @param int $verbosity * * @return int The previous verbosity level: , * * or . */ function pg_set_error_verbosity($connection = NULL, $verbosity) { }
true
e25bfb721267667e8fbcd7ead5753e4811ebc130
PHP
lokinz/headfirst
/src/Duck/FlyWithWings.php
UTF-8
164
3.03125
3
[]
no_license
<?php namespace Headfirst\Duck; class FlyWithWings implements FlyBehavior{ public function fly(): void { echo 'I\'m Flying' . PHP_EOL; } }
true
654202777f99dc91022b5675e44f7242660bd460
PHP
bingxindan/swoole_framework
/Packages/bxd/rabbitmq/src/AmqpPublish.php
UTF-8
626
2.53125
3
[]
no_license
<?php namespace BxdFramework\RabbitMq; use BxdFramework\Base\Code; use BxdFramework\Base\Conf; class AmqpPublish extends Amqp { /** * 获取实例 * @param $attribute * @return \AMQPExchange * @author zm */ public static function getInstance($exchangeAttr, $setReadTimeout = 0) { /...
true
85c1fc192e3191b31378abc247d9eb7648c7a992
PHP
zhucg/purfect-teacher-backend
/app/Dao/Notice/AppProposalDao.php
UTF-8
1,540
2.625
3
[]
no_license
<?php namespace App\Dao\Notice; use App\Models\Notices\AppProposal; use App\Models\Notices\AppProposalImage; use App\Utils\Misc\ConfigurationTool; use Illuminate\Support\Facades\DB; class AppProposalDao { /** * 添加 * @param $data * @param $images * @return bool */ public function a...
true
08cc690e3fe8502ed0f4bd2004213d8f965bc34b
PHP
kacana/kacana.com
/app/Http/Requests/TagRequest.php
UTF-8
792
2.703125
3
[ "MIT" ]
permissive
<?php namespace App\Http\Requests; use App\Http\Requests\Request; class TagRequest extends Request{ public function authorize() { return true; } /** * Get the validation rules that apply to the request * * @return array */ public function rules() { switch($...
true
7ce0e87cbbf823f25157e33c1f5d7b0c49c7f1ee
PHP
sayhicoelho/php-api
/core/Auth.php
UTF-8
1,848
2.875
3
[ "MIT" ]
permissive
<?php namespace Core; use PDO; use App\User; abstract class Auth { /** * The User instance. * * @var \App\User */ private static $user; /** * Get the username field. * * @return string */ public static function getUsername () { return config('auth'...
true
113121cf2374c6a10e80246558a77079c271f897
PHP
zamozhnii/php
/admin/inc/Genre.class.php
UTF-8
651
3.09375
3
[]
no_license
<?php class Genre extends Mypdo { public $link; public $genre; public function __construct() { $this->link = new Mypdo(); } public function createGenre() { $sql = "INSERT INTO genres(genre_name) VALUES (?)"; $this->link->prepare(...
true
6e8dd9a354c99346f556a6015c97c7fde1f0953a
PHP
nickcuper/erm
/common/components/UserIdentity.php
UTF-8
1,111
2.6875
3
[]
no_license
<?php /** * UserIdentity represents the data needed to identity a user. * It contains the authentication method that checks if the provided * data can identity the user. * * @property-read boolean $ok */ class UserIdentity extends CUserIdentity { /** * @var User */ public $user; public fu...
true
928af816a81e994428a42364273b0395f93fc355
PHP
SCCapstone/chemlabaccs
/application/libraries/Commenthandler.php
UTF-8
2,261
2.890625
3
[ "MIT" ]
permissive
<?php /** * The Comment Handler class is responsible for inserting, displaying, and removing comments from the Chemlabaccs Application * Modified by D.Cooper 4/17/2014 */ class CommentHandler { private $CI; private $accidentid; private $userID; private $table = ""; private $comment; /********...
true
e76ece6c993e9fe4b1c47b56dc25cead4fe10f99
PHP
RodolfoTerra/guzzleExemple
/index.php
UTF-8
1,440
2.703125
3
[]
no_license
<!doctype html> <html lang="pt-br"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Guzzle Estruturado - By Rodolfo Terra</title> </head> <body> <?php ini_set('display_errors',1); $url = 'http://www.guiatrabalhista.com.br/guia/salario_minimo.htm'; requir...
true
76186df84ab6aaea2921b817e71902db1efa85c3
PHP
yernat73/uis
/app/Http/Controllers/GroupsController.php
UTF-8
3,295
2.515625
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Group; use App\User; class GroupsController extends Controller { /** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function __construct() { $this->middleware('auth'...
true
2347cccc875ea0a0a0ae46e733fdf49a7709d75b
PHP
booyen/uf
/general_base/donation-system-master/donation-form/php/include/abstract.donation.handler.php
UTF-8
5,467
2.609375
3
[ "MIT" ]
permissive
<?php abstract class AbstractDonationHandler { protected $_payment_method = null; protected $_merchant_settings = null; protected $_donation_bo = null; protected $_donation_id = null; protected $_donation_data = null; protected $_test_mode = null; public function __construct() { ...
true
a4db1c505abbb28d373972ffaac739d508753068
PHP
banksbestrates/BankFx
/news/wp-content/plugins/amp/includes/sanitizers/class-amp-base-sanitizer.php
UTF-8
27,080
2.65625
3
[ "GPL-2.0-only", "GPL-2.0-or-later", "GPL-1.0-or-later", "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
<?php /** * Class AMP_Base_Sanitizer * * @package AMP */ use AmpProject\DevMode; use AmpProject\Dom\Document; /** * Class AMP_Base_Sanitizer * * @since 0.2 */ abstract class AMP_Base_Sanitizer { /** * Value used with the height attribute in an $attributes parameter is empty. * * @since 0.3.3 * * @...
true
0bf6309b4efe50c39727e3867876b75198d48451
PHP
cmdconfig/w-task
/core/lang.php
UTF-8
558
2.890625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: asm * Date: 5/26/15 * Time: 12:27 AM */ namespace Core; class Lang { /** * Метод подгрузки языковых файлов * @param $string * @param $setLang * @return mixed */ public static function get($string,$setLang){ $langArr = []; ...
true
22fd25a96d52abf401afd7a0987ad5c2e49d72a8
PHP
Unfallen/BuStop-laravel
/app/Http/Models/User.php
UTF-8
801
2.609375
3
[ "MIT" ]
permissive
<?php namespace App\Http\Models; use Illuminate\Notifications\Notifiable; use Illuminate\Foundation\Auth\User as Authenticatable; class User extends Authenticatable { protected $table = 'users'; use Notifiable; /** * The attributes that are mass assignable. * * @var array */ prot...
true
2e91049761ca067d0ba46c10fc38966d31d9dc99
PHP
arabhossain/xpeedOOPTest
/core/xpeed/App.php
UTF-8
884
2.703125
3
[]
no_license
<?php /** * Created by PhpStorm. * User: arab * Date: 11/14/19 * Time: 9:33 AM */ namespace Xpeed; class App { public static $app_instance; private $config = []; public function __construct() { $this->config = include ROOT_PATH.'/configs/configs.php' ; } public static functio...
true
7d1cb94f5cf2590d3c41ae65136989eaa9b5fa05
PHP
slionx/laravelapp
/database/seeds/CategoryTableSeeder.php
UTF-8
564
2.765625
3
[]
no_license
<?php use Illuminate\Database\Seeder; class CategoryTableSeeder extends Seeder { /** * Run the database seeds. * * @return void */ public function run() { for($i=0;$i<10;$i++){ $tmp = []; $tmp['name'] = str_random(10); $tmp['count'] = rand(0,...
true
56567f97303452a5014f7c7a8dd5ee6f46bcdb62
PHP
sarkerarpita1/vlearning
/discussion_add.php
UTF-8
1,177
2.578125
3
[]
no_license
<html> <head> <title>Add a Topic</title> </head> <body> <div> <button onclick="location.href='discussion.php'">List</button> </div> <h1>Add a Topic</h1> <form method="POST" action=""> <p><strong>Your E-Mail Address:</strong><br> <input type="email" name="email" size=40 maxlength=40> <p><st...
true
f5c747a00f7b355476c321bf69e90f655cadc569
PHP
Nayjest/di-hub
/tests/Integration/GetRefTest.php
UTF-8
748
2.71875
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php namespace Nayjest\DI\Test\Integration; use Nayjest\DI\Definition\Value; use Nayjest\DI\Hub; use PHPUnit\Framework\TestCase; class GetRefTest extends TestCase { public function test() { $hub = new Hub([ new Value('item',1) ]); $ref = &$hub->get('item'); $hub-...
true
8880654de0b732058b11d09943567fa4b7f9abc2
PHP
lovesyx2012/LeePHP-Socket
/LeePHP/Net/SFTP.php
UTF-8
3,445
3.03125
3
[]
no_license
<?php namespace LeePHP\Net; use LeePHP\NetworkException; use LeePHP\PermissionException; use LeePHP\IOException; use \Exception; /** * SFTP 协议管理对象。 * * @author Lei Lee <web.developer.network@gmail.com> * @version 1.0.0 * @copyright (c) 2013, Lei Lee */ class SFTP { private $sess; private $sftp; priv...
true
70d99dd729e49c21cd09c065a6368fb4cc92f6d0
PHP
Yui-Ezic/crypto-correlation
/app/src/Correlation/Service/Calculator.php
UTF-8
213
2.625
3
[]
no_license
<?php declare(strict_types=1); namespace App\Correlation\Service; use App\Correlation\Entity\Chart\Chart; interface Calculator { public function calculateCorrelation(Chart $chart1, Chart $chart2): array; }
true
aff0fd4c6c75e231e9d0b0b04e311784b187bd5e
PHP
abhidilliwal/psession
/demo.php
UTF-8
2,817
3.078125
3
[]
no_license
<?php // These are required files in order. require_once 'psession/PersistentSessionExceptions.php'; require_once 'psession/PersistentSession.php'; require_once 'psession/PersistentSessionModel.php'; require_once 'psession/PersistentSessionManager.php'; use abhidilliwal\psession\PersistentSes...
true
ac206d63779c721f46ca043a9524d803a730a088
PHP
WalkWeb/Battle-Module
/templates/battle/row.template.php
UTF-8
590
2.53125
3
[]
no_license
<?php use Battle\View\ViewException; if (!isset($leftRangeUnits, $leftMeleeUnits, $rightMeleeUnits, $rightRangeUnits)) { throw new ViewException(ViewException::MISSING_COMMAND); } ?> <div class="row"> <table> <tr> <td class="w25" id="left_command_range"><?= $leftRangeUnits ?></td> ...
true
bf78c5205adc503886f0b920534c9ec4c99948a4
PHP
Abdul-aziz-shuvo/PHP-CMS-OOP
/SourceFiles/src/template.php
UTF-8
260
2.703125
3
[]
no_license
<?php class Template { private $layout; public function __construct($layout){ $this->layout = $layout; } public function view($template,$variables){ include VIEW_PATH.'layouts/'.$this->layout.'.html'; } }
true
9bf74b200520b1867a42ea6a4e4717dbcafa2f93
PHP
codingdojoangola/dojophp
/tests/Calculadoras/MyCalculadoraTest.php
UTF-8
291
2.578125
3
[]
no_license
<?php use DojoPHP\CalculadorasDeIdade\MyCalculadora; use PHPUnit\Framework\TestCase as PHPUnit; class MyCalculadoraTest extends PHPUnit { public function testCalculo() { $obj = MyCalculadora::_getAno('29/08/1989'); return $this->assertEquals('28', $obj); } }
true
c2ddf77f455354a72a5bf914d31b723aa5490b5b
PHP
Samiul-Hossain/SMS
/routine_pagination.php
UTF-8
2,488
2.703125
3
[]
no_license
<?php require_once('config/db_connect.php'); $limit = 5; if(isset($_POST['page_no'])){ $page_no = $_POST['page_no']; }else{ $page_no = 1; } $offset = ($page_no-1)*$limit; $query = "SELECT r.routine_id,c.course_name,s.section_no,r.day,r.time_start,r.time_end,t.name FROM routine r, course c, section s,...
true
f772bf012396a4e9079f901780ed7fdc820323ca
PHP
davidgauthier/trello
/controller/indexController.php
UTF-8
358
2.71875
3
[]
no_license
<?php class IndexController{ public function pageAccueilAction(){ // les deux manager car on en a besoin dans la vue $cm = new ColumnManager(); $tm = new TaskManager(); $columns = $cm->getColumns(10); // arg : limit require ("vue/vue_accueil.php"); } public function pageErreurAction($error){ req...
true
f97981799f10d72e9c06f3a3243095d81857cf31
PHP
wulibo123/basic
/jimujia-framework/framework/mvc/Dispatch.class.php
UTF-8
3,168
2.796875
3
[ "BSD-3-Clause" ]
permissive
<?PHP /** * @Copyright (c) 2011 Ganji Inc. * @author longweiguo@ganji.com * @date 2011-08-20 * * 流程分发 */ require_once dirname(__FILE__) . '/../util/http/ResponseUtil.class.php'; /** * @class: Dispatch * 流程分发类 * 所有用户的访问都是通过此类进行分发到app下不同目录下的BasePage派生类的*Action()方法执行 */ class Dispatch { pu...
true
bef694c43263ce8352c33f3bada9c21e83c4c3b0
PHP
c2is/BigfootNavigationBundle
/Form/DataTransformer/ItemToJsonTransformer.php
UTF-8
3,219
2.65625
3
[]
no_license
<?php namespace Bigfoot\Bundle\NavigationBundle\Form\DataTransformer; use Symfony\Component\Form\DataTransformerInterface; use Doctrine\Common\Collections\ArrayCollection; use Doctrine\ORM\EntityManager; use Bigfoot\Bundle\NavigationBundle\Entity\Menu\Item; class ItemToJsonTransformer implements DataTransformerInte...
true
d2170179c395cd494bb5df37fb301e8ad46f8fb2
PHP
1767701491/1604A--wangxiliang
/function.php
UTF-8
1,228
3.671875
4
[]
no_license
<?php /** * Created by PhpStorm. * User: 黑山老妖 * Date: 2018/11/29 * Time: 8:22 */ /** * 数组函数 */ $a = [1,2,3,4,5,6,7]; //1.生成一个第一个参数到第二个参数之间的数组 $b = range(1,5); //2.返回数组值 $c = array_values($a); //3.返回数组所有键 $d = array_keys($b); //4.计算数组长度 $e = count($a); //5.计算书组和 $f = array_sum($a); //6.合并数组 $g = array_merge($a,$b...
true
350791c377aa90a665d801a9a0f8c0bf92bc51e4
PHP
Mass-Kunc/php-web-latihan
/2 String, Array, dan Tanda Baca/P03-1.php
UTF-8
502
3.21875
3
[]
no_license
<?php // File P03-1.php // Tipe Data String $nama = "Ananda Maria Diana"; $kata1 = "Nama Saya adalah $nama"; $kata2 = 'nama Saya adalah $nama'; // Lihat perbedaan hasil saat menggunakan (") dan (') ...... Perbedaannya Penggunaan tanda “ akan memproses isi variabel sebelum ditampilkan // sedang penggunaan t...
true
cd336f643a3798d2400f9a1c1c3179ae0fc9cf33
PHP
bisight/bisight
/src/Core/Driver/PdoResultSet.php
UTF-8
1,262
2.796875
3
[]
no_license
<?php namespace BiSight\Core\Driver; use Symfony\Component\ExpressionLanguage\ExpressionLanguage; use BiSight\Core\Utils\ExpressionUtils; use PDO; class PdoResultSet implements ResultSetInterface { private $stmt; private $columns; private $language; private $utils; public function __construc...
true
4ea76e88921babf8b664144d293a7dfaaf9c85b4
PHP
lucbories/LibApt
/libapt-server-0.9.5/php/L0-core/html/class_default_input_adapter.php
UTF-8
17,668
2.578125
3
[ "LicenseRef-scancode-unknown-license-reference", "Apache-2.0" ]
permissive
<?php /** * @file class_default_input_adapter.php * @brief ... * @details ... * @see Trace Type * @ingroup L0_CORE * @date 2012-11-07 * @version 0.9.x * @author Luc BORIES * @copyright Copyright (C) 2011 Luc BORIES All rights reserved. * @license Apache License Version 2.0...
true
842070527a8c5dc45f524975f848b7efea8a5afd
PHP
ankitluthra/Steampunked
/tests/tests/PipeTest.php
UTF-8
2,088
2.734375
3
[ "MIT" ]
permissive
<?php require __DIR__ . "/../../vendor/autoload.php"; use Steampunked\Pipe as Pipe; /** @file * @brief Unit tests for the class Steampunked * @cond */ class PipeTest extends \PHPUnit_Framework_TestCase { const SEED = 42; public function test_construct() { $steam = new \Steampunked\Steampunked(self::SEED); ...
true