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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
68006cee22582f7cc6c8a29ad2af117d6f11f6c5 | PHP | weibreeze/breeze-php | /src/Breeze/Types/TypeArray.php | UTF-8 | 2,605 | 2.828125 | 3 | [
"Apache-2.0"
] | permissive | <?php
/**
* Copyright (c) 2009-2019. Weibo, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless req... | true |
8fdb1557bf128b30fba602e42fa4f5588e26d8cf | PHP | ZainabImad94/E-Commerce | /admin/manage_category.php | UTF-8 | 3,825 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
require 'includes/connection.php';
if (isset($_POST['submit'])) {
# code...
#fetch data from webform
if (is_null($_GET['edit'])) {
# code...
$name = $_POST['category-name'];
$query = "insert into category(cat_name) values('$name')";
mysqli_query($conn,$query);
}
else{
# ... | true |
fe98d410437d13d3c360872a1674070d1150a912 | PHP | amin007/hacker-apps | /Aplikasi/Kelas/Kitab/Vendor/Borang/Html_Ulli.php | UTF-8 | 2,354 | 2.703125 | 3 | [] | no_license | <?php
namespace Aplikasi\Kitab; //echo __NAMESPACE__;
class Html_Ulli
{
#==========================================================================================
#------------------------------------------------------------------------------------------
public static function paparUl($senarai)
{
foreach ($senarai... | true |
139bd9a94a1e6944f100d14561f70172f92fbba0 | PHP | neojiaying/Software-Project-Management-BIOS | /app/include/protect.php | UTF-8 | 389 | 2.59375 | 3 | [] | no_license | <?php
require_once 'common.php';
$student = '';
if (isset($_SESSION['userid'])) {
$student = $_SESSION['userid'];
}
# check if the username session variable has been set
# send user back to the login page with the appropriate message if it was not
# add your code here
if (!isset($_SESSION['userid']))... | true |
d5fbc6374573bf8cc7e55aed96fa18d0427954e6 | PHP | php-lug/lug | /src/Component/Grid/Filter/Type/TextType.php | UTF-8 | 4,487 | 2.671875 | 3 | [
"MIT"
] | permissive | <?php
/*
* This file is part of the Lug package.
*
* (c) Eric GELOEN <geloen.eric@gmail.com>
*
* For the full copyright and license information, please read the LICENSE
* file that was distributed with this source code.
*/
namespace Lug\Component\Grid\Filter\Type;
/**
* @author GeLo <geloen.eric@gmail.com>
... | true |
5c2942c5a5357f575e8e8674730d22292f2bdb30 | PHP | newclass-pl/pactum | /src/Pactum/Cache/AbstractCache.php | UTF-8 | 2,143 | 2.828125 | 3 | [
"MIT"
] | permissive | <?php
/**
* Unauthorized copying of this file, via any medium is strictly prohibited
* Proprietary and confidential
* Written by Michal Tomczak <michal.tomczak@newaxis.pl>
*
* @copyright Copyright (c) Newaxis (http://newaxis.pl)
* @link https://cogitary-polisy.aria.pl
* @license http://www.bin... | true |
b7fdde54183500c86894011330b109821142387a | PHP | qaz734913414/PHP_Plugins | /plugin84.php | UTF-8 | 1,056 | 2.984375 | 3 | [] | no_license | <?php // 插件84:保护Email
/***************
*Owner: 水木
*Licence: GPL
*Description:
*PHP功能插件开发应用
*Blog: www.4u4v.net
*Email: admin@4u4v.net
**********************/
$email = 'admin@4u4v.net';
$pemail = DOPHP_ProtectEmail($email);
echo "My email address is $pemail";
function DOPHP_ProtectEmail($email)
{
/*
插件说明:
插件接... | true |
0955ec61c3fc87908ee48ba5e3da3110b6577773 | PHP | Yasmanis/send_email | /app/Listeners/SendNotificationPadres.php | UTF-8 | 810 | 2.578125 | 3 | [] | no_license | <?php
namespace App\Listeners;
use App\User;
use App\Notifications\SendNotification;
use App\Events\CorreoPadres;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Contracts\Queue\ShouldQueue;
class SendNotificationPadres implements ShouldQueue
{
/**
* Create the event listener.
*
* @return ... | true |
9707d29896444ad0e910bacd394bc2a49b8707f7 | PHP | trungkien12/project--ttu | /src/models/userModel.php | UTF-8 | 736 | 2.84375 | 3 | [] | no_license | <?php
class UserModel extends DB {
public function InsertNewUser($fullname, $email, $username, $password, $location) {
$qr = "INSERT INTO users VALUE(null, '$fullname', '$email', '$username', '$password', '$location')";
$result = false;
if(mysqli_query($this->con, $qr)){
... | true |
93f4b16074b9199d9efe8372a83ceb2d45981fc4 | PHP | Nhocden/bai-tap-PHP | /lab5/exercise.php | UTF-8 | 2,173 | 3.078125 | 3 | [] | no_license | <?php
class Page {
private $page = "";
private $title = "";
private $year;
private $copyright = "";
public function getPage(){
return $this->page;
}
public function setPage($page){
$this->page = $page;
}
... | true |
6c0d5172dbe336aebd2cf74f4d60239b53032eea | PHP | valdineireis/php-hmvc-example | /infra/models/Venda.php | UTF-8 | 3,036 | 2.796875 | 3 | [] | no_license | <?php
class Venda extends Entity implements EntityContract
{
private $valor;
private $status_pagamento;
private $link_pagamento;
private $uf;
private $cep;
private $cidade;
private $bairro;
private $logradouro;
private $numero;
private $complemento;
private $dh_cadastro;
private $tipoPagamento;
private... | true |
0e23ce446402e9b31620ea62e8fb1397c01cf79d | PHP | lecongngan/NganBK | /001/index11.php | UTF-8 | 1,098 | 3.609375 | 4 | [] | no_license | <!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>
<body>
... | true |
1ae85c9a080534a8b21ba7c92aa76e60d2148828 | PHP | qingchoulove/qfnu_server | /controllers/ClazzController.php | UTF-8 | 1,276 | 2.765625 | 3 | [] | no_license | <?php
namespace controllers;
use common\exceptions\FieldNotValidException;
use services\ClazzService;
use Slim\Http\Request;
use Slim\Http\Response;
use validators\ClazzValidator;
/**
* Class ClazzController
* @package controllers
* @property ClazzService clazzService
*/
class ClazzController extends BaseControl... | true |
ea864bd145616fbfc73cc61eda7407df13f3fff1 | PHP | viviniko/promotion | /src/Enums/CouponFormat.php | UTF-8 | 1,302 | 2.78125 | 3 | [] | no_license | <?php
namespace Viviniko\Promotion\Enums;
class CouponFormat
{
const ALPHANUMERIC = 'alphanum';
const ALPHABETICAL = 'alpha';
const NUMERIC = 'num';
private static $formats = [
self::ALPHANUMERIC => '字母数字',
self::ALPHABETICAL => '字母',
self::NUMERIC => '数字'
... | true |
f85d624ecbe6a0d9439a489805dce18da28c7566 | PHP | bimalsharma1443/asgardcms_demo | /Modules/EmailTemplateManagement/Database/Seeders/EmailTemplateManagementDatabaseSeeder.php | UTF-8 | 787 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php namespace Modules\Emailtemplatemanagement\Database\Seeders;
use Illuminate\Database\Seeder;
use Illuminate\Database\Eloquent\Model;
use Modules\EmailTemplateManagement\Repositories\Email_TemplateRepository;
class EmailTemplateManagementDatabaseSeeder extends Seeder {
private $emailtemplatemanagement;
p... | true |
b3272137e0a69d447e17a840417be2914ba33608 | PHP | ElliotSanchez/mSchoolOnline | /module/Admin/src/Admin/Mclass/Service.php | UTF-8 | 6,030 | 2.703125 | 3 | [] | no_license | <?php
namespace Admin\Mclass;
use Admin\ModelAbstract\ServiceAbstract as ServiceAbstract;
use Admin\Mclass\Table as MclassTable;
use Admin\Mclass\Entity as Mclass;
use Admin\Account\Entity as Account;
use Admin\School\Entity as School;
use Admin\School\Service as SchoolService;
use Admin\MclassStudent\Service as Mcla... | true |
d5723efdcf20cb494d77c28bd24647219a4cdfbc | PHP | YoheiTakada-p/practice01 | /testhtml01/index.php | UTF-8 | 870 | 2.71875 | 3 | [] | no_license | <?php
function visitedCountFunc()
{
if ($_COOKIE) {
return $_COOKIE['visited'];
} else {
return '0';
}
};
$visitedCount = visitedCountFunc();
setcookie('visited', $visitedCount + 1, time() + 1000);
echo $visitedCount + 1;
// header("Location: http://localhost/test/sample.php", true, 301)... | true |
fb9c81e428bdd372ebc779142986297fa9f29bf7 | PHP | oal/babble | /src/Config.php | UTF-8 | 972 | 2.921875 | 3 | [
"Apache-2.0"
] | permissive | <?php
namespace Babble;
use Symfony\Component\Yaml\Yaml;
class Config
{
private $config;
public function __construct(string $currentHost)
{
$config = Yaml::parse(file_get_contents(absPath('config.yaml')));
$this->initForHost($currentHost, $config);
}
private function initForHos... | true |
06d9744908ea8c31062f4e8978b03b96d441689c | PHP | elizabethcnfortunato/controle-de-estoque | /rascunho/inicial.php | UTF-8 | 1,099 | 3.078125 | 3 | [
"MIT"
] | permissive | //Conexão com o Banco
<?php
$servidor = "localhost";
$usuario = "root";
$senha = "";
$banco="music";
$conecta = mysqli_connect($servidor,$usuario,$senha,$banco);
if(mysqli_connect_errno()){
die("Conexão falhou: ".mysqli_connect_errno());
}else{
echo "Conectou com Sucesso";
}
?>
/... | true |
b8ada224d3f229ba2dd65fcbc33fd96fc18b588b | PHP | iskanderjaiem/Rental-Management | /src/svplocation/AdminBundle/Entity/Entrepot.php | UTF-8 | 2,347 | 2.59375 | 3 | [
"BSD-3-Clause",
"MIT"
] | permissive | <?php
namespace svplocation\AdminBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* Entrepot
*
* @ORM\Table(name="entrepot")
* @ORM\Entity
*/
class Entrepot {
/**
* @var integer
*
* @ORM\Column(name="id_entrepot", type="integer", nullable=false)
* @ORM\Id
* @ORM\GeneratedValue(s... | true |
da50082c2c7a400908d0eba2552007fc1d835890 | PHP | Maximetr/gcras-web | /models/Admin.php | UTF-8 | 1,631 | 2.765625 | 3 | [] | no_license | <?php
class Admin {
public static function selectAll($connect, $userID) {
$users = array();
$sql = "SELECT UserID, Email, InsertRights, AdminRights FROM UsersToDownload WHERE UserID <> $userID";
$query = mysqli_query($connect, $sql);
while ($result = mysqli_fetch_array($query, MYS... | true |
3f0b49665a5e8843afe6232527175146e7ad05bb | PHP | viktor8881/vl2 | /module/Course/src/View/Helper/ThreeBottomTableStock.php | UTF-8 | 1,809 | 2.703125 | 3 | [] | no_license | <?php
namespace Course\View\Helper;
use Analysis\Entity\MoexFigureAnalysis;
use Analysis\Entity\MoexPercentAnalysis;
use Course\Entity\MoexCacheCourse;
use Zend\View\Helper\AbstractHelper;
class ThreeBottomTableStock extends AbstractHelper
{
const MINIMUM_PERFORMANCE_VALUE = 30;
public function __invoke(arr... | true |
958297d6a6e909073ed4202339531d8679129145 | PHP | Stephennew/eleb_front | /app/Http/Controllers/AddressController.php | UTF-8 | 4,877 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use App\Model\Address;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\DB;
use Validator;
use Illuminate\Http\Request;
class AddressController extends Controller
{
public function addAddress(Request $request)
{
/*
* /**
* nam... | true |
ceb0b3d8dd98ee7491d5fb014258bc2dcc364d1e | PHP | hasibaahmadi/Zakira | /application/models/student_model.php | UTF-8 | 1,396 | 2.53125 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
class student_model extends CI_model{
function __construct(){
parent::__construct();
$this->load->database();
}
public function get_student($limit,$offset){
return $this->db->get('student',$limit,$offset)->result();
}
public function save_student($data){
re... | true |
126a13a125d289853a563a15974b472b27d2b020 | PHP | KristofferRisa/WEB1000-Exam | /vedlikehold/Bestillinger/endre.php | UTF-8 | 9,590 | 2.546875 | 3 | [] | no_license | <?php
$title = "FLY - Admin";
//Includes
include('./../html/start.php');
include('./../html/header.html');
include('./../html/admin-start.html');
include('../php/Bestilling.php');
$bestillinger = new Bestilling();
$responseMsg = "";
//RegEx pattern
$brukernavnPattern = "/^[A-Za-z0-9]{2,}$/";
$navnPattern = "/^[A-Z... | true |
0615d60a85bf768d80d61dd6ae0c7dd5fc618ec8 | PHP | claremontdesign/zbase | /src/Ui/Form/Type/Checkbox.php | UTF-8 | 2,898 | 2.703125 | 3 | [] | no_license | <?php
namespace Zbase\Ui\Form\Type;
/**
* Zbase-Form Element-Checkbox
*
* Element-Checkbox
*
* @link http://zbase.dennesabing.com
* @author Dennes B Abing <dennes.b.abing@gmail.com>
* @license proprietary
* @copyright Copyright (c) 2016 ClaremontDesign/MadLabs-Dx
* @file Checkbox.php
* @projec... | true |
fb0472cd09986331da760a6812935b3959b2ff18 | PHP | lmc-eu/matej-client-php5 | /src/Model/Command/UserMerge.php | UTF-8 | 2,284 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
namespace Lmc\Matej\Model\Command;
use Lmc\Matej\Model\Assertion;
/**
* Take all interactions from the source user and merge them to the target user.
* Source user will be DELETED and unknown to Matej from this action.
*/
class UserMerge extends AbstractCommand implements UserAwareInterface
{
/** @var s... | true |
5898ca005015d02d6b651ea7b659238629a1d886 | PHP | viktor8881/vl2 | /module/Analysis/src/Entity/TaskAnalysis.php | UTF-8 | 4,603 | 2.796875 | 3 | [] | no_license | <?php
namespace Analysis\Entity;
use Course\Entity\ICourse;
use Doctrine\ORM\Mapping as ORM;
use Base\Entity\AbstractEntity;
use Course\Entity\Course;
use Doctrine\Common\Collections\ArrayCollection;
use Exchange\Entity\Exchange;
/**
* @ORM\Entity
* @ORM\Table(name="task_analysis")
* @ORM\InheritanceType("SINGLE_T... | true |
0802343d365d6665f780e24e8b9d9cbed751c44c | PHP | KNIGHTTH0R/news-scraper | /app/Http/Controllers/IndexController.php | UTF-8 | 1,389 | 2.53125 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use App\Contracts\BBCNewsServiceInterface;
use App\Contracts\HackerNewsServiceInterface;
use App\Contracts\NewsScraperServiceInterface;
use App\Contracts\SlashDotCrawlerServiceInterface;
class IndexController extends Controller
{
public function index(NewsScraperServiceInter... | true |
a072376bc1a8a5104c42880176d8d4b72b52664c | PHP | Shadowsun52/DubInfo_Gestion_immobilier | /data/DAOProjet.php | UTF-8 | 10,165 | 2.90625 | 3 | [] | no_license | <?php
namespace DubInfo_gestion_immobilier\data;
use DubInfo_gestion_immobilier\model\Projet;
use DubInfo_gestion_immobilier\model\Investisseur;
use DubInfo_gestion_immobilier\model\Maison;
use DubInfo_gestion_immobilier\model\Etat;
use DateTime;
/**
* Description of DAOProjet
*
* @author Jenicot Alexandre
*/
clas... | true |
bb339a04bbaca4dced59166bf1947ff44a99a5e6 | PHP | kschat/genassem | /core/Model.class.php | UTF-8 | 264 | 2.9375 | 3 | [] | no_license | <?php
class BaseModel {
private $args;
public function __construct(array $args = array()) {
$this->args = $args;
}
public function __get($name) {
return $this->args[$name];
}
public function __set($name, $value) {
$this->args[$name] = $value;
}
} | true |
43abc6072decb09b898037a3957f3f90a5b0c63f | PHP | dariobennaia/api-testepratico | /app/Http/Controllers/Refrigerantes/LitragensRefrigerantesController.php | UTF-8 | 897 | 2.59375 | 3 | [] | no_license | <?php
namespace App\Http\Controllers\Refrigerantes;
use App\Http\Controllers\Controller;
use App\Services\Refrigerantes\LitragensRefrigerantesService;
class LitragensRefrigerantesController extends Controller
{
/**
* @var LitragensRefrigerantesService
*/
private $litragensRefrigerantesService;
... | true |
01c20c2961b3b896bf54002441a98bef67b40104 | PHP | leuchtdiode/zend3-ecommerce | /src/Customer/Auth/ForgotPasswordMailPlaceholderValues.php | UTF-8 | 1,034 | 2.796875 | 3 | [] | no_license | <?php
namespace Ecommerce\Customer\Auth;
use Common\Util\ArrayCreator;
use Ecommerce\Customer\Customer;
use Mail\Mail\PlaceholderValues;
class ForgotPasswordMailPlaceholderValues implements PlaceholderValues
{
/**
* @var Customer
*/
private $customer;
/**
* @var string
*/
private $hash;
/**
* @return... | true |
660e67e55f26fdd0fd871270f213d59ce823e281 | PHP | meinfernbus/zf2 | /library/Zend/Form/Fieldset.php | UTF-8 | 8,706 | 2.890625 | 3 | [
"LicenseRef-scancode-warranty-disclaimer"
] | no_license | <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license an... | true |
7a6d5a7ddf21f21ce71ec984e0f303d5d9f27e7f | PHP | chemisus/tessa | /src/Tessa/Asset.php | UTF-8 | 1,774 | 2.75 | 3 | [] | no_license | <?php
namespace Tessa;
class Asset
{
private $root;
public function __construct($root)
{
$this->root = $root;
}
function glob_recursive($pattern, $flags = 0)
{
$files = glob($pattern, $flags);
foreach (glob(dirname($pattern) . '/*', GLOB_ONLYDIR | GLOB_NOSORT) as $dir... | true |
5a38ad3acab2800dd80e08b281513ff1fd7099a7 | PHP | crojasaragonez/todo | /app/controllers/TasksController.php | UTF-8 | 2,310 | 2.96875 | 3 | [] | no_license | <?php
class TasksController extends \BaseController {
protected $task;
function __construct(Task $task) {
$this->task = $task;
}
/**
* Display a listing of the resource.
*
* @return Response
*/
public function index()
{
$tasks = $this->task->all();
return $this->response($tasks, self::O... | true |
6d67d6870d7c1a489250aa0c97387fb2083602bf | PHP | renatocosta/Experimental-Agence | /bundle/Backoffice/Client/Application/Command/Handler/QueryClientByPerformanceCommandHandler.php | UTF-8 | 693 | 2.71875 | 3 | [] | no_license | <?php
namespace Backoffice\Client\Application\Command\Handler;
use Backoffice\Client\Domain\Repositories\ClientByPerformanceRepository;
use Backoffice\Client\Application\Command\QueryClientByPerformanceCommand;
class QueryClientByPerformanceCommandHandler {
private $repository;
/**
*
* @param Cl... | true |
0426a881a741dae56fab92931e7108fdee52bd82 | PHP | andrescontreras/ProyectoPHP | /controlador/c_visitante.php | UTF-8 | 2,285 | 2.625 | 3 | [] | no_license | <?php
include_once("../modelo/m_banco.php");
include_once("../modelo/m_credito.php");
include_once("../modelo/m_c_ahorro.php");
include_once("c_correo.php");
class c_visitante
{
//Solicitar un nuevo credito
public static function solicitarCredito($monto,$correo,$cedula)
{
$consulta = m_banco::getDatosBanco();... | true |
644569b537c4ac40186597ef3527731002ffa7a1 | PHP | rdohms/dms-filter | /src/DMS/Filter/Filters/Laminas.php | UTF-8 | 1,529 | 2.703125 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace DMS\Filter\Filters;
use DMS\Filter\Exception\InvalidZendFilterException;
use DMS\Filter\FilterInterface;
use DMS\Filter\Rules\Laminas as LaminasRule;
use DMS\Filter\Rules\Rule;
use ReflectionException;
use ReflectionMethod;
use function class_exists;
use function sprintf;
use... | true |
d026a20435935b4a6677cbdfe3c0cfef57cb9cee | PHP | Usocrate/em | /topic_remove.php | UTF-8 | 2,723 | 2.609375 | 3 | [] | no_license | <?php
require_once './classes/System.class.php';
$system = new System('./config/host.json');
if (! $system->configFileExists()) {
header('Location:' . $system->getConfigUrl());
exit();
}
include_once './inc/boot.php';
session_start();
$topic = new Topic($_REQUEST['topic_id']);
$topic->hydrate();... | true |
7da76c25e6bb5728607d40736188d50918a1f600 | PHP | kartenmacherei/cqrs-framework | /src/Library/File/File.php | UTF-8 | 1,507 | 3.203125 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
namespace Kartenmacherei\CQRSFramework\Library\File;
class File
{
/**
* @var Directory
*/
private $directory;
/**
* @var FileName
*/
private $fileName;
/**
* @param Directory $directory
* @param FileName $fileName
*/
public function __construct(Direct... | true |
2fd05383c18b7308cdccf44f0b379114ef231575 | PHP | joaosolution/solutiondash | /app/Database/Migrations/2021-10-04-014025_UsuariosMenus.php | UTF-8 | 961 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Database\Migrations;
use CodeIgniter\Database\Migration;
class UsuariosMenus extends Migration
{
public function up()
{
$this->forge->addField([
'id_login_menu' => [
'type' => 'INT',
'constraint' => 9,
'usigned' => true,
'auto_increment' => true,
],
'login_id' =... | true |
21150659c78143a04c4628e2c2f4a46c41b8b066 | PHP | Victoriaff/Trends | /core/view/view.php | UTF-8 | 3,512 | 2.65625 | 3 | [] | no_license | <?php
namespace trends\view;
/**
* Anything to do with templates
* and outputting client code
**/
class view {
/**
* Load view. Used on back-end side
*
* @throws \Exception
**/
function load( $path = '', $data = array(), $return = false, $base = null ) {
if ( is_null( $base ) ) {
$base = get_st... | true |
1d4595c4aa2e5055c55ff7edc5feb4a93a542422 | PHP | 1984xunhuan/ei | /app/models/BaseDAO.class.php | UTF-8 | 2,710 | 2.8125 | 3 | [] | no_license | <?php
class BaseDAO {
protected static $db_dburl;
protected static $db_dbname;
protected static $db_username;
protected static $db_password;
protected static $db_charset;
protected $db;
function __construct()
{
$this->get_db_info();
//$this->init_db();
}
function __destruct()
{... | true |
70ee1100b08959cd008abb15f127202502ff5236 | PHP | EstevanLJ/desing-pattern | /app/Aluno.php | UTF-8 | 1,121 | 2.625 | 3 | [] | no_license | <?php
namespace App;
use App\Events\AlunosCacheHit;
use App\Events\AlunosCacheMissed;
use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Log;
use Illuminate\Support\Facades\Cache;
use Illuminate\Database\Eloquent\Model;
class Aluno extends Model
{
public $fillable = ['nome', 'cidade'];
p... | true |
809cac27879ed9d8a022b536042949d564037775 | PHP | joel123vilca/gallery-back | /app/Http/Controllers/DocumentsController.php | UTF-8 | 3,941 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Http\Resources\DocumentResource;
use Illuminate\Support\Facades\Schema;
use App\Models\Document;
use Storage;
class DocumentsController extends Controller
{
/**
* Store a newly created resource in storage.
*
* @param \Illu... | true |
24c4ed0d811f34288ca8a68c7bfceed290bcd93b | PHP | 649397821/fundata-php-sdk | /src/Request/Traits/AuthTrait.php | UTF-8 | 1,824 | 2.6875 | 3 | [
"MIT"
] | permissive | <?php
namespace Varena\SDK\Request\Traits;
use Varena\SDK\Request\Helper\UniqueRequest;
trait AuthTrait
{
/**
* 设置当前auth_headers
* @param string $key
* @param string $uri
* @param array $params
* @param string $secert
*/
private function setExtraRequestOptions(string $key,string... | true |
a96697fb4230e5ff9d71136ec3344b59c5cd1c4a | PHP | Mugenzo/laravel-shopping-cart | /src/CanBeBought.php | UTF-8 | 1,172 | 2.90625 | 3 | [] | no_license | <?php
namespace Mugenzo\LaravelShoppingCart;
trait CanBeBought {
/**
* Get the identifier of the Buyable item.
*
* @param null $options
*
* @return int|string
*/
public function getBuyableIdentifier( $options = null ) {
return method_exists( $this, 'getKey' ) ? $this->get... | true |
3daf73e558a16ff49ad3ea20121c27bb5bcd18e5 | PHP | xiaocaigua/pay | /src/WeChat/RequestBean/Pos.php | UTF-8 | 1,349 | 2.65625 | 3 | [] | no_license | <?php
/**
*
* Copyright EasySwoole
* User: hanwenbo
* Date: 2019-02-17
* Time: 13:24
*
*/
namespace EasySwoole\Pay\WeChat\RequestBean;
class Pos extends Base
{
protected $trade_type = 'MICROPAY';
/**
* @var string
*/
protected $out_trade_no;
/**
* @var string
*/
protected $total_fee;
/**
* @... | true |
83e57db3eb436200efe06727f0f3fe7c5ffec4ab | PHP | Pawel9903/weather-api | /src/Core/Dao/Table/TableInterface.php | UTF-8 | 316 | 2.53125 | 3 | [] | no_license | <?php declare(strict_types=1);
namespace App\Core\Dao\Table;
use App\Core\Dao\DaoCollectionInterface;
/**
* Interface TableInterface
* @package App\Core\Dao\Table
*/
interface TableInterface
{
/**
* @return DaoCollectionInterface
*/
public function getDaoInstance(): DaoCollectionInterface;
} | true |
108ab6b7ad64f4f0febb4abbb029c6bacc46bdd5 | PHP | charles-owen/interact-cl | /src/Interact/InteractEmail.php | UTF-8 | 6,928 | 2.828125 | 3 | [
"MIT"
] | permissive | <?php
/**
* @file
* Class that manages Interact! system email
*/
namespace CL\Interact;
use CL\Site\Site;
use CL\Users\User;
use CL\Site\Email;
use CL\Course\Members;
use CL\Course\Member;
/**
* Class that manages Interact! system email
*/
class InteractEmail {
/**
* Constructor
*/
public function __cons... | true |
6d0dda9e96592af42c5f5f182361bf274c9f958f | PHP | haloalfii/SistemNilai-PhpNative | /proses.php | UTF-8 | 4,990 | 2.8125 | 3 | [] | no_license | <?php
class Siswaku {
public $siswaku;
public $pdo;
public function __construct(){
$host="localhost";
$database="sekolahfinal";
$user="root";
$password="";
$this->pdo = new PDO("mysql:host={$host};dbname={$database}", $user, $passw... | true |
48528de23ff266766b29be2fb3ad7025c4f4755d | PHP | tendo123/tienda-php | /controllers/productoController.php | UTF-8 | 4,314 | 2.578125 | 3 | [] | no_license | <?php
require_once 'models/producto.php';
class productoController {
public function index() {
$producto = new Producto();
$productos = $producto->random(6);
require_once 'views/producto/destacado.php';
}
public function ver() {
if (isset($_GET['id'])) {
$id =... | true |
bf8ae5a36f7c16d044a6bbe775206da25cd145c5 | PHP | StefanB997/rdws | /rdws4.1.php | UTF-8 | 183 | 2.9375 | 3 | [] | no_license | <?php
function parnost($broj){
return ($broj % 2);
}
function dolzina(){
$dolzina = strlen($string);
if($dolzina > 5){
return true;
}else{
return parnost($dolzina);
}
}
?> | true |
0f844a49c9f02148fecea4a3b771cefa25a9fde9 | PHP | yangruofeng/wechat | /microbank/class/passbook/trading/client.withdraw.by.cash.trading.class.php | UTF-8 | 2,146 | 2.953125 | 3 | [] | no_license | <?php
class clientWithdrawByCashTradingClass extends tradingClass {
private $client_savings_passbook;
private $cashier_user_id;
private $amount;
private $multi_currency;
public function __construct($clientSavingsPassbook, $cashierUserId, $amount = null, $currency = null, $multi_currency = array())... | true |
eacdf19d1f48647fcbbbaf02c87c464214633f2b | PHP | manmath/elections | /application/helpers/utility_helper.php | UTF-8 | 1,157 | 2.515625 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
defined('BASEPATH') OR exit('No direct script access allowed');
if (! function_exists('alert_message')) {
/**
* @param $message
* @param string $type
* @return string
*/
function alert_message($message, $type = 'success') {
$icon = ($type == 'success') ? 'ok-circle' : (($type == 'danger') ? 'remove-c... | true |
e9ae239feab4e9f16dcd03a296f0b634671749d5 | PHP | primephp/framework | /Console/stubs/config/database.php | UTF-8 | 3,064 | 2.703125 | 3 | [
"MIT"
] | permissive | <?php
$database['default'] = [
/*
|-------------------------------------------------------------------------
| Drive de Conexão
|-------------------------------------------------------------------------
|
| Define o drive de conexão à base de dados, os valores aceitos são:
| pgs... | true |
7c144d5c7c788223453f5dac12af0579b7a11210 | PHP | dbierer/zend-expressive-generic-api-backend | /src/Common/src/Table/Legacy/SiteInfo.php | UTF-8 | 731 | 2.640625 | 3 | [] | no_license | <?php
namespace Common\Table;
/**
* Models a single row from this database table:
*
CREATE TABLE `site_info` (
`SiteInfoID` int(11) NOT NULL,
`Name` varchar(255) DEFAULT NULL,
`Url` varchar(255) DEFAULT NULL,
`LogoImage` varchar(255) DEFAULT NULL,
`GoogleAnalyticsCode` text
) ENGINE=MyISAM DEFAULT CHARSET=... | true |
2480d319efab929634a0894abedee9989c1f3393 | PHP | ysbaddaden/misago | /lib/Test/Unit/AutoRunner.php | UTF-8 | 662 | 2.6875 | 3 | [
"MIT"
] | permissive | <?php
namespace Test\Unit;
class AutoRunner
{
static $has_run = false;
function __destruct() {
static::run();
}
static function run($name='AutoRunner')
{
if (static::$has_run) return;
$suite = new TestSuite($name);
$class_names = get_declared_classes();
foreach($class_name... | true |
aeecbb63b0de21b27938bca34d2963998e905163 | PHP | devtoolboxuk/engrafo | /library/ArchiveService.php | UTF-8 | 1,042 | 2.78125 | 3 | [
"MIT"
] | permissive | <?php
namespace devtoolboxuk\engrafo;
use ZipArchive;
class ArchiveService extends AbstractFileService
{
private $archive;
public function __construct($options)
{
parent::__construct($options);
$this->archive = new ZipArchive();
}
public function archiveFile($file, $archiveName ... | true |
c2a0535d6cab25958a49b79c2c90efd47f6f673a | PHP | xBajci/nette-workshop | /app/modules/Front/ArticlePresenter.php | UTF-8 | 1,157 | 2.609375 | 3 | [] | no_license | <?php
namespace App\Front\Presenters;
use Nette,
App\Model;
/**
* Homepage presenter.
*/
class ArticlePresenter extends BasePresenter
{
/** @var Model\ArticleFacade @inject */
public $facade;
const ARTICLES_PER_PAGE = 5;
function renderList($page = 1)
{
if ($page < 1) {
$this->redirect('list'); // ... | true |
08e9e87b1cff2c437ad514458d7aef8c1c5bf2a8 | PHP | maieasylife/Cash-Counter | /calculate.php | UTF-8 | 696 | 2.703125 | 3 | [] | no_license | <?php
// $_Cash (array)
include("cashdata.php");
// extend cashdata for zero values
$_Cash["0.00"] = array("weight" => 0.00);
$_Value = "0.00";
$_Input = "0.00";
$_Type = "count";
if(!empty($_POST["value"])) {
$_Value = $_POST["value"];
}
if(!empty($_POST["input"])) {
$_Input = $_POST["input"]; ... | true |
fe777f2a8079ba66a0a480c5a3517628ae09deec | PHP | p0s1t/Opero | /insertFave.php | UTF-8 | 794 | 2.640625 | 3 | [] | no_license | <?php
$jobID = $_POST['jID'];
$memberID = $_POST['mID'];
makeFavorite($memberID, $jobID);
function makeFavorite($memberID, $jobID){
$connect = mysql_connect('localhost', 'a', $login_id);
$i = 0;
$db = mysql_select_db('jobs', $connect);
/*
$faveIDQuery = "SELECT MAX(faveID) FROM favorites";
$fqResult = m... | true |
3b4197f066726d67667f94ceb87dab4d47427ca6 | PHP | eberfreitas/dbl | /src/Column.php | UTF-8 | 813 | 3.15625 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace Dbl;
class Column
{
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $type;
/**
* @var bool
*/
public $null;
/**
* @var int|null
*/
public $length;
/**
* @var array
*/
... | true |
656d8469aad9a9309b426ff46ec0da974c4a1739 | PHP | OlehPetryna/fluffy-hospital-app | /back/middlewares/ModelSorter.php | UTF-8 | 937 | 2.6875 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace app\middlewares;
use http\Exception\InvalidArgumentException;
use Slim\Http\Request;
use Slim\Http\Response;
class ModelSorter
{
private $sortParamName = 'sort-attribute';
private $sortDirectionName = 'sort-dir';
private $directions = [1 => 'ASC',... | true |
cd475868458e8bf92062decedc06b05f9e458f96 | PHP | geangontijo/Instagram-clone-PHP-MVC | /src/Database/Conexao.php | UTF-8 | 334 | 2.84375 | 3 | [] | no_license | <?php
namespace Inst\Database;
abstract class Conexao
{
static public function getConexao():\PDO
{
try {
$rootDir = __DIR__ . '/database.sqlite';
return new \PDO('sqlite:'. $rootDir);
}catch (\PDOException $exception){
var_dump($exception->getMessage());
... | true |
5eeabd0acb686c61bf16e0066c5a17adbe13bfec | PHP | EdwinRoelandt/MVC-EDWIN | /public/pages/suppression.php | UTF-8 | 2,534 | 2.640625 | 3 | [] | no_license | <?php
require 'public/functions/bdd.php';
require 'public/class/user-class.php';
?>
<?php
$login = $_SESSION['id_user'];
$id=$_GET['id'];
$userManager = new UserManager($bdd);
$myUser=$userManager->get($id);
?>
<div class="container-fluid">
<?php
if($login==$id)
{
?>
... | true |
42aca9d061aa36576821f28d5c7d33cbd29557c0 | PHP | kehindealade/radiant-minds-schools | /app/Http/Controllers/AcademicSessionController.php | UTF-8 | 2,597 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use App\Models\AcademicSession;
use Illuminate\Http\Request;
use Illuminate\Validation\Rule;
class AcademicSessionController extends Controller
{
private function validateAcademicSession($request, $academicSession = null)
{
$messages = [
'name.require... | true |
532c6d0f3a66e1240b64b842a56703d25ba1efa3 | PHP | apaire/pro_gesco | /htdocs/progesco/communs/creation_db.php | UTF-8 | 592 | 2.515625 | 3 | [] | no_license | <h3 class="center">C'est la première utilisation du logiciel sur cet ordinateur</h3>
<?php
// Création de la base de données
$query = "CREATE DATABASE cneac DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci";
if (mysql_query($query)){
echo "<p class='center'>La base de données 'cneac' a été créée</p>";
mysql_s... | true |
8b96cb2f27836c5b97de7bc33f4ef480a833df2a | PHP | kasa2001/Programming-Course | /app/lib/built/collection/collection.php | UTF-8 | 5,441 | 3.125 | 3 | [] | no_license | <?php
namespace Lib\Built\Collection;
/**
* Abstract collection class
*
* @author Paweł Gomółka (kasa2001) <pawelgomolka@interia.pl>
* @version 0.1
* @since 1.0
* @todo change _getError method
* @package Lib\Build\Collection
* */
abstract class Collection implements \JsonSerializable, \Countable
{
const W... | true |
621ac9816eab874b62d62f495fea50cf90a5d5ca | PHP | strix-community/core | /src/Models/Comment/Comment.php | UTF-8 | 2,779 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
/*
* This file is part of Strix.
*
* For detailed copyright and license information, please view the
* LICENSE file that was distributed with this source code.
*/
namespace Strix\Models\Comment;
use Illuminate\Database\Eloquent\Model;
use Strix\Traits\Models\HasNanoId;
/**
* Strix\Models\Comment\Comment... | true |
ba97a7527815f44e6753df4c58d8164529976017 | PHP | yoperiquoi/Odot | /modele/Modele.php | UTF-8 | 2,744 | 2.859375 | 3 | [] | no_license | <?php
namespace modele;
use DAL\ListeGateway;
use DAL\TacheGateway;
use DAL\UtilisateurGateway;
class Modele
{
private $UtilisateurGateway;
private $ListeGateway;
private $TacheGateway;
public function __construct()
{
$this->UtilisateurGateway = new UtilisateurGateway();
$this->T... | true |
1b67e66955c059e8b3a314f9d381c24bc748f4f5 | PHP | butschster/sputnik | /domain/SSH/Bash/SshKeygen.php | UTF-8 | 887 | 2.6875 | 3 | [] | no_license | <?php
namespace Domain\SSH\Bash;
use Domain\SSH\Contracts\ProcessExecutor;
use Domain\SSH\Shell\Response;
use Symfony\Component\Process\Process;
class SshKeygen
{
/**
* @var ProcessExecutor
*/
protected $executor;
/**
* @param ProcessExecutor $executor
*/
public function __constr... | true |
594329f0928c13b404db5005d402f9cb5d0934f0 | PHP | Praktika-magazin/practice | /index_post_admin.php | UTF-8 | 2,817 | 2.734375 | 3 | [] | no_license | <?php
include 'connect.php';
if (isset($_GET['del_id']))
{
$sql_delete = "DELETE FROM post WHERE id_post = {$_GET['del_id']}";
$result_delete = mysqli_query($link, $sql_delete);
if ($result_delete)
{
header('Location: index.php');
}
else
{
echo '<p>Произошла ошибка: '.mysqli_error($link).'</p>';
... | true |
f49038ab9cffd90a601172c532626b45a3bc6cf5 | PHP | Nornu/portfolio | /css/contact-form.php | UTF-8 | 5,895 | 2.75 | 3 | [] | no_license | <?php
/*
Template Name: Contact Form
*/
?>
<?php
//If the form is submitted
if(isset($_POST['submitted'])) {
//Check to see if the honeypot captcha field was filled in
if(trim($_POST['checking']) !== '') {
$captchaError = true;
} else {
//Check to make sure that the name field is not... | true |
fa98c8988ced3088cdf69373835be9a3695c698f | PHP | Deparagon/jammytech | /app/Social.php | UTF-8 | 903 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class Social extends Model
{
//
public function user()
{
return $this->belongsTo('App\User');
}
public static function getSocial($userid, $type ='Facebook')
{
return self::where(['user_id' => $userid, 'socialtype' =... | true |
0a8ab5e77f381565cf52def9e60ad2d78380454f | PHP | yutthapichai/Test_Inventory | /model/connect.php | UTF-8 | 2,047 | 2.796875 | 3 | [] | no_license | <?php
date_default_timezone_set("Asia/Phnom_Penh");
class db{
public function mysqlconnect($host,$username,$password,$dbname){
$connect = mysqli_connect($host,$username,$password,$dbname);
return $connect;
}
public function mysqlshowrow($connect,$table,$event){
if($event != NULL){
... | true |
c0a0154a55dde3934663f2e695b957d090c9b10e | PHP | web-kuznec/raduga | /application/classes/Controller/Static/Images.php | UTF-8 | 3,784 | 2.65625 | 3 | [] | no_license | <?php defined('SYSPATH') or die('No direct script access.');
class Controller_Static_Images extends Controller
{
/**
* Метод ресайзит изображение
* @param varchar $outfile - имя нового изображения с полным путем
* @param varchar $infile - имя исходного изображения с полным путем
* @param int $n... | true |
57ec07f175739915dd65401d3b93ec1898af9fc1 | PHP | KaridaLiu/fileManagement | /lib/db.func.php | UTF-8 | 1,179 | 2.78125 | 3 | [] | no_license | <?php
function connect()
{
$config = require dirname(__FILE__) . '/config.php';
$mysqli = @mysqli_connect(
$config['DB_HOST'] . ':' . $config['DB_PORT'],
$config['DB_USER'],
$config['DB_PASS'],
$config['DB_NAME']
) or die('Connect Error: ' . mysqli_connect_errno() . '-' . my... | true |
025337f4a9c9ca4d929a34fff6e6f3d892bbcdad | PHP | Danielunan/Laravel-Ecommerce | /database/factories/ModelFactory.php | UTF-8 | 1,209 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
/*
|--------------------------------------------------------------------------
| Model Factories
|--------------------------------------------------------------------------
|
| Here you may define all of your model factories. Model factories give
| you a convenient way to create models for testing and seeding yo... | true |
82b4809edbc2b0063f29ce91119504a4a3044f4a | PHP | danielcaballero796/initial | /back/facade/EmpleadoFacade.php | UTF-8 | 3,985 | 2.96875 | 3 | [] | no_license | <?php
/*
-------Creado por-------
\(x.x )/ Anarchy \( x.x)/
------------------------
*/
// Damos paso a la anarquía... \\
require_once realpath('../facade/GlobalController.php');
require_once realpath('../dao/interfaz/IFactoryDao.php');
require_once realpath('../dto/Emple... | true |
022b361ce86d6ae191fe85cfdf7557b572c8d907 | PHP | Skarreggat/pruebaltw | /app/Http/Controllers/EntradasController.php | UTF-8 | 7,149 | 2.671875 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Client;
use App\Tractament;
class EntradasController extends Controller {
public function index() {
$clientes = Client::all();
$tratamientos = Tractament::all();
return view('index', ['clientes' => $clientes, 'tr... | true |
032820403de2684df737fda6b4c9fe9d526ab0a7 | PHP | maturao/semestralka-web | /src/app/Utils.class.php | UTF-8 | 921 | 3.328125 | 3 | [] | no_license | <?php
namespace semestralkaweb;
/**
* Trida s uzitecnymi funkcemi
* @package semestralkaweb
*/
class Utils
{
/**
* Vrati z pole hodnotu pod klicem, a nebo vychozi hodnotu
* @param $array
* @param $key
* @param $default
* @return mixed
*/
public static func... | true |
558c9a6c71436900a89b0b3d73da795db1d1c789 | PHP | levonml/php_piscine | /rush00/users.php | UTF-8 | 2,428 | 3.015625 | 3 | [] | no_license | <?php
require_once('database_utils.php');
/**
* Returns TRUE if user already exists, else FALSE.
*
* @username entered username
* @hash_pw entered password which is hashed (whirlpool)
*/
function user_is_valid($username, $hash_pw)
{
// Connect to MySQL
$link = g... | true |
67e3d715aca621dcf3a270ba2609a0a973935a85 | PHP | yuchao568/Corvus-Api | /app/Entity/StarEntity.php | UTF-8 | 5,858 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Entity;
use App\CommunicationStatus;
use App\Gender;
use App\SignContractStatus;
use App\StarSource;
use App\User;
use App\Whether;
/**
* Created by PhpStorm.
* User: apple
* Date: 2019-01-23
* Time: 15:12
*/
class StarEntity
{
/** 主键id
*@desc
*/
public $id;
/**
*... | true |
96896b3347bc8beafa23bdaf68102be676f5287e | PHP | savanevich/skills | /skeleton/backend/app/Http/Controllers/Auth/AuthController.php | UTF-8 | 3,170 | 2.640625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers\Auth;
use App\Models\User;
use App\Http\Requests\Request;
use App\Http\Requests\LoginRequest;
use App\Http\Requests\RegisterRequest;
use App\Http\Controllers\Controller;
use Illuminate\Foundation\Auth\ThrottlesLogins;
use Illuminate\Foundation\Auth\AuthenticatesAndRegistersUsers... | true |
16074900d8137f43e19041963c69a326500861d7 | PHP | drnkwati/repack-htmlsanitizer | /src/NodeVisitor/RemoveNodeVisitor.php | UTF-8 | 566 | 2.65625 | 3 | [
"MIT"
] | permissive | <?php
namespace Repack\HtmlSanitizer\NodeVisitor;
use DOMNode;
use Repack\HtmlSanitizer\Cursor;
class RemoveNodeVisitor extends TagNodeVisitor
{
/**
* @param DOMNode $domNode
* @param Cursor $cursor
*/
public function enterNode(DOMNode $domNode, Cursor $cursor)
{
while ($domNode->... | true |
1ab85bccfa2c2f10c4d4dea35727464e6d6c02c1 | PHP | binsoul/net-http-router | /tests/Matcher/StaticMatcherTest.php | UTF-8 | 2,915 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
namespace BinSoul\Test\Net\Http\Router\Matcher;
use BinSoul\Net\Http\Router\DefaultRoute;
use BinSoul\Net\Http\Router\Matcher\StaticMatcher;
use Psr\Http\Message\RequestInterface;
use Psr\Http\Message\UriInterface;
class StaticMatcherTest extends \PHPUnit_Framework_TestCase
{
/**
* @param string $path... | true |
e1b4a5d2d8367cf5f8cdf48ee2f2d6aac82ffa84 | PHP | BRAYANCT/BoomGo | /database/migrations/2020_11_14_122456_create_billing_information_table.php | UTF-8 | 1,222 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateBillingInformationTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('bill... | true |
4a09245c8e8d0e173ac3b89cf89227d2391bd71f | PHP | ghola/persistence-doctrine1 | /src/Doctrine1PersistenceConfigurator.php | UTF-8 | 2,741 | 2.625 | 3 | [
"MIT"
] | permissive | <?php
namespace PSB\Persistence\Doctrine1;
use PSB\Core\Persistence\PersistenceConfigurator;
class Doctrine1PersistenceConfigurator extends PersistenceConfigurator
{
/**
* A DSN is essential when the bus attempts to automatically recover from disconnects.
* The DNS formats are as described in the Doctr... | true |
b51e6ba853d52719f9685fad8346e84a67a3e767 | PHP | Ujitoko/web | /exForVR/upload.php | UTF-8 | 236 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
// リクエストBodyからファイルのデータを取得.
$image = file_get_contents("php://input");
// 取得したバイナリデータを画像(png)として保存.
file_put_contents('dl.csv',$image);
?> | true |
04495d1fc31f58ada32285224f89096a70549309 | PHP | spysystem/epay | /src/gettransactionResponse.php | UTF-8 | 1,797 | 2.9375 | 3 | [] | no_license | <?php
namespace EPay;
/**
* Class gettransactionResponse
*/
class gettransactionResponse
{
/**
* @var bool $gettransactionResult
*/
protected $gettransactionResult;
/**
* @var null|TransactionInformationType $transactionInformation
*/
protected $transactionInformation;
/**
* @var int $epayresponse... | true |
a591cb8cdc97692137d8c6e60babcf8df61eee85 | PHP | janLo/ancient-weatherstation | /webstuff/frontend/php_inc/modules/rain.inc.php | UTF-8 | 4,858 | 2.96875 | 3 | [] | no_license | <?
/* copyright: Jan Losinski, 2006
at the Moment this is no free software, look at the
COPYING-File in the Main-Directory for License-Terms
*/
include_once($path."php_inc/connection.inc.php");
/* Rain-Klasse fuer das Rain-Modul */
class Rain{
var $nowHour = "nc"; /* Regen in der momenta... | true |
c3e9c51fdedef8371b36da5140cff86ef778f9e5 | PHP | neitanod/SLGTerm | /SLGTerm/TraitHasHeight.php | UTF-8 | 417 | 2.765625 | 3 | [] | no_license | <?php
namespace SLGTerm;
trait HasHeight {
protected $height;
public function getHeight() {
if (
is_null($this->height) &&
defined('self::DEFAULT_HEIGHT')
) {
$this->height = self::DEFAULT_HEIGHT;
}
return $this->height;
}
public fu... | true |
4a713e8027a75314725b1dd2177f9d55e1846e2f | PHP | jawira/emoji-catalog | /tasks/AbstractEmojiTask.php | UTF-8 | 1,106 | 2.78125 | 3 | [
"MIT"
] | permissive | <?php declare(strict_types=1);
namespace Jawira\EmojiTask;
abstract class AbstractEmojiTask extends \Phing\Task
{
function codepointsToEmoji(string $codepoints): string
{
$codepointsArray = array_filter(explode(' ', $codepoints));
$reducer = function (string $carry, string $codepoint) {
... | true |
8a35713961e7577c0381793810d0a72da8d5ac64 | PHP | kaliss96/calificaciones | /models/Asignaturas.php | UTF-8 | 2,206 | 2.546875 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
namespace app\models;
use Yii;
/**
* This is the model class for table "asignaturas".
*
* @property integer $id_asig
* @property string $cod_asig
* @property string $nombre_asig
* @property integer $total_horas_asig
* @property integer $creditos_asig
* @property string $especificacion_asi... | true |
e2e1355ef9877fd971fa284bb3a5314f640e9fd0 | PHP | nikolaynizruhin/devices-groups | /app/Http/Controllers/DeviceGroupController.php | UTF-8 | 977 | 2.546875 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use App\Device;
use Illuminate\Http\Request;
class DeviceGroupController extends Controller
{
/**
* Connect the device to a group.
*
* @param \Illuminate\Http\Request $request
* @param \App\Device
* @return \Illuminate\Http\Response
*/
pu... | true |
fc3d1141620ac77cd18882d4050d645ead3fa7f2 | PHP | richard85501/auction | /checkSession.php | UTF-8 | 285 | 2.53125 | 3 | [] | no_license | <?php
// session 開啟
session_start();
// 驗證username是否存在
if(!isset($_SESSION['username'])){
//關閉session
session_destroy();
//回到登入頁面
header('Refresh:1; url=./index.php');
echo "請確實登入頁面,3秒後自動跳轉";
exit();
} | true |
d83646536fda1c05cc6f3f1a782ac4927fbe2949 | PHP | geetikapant/Coding-Question-Website | /pps/data_types/reverse_the_string.php | UTF-8 | 2,628 | 2.53125 | 3 | [] | no_license | <?php
include "header.php";
include "sidenav.php";
?>
<!DOCTYPE html>
<html>
<head><!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Boots... | true |
c95ef2df8c7b8b6e299129ddad8b380ac0903793 | PHP | mohitbansal623/projarch.com | /signin.php | UTF-8 | 3,531 | 2.90625 | 3 | [] | no_license | <?php
$name = $email = $passwd = "";
$emailErr = $pwdErr = "";
$found = 0;
//This function checks the user's login details and matches with the DB.
function loginCheck() {
if ($_SERVER["REQUEST_METHOD"] == "POST") {
if (isset($_POST['submit'])) {
global $name, $emailErr, $passwd, $pwd... | true |