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
acbb84d603335d99c4bec04ff11fd61ab511c66a
PHP
samhol/_RVS_
/sphp/php/Sphp/Html/Apps/Calendars/MonthView.php
UTF-8
2,763
2.828125
3
[]
no_license
<?php /** * MonthView.php (UTF-8) * Copyright (c) 2014 Sami Holck <sami.holck@gmail.com> */ namespace Sphp\Html\Apps\Calendars; use Sphp\Html\Tables\Tbody; use Sphp\Html\Tables\Tr; use Sphp\Html\Tables\Td; use Sphp\Html\Tables\Thead; use Sphp\Html\Tables\Table; use Sphp\I18n\Calendar; use DateTimeInterface; /** ...
true
729930a2b2bae57873c8a0e1f5b71187113668e1
PHP
TheCats100/php-features
/site/jeu.php
UTF-8
1,017
2.90625
3
[]
no_license
<?php $aDeviner = 150; $erreur = null; $success = null; $value = null; if (isset($_POST['chiffre'])) { if ($_POST['chiffre'] > $aDeviner) { $erreur = "Votre chiffre est trop grand"; } elseif ($_POST['chiffre'] < $aDeviner) { $erreur = "Votre chiffre est trop petit"; } else { $success...
true
0fb0b948d6b094bd3fcfece5c378bf84df38e9ac
PHP
Fibanachi/PHP
/236.php
UTF-8
375
3.5
4
[]
no_license
Сделайте функцию isEven() (even - это четный), которая параметром принимает целое число и проверяет: четное оно или нет. Если четное - пусть функция возвращает true, если нечетное - false <?php function isEven($num) { return $num % 2 == 0; }
true
ba0e49a9c030af437e39c237bd89a5b867407930
PHP
debdebfr/test-blog
/article.php
UTF-8
1,585
2.78125
3
[]
no_license
<?php require_once 'core.php'; $managerCat = new CategorieManager($bdd); $liste = $managerCat->read(); $manager = new ArticleManager($bdd); if ( isset($_POST) && isset($_POST["titre"])) { $art = new Article($_POST['titre'],$_POST['contenu'],$_POST['date'],$user->getId(),$_POST['id_categorie']); // enregis...
true
6c5c829fe6f6dcf5e548fecf451d9254d719d334
PHP
harperj7/future
/FeedImport/ClassFeed.php
UTF-8
903
3.171875
3
[]
no_license
<?php namespace FeedImport; /** * Class ClassFeed * Base class for importing a feed * * @package FeedImport */ class ClassFeed { protected $curl; /** * Initialise a curl resource. Set the required curl options */ function __construct() { $this->curl = curl_init(); curl_s...
true
ffbc37eb70970b1d872f8db50379fc6ebaa8901c
PHP
rougin/windstorm
/tests/Fixture/Entities/User.php
UTF-8
1,550
2.984375
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php namespace Rougin\Windstorm\Fixture\Entities; /** * @Entity * @Table(name="users") */ class User { /** * @Id @GeneratedValue * @Column(name="id", type="integer", length=10, nullable=false, unique=false) * @var integer */ protected $id; /** * @Column(name="name", type="str...
true
74656cbe6487beb2d07fc68298d8ce0d6c20344f
PHP
davidjoan/saludonline
/lib/form/apps/backend/LoginBackendForm.class.php
UTF-8
1,222
2.578125
3
[]
no_license
<?php /** * LoginBackendForm. * * @package saludonline * @subpackage form * @author David Joan Tataje Mendoza <dtataje@datasolutions.pe> */ class LoginBackendForm extends BaseForm { public function initialize() { $this->labels = array ( 'email' => 'E-mail Address', '...
true
30edce074efbd2446c9541217c0e57e62b459a5a
PHP
peinda/digitata
/src/Entity/Contact.php
UTF-8
5,556
2.734375
3
[]
no_license
<?php namespace App\Entity; use DateTime; use PhpParser\Builder\Property; use Symfony\Component\Validator\Constraints as Assert; class Contact { /** * @var string|null * @Assert\NotBlank() * @Assert\Length(min=2, max=100) */ private $firstname; /** * @var...
true
732627269f8b6df948d315bec1f100118be20e9f
PHP
codejaley/kms_narc
/app/models/Album.php
UTF-8
425
2.59375
3
[ "MIT" ]
permissive
<?php class Album extends \Eloquent { // Add your validation rules here public static $rules = [ // 'title' => 'required' ]; // Don't forget to fill this array protected $fillable = ['title', 'slug', 'description','is_active']; public function OrmPhoto() { return $this->hasMany('Photo'); } public fu...
true
c5e64e711125729647644e027df144a86990b45f
PHP
jnlorenzi/synteruptor
/search_lib.php
UTF-8
1,570
2.671875
3
[]
no_license
<?php require_once("common.php"); $max_gbks = 6; $max_size = ini_get('post_max_size'); $dbdir = get_setting("db_dir"); $basedir = get_setting("search_dir"); $builder = "search.php"; $id = get_id(); $workdir = ""; $status_file = check_status_file(); if ($id) { $workdir = "$basedir/$id"; } function get_id() { if (iss...
true
8d9a1434ea635c732cda0b278d7daeb5ff4561db
PHP
onenewera/evergreen-escapes
/app/public/wp-content/plugins/defender-security/app/module/hardener/component/change-admin.php
UTF-8
2,150
2.546875
3
[ "GPL-2.0-only", "GPL-1.0-or-later", "LicenseRef-scancode-unknown-license-reference", "GPL-2.0-or-later" ]
permissive
<?php /** * Author: Hoang Ngo */ namespace WP_Defender\Module\Hardener\Component; use Hammer\Helper\HTTP_Helper; use WP_Defender\Module\Hardener\Model\Settings; use WP_Defender\Module\Hardener\Rule; class Change_Admin extends Rule { static $slug = 'replace-admin-username'; static $service; public function get...
true
8112f363219bdfb6e56716809a1bc54b448879c9
PHP
Tonyio83/PDOpartie1
/exercice3/index.php
UTF-8
940
2.921875
3
[]
no_license
<?php include '../header.php'; function connectDb() { require_once '../../Params/params.php'; $dsn = 'mysql:dbname=' . DB . ';host=' . HOST . ';charset=utf8'; try { $db = new PDO($dsn, USER, PASSWORD); return $db; } catch (Exception $exc) { die('La connexion à la base de données...
true
bb64ee39a19b1e350bc250a4afcf0d7ed4d8a91c
PHP
Provincia-di-Brescia/library-olap-api
/wsdigest.php
UTF-8
2,181
2.640625
3
[]
no_license
<?php /* viene eseguito dal web server (apache) e si incarica di istanziare la classe UriParser per la decifrazione dei parametri passati dalla GET dell'http. Una volta eseguito il parsing della url istanzia la classe OlapQuery che, a partire dalle istruzioni ricavate dalla url, predispone la query sql da utilizzare p...
true
81375dc2b120a1dc56551d5a60cf2572df55d6f3
PHP
kungfunk/dreams
/page-templates/registro.php
UTF-8
2,208
2.53125
3
[]
no_license
<?php /** * Template Name: Registro */ if (is_user_logged_in() || !get_option('users_can_register')) { wp_redirect(home_url()); } if (!empty($_POST)) { $errors = register_new_user($_POST['user'], $_POST['email']); if (!is_wp_error($errors)) { wp_redirect(home_url(LOGIN_URL . '?referer=' . $_P...
true
fd94fa3374e6754eabd0361877f040f0ee4d7338
PHP
WorkForFood/modx.evo.custom
/assets/snippets/DocLister/lib/DLpaginate.class.php
UTF-8
10,750
3.140625
3
[]
no_license
<?php class DLpaginate { /** * Script Name: *Digg Style Paginator Class * Script URI: http://www.mis-algoritmos.com/2007/05/27/digg-style-pagination-class/ * Description: Class in PHP that allows to use a pagination like a digg or sabrosus style. * Script Version: 0.5 * Author: Victo...
true
9f0ae7d9817683d934faacd348ece95219657f35
PHP
debmego/wrubus.in
/classes/Basic.php
UTF-8
770
2.6875
3
[ "MIT" ]
permissive
<?php /** * Created by Sudipta Deb * Date: 25/9/15 * Time: 7:58 AM */ class Basic { public static function print_pre_r($arr) { echo '<pre>'; var_dump($arr); echo '</pre>'; } public static function addScript($script) { echo '<script>' . $script . '</script>'; ...
true
7948d38cd218f462901a8723222c7fa60eb54afd
PHP
HattrickNZ/npv_irr
/index1.php
UTF-8
1,066
2.640625
3
[]
no_license
<html> <head> </head> <body> <!-- working on this here http://javascript.info/tutorial/settimeout-setinterval --> <hr> <hr> <input type="button" onclick="clearInterval(timer)" value="stop"> <p> this is a paragrph with the time goes here: XX</p> <div id="clock"> <span id="hour">hh</span>:<span...
true
9df9144b5264183301b8b4c1a5011a47e0c536c3
PHP
akoch-ov/bork-test
/src/Common/Position.php
UTF-8
386
3.03125
3
[]
no_license
<?php namespace TestDeliveryTask\Common; /** * @property float $weight * @property string $size * @property int $count */ class Position { public $weight; public $size; public $count; public function __construct($weight, $size, $count) { $this->weight = $weight; ...
true
e865d988ba249c963607ab8b577906f8d1c630b8
PHP
SeairahM/MysteryTeamProject
/editSalesForm.php
UTF-8
7,144
3.09375
3
[]
no_license
<?php require_once("checkLogin.php"); ?> <!DOCTYPE html> <html lang="en"> <head> <?php include("head.php"); ?> </head> <body> <?php include("navigation.php"); ?> <div> <?php require_once("dbconn.php"); $conn = $DBConn; if(isset($_POST["edit"])) { $sale = $_POST["edit"]; //if the user is c...
true
91849dfb7ea54c56b1fa006abe813fd77f2201f1
PHP
degiocuondi0897/project-ismart
/ismart.com/modules/post/models/indexModel.php
UTF-8
656
2.5625
3
[]
no_license
<?php //1. Hàm lấy ra tất cả các bài viết function get_list_post() { return db_fetch_array("SELECT * FROM `tbl_post` WHERE `status` = 3"); } //2.Các hàm xử lý phân trang bài viết //-------- Hàm lấy ra tổng số bài viết đã đăng function get_num_all_post() { return db_num_rows("SELECT * FROM `tbl_post` WHERE `sta...
true
1630434bac5f3e1432146923f6518b3cf9e14703
PHP
Hector357159/proyecto
/Framework/login.php
UTF-8
6,952
2.578125
3
[]
no_license
<?php // Reportamos Errores session_start(); header('Content-Type: text/html; charset=utf-8'); // Verificamos la version de PHP del servidor if (version_compare(phpversion(), '5.1.0', '<') == true) { exit('PHP5.1+ Required'); } // VAMOS A TRAER LA INFORMACION DE CONFIG UNA SOLA VEZ 'require_once' if (file_ex...
true
f299e8db80aa10ed55386e76d5ccb7dabdd3eb48
PHP
Galimbor/DAW-Pen_E-Shop
/src/Service/Cart.php
UTF-8
1,815
3.125
3
[]
no_license
<?php namespace App\Service; use App\Repository\ProductsRepository; use PhpParser\Node\Expr\Array_; use Symfony\Component\HttpFoundation\Session\SessionInterface; class Cart { public function retrieveCartItems(SessionInterface $session, ProductsRepository $productsRepository): array { ...
true
a2ef9156219fdb1c1e2ef9eccd153a2f1d96aabe
PHP
jcqdy/waima-script
/protected/modules/operation/models/data/ModelDataConf.php
UTF-8
653
2.671875
3
[]
no_license
<?php class ModelDataConf { protected $modelDaoOperation; protected $modelDaoActive; public function __construct() { $this->modelDaoOperation = new ModelDaoOperation(); $this->modelDaoActive = new ModelDaoActive(); } public function addOp($type, $gotoType, $resourceUrl, $sort...
true
b803ece1dff3aab37b315f49026366f8addaf075
PHP
masknetwork/web_node
/pages/app/assets/feeds/CMyFeeds.php
UTF-8
8,833
2.6875
3
[]
no_license
<? class CMyFeeds { function CMyFeeds($db, $template) { $this->kern=$db; $this->template=$template; } function newFeed($net_fee_adr, $adr, $name, $desc, $source, $website, $symbol, $days) { // Decode $name=base64...
true
eae6232a73f48d67b7a3e03c76c766de027b1d5c
PHP
Spyryto/AbstractClassUtils
/CheckMissingProperties/CheckMissingProperties.php
UTF-8
727
2.828125
3
[]
no_license
<?php namespace AbstractClassUtils\CheckMissingProperties; use AbstractClassUtils\Error\MissingValues; trait CheckMissingProperties { static function checkMissingPropertiesIn(array $data) { $nullProperties = []; foreach ($data as $key => $value) { if ($value === null) { $nullProperties[] = $key; } ...
true
d29b4d6c88fefde784eaca264efda162aa25067f
PHP
GovTribe/laravel-kinvey
/src/GovTribe/LaravelKinvey/Client/Plugins/KinveyEntityPathRewritePlugin.php
UTF-8
1,573
2.546875
3
[]
no_license
<?php namespace GovTribe\LaravelKinvey\Client\Plugins; use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Guzzle\Common\Event; class KinveyEntityPathRewritePlugin extends KinveyGuzzlePlugin implements EventSubscriberInterface { /** * Return the array of subscribed events. * * @return array *...
true
d94df86a77e3882199aea89cce4ebb0be6deb0af
PHP
Mirza233/SIS3_Project
/reg_form.php
UTF-8
2,106
2.609375
3
[]
no_license
<?php require('db_connect.php'); if (isset($_POST['username']) and isset($_POST['password']) and isset($_POST['email']) and isset($_POST['password_confirm'])){ // Assigning POST values to variables. $username = $_POST['username']; $password = $_POST['password']; $email = $_POST['email']; $confirm = $_POST['passwo...
true
ef036926008290255ad1ed47120affb20732b37e
PHP
thiraj/dolphiq-assessment
/dolphiq-api/app/DTOs/Customer/CustomerUpdateDTO.php
UTF-8
1,611
2.96875
3
[]
no_license
<?php namespace App\DTOs\Customer; use App\DTOs\AbstractDTO; use App\DTOs\BaseDtoInterface; /** * Class CustomerUpdateDTO * @package App\DTOs\Customer */ class CustomerUpdateDTO extends AbstractDTO implements BaseDtoInterface { /* @var string */ protected $id; /** * @var */ protected $...
true
7106eef238fb6891803f7a74a745502bc127b8f2
PHP
tourboks/apiclient
/src/Tourboks/Response/ProductSearch.php
UTF-8
822
2.78125
3
[ "LicenseRef-scancode-warranty-disclaimer", "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
<?php namespace Tourboks\Response; use Tourboks\Model\Product; use Tourboks\TourboksResponse; class ProductSearch extends TourboksResponse { /** * @return Product[] */ public function getData() { $items = $this->getBody()['item']; $products = []; if ($items) { ...
true
6b8831dbc0cfab6517a7f7266d6273051f0206cf
PHP
VolkovskiyAlexey/week2
/protected/commands/CreateAdminCommand.php
UTF-8
590
2.71875
3
[]
no_license
<?php class CreateAdminCommand extends CConsoleCommand { public function actionIndex($email='admini@stradm.in', $first_name='administrator', $last_name='admininstfxvc', $phone='1231231234', $password='admin', $repeat_password='admin') { $model = new User(); $model->role_id = User::ROLE_ADMIN; $model->e...
true
89aaac86655c9a916355d8b12eef174e9b27060c
PHP
ytnuk/routing
/src/Routing/Route/Collection.php
UTF-8
4,791
2.78125
3
[]
no_license
<?php namespace WebEdit\Routing\Route; use Kdyby\Translation; use Nette\Application; use Nette\Http; use Nette\Utils; use WebEdit\Routing; /** * Class Collection * * @package WebEdit\Routing */ final class Collection extends Application\Routers\RouteList { /** * @var Translation\Translator */ private $tra...
true
eca2d166a5841c4cde424dcf2a19d53f20d5c76c
PHP
evoliz/evoliz-php
/src/HttpClient.php
UTF-8
1,840
2.828125
3
[ "MIT" ]
permissive
<?php namespace Evoliz\Client; use GuzzleHttp\Client; class HttpClient extends Client { const PRODUCTION_URI = "https://www.evoliz.io/"; const STAGING_URI = "https://www.api.evoliz.net/"; private static $baseUri = self::PRODUCTION_URI; /** * @var HttpClient The SDK global HttpClient instance ...
true
c903fc5282298c25f05975e9a7e15e56db5eab1d
PHP
prolic/PhpDisruptor
/tests/PhpDisruptorTest/TestAsset/LongEvent.php
UTF-8
328
2.53125
3
[ "MIT" ]
permissive
<?php namespace PhpDisruptorTest\TestAsset; use Threaded; class LongEvent extends Threaded { public $long; public function __construct() { $this->long = 0; } public function set($long) { $this->long = $long; } public function get() { return $this->long; ...
true
210b18e2a09cd678b8e115b23073a8792d87639e
PHP
ampachts/QuestionR
/libs/mysql.php
UTF-8
2,788
3.03125
3
[]
no_license
<?php class mysqlDb extends PDO { protected $host='localhost', $user='mysqlUser', $password='mysqlPass', $database='dbName', $port=3306; private $result, $q, $stmt, $params=array(), $dbLink; public $lastCall, $records=array(); public function __construct($host='',$user=...
true
536bddaf8d83d68666662038304b6abf5007a931
PHP
webemyos/webemyoside
/Trunk/JHom/Core/JHomAjax.php
UTF-8
656
2.609375
3
[]
no_license
<?php /** * JHomFramework * Webemyos.com - la plateforme collaborative pour les startups * Oliva Jérôme * 02/11/2015 * */ class JHomAjax { //Proprietes private $Controls = array(); public $Version; function JHomAjax() { //Version $this->Version = "2.1.0.0"; } //Ajout de control...
true
a537248961afd51d0247b2fe7202558a9a04b9e6
PHP
alejogtz/fake-instagram-for-pets
/app/Models/Comment.php
UTF-8
524
2.640625
3
[]
no_license
<?php namespace App\Models; use Illuminate\Database\Eloquent\Model; class Comment extends Model { //aqui se declara el nombre de la tabla que esta en mysql protected $table = 'comments'; /** * primaryKey * * @var integer * @access protected */ protected $primaryKey = null; /** * Indicates if the...
true
25bd15563a138f02fd83724fd4bfd5675e09be57
PHP
abhijeetgk/patpedhi
/classes/registry.php
UTF-8
401
2.890625
3
[]
no_license
<?php /** * A simple registry class to hold objects and use it when needed. * @version 1.0 * @package Moneycontrol * @author abhijeetk */ class Registry { protected $_objects = array(); function set($name, &$object) { $this->_objects[$name] =& $object; } function get($name) { retu...
true
684e59e41cc96caeab4df1acb87fd9008b23bc45
PHP
joyhooei/u591
/u591_web/interface/yeshen/noxsdk/entity/KSPayResponseEntity.php
UTF-8
4,125
2.734375
3
[]
no_license
<?php /** * 支付查询和回调共用的结果实体,存储支付结果 * User: panwanghai * Date: 15/9/15 * Time: 下午12:41 */ require_once dirname(__FILE__) . '/KSBaseResponseEntity.php'; class KSPayResponseEntity extends KSBaseResponseEntity { private $appId="null";// 应用ID,在nox 平台上申请获取的 private $uid="null";// 用户ID private $payStatus=...
true
4e47fa14d03cd75c6384ce41d4d76efa985e853e
PHP
abrahamgodoy/user200
/Modelo/AltaAlumnoMdl.php
UTF-8
2,374
2.765625
3
[]
no_license
<?php class AltaAlumnoMdl { private $bd; function __construct() { require_once( "BaseDeDatos.php" ); $this -> bd = BaseDeDatos::obtenerInstancia(); } function buscarAlmuno( $codigo ) { $consulta = "SELECT * FROM alumno WHERE codigo = \"$codigo\""; $resultado = $this -> bd -> consultaEspecifica( $consulta...
true
3fc834a5dd9c641850842193878de65693df5f23
PHP
meenabisht/oops
/src/mail.php
UTF-8
2,070
2.734375
3
[]
no_license
<?php namespace Meena\loginform; use PHPMailer\PHPMailer\PHPMailer; use PHPMailer\PHPMailer\Exception; // require 'vendor/autoload.php'; class mail{ // Import PHPMailer classes into the global namespace // These must be at the top of your script, not inside a function //Load Composer's autoloader public function mail...
true
c36e36f147c2cf7112f4d89f04fd42d3554fa99e
PHP
aedart/athenaeum
/packages/Contracts/src/Http/Messages/Types.php
UTF-8
438
2.5625
3
[ "BSD-3-Clause" ]
permissive
<?php namespace Aedart\Contracts\Http\Messages; /** * Http Message Types * * @author Alin Eugen Deac <aedart@gmail.com> * @package Aedart\Contracts\Http\Messages */ interface Types { /** * Request type */ public const TYPE_REQUEST = 'request'; /** * Server Request type */ pu...
true
be3de0080a7ff6b730d0642edf8e3ffffb85bca5
PHP
Boukos/wustl-cse330-web
/sql/news_comment_edit.php
UTF-8
752
2.578125
3
[]
no_license
<!DOCTYPE html> <html> <head> <title>News Comment Edit</title> <link rel="stylesheet" type="text/css" href="news.css"> </head> <body> <h1>Edit</h1> <?php session_start(); $comment_id= $_POST["comment_id"]; $comment = $_POST["comment"]; printf( "<form method=\"POST\" action=\"news_comment_handler.php\"> <...
true
5b0d98a63245a4ae957c64403c2d0f6885fcc1ea
PHP
yijiangwen/auth
/src/Session/Jwt.php
UTF-8
3,342
2.8125
3
[]
no_license
<?php declare(strict_types=1); namespace Jasny\Auth\Session; use Jasny\Auth\Session\Jwt\Cookie; use Jasny\Auth\Session\Jwt\CookieInterface; use Jasny\Immutable; use Lcobucci\JWT\Parser; use Lcobucci\JWT\Builder; use Lcobucci\JWT\Signer; use Lcobucci\JWT\ValidationData; /** * Use JSON Web Token and JSON Web Signatu...
true
192cdd339efea118ebe7b9348183453f39559817
PHP
ideatic/l10n
/src/Utils/ICU/Parser.php
UTF-8
5,402
2.9375
3
[]
no_license
<?php declare(strict_types=1); namespace ideatic\l10n\Utils\ICU; use Exception; use ideatic\l10n\Utils\Str; class Parser { private int $_position; private int $_length; private bool $_throwExpressionEnd = true; public function parse(string $icuPattern, Pattern $destiny, int $beginAt = 0): void ...
true
f5466004109fdb4cfc4d10a2ff00fee3325cc091
PHP
ANARCYPHER/exchange-2
/src/Currency/ListRates.php
UTF-8
1,826
2.796875
3
[]
no_license
<?php declare(strict_types=1); namespace h4kuna\Exchange\Currency; use h4kuna\Exchange; use h4kuna\Exchange\Exceptions\FrozenMethod; /** * @implements \ArrayAccess<string, Property> * @implements \Iterator<string, Property> */ class ListRates implements \ArrayAccess, \Iterator { /** @var \DateTimeInterface */ ...
true
4478aa7545b87e4fe53086391146c7e278e2b0a7
PHP
sidis405/blog-fit-tdd
/app/Acme/Http/Controllers/Api/PostsController.php
UTF-8
3,029
2.609375
3
[]
no_license
<?php namespace Acme\Http\Controllers\Api; use Acme\Models\Post; use Illuminate\Http\Request; use App\Events\PostWasUpdated; use Acme\Repositories\PostsRepo; use Acme\Http\Requests\PostRequest; use Acme\Http\Resources\PostsCollection; use Acme\Http\Resources\Post as PostResource; class PostsController extends ApiCon...
true
7f7e7c938827b9e02a965d3e6d1e4ee99fde2d8f
PHP
xiaolizilg/laravel
/laravel/app/Http/Controllers/Admin/RoleController.php
UTF-8
2,768
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers\admin; use Illuminate\Http\Request; use App\Http\Controllers\Controller; use App\Models\admin\Role; use App\Repositories\admin\RoleRepository; use App\Models\admin\AdminAction; class RoleController extends Controller { protected $role; public function __construct(RoleRep...
true
5f792daaf7144f5bf95ebd8b1ed5de5432fa0601
PHP
misterhub/atividades
/cadastroproduto/editar.php
UTF-8
979
2.546875
3
[]
no_license
<?php require_once("menu.php"); session_start(); if(!isset($_SESSION["cadastro"])){ echo "Não existem produtos para aditar"; } else{ $id = $_REQUEST["id"]; $nome = $_REQUEST["nome"]; $detalhes = $_REQUEST["detalhes"]; $cor = $_REQUEST["cor"]; $pr...
true
8f79c16d9ac25008ac29f3f4198a60edf95e7362
PHP
EntityFX/Tarakaning
/www/engine/modules/Tarakaning/Model/CheckParams.php
WINDOWS-1251
980
2.8125
3
[]
no_license
<?php require_once 'ProjectsController.php'; require_once 'ReportHistoryController.php'; class CheckParams { public function checkExisting($paramArray) { foreach ($paramArray as $key => $value) { if ($key == "projectID") { $p = new ProjectsModel(); $value = (int)$value; if(!$p->is...
true
117a348bb1dd3e682dadabf979248da1b1a7b0d7
PHP
blackblue2712/Study-Laravel
/routes/web.php
UTF-8
9,105
2.546875
3
[ "MIT" ]
permissive
<?php /* |-------------------------------------------------------------------------- | Web Routes |-------------------------------------------------------------------------- | | Here is where you can register web routes for your application. These | routes are loaded by the RouteServiceProvider within a group which | ...
true
25617239be325e350aaf671b43ce20c9f0a6b702
PHP
mops1936/GildedRose-Refactoring-Kata-php
/tests/GildedRoseTest.php
UTF-8
973
2.75
3
[]
no_license
<?php declare(strict_types=1); namespace Tests; use GildedRose\GildedRose; use GildedRose\Item; use PHPUnit\Framework\TestCase; class GildedRoseTest extends TestCase { public function itemsDataProvider(): array { return [ [[new Item('Conjured Mana Cake', 3, 6)], [4]], [[new I...
true
5a43c58f0dc2b472765358604ad15f31495ebf4e
PHP
CakeDC/cakephp-clamav
/src/Validation/ClamdValidation.php
UTF-8
4,570
2.75
3
[ "MIT" ]
permissive
<?php /** * Copyright 2010 - 2019, Cake Development Corporation (https://www.cakedc.com) * * Licensed under The MIT License * Redistributions of files must retain the above copyright notice. * * @copyright Copyright 2010 - 2019, Cake Development Corporation (https://www.cakedc.com) * @license MIT License (http:/...
true
baa97a3a66831413c17b0a21a0e11d128647c33d
PHP
thilagam/Fo_FrTest
/FO/models/Ep/Controller/Pattern.php
UTF-8
5,524
2.765625
3
[]
no_license
<?php /** * Ep_Controller_Pattern * * * @date 9 Mai 08 * @category EditPlace * @author Farid * @package Controller * @version version 1.0 * */ class Ep_Controller_Pattern extends Ep_Db_Xml { /** * String Variable * @var String $skeleton * @var Array $css * @var Array $javascript * @var Array $m...
true
ad953feea466f1cc9f9ce9bed3e4fcb6d2fa0bd0
PHP
bwalker8038/caboose
/php/caboose.php
UTF-8
1,280
3.15625
3
[]
no_license
<?php // Include Caboose class include_once("./class_caboose.php"); /* Define the rules for each alias Method names should correspond to the names used in the data attributes This class is basically a router for your Caboose calls Ideally, you should call other classes/functions within each rule method rather ...
true
ebb85e583f2c3afb558b4ffed201f1d6e8c90c65
PHP
evgenimir/bestspend-yii2
/models/Category.php
UTF-8
1,182
2.578125
3
[ "BSD-3-Clause" ]
permissive
<?php /** * Created by PhpStorm. * User: Zheka1 * Date: 18.02.2018 * Time: 13:18 */ namespace app\models; use yii\db\ActiveRecord; use paulzi\adjacencyList\AdjacencyListBehavior; /** * Class Category - model of product categories * @package app\models */ class Category extends ActiveRecord { // CostaRico...
true
ff35e0beb55ba495ca1db2d0d329aaa0e6effb76
PHP
seeme/php-db-example
/signup.php
UTF-8
702
2.984375
3
[]
no_license
<?php $servername = "localhost"; $username = "root"; $password = ""; $dbname = "shopping"; // Create connection $conn = new mysqli($servername, $username, $password, $dbname); // Check connection if ($conn->connect_error) { die("Connection failed: " . $conn->connect_error); } $fullname = $_POST["fullname"]; $email ...
true
611ffa670d6ad1002eb37012bcf83ac9131d5a2a
PHP
15110051740/demo
/function.php
UTF-8
379
3.203125
3
[]
no_license
<?php $A=[1,3,6,9]; $B=[2,4,5,8,20]; function Combine($A,$B) { $arr=array_merge($A,$B); // var_dump($arr);die; $count=count($arr); for ($i=0; $i <$count ; $i++) { for ($j=$i+1; $j <$count ; $j++) { if($arr[$i]>$arr[$j]) { $temp=$arr[$i]; $arr[$i]=$arr[$j]; $arr[$j]=$temp; ...
true
6668734a3cf7dcc4604825cd016e4ae041635bf8
PHP
victorrentea/design-patterns-php
/src/victor/training/ddd/agile/Sprint.php
UTF-8
2,203
3.03125
3
[ "MIT" ]
permissive
<?php namespace victor\training\ddd\agile; use DateTime; class Sprint { const STATUS_CREATED = 'CREATED'; const STATUS_STARTED = 'STARTED'; const STATUS_FINISHED = 'FINISHED'; private int $id; private int $iteration; private Product $product; private DateTime $start; private DateTi...
true
cbe47231c4af6587051bf50a10f03e48f8ac573e
PHP
hyybee/do-an-chuyennganh
/doan/seo_friendly.php
UTF-8
1,362
2.59375
3
[]
no_license
<?php require 'connect.php'; $query = mysqli_query($conn, "SELECT * FROM posts WHERE url = '' "); while($row = mysqli_fetch_assoc($query)){ $new_friendly_url = $vl_url_string = friendly_seo_string($row['title']); $counter = 1; $intial_friendly_url = $new_f...
true
15a78c1509178fecc96b2488b17bc478142bec52
PHP
oojoseph67/Result-Management-System
/database/factories/ResultFactory.php
UTF-8
3,324
2.578125
3
[]
no_license
<?php namespace Database\Factories; use App\Models\Result; use App\Models\User; use App\Models\Subject; use Illuminate\Database\Eloquent\Factories\Factory; class ResultFactory extends Factory { /** * The name of the factory's corresponding model. * * @var string */ protected $model = Resu...
true
73925356fc2e389fa6c86908be6fb64951a1ee63
PHP
palchik1985/partofthetestproject
/app/Http/Controllers/API/RestaurantAPIController.php
UTF-8
6,258
2.53125
3
[]
no_license
<?php namespace App\Http\Controllers\API; use App\Criteria\PaginateCriteria; use App\Http\Controllers\AppBaseController; use App\Http\Requests\API\CreateRestaurantAPIRequest; use App\Http\Requests\API\UpdateRestaurantAPIRequest; use App\Models\Restaurant; use App\Repositories\RestaurantRepository; use Illuminate\Http...
true
78fa0be2a68dbceb65d5550010aa539025cf9070
PHP
boris1690/arcimed
/sitio/_funciones/funciones.php
ISO-8859-1
20,493
2.859375
3
[ "MIT" ]
permissive
<? /** * Conecta con un web service API REST y obtine la ubicacin geografica de Ip actual * lugo seleciona los paices tendran acceso y bloquea cualquier otro pais * @return boolean */ function countryBlock() { /*$allowed_countries = array( "GT", // "SV", // "EC", ); $infoObj = json_decode(fi...
true
d1ab7a90e1b51f58a9f89f64bb588b8914be38f4
PHP
davidtrussler/dtNet
/blog_main.php
UTF-8
3,885
2.640625
3
[]
no_license
<?php include ('includes/weblog.php'); include ('includes/dateFormatter.php'); $weblog = new Weblog(); $dateFormatter = new DateFormatter(); // TODO - get blog posts as object not 2 db requests // and get post from titleid not postid if (isset($_GET['tagNameId'])) { $postIdArray = $weblog->getPostIds($_GET['tagNa...
true
737d82c419c364e4507ccbb06702609352a6ef03
PHP
jhumjhum12/use1id1.0
/app/ScreenBuilder/HTMLBuilder.php
UTF-8
3,178
2.75
3
[]
no_license
<?php namespace App\ScreenBuilder; use Form; use Request; use Illuminate\Support\Facades\View; use URL; use Illuminate\Support\Facades\Auth; /** * Created by PhpStorm. * User: srdjan * Date: 9/29/16 * Time: 12:25 */ class HTMLBuilder { /** * * Render any of internal screens * Single screen...
true
515c190201f84a746044df3725b1b0e748e15ad6
PHP
Baba-Muizz/RDHIPHP
/assets/private/db/config.php
UTF-8
529
3.296875
3
[]
no_license
<?php // Database connection CLASS class Connection { // Properties private $host = 'localhost'; private $dbname = 'royal diamond investment'; private $username = 'root'; private $password = ''; // Methods public function connect() { try { $database = new PDO("mysql:host=$this->host;dbname=$thi...
true
fddd1d918f3a457a168471a0f1b56e90e753b6e0
PHP
CodeStuffLiamCanLookAt/BMR
/tests/male_bmr.test.php
UTF-8
1,405
2.75
3
[]
no_license
<?php use Footballencarta\BMR\BMR; class MaleBmrTest extends \PHPUnit\Framework\TestCase { protected $bmr; public function setUp() { $this->bmr = new BMR(); } public function testCalculateFeetStone() { $bmr = $this->bmr ->age(55) ->gender(BMR::MALE) ->heightInFe...
true
62cfb7379f6cfbfa26cb61cc05f0fe1b87dafc69
PHP
david99cartagena/burguerlandia
/modelo/Model.php
UTF-8
372
2.625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: fhjua * Date: 23/06/2018 * Time: 12:12 PM */ include_once "Conexion.php"; abstract class Model extends Conexion { abstract public function getRegistro(); abstract public function insertaRegistro(); abstract public function setRegistro($ident, $col, $valor);...
true
a9132395912c9540b8a8abf4cb90955761a71f39
PHP
Andrey7098/Work_chat
/work/models/User.php
UTF-8
2,093
2.90625
3
[]
no_license
<?php class User{ public static function check($login,$password1,$password2){ $error = false; if($login == ""){ $error[] = "Введите логин"; } if($password1 == "") { $error[] = "Введите пароль!"; } if($password2 != $password1) {...
true
706431c70babaaee791edcc4ec887f65e4cf601a
PHP
graphen/ex-framework
/ExFramework/app/controllers/admin/AdminRecipeEditForm.class.php
UTF-8
7,555
2.515625
3
[]
no_license
<?php class AdminRecipeEditForm extends AdminBaseControllerActionAbstract implements IController { protected $_request = null; protected $_session = null; protected $_i18n = null; protected $_recipeMapper = null; protected $_categoryMapper = null; protected $_ingredientMapper = null; protected $_unitMapper = ...
true
3037bf484ce8a37da0773fdfd108b530e0a9df4a
PHP
itikku/ues-store-prototype
/related.php
UTF-8
1,830
2.765625
3
[]
no_license
<?php // currently active products that have been viewed by other customers that also viewed the selected product // ordered by descending views, with precedence given to featured products include 'header.php'; $queryResult = NULL; if(isset($_POST['submit'], $_POST['name']) && $_POST['...
true
74912f05099b6c50b208bcd3556d3a1b5086985b
PHP
jdpsl/construct
/advancedproperties.php
UTF-8
381
2.53125
3
[]
no_license
<p>Advanced Properties <hr></p> <?php $file=file_get_contents("css.txt"); $file=explode("\n", $file); echo "<table>"; foreach ( $file as $line ){ $tmp=explode("\t",$line); echo "<tr>"; echo "<td title='".$tmp[1]."' alt='".$tmp[1]."'>" . $tmp[0] . "</td><td><input type=text></td>"; ...
true
d844b9d917872d441fc0534791c62c22735ed4fa
PHP
frfusch21/PHP-Based-Journal-Register-Website
/lrpm/lrpm/samples/Listitem.php
UTF-8
7,329
2.59375
3
[]
no_license
<?php date_default_timezone_set("Asia/Jakarta"); include_once 'Sample_Header.php'; include 'tes.php'; // New Word document echo date('H:i:s'), ' Create new PhpWord object', EOL; $phpWord = new \PhpOffice\PhpWord\PhpWord(); $phpWord->setDefaultParagraphStyle( array( //'alignment' => \PhpOffice\PhpWord\SimpleTyp...
true
ec91d909a15191f94b45adc42f940fbe78bc4221
PHP
adriR97/aprendendoPhp
/estruturasDeControle.php
UTF-8
1,205
3.78125
4
[]
no_license
<?php $a = 10; $b = 35; if($a > $b){ echo "A é maior"; } elseif($a < $b) { echo "B é maior"; } else{ echo "Os dois são iguais"; } /////////////////////////////////////////////////////////// echo "<br/>"; $nome = "Adriane"; switch ($nome) { case "Adriane": echo "Rodrigues"; break; default...
true
2e0af7391e6ed862d7aa6fc79c248e43b9d33a04
PHP
edbertproject/php-dasar
/login/session/index.php
UTF-8
1,709
2.640625
3
[]
no_license
<?php require "function.php"; session_start(); if (!isset($_SESSION["login"])) { header("Location: masuk.php"); exit; } $penampung = setquery("SELECT * FROM laptop"); ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=...
true
2d4aa3c3a69bfead37b1e311d6372e82c2969432
PHP
iamevans/php_basic
/book1/1-14/class-18.php
UTF-8
743
4.0625
4
[]
no_license
<?php class MyClass { public function __set($name, $value) { echo "Setting '$name' to '$value' <br>"; } public function __isset($name) { echo "Is '$name' set? <br>"; } public function __unset($name) { echo "Unsetting '$name' <br>"; } // 접근불가 프로퍼티에 대해 isset() 나 empty() 가 호출되었을때 불려집니다. ...
true
4f029e94569bdcc56c478c8f03ed070eadeda0f6
PHP
websea/laravel-visitors-statistics
/src/Console/Commands/UpdateMaxMindDatabase.php
UTF-8
1,957
2.71875
3
[ "MIT" ]
permissive
<?php namespace Websea\LaravelVisitorsStatistics\Console\Commands; use Exception; use Illuminate\Console\Command; class UpdateMaxMindDatabase extends Command { /** * The name and signature of the console command. * * @var string */ protected $signature = 'maxmind:update {--scheduled}'; ...
true
0bd119e1aa1330e2aa5d168adafe2b3cc837bcde
PHP
nox12/Pai2019
/Repository/ParkingRepository.php
UTF-8
4,041
3.15625
3
[]
no_license
<?php require_once "Repository.php"; require_once __DIR__.'//..//Model//Parking.php'; class ParkingRepository extends Repository{ //gets all parkings data from DB public function getParkings(string $id_user): array { $parkings = []; $stmt = $this->database->connect()->prepare(' SEL...
true
5b7ce4c1f883f5a3066d5639814a5e6a8f59150a
PHP
hxxy2003/WelHair
/src/www/library/Welfony/Repository/ProductsRepository.php
UTF-8
2,776
2.78125
3
[]
no_license
<?php // ============================================================================== // // This file is part of the WelStory. // // Create by Welfony Support <support@welfony.com> // Copyright (c) 2012-2014 welfony.com // // For the full copyright and license information, please view the LICENSE // file that was di...
true
c527a982b37bf2aa9133340ade145e69de4a0eba
PHP
ArekX/html-processor
/src/Attributes/Classname.php
UTF-8
799
2.765625
3
[ "Apache-2.0" ]
permissive
<?php /** * @author Aleksandar Panic * @license http://www.apache.org/licenses/LICENSE-2.0 * @since 1.0.0 **/ namespace ArekX\HtmlProcessor\Attributes; class Classname extends Base { public function handle($attribute, $value, array $config): string { $results = []; foreach ...
true
48c3c1efa3781c8c3c12446f637adcd1c2cd7f3a
PHP
marcelhoyama/dmrimoveis
/models/cidade.php
UTF-8
2,181
2.734375
3
[]
no_license
<?php class cidade extends model { public function verificarCidade($id_estado, $cidade) { try { $sql2 = "SELECT c.id as id FROM cidades c JOIN estados e ON c.id_estado = e.id WHERE c.nome= :cidade AND c.id_estado= :id_estado"; $sql2=$this->db->prepare($sql2); $sql2->...
true
59febe9f69fa58324bcd6fb9408e93d8224c9053
PHP
LuscapLudovic/wttz-api
/src/MessageDao.php
UTF-8
2,823
2.859375
3
[]
no_license
<?php namespace SilexApi; use Doctrine\DBAL\Connection; use Doctrine\DBAL\Exception\InvalidArgumentException; class MessageDao { private $db; public function __construct(Connection $db) { $this->db = $db; } protected function getDb() { return $this->db; } public fu...
true
53d39e88bbf681c1c759f9dc28f9a72642c1bbf7
PHP
wanxiang-blockchain/hackathon2020-T11-Benefitom
/web/app/Service/TradeSetService.php
UTF-8
1,082
2.765625
3
[]
no_license
<?php /** * Created by PhpStorm. * User: johnShaw * Date: 17/7/24 * Time: 上午10:41 */ namespace App\Service; use App\Model\TradeSet; use Carbon\Carbon; class TradeSetService { /** * @desc isInTradeTime * @param $trade TradeSet || int * trade model or trade.asset_type * @return bool */ pu...
true
d86a357fc4291b5cb7bb41fcc27960b44ad0b2b4
PHP
RohitSharma0077/User-System-CodeIgniter
/application/models/File.php
UTF-8
877
2.8125
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); class File extends CI_Model{ function __construct() { $this->tableName = 'files'; } /* * Fetch files data from the database * @param id returns a single record if specified, otherwise all records ...
true
93259d9531abbd5e635d1025118834b7609aa2b6
PHP
Saaarana/CALCULO-DE-AREA-
/circulo.php
UTF-8
1,355
3.0625
3
[]
no_license
<?php // DECLARANDO VARIAVEL E DADOS $vPi = pi (); $vRaio = (float) null; $result = (float) null; // BOTAO CALC CLICADO? if(isset($_GET['btnCalc'])) { $vRaio = $_GET['text1']; // ENTRADA E ERRO DE CX VAZIA if($vRaio =='') { echo('<script> alert ("Caixa vazia não deve calcula...
true
9904a33ac599ea9b27e37e9a367b6f0802b4fe95
PHP
IlyasNurani123/excite-brand
/app/Models/Slider.php
UTF-8
551
2.53125
3
[ "MIT" ]
permissive
<?php namespace App\Models; use App\Models\Image; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Factories\HasFactory; class Slider extends Model { use HasFactory; /** * The attributes that are mass assignable. * * @var array */ protected $fillable = ['slider_t...
true
5c080143c60323c64362f588429b36089aa00558
PHP
am1081/PHPBlackjack
/Dealer.php
UTF-8
804
3
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. */ /** * Description of Dealer * * @author Andrew */ namespace Blackjack; class Dealer extends Person { ...
true
4484f81a897b77ea75edf44b490eea40961d6e96
PHP
sullivanproject/2016-PHP-with-Hyundai-High-School
/Backend/3차시/실습/ex2.php
UTF-8
269
3.6875
4
[]
no_license
<?php # 변수 설정 $variable = 15; # 만약 $variable 이 10 이상일 때 if($variable >= 10) { # $i 를 0으로 선언하고 $variable보다 작으면 안의 내용을 실행하고 1을 더함. for($i = 0;$i < $variable;$i++) { echo "Hello, World!\n"; } } ?>
true
1f2e1bb8b64237a7acd58c67f20aaf3e220ae78f
PHP
samratshamim/aBillander
/database/migrations/2014_12_13_054830_create_customer_invoice_lines_table.php
UTF-8
2,795
2.59375
3
[ "MIT" ]
permissive
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; class CreateCustomerInvoiceLinesTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::dropIfExists('customer_invoice_lines...
true
9a48e95502ab135e33a4ad7ee679b99d8da4b790
PHP
niroshansb/MandE
/convert/test/test1.php
UTF-8
180
2.53125
3
[]
no_license
<!DOCTYPE html> <html> <body> <?php #$x = 5 /* + 15 */ + 5; #echo $x; $contents = file_get_contents('/usr/local/bin/odk.sh'); echo shell_exec($contents); ?> </body> </html>
true
5af3b7fdbb3c4d47518c17277c2fe050f5a2c96e
PHP
LeonardoooCruzzz/carteira-digital-php
/lib/sets.php
UTF-8
8,534
2.96875
3
[]
no_license
<?php /** * Criado e registrado pelo desenvolvedor Leonardo Cruz. * author: Leonardo Cruz */ class sets extends conexao{ //metodos public function contruct($return = false) { if (isset($_POST['acao']) && $_POST['acao'] != '' && $return == true) { return $_POST['acao']; } ...
true
7bdee761ce2495b00fcecaaff30058d0d7a22203
PHP
ZaffJa/perbaiah
/app/Http/Requests/UpdateUser.php
UTF-8
1,418
2.53125
3
[]
no_license
<?php namespace App\Http\Requests; use Illuminate\Foundation\Http\FormRequest; use App\User; class UpdateUser extends FormRequest { /** * Determine if the user is authorized to make this request. * * @return bool */ public function authorize() { $user = User::find($this->id); ...
true
c6b8ab0442e169020621b40e4e9773fec93bd122
PHP
rodriguehee/testdeploy
/applications/copilote/tags/2015-07-22.16-00-00/library/Demande.php
UTF-8
1,663
2.6875
3
[]
no_license
<?php class Copilote_Library_Demande extends Copilote_Library_Record { /** * @var array */ protected $_depenses = array() ; /** * @var Copilote_Library_Record */ protected $_ub ; /** * @param string $tableName * @param integer $idData */ public function __construct( $tableName, $id ) { pare...
true
e02f04d8cd6a3f9b616d4255e5e67856c6065fa9
PHP
symphonists/section_schemas
/extension.driver.php
UTF-8
622
2.515625
3
[ "MIT" ]
permissive
<?php require_once EXTENSIONS . '/section_schemas/data-sources/datasource.section_schema.php'; Class Extension_Section_Schemas extends Extension { private static $provides = array(); public static function registerProviders() { self::$provides = array( 'data-sources' => array( 'SectionSchemaData...
true
ddf90e3176c0dea179a77a443542c0458e8b3411
PHP
pilau/base
/inc/users.php
UTF-8
6,330
2.75
3
[]
no_license
<?php /** * User-related functions * * @package Pilau_Base * @since 2.2 */ /** * Get all roles that can edit, create or publish posts or a certain type * * @link http://themehybrid.com/weblog/correcting-the-author-meta-box-drop-down * @since 2.2.2 * * @param string $post_type * @return array */ functio...
true
36cf46e5f9219b0834e6c963aefc9dfc675bd8b6
PHP
intersvyaz/yii-bootstrap-datetimepicker
/src/BootstrapDateTimePicker.php
UTF-8
2,257
2.625
3
[ "Apache-2.0" ]
permissive
<?php namespace Intersvyaz\Widgets; /** * DateTimePicker widget for Twitter Bootstrap. * @see https://github.com/smalot/bootstrap-datetimepicker */ class BootstrapDateTimePicker extends \CInputWidget { /** * Options for the bootstrap-datetimepicker plugin. * @var array */ public $options = []; /** * Ja...
true
73cc975efbdd4c93de27faa67aac4077010394a1
PHP
Monica-Ibtikar/monica-hyn
/app/Repositories/AbstractGenericRepository.php
UTF-8
461
2.53125
3
[]
no_license
<?php /** * Created by PhpStorm. * User: monica * Date: 11/01/21 * Time: 05:00 م */ namespace App\Repositories; use App\Repositories\Contracts\GenericRepositoryInterface; class AbstractGenericRepository implements GenericRepositoryInterface { protected $model; public function __construct($model) {...
true
968871506ae00a02eb3aa9e549cc749481941de4
PHP
trevorthornton/resource_guide_builder
/includes/models.php
UTF-8
9,067
2.859375
3
[]
no_license
<?php function get_record_by_id($table, $id) { $valid_attributes = valid_attributes($table); $query = "SELECT * FROM $table WHERE id = $id LIMIT 1"; $connection = db_connection(); if ($result = $connection->query($query)) { /* fetch associative array */ $row = $result->fetch_assoc(); ...
true
529bf9442c530029da6d698d6a5db46676fa35f9
PHP
Magneds/php-lokalise
/src/Language/Request/AddLanguageRequest.php
UTF-8
1,944
2.78125
3
[ "MIT" ]
permissive
<?php // Copyright ⓒ 2018 Magneds IP B.V. - All Rights Reserved namespace Magneds\Lokalise\Language\Request; use Magneds\Lokalise\Language\Entity\Language; use Magneds\Lokalise\Project\Entity\ProjectID; use Magneds\Lokalise\RequestInterface; use Magneds\Lokalise\ResponseInfo; use Psr\Http\Message\ResponseInterface; us...
true
cdff2542ffd5169790500f4d7f0f9cc00926b284
PHP
poojakarthik/my-work
/lib/classes/recurring/Recurring_Charge.php
UTF-8
50,169
2.65625
3
[]
no_license
<?php //----------------------------------------------------------------------------// // Recurring_Charge //----------------------------------------------------------------------------// /** * Recurring_Charge * * Models a record of the RecurringCharge table * * Models a record of the RecurringCharge table * * ...
true
e02af9b2bc7c2f6f9a031fd0e04e151b755d0902
PHP
AgustinMiguel/TPE-Web-2
/model/PlayersModel.php
UTF-8
2,049
2.890625
3
[]
no_license
<?php class PlayersModel{ function __construct(){ $this->db = new PDO('mysql:host=localhost;'.'dbname=tpe;charset=utf8', 'root', ''); } public function getPlayers(){ $sentencia = $this->db->prepare( "select * from jugadores J join equipos E on J.id_equipo = E.id_equipo"); $sentencia->execute...
true