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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
e225875769ecd9cf9939ddb2a9e03d217cb18721 | PHP | jkopstals/dingo-api | /app/Models/User.php | UTF-8 | 1,503 | 2.984375 | 3 | [] | no_license | <?php
namespace App\Models;
use Illuminate\Foundation\Auth\User as Authenticatable;
class User extends Authenticatable
{
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'name', 'email', 'password',
];
/**
* The attributes that... | true |
56ae258cf839249daa8faa7ff534c52b7fa7535d | PHP | gmarv1n/design-patterns-php | /Behavioural/Mediator/AdminUser.php | UTF-8 | 462 | 2.84375 | 3 | [] | no_license | <?php
/**
* Behavioural Patterns: Mediator
* AdminUser class
*
* Администратор чата
*
* @author Gregory Yatsukhno <codejournaldev@gmail.com>
* @version 13.04.2021
*/
namespace DesignPatterns\Behavioural\Mediator;
use DesignPatterns\Behavioural\Mediator\User;
class AdminUser extends User
{
// Администратора... | true |
edca625365643058313e34955ab82b925cb56196 | PHP | egav210309/igle_admin | /app/Entities/Estatus.php | UTF-8 | 291 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Entities;
use CodeIgniter\Entity;
class Estatus extends Entity
{
public function getNameEstatus(){
return $this->name_estado;
}
//genera link para editar
public function getEditRegisterst(){
return base_url(route_to('editsettig', $this->cod_estado.'/2'));
}
} | true |
9458070a17d7c12728ec4094364e0abaecb4ef65 | PHP | sohophp/schemaorg | /src/Thing/Intangible/DefinedTerm.php | UTF-8 | 2,146 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
namespace Sohophp\SchemaOrg\Thing\Intangible;
use Sohophp\SchemaOrg\Thing\Intangible;
use Sohophp\SchemaOrg\Thing\CreativeWork\DefinedTermSet;
/**
* A word, name, acronym, phrase, etc. with a formal definition. Often used in the context of category or subject classification, glossaries or dictionaries, product ... | true |
a69847e91be68cf85168204f177fca72079fc56d | PHP | intellivoid/Admin-Dashboard | /src/resources/libraries/CoffeeHouse/Abstracts/APIPlan.php | UTF-8 | 231 | 2.6875 | 3 | [] | no_license | <?php
namespace CoffeeHouse\Abstracts;
/**
* Class APIPlan
* @package CoffeeHouse\Abstracts
*/
class APIPlan
{
const Free = 0;
const Basic = 1;
const Enterprise = 2;
} | true |
13cf929c234a9757eeb48b678f8b2cbbcb1aeabc | PHP | garak/clean-architecture | /src/Common/Collection/ArrayCollection.php | UTF-8 | 2,635 | 3.015625 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace Damianopetrungaro\CleanArchitecture\Common\Collection;
use Damianopetrungaro\CleanArchitecture\Common\CommonTrait\CloneArrayTrait;
class ArrayCollection implements Collection
{
use CloneArrayTrait;
/**
* Array of request parameters.
*
* @var array $it... | true |
a7bfd27edb51002fdb562fe1b6995eb13747503d | PHP | egulias/ycrawler | /tests/yCrawler/Tests/Crawler/Runner/ThreadedRunner/WorkTest.php | UTF-8 | 1,261 | 2.640625 | 3 | [] | no_license | <?php
namespace yCrawler\Tests;
use yCrawler\Tests\TestCase;
use yCrawler\Crawler\Runner\ThreadedRunner\Work;
use yCrawler\Crawler\Runner\ThreadedRunner\Pool;
use yCrawler\Document;
use Exception;
class WorkTest extends TestCase
{
public function testSubmitWorkFail()
{
$this->markTestIncomplete(
... | true |
98e19491feac57070efdda1cb7c1e4126e477dc7 | PHP | arsenpahi/gold-gym | /entry_form.php | UTF-8 | 3,422 | 2.703125 | 3 | [] | no_license | <?php
ob_start();
session_start();
require("dbconnect.php");
if (isset($_SESSION['user']))
{
$login = true;
$result = $conn->query("SELECT * FROM users WHERE userId=".$_SESSION['user']);
$userRow = $result->fetch(PDO::FETCH_ASSOC);
$userId = $_SESSION['user'];
$userName = $userRow['userName'];
$u... | true |
86e510226a225ff9ee5be07b6d8f0460e6098186 | PHP | Eliphio/acad | /application/forms/Imc.php | UTF-8 | 1,594 | 2.546875 | 3 | [] | no_license | <?php
/**
* @author Elan
*
*
*/
class Form_Imc extends Form_PadraoForm
{
public function __construct($options = null) {
$this->addElement('radio', 'cod_sex', array(
'label' => 'Sexo',
'multiOptions' => array(0 => 'Feminino', 1 => 'Masculino'),
'required' => true... | true |
c8081337f51b6f18d0852b9b705d83674b78f77e | PHP | spiral/app-grpc | /app/src/Job/Ping.php | UTF-8 | 517 | 2.515625 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
/**
* This file is part of Spiral 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 App\Job;
use Spiral\Queue\JobHandler;
/**
* (QueueInterface)->push(new PingJob(["value"=>"my va... | true |
b300006b0ee8a100a969df34e264089b5f961f9d | PHP | misoks/dads-inn | /functions.php | UTF-8 | 1,144 | 2.734375 | 3 | [] | no_license | <?php
include('SimpleImage.php');
function navLink($url, $linktext) {
$current = substr($_SERVER["SCRIPT_NAME"],strrpos($_SERVER["SCRIPT_NAME"],"/")+1);
if ($url == $current) {
return '<a class="current">'.$linktext.'</a>';
}
else {
return '<a href="'.$url.'">'.$linktext.'</a>';
}
}... | true |
724c1c632bec6a53a65939766e019cd1ec1927d3 | PHP | devphp90/leoharleydavidson | /_includes/classes/SC_Order.php | UTF-8 | 98,080 | 2.546875 | 3 | [] | no_license | <?php
class SC_Order
{
public $mysqli='';
public $messages=array();
// constructor
public function __construct($mysqli) {
if (!$mysqli instanceof MySQLi) throw new Exception('Invalid mysqli object');
$this->mysqli=$mysqli;
}
public function load($id_orders)
{
$id_orders=(int)$id_orders;
// get o... | true |
a816b6a60dcc55085e9dc149f535689d121e6833 | PHP | KyleMalabuyoc/LoginSimulation | /loginSimulation/loginHome.php | UTF-8 | 498 | 2.515625 | 3 | [] | no_license | <?php
include_once 'headerLogin.php'; //just included the header file so we dont have to re-write everything
?>
<section class = "main-container">
<div class="main-wrapper">
<h2>Home</h2>
<?php
if(isset($_SESSION['u_id'])){ //isset is true if that variavle $_SESSION was... | true |
42dc034a671f5fa53b997ed8b6a0100782d4f235 | PHP | islam95/Corporate-Laravel | /app/Models/User.php | UTF-8 | 2,311 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
namespace Corp\Models;
use Illuminate\Foundation\Auth\User as Authenticatable;
class User extends Authenticatable
{
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'name', 'email', 'password',
];
/**
* The attributes tha... | true |
1f72ab4623270f06f36f2b406f2ea827be890c80 | PHP | zakiganteng/inventory | /application/models/gedungModel.php | UTF-8 | 1,100 | 2.53125 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
class gedungModel extends CI_Model {
public function __construct()
{
// Call the CI_Model constructor
parent::__construct();
}
public function selectGedung()
{
$query = $this->db->get('gedung');
return $query... | true |
6ab1dee91b58947682ade55013305755ac3f4453 | PHP | jolicode/secret-santa | /src/Model/ApplicationToken.php | UTF-8 | 682 | 2.65625 | 3 | [
"MIT"
] | permissive | <?php
/*
* This file is part of the Secret Santa project.
*
* (c) JoliCode <coucou@jolicode.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace JoliCode\SecretSanta\Model;
class ApplicationToken
{
/**
* @para... | true |
ba7a26dbf448ceb15829ac16ccb583252996ec58 | PHP | fvarli/php-tutorial | /23-Ajax/contact_form/ajax.php | UTF-8 | 1,367 | 2.671875 | 3 | [] | no_license | <?php
require 'db.php';
$result = [];
if(isset($_POST['type'])){
if($_POST['type'] == 'contact'){
$full_name = $_POST['full_name'] ?? false;
$email = $_POST['email'] ?? false;
$message = $_POST['message'] ?? false;
if(!$full_name){
$result['error'] = 'Full name can not b... | true |
485a61c010bd996faa45fb225507a8fb35fb75dd | PHP | adedotunbashorun/advance-laravel-api | /Modules/Users/Repositories/UserRepository.php | UTF-8 | 1,623 | 2.53125 | 3 | [] | no_license | <?php
namespace Modules\Users\Repositories;
use Carbon\Carbon;
use Exception;
use Illuminate\Support\Facades\Auth;
use Modules\Users\Repositories\AuthInterface;
use Modules\Users\Repositories\UserInterface;
use Modules\Users\Entities\User;
use Modules\Users\Entities\UserDetail;
use Modules\Core\Repositories\Repositori... | true |
86cf9efeadcd6c74d653c9b7671861111326c2fe | PHP | niklug/masterinvite | /administrator/components/com_akeebasubs/assets/customfields/abstract.php | UTF-8 | 3,001 | 2.8125 | 3 | [] | no_license | <?php
/**
* @package akeebasubs
* @copyright Copyright (c)2010-2013 Nicholas K. Dionysopoulos / AkeebaBackup.com
* @license GNU GPLv3 <http://www.gnu.org/licenses/gpl.html> or later
*/
defined('_JEXEC') or die();
/**
* Abstract base class for custom per-user and per-subscription fields
*
* @since 2.6.0
*/
... | true |
bbaa70590a3a629dd09702eb9f4495835adc1630 | PHP | Wuthikan/PD-Company | /database/migrations/2017_05_18_105112_add_some_field_shipping.php | UTF-8 | 911 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddSomeFieldShipping extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('shipping', fun... | true |
476db12e23d8736e6e3ba0b2fbf8c9c137640b75 | PHP | mocniak/propaganda | /src/Infrastructure/Repository/DoctrineChartRepository.php | UTF-8 | 1,176 | 2.734375 | 3 | [] | no_license | <?php
namespace Propaganda\Infrastructure\Repository;
use Doctrine\ORM\EntityManager;
use Propaganda\Domain\Entity\Chart;
use Propaganda\Domain\Repository\ChartRepositoryInterface;
use Ramsey\Uuid\UuidInterface;
class DoctrineChartRepository implements ChartRepositoryInterface
{
private $entityManager;
priva... | true |
ed8a60d1d639f749261508866fd211c155ea7384 | PHP | nojimage/Sirousagi | /core/features/log_feature.php | UTF-8 | 3,812 | 2.625 | 3 | [
"MIT"
] | permissive | <?php
/**
* ロギング
*
* PHP versions 5
*
* Copyright 2009, nojimage (http://php-tips.com/)
*
* Licensed under The MIT License
* Redistributions of files must retain the above copyright notice.
*
* @version Sirousagi 0.4
* @author nojimage <nojimage at gmail.com>
* @copyright 2009 nojimage
* @license ... | true |
1f83dc64e5c2f8e66ccd4955abd130142fd5d0b1 | PHP | sonnenkindhope/MedicalFinder | /src/Mapper/Medical/PDO.php | UTF-8 | 2,250 | 2.96875 | 3 | [] | no_license | <?php
namespace App\Mapper\Medical;
use App\DTO\Medical;
use App\Mapper\Connector\ConnectorInterface;
/**
* Class PDO
* @package App\Mapper\Medical
*/
class PDO implements MedicalInterface, \Psr\Log\LoggerAwareInterface
{
use \Psr\Log\LoggerAwareTrait;
/**
* @var \PDO
*/
private \PDO $connec... | true |
dbea2905f99f5cf542ed38258bac1d00cee799b4 | PHP | symcloud/distributed-storage | /tests/Unit/Component/FileStorage/FileSplitterTest.php | UTF-8 | 1,722 | 2.828125 | 3 | [
"MIT"
] | permissive | <?php
namespace Unit\Component\FileStorage;
use Symcloud\Component\FileStorage\FileSplitter;
class FileSplitterTest extends \PHPUnit_Framework_TestCase
{
public function adapterProvider()
{
return array(
array(($data = $this->generateString(5)), 10, array($data)),
array(($data... | true |
b39c1d00997185b39e6ee7670d609f0506d40b4a | PHP | angellegerdealer/news-api | /storage/db/migrations/20181126213406_add_news_table.php | UTF-8 | 2,044 | 2.546875 | 3 | [] | no_license | <?php
use Phinx\Migration\AbstractMigration;
class AddNewsTable extends AbstractMigration
{
public function up()
{
$table = $this->table(
'news',
[
'id' => 'id',
'signed' => false,
]
);
$table
->addColum... | true |
b06ffc90b6dc0d0969c53bcc91d30be01ca6ed2a | PHP | graywrk/gendiff | /src/Differ.php | UTF-8 | 2,686 | 3.015625 | 3 | [] | no_license | <?php
namespace Differ;
use Funct\Collection;
function genDiff($reportFormat, $pathToFile1, $pathToFile2)
{
$data1 = getDataFromFile($pathToFile1);
$data2 = getDataFromFile($pathToFile2);
$AST = generateAST($data1, $data2);
return buildReport($reportFormat, $AST);
}
function generateAST($data1, $d... | true |
0a249d46eabb0ed1dbd207deefdbc0c797aa381a | PHP | ko22009/play-patterns | /src/Structural/Flyweight/Car.php | UTF-8 | 350 | 3.109375 | 3 | [] | no_license | <?php
namespace PlayPatterns\Structural\Flyweight;
class Car
{
private MakeModelCar $makeModelCar;
private string $plates;
private string $owner;
public function __construct($makeModelCar, $plates, $owner)
{
$this->makeModelCar = $makeModelCar;
$this->plates = $plates;
$t... | true |
9db2439f5f3cba4ab77a17a00cc38cc22c194a7d | PHP | algebrateam/phpdev2018 | /public/pmrvic/21-24/24.funkcije.php | UTF-8 | 3,003 | 3 | 3 | [
"MIT"
] | permissive | <?php
/**
* 24.
* Objasniti pojam funkcije. Prikazati kako se definira funkcija.
* Prikazati kako se poziva funkcija. Objasniti funkcije sa i bez
* ključne riječi return. Detaljno objasniti koja je razlika
* između return i metoda koje ispisuju izlaz na ekran (echo,
* print). Prikazati kako koristiti varijable s ... | true |
5932c86c1f4e63b2d998be26dbe81efd991807e1 | PHP | jankichaudhari/yii-site | /docroot/v3.0/live/public_inx/db.inc.php | UTF-8 | 6,498 | 2.875 | 3 | [] | no_license | <?php
// DATABASE CONNECTION
require_once("DB.php");
$dsn = array(
'phptype' => "mysql",
'database' => "wsv3_live",
'username' => "wsv3_db_user",
'password' => "CHe9adru+*=!a!uC7ubRad!TRu#raN"
);
$db = DB::connect($dsn);
if (DB::isError($db)) { die("Fatal error: ".$db->getMessage()); }
$db->setFetchM... | true |
b46d2937b8c1a4d41039b462709de30d539f25c8 | PHP | BenMakesGames/PsyPets | /crontab/hostedevents.php | UTF-8 | 11,006 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
/* hosts daily events
*/
$maintenance_when = (int)date('Gi');
// midnight through 12:20, we are in maitenance
if(($maintenance_when >= 0 && $maintenance_when <= 20 && $_GET['maintenance'] != 'no') || $_GET['maintenance'] == 'yes')
die('Maintenance, fool!');
// --- BEGIN! ---
//ini_set('include_path', '/your... | true |
4b8078874e41c11396f488efbc88be6814ae286c | PHP | ahennebel/ue3dw17 | /valid.php | UTF-8 | 1,894 | 2.65625 | 3 | [] | no_license | <?php include 'session.php'?>
<?php include 'bdd.php'?>
<html>
<head>
<meta charset="UTF-8">
<title>Quizzy , questions à valider</title>
<link rel="stylesheet" href="main.css" />
</head>
<body>
<h1>Questions à valider</h1>
<div class="content">
<h2>Voici l... | true |
3b7c161096ca9f3ce5f0c0ad40663eacf03c6270 | PHP | wenerme/tellets-php | /app/classes/predefined_hooks.php | UTF-8 | 2,918 | 2.65625 | 3 | [
"MIT"
] | permissive | <?php
use FeedWriter\Atom;
use FeedWriter\RSS2;
Hook::AddHook(Hook::RESOLVE_REQUEST, 'rssOratomAction');
Hook::AddHook(Hook::RESOLVE_POST, 'basic_post_resolver');
Hook::AddHook(Hook::FIND_POST_LIST, 'posts_in_post_dir');
Hook::AddHook(Hook::RESOLVE_REQUEST, 'update_action');
Hook::AddHook(Hook::GENERATE_HEADER, 'gene... | true |
0301d5369f5c76ba17a6dcb25a7d1d25353ae7ee | PHP | andreev2007/test-task-income-apps | /console/controllers/RbacController.php | UTF-8 | 1,472 | 2.65625 | 3 | [] | no_license | <?php
namespace console\controllers;
use common\models\User;
use Yii;
use yii\console\Controller;
// Создание админа
class RbacController extends Controller
{
public function actionInit()
{
$auth = Yii::$app->authManager;
$admin = $auth->createRole('admin');
$user =... | true |
e9b6959e2e4cfa19c03ebfc4ee5ed5bde1c6c5ae | PHP | dnohales/ucaecemdp-arqweb | /app/Segdmin/Framework/Logging/LogEntry.php | UTF-8 | 747 | 2.96875 | 3 | [] | no_license | <?php
namespace Segdmin\Framework\Logging;
/**
* Description of LogEntry
*
* @author eagleoneraptor
*/
class LogEntry
{
private $level;
private $category;
private $message;
public function __construct($level, $message, $category)
{
$this->setLevel($level);
$this->setMessage($message);
$this->setCatego... | true |
7d818805de9f119ed00b0f5bf1a9f2279724c27d | PHP | msdlt/medswipe | /app/Controller/UsersController.php | UTF-8 | 3,471 | 2.609375 | 3 | [] | no_license | <?php
class UsersController extends AppController {
var $name = 'Users';
function beforeFilter() {
//$this->Auth->autoRedirect = false;
}
/**
* The AuthComponent provides the needed functionality
* for login, so you can leave this function blank.
*/
/*function login() {
$username= "mdiv0044";
//if(iss... | true |
aa3564ed36986e007da28a66420f9f7a2d728e27 | PHP | sakibahmad24/CRUD-PHP-Codeigniter-Bootstrap | /application/models/Product_model.php | UTF-8 | 1,489 | 2.75 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
/**
*
*/
class Product_model extends CI_Model
{
public function add_product(){
$data = array(
'product_name' => $this->input->post('product_name'),
'product_price' => $this->input->post('product_price'),
'quantity' => $this->input->post('quantity'),
'company_name' => $this->input->post('compan... | true |
d3abb4fc4b934d0a962c60f7eac6ddc94e3eead1 | PHP | brahn311/hello-world | /codes/php/poo_linkedin/2_1_a_constant.php | UTF-8 | 483 | 2.78125 | 3 | [] | no_license | <?php
class Config
{
const DB_USER_NAME = 'aomana03';
const DB_USER_PASSWORD = '1234';
const DB_DATABASE_NAME = 'mydb';
// por norma en poo en php, las constantes se declaran en mayusculas, pero no es una regla
}
class BaseProfile extends Config
{
}
class Profile extends BaseProfile
{
const DOMAIN_NAME = '... | true |
65605475de2f69ef6ad2e946ea12d7928499ff63 | PHP | serycjon/skaut-google-drive-gallery | /plugin/frontend/class-option.php | UTF-8 | 934 | 2.78125 | 3 | [
"MIT"
] | permissive | <?php
namespace Sgdg\Frontend;
abstract class Option {
protected $name;
protected $default_value;
protected $section;
protected $title;
public function __construct( $name, $default_value, $page, $section, $title ) {
$this->name = 'sgdg_' . $name;
$this->default_value = $default_value;
$this->page ... | true |
5961514cc8c7aeca26b8cc83ab16dd5d4a833a3d | PHP | cyruscollier/upcloud-php-api | /lib/Model/ZoneListResponse.php | UTF-8 | 855 | 2.875 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace Upcloud\ApiClient\Model;
class ZoneListResponse
{
/**
* @var ZoneListResponseZones|null
*/
private $zones;
/**
* Constructor
* @param mixed[] $data
*/
public function __construct(array $data = null)
{
$this->setZones($data... | true |
d23c449d1cbef11e23863c6cbbdf3cbe53bd0a5b | PHP | zvitek/dontpanic-elearning | /app/Entities/Token/Token.php | UTF-8 | 1,816 | 2.609375 | 3 | [] | no_license | <?php
namespace DontPanic\Entities;
use Doctrine\ORM\Mapping as ORM;
use JMS\Serializer\Annotation as Serializer;
use Kdyby\Doctrine\Entities\Attributes\Identifier;
use Kdyby\Doctrine\Entities\BaseEntity;
use Knp\DoctrineBehaviors\Model\Timestampable\Timestampable;
/**
* @ORM\Entity
* @ORM\Table(name="tokens")
*/... | true |
7aa78840501e12305be9ab36013f7f43328371c2 | PHP | mchekin/design-patterns | /tests/Creational/AbstractFactoryTest.php | UTF-8 | 1,857 | 3.015625 | 3 | [] | no_license | <?php
namespace Tests\Creational;
use InvalidArgumentException;
use Patterns\Creational\AbstractFactory\AbstractAnimalFactory;
use Patterns\Creational\AbstractFactory\Continent;
use Patterns\Creational\FactoryMethod\Animal;
use Patterns\Creational\FactoryMethod\Species;
use PHPUnit\Framework\TestCase;
class Abstract... | true |
9670551b538491d3546b3c416a9549a4bfceb82a | PHP | stevehoneyman/wordcamp-london | /functions.php | UTF-8 | 1,245 | 2.625 | 3 | [] | no_license | <?php
// enqueue styles
function theme_styles() {
wp_enqueue_style('main_css', get_template_directory_uri(). '/css/main.css?v=' .time() );
}
add_action('wp_enqueue_scripts', 'theme_styles');
// enable featured images
add_theme_support('post-thumbnails');
// show admin bar
add_filter('show_admin_bar', '__return_tr... | true |
7c2c0c04400beae6c6bc8c6b2063eac296fdf293 | PHP | tonioriol/catalanitzador | /Output.php | UTF-8 | 147 | 3.015625 | 3 | [] | no_license | <?php namespace App;
class Output
{
public static function write($string)
{
return !empty($string) ? fwrite(STDOUT, $string . "\n") : -1;
}
} | true |
f9b9ffe7888c7fbbdc05d85a05eaaebcfc3aa5e5 | PHP | cglazier12/player-character-codeLou2020 | /app/Http/Controllers/SheetsController.php | UTF-8 | 1,734 | 2.609375 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use App\Sheet;
use Spatie\QueryBuilder\QueryBuilder;
use Illuminate\Support\Facades\Auth;
use Illuminate\Http\Request;
class SheetsController extends Controller
{
// grab the user's sheet from the database
public function fetchAbility(Request $request)
{
$use... | true |
51249e7664e257785f0168f83bd18bc91caa2b77 | PHP | alinav12/researchwork | /newuser.php | UTF-8 | 738 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: macbookair
* Date: 06.05.2021
* Time: 23:42
*/
use App\Models\User;
use App\Models\Post;
use Illuminate\Support\Facades\DB;
echo "hi!";
$name = $_POST['name'];
echo $name;
$email = $_POST['email'];
echo $email;
$password = $_POST['password'];
echo $password;
//$user = ... | true |
1205b54e66efac704729929e4b862d1e6c47de16 | PHP | johned21/Capstone-Project-Nov-8-2021 | /app/Models/Subject.php | UTF-8 | 505 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class Subject extends Model
{
use HasFactory;
protected $guarded = [];
public function sessions() {
return $this->hasMany('App\Models\Session');
}
public function ... | true |
e2d64452202b32957250fdd7f5598ec985d3e2e1 | PHP | Shareed2k/framework | /src/Session/Store/AbstractStore.php | UTF-8 | 1,327 | 2.6875 | 3 | [
"MIT"
] | permissive | <?php
/**
* @copyright Bluz PHP Team
* @link https://github.com/bluzphp/framework
*/
/**
* @namespace
*/
namespace Bluz\Session\Store;
use Bluz\Common\Options;
/**
* Abstract Session
*
* @category Bluz
* @package Session
*
* @author Anton Shevchuk
* @created 26.01.12 18:19
*/
abstract class Abstract... | true |
a43d37b99ef28d2223d290e478e04bfbe7546477 | PHP | marco32/php-exercise | /Loop/exercice4.php | UTF-8 | 57 | 2.6875 | 3 | [] | no_license | <?php
$a=1;
while($a<=10){
$a+=$a*0.5;
echo "$a,";
}
?> | true |
3190d2e791f275d44c10156bebd868bd5852ec14 | PHP | hectareua/hectare | /migrations/m160623_075120_create_field_option.php | UTF-8 | 1,069 | 2.5625 | 3 | [] | no_license | <?php
use yii\db\Migration;
/**
* Handles the creation for table `field_option`.
* Has foreign keys to the tables:
*
* - `field`
*/
class m160623_075120_create_field_option extends Migration
{
/**
* @inheritdoc
*/
public function up()
{
$this->createTable('field_option', [
... | true |
4d30981e9809720085cdabbd55568c60b6840e7f | PHP | chendaxian/Alive | /app/Traits/UploadFile.php | UTF-8 | 751 | 2.703125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Traits;
use Illuminate\Http\Request;
use Image;
trait UploadFile
{
/**
* 压缩图片上传复用函数
*
* @param $file, $path
* @return mixed
*/
public function uploadImg($file, $path)
{
$size = filesize($file->getRealPath())/1000;
$picName = str_random(40).'.'... | true |
c1dab31c690567341d20ecf49a27171010268903 | PHP | sagnikmitra/codetigers | /forum.codetigers.org/library/Vanilla/Site/SiteSectionSchema.php | UTF-8 | 1,038 | 2.890625 | 3 | [
"LicenseRef-scancode-free-unknown",
"GPL-1.0-or-later",
"GPL-2.0-or-later",
"GPL-2.0-only",
"MIT"
] | permissive | <?php
/**
* @author Adam Charron <adam.c@vanillaforums.com>
* @copyright 2009-2019 Vanilla Forums Inc.
* @license GPL-2.0-only
*/
namespace Vanilla\Site;
use Vanilla\Contracts\Site\SiteSectionInterface;
use Vanilla\Utility\InstanceValidatorSchema;
/**
* Schema for validating a site section.
*/
class SiteSectio... | true |
bbd361a84240081f87a10448c6cc2c36b3c1ae11 | PHP | hanabinoir/csis3280as4 | /addOrderGame.php | UTF-8 | 3,854 | 2.5625 | 3 | [] | no_license | <?php
$myCon = mysqli_connect("localhost","root","","gamebuydb");
function table($myCon){
$cardNum = "";
$grandTotal = 0;
$fhTitle = fopen("title.txt","r");
$custID = $_COOKIE['id'];
$sql = "select * from ordertbl where ord_cust_id = $custID";
$res = mysqli_query($myCon,$sql);
if(fgets($fhTitle) == ""){
print... | true |
44af952c4ffc77382976bc6438c7e403fcd78f35 | PHP | PHPOffice/PhpSpreadsheet | /tests/PhpSpreadsheetTests/Reader/Csv/CsvContiguousTest.php | UTF-8 | 3,735 | 3.21875 | 3 | [
"MIT"
] | permissive | <?php
namespace PhpOffice\PhpSpreadsheetTests\Reader\Csv;
use PhpOffice\PhpSpreadsheet\Reader\Csv;
use PhpOffice\PhpSpreadsheet\Spreadsheet;
use PHPUnit\Framework\TestCase;
class CsvContiguousTest extends TestCase
{
/**
* @var string
*/
private $inputFileName = 'samples/Reader/sampleData/example2.c... | true |
7a15b34273e474aac14d5467cea6b26f0aad8546 | PHP | vivpra89/RawlsGACode | /Game2V10Dec/Game2/delete.php | UTF-8 | 535 | 2.703125 | 3 | [] | no_license | <?php
/* Specify the server and connection string attributes. */
$serverName = "bamsql2";
/* Get UID and PWD from application-specific files. */
$uid = genes;
$pwd = Genes12;
$connectionInfo = array( "UID"=>$uid,
"PWD"=>$pwd,
"Database"=>"genes");
/* Connect using SQ... | true |
4fd657f49e61166be68cdc38fc3c27ae9cf956d5 | PHP | 10urunal/yks | /class/apis/yphar.php | UTF-8 | 1,422 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
class yphar {
private static $in_phar;
public static function init(){
self::$in_phar = defined('PHAR_CURRENT');
}
public static function phar_include($path){
if(self::$in_phar)
include PHAR_CURRENT."/".$path;
else include $path;
}
public static function phar_exec($cmd, &$out){
... | true |
177287577119b48167c91fc31d1030d74d720010 | PHP | militest/mycheatsheets | /php/functions.php | UTF-8 | 2,858 | 3.859375 | 4 | [] | no_license | <?php
declare(strict_types = 1);
$a = 10;
function add(int $arg) : int {
// global $a;
$a = $GLOBALS['a'];
return $a + $arg;
}
function sum($name = 'default', ...$nums) {
$sum = 0;
foreach($nums as $num) {
$sum += $num;
}
return $sum;
}
echo sum('name',1,4,1,6,8,9,2,14);
/... | true |
15f41fcba0249c1200edd367115264528cb6955c | PHP | maiwang79/cnquinary | /library/Quinary/Base/Stem.php | UTF-8 | 593 | 2.75 | 3 | [] | no_license | <?php
namespace Quinary\Base;
/**
* 天干基本类
*/
//$stem_types = array('jia'=>WuXing::mu,'yi'=>WuXing::mu,'bin'=>WuXing::huo,'din'=>WuXing::huo,'wu'=>WuXing::tu,'ji'=>WuXing::tu,'gen'=>WuXing::jin,'xin'=>WuXing::jin,'ren'=>WuXing::shui,'gui'=>WuXing::shui);
class Stem extends Elements {
static $SYMBOL = 'G';
stati... | true |
d1f53455ef2f79b531e6c97f10926b35213bf095 | PHP | rickselby/laravel-request-field-types | /src/Traits/RulesTrait.php | UTF-8 | 912 | 2.796875 | 3 | [
"MIT"
] | permissive | <?php
namespace RickSelby\LaravelRequestFieldTypes\Traits;
use Illuminate\Support\Collection;
/**
* Allow a class to manage a list of rules for input fields.
*/
trait RulesTrait
{
/** @var Collection */
protected $rules;
public function setRules($inputField, array $rules)
{
$rules = collec... | true |
360e690fac4e036101b315cb184b9939b90793d6 | PHP | i-om/DBT | /util/class.db1UserInfo.php | UTF-8 | 5,885 | 2.828125 | 3 | [] | no_license | <?php
include('class.dbConnect.php');
/*
* Class/ db1UserInfo
*
* Use/ explain in the function
*
*
*/
//! inheriting class from class dbConnect
class db1UserInfo extends dbConnect
{
function set_data($sLoginId,$sUserName, $sPassword, $sHintQuestion, $sHintAnswer, $sEmail, $sRights, $sDepartmen... | true |
e4409530500da9b59d38bf62e0f11f65c89fe1e9 | PHP | bobbymcdonald27/sois | /helper/phpform.php | UTF-8 | 1,537 | 3.140625 | 3 | [] | no_license | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Assignment 4 Example</title>
</head>
<body>
<form action="
... | true |
ac9fdf712e7a9c8230cf5992bf35ebe82b5cec70 | PHP | awsninja/awsninja_cloudfrontjavascript | /examples/serviceTest.php | UTF-8 | 1,058 | 2.765625 | 3 | [] | no_license | #!/usr/bin/php -q
<?php
/**
* CloudFrontJavascript Service
*
* serviceTest.php - Uses CloudFrontJavaScriptService to generate the script HTML tags to insert into web pages.
*
*/
define('NINJA_BASEPATH', dirname(__FILE__) . '/../../');
require_once(NINJA_BASEPATH . 'awsninja_cloudfrontjavascript/CloudFrontJavaScr... | true |
659e155124f1385ab2a17f649c0ff1998f83f4bb | PHP | waydelyle/quarrymanagement | /app/Http/Controllers/VehicleController.php | UTF-8 | 1,438 | 2.53125 | 3 | [] | no_license | <?php namespace App\Http\Controllers;
use Auth;
use App\Vehicle;
use Illuminate\Http\Request;
use Illuminate\Http\RedirectResponse;
class VehicleController extends Controller
{
public function show()
{
$vehicles = Vehicle::where('id', '!=', Vehicle::NO_VEHICLE)->get();
return view('vehicles'... | true |
7574a53f7684cfbbf9f7f2ea7ed06c207e8764f8 | PHP | PaperlessHouse/nextcloud-faxapp | /lib/Db/FaxMapper.php | UTF-8 | 771 | 2.578125 | 3 | [] | no_license | <?php
namespace OCA\FaxApp\Db;
use OCP\IDBConnection;
use OCP\AppFramework\Db\Mapper;
class FaxMapper extends Mapper {
public function __construct(IDBConnection $db) {
parent::__construct($db, 'fax');
}
/**
* @throws \OCP\AppFramework\Db\DoesNotExistException if not found
* @throws \... | true |
7d3c11e5dbec2490b9a860d0c21326ba5950c6e9 | PHP | mu4ddi3/compensa-webservice | /src/ArrayType/ArrayOfBurglaryExcludedDiscountFactor.php | UTF-8 | 6,851 | 2.546875 | 3 | [] | no_license | <?php
namespace Mu4ddi3\Compensa\Webservice\ArrayType;
use \WsdlToPhp\PackageBase\AbstractStructArrayBase;
/**
* This class stands for ArrayOfBurglaryExcludedDiscountFactor ArrayType
* Meta informations extracted from the WSDL
* - nillable: true
* - type: tns:ArrayOfBurglaryExcludedDiscountFactor
* @subpackage ... | true |
62e93d6cffb888c0bd02bd6ccf711443f050a337 | PHP | aryashreep/magento2training | /Unit4/RootCategories/ViewModel/StoresList.php | UTF-8 | 1,482 | 2.828125 | 3 | [] | no_license | <?php
namespace Unit4\RootCategories\ViewModel;
use \Magento\Framework\View\Element\Block\ArgumentInterface;
use \Magento\Catalog\Model\CategoryFactory;
use \Magento\Store\Model\StoreManager;
/**
* Class StoresList
* @package Unit4\RootCategories\ViewModel
*/
class StoresList implements ArgumentInterface {
/**
... | true |
33b64a8005aed486f5ebcce3afd3cb47404f6520 | PHP | HyperEnte/AdvancedReport | /src/Crasher508/AdvancedReport/Report.php | UTF-8 | 724 | 3.390625 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace Crasher508\AdvancedReport;
class Report
{
public $reason = "", $reporter = "", $player = "", $info = "", $date = "";
/**
* Plot constructor.
*
* @param string $reason
* @param string $reporter
* @param string $player
* @param string $info
* @pa... | true |
19ddff4763f2d930d2cdc736a35bbe741f6f29de | PHP | aabizri/g3c | /website/Views/FAQ/faq/faq.php | UTF-8 | 656 | 2.6875 | 3 | [] | no_license | <main>
<div id="faqpage">
<h2 id="titre">Foire Aux Questions</h2>
<?php
foreach ($data["qa_results"] as $p) {
//on récupère la question, puis sa réponse
$question = $p->getQuestion();
$answer = $p->getAnswer();
?>
<?php
... | true |
dba5ba0697527d86f6c5d3216c36b613a3a98924 | PHP | Kennyl/pixmicat_modules | /mod_imgsizelimit/mod_imgsizelimit.php | UTF-8 | 1,146 | 2.609375 | 3 | [
"LicenseRef-scancode-public-domain"
] | permissive | <?php
/*
mod_imgsizelimit.php
*/
class mod_imgsizelimit extends ModuleHelper {
private $MIN_W = 320; // 最小寬度 (0為不限制)
private $MIN_H = 240; // 最小高度 (0為不限制)
private $MAX_W = 5000; // 最大寬度 (0為不限制)
private $MAX_H = 5000; // 最大高度 (0為不限制)
private $MIN_FILESIZE = 0; // 最小檔案大小 (位元組, 0為不限制)
public function ... | true |
be4ef44e5be9551309173f9de9098d27e3d4edc1 | PHP | ellalves/voed | /app/Repositories/CategoryRepository.php | UTF-8 | 1,416 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Repositories;
use App\Models\Category;
use App\Repositories\Contracts\CategoryRepositoryInterface;
use App\Tenant\Scopes\TenantScope;
class CategoryRepository implements CategoryRepositoryInterface
{
protected $entity, $tenant;
public function __construct(Category $category)
{
... | true |
838194a5d6428a46ae37c7c93a208e1792246802 | PHP | Gael972/plateforme_ENT | /src/Entity/Ticket.php | UTF-8 | 3,154 | 2.578125 | 3 | [] | no_license | <?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use App\Entity\Statut;
use App\Repository\StatutRepository;
/**
* @ORM\Entity(repositoryClass="App\Repository\TicketRepository")
*/
class Ticket
{
private $statutC;
/**
* @ORM\Id()
* @ORM\GeneratedValue()
* @ORM\Column(type="integer... | true |
1059d71182b112511b0e57db78b0d414a82a2f1a | PHP | alesinicio/EasysubtitleDownloader | /tests/alesinicio/Easysubtitle/EasysubtitleDownloader.test.php | UTF-8 | 6,811 | 2.890625 | 3 | [] | no_license | <?php
namespace alesinicio\Easysubtitle;
use Exception;
/**
* Test class for `subtitleDownloader`.
*
* @author alexandre.sinicio
* @version 1.000.000
*/
class EasysubtitleDownloaderTest {
private static $testResults = [];
public static function runAllTests() {
$tests = get_class_methods(__CLASS... | true |
ca43f85faef50cadfcf360ee215eb4cb246add1f | PHP | igor822/PHPlockchain | /src/Block.php | UTF-8 | 3,287 | 3.15625 | 3 | [
"MIT"
] | permissive | <?php declare(strict_types=1);
namespace Blockchain;
class Block
{
const HASH_TYPE = 'sha256';
private $previousHash;
private $data = [];
private $blockHash;
private $timestamp;
private $bits;
private $nounce;
/**
* @param string $previousHash
* @param int $timestamp
... | true |
c466de1924bffa62e8dcfd2bb6da40421926015d | PHP | GabrielGrrr/EliteNews | /src/Entity/ContactMessage.php | UTF-8 | 2,400 | 2.578125 | 3 | [] | no_license | <?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass="App\Repository\ContactMessageRepository")
*/
class ContactMessage
{
/**
* @ORM\Id()
* @ORM\GeneratedValue()
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="str... | true |
f2808aa81aa91aefb0534d4402f09f40802f895f | PHP | DanielCsonka987/WFAThesisProject | /WFAThesisProject/ThesisChemoSafeStore/php/requests/requestModellerInterfare.php | UTF-8 | 2,461 | 2.640625 | 3 | [] | no_license | <?php
class deletActiveRequest{
private $conn;
private $queryOfDeletActiveRequest =
"UPDATE keresek SET keres_erveny=0, keres_modosit=?"
. " WHERE keres_id=? AND keres_erveny=1 AND keres_teljesit=0";
public function setConnectionDatas($connection){
$this->conn = $... | true |
fdd6bd4622f7efe88008e70109ff247908b82075 | PHP | nikola-n/php | /php-bits/array_destructruing.php | UTF-8 | 512 | 2.921875 | 3 | [] | no_license | <?php
$people = [
['John', 'Doe'],
['Jeffrey', 'Way']
];
foreach($people as [$first, $last])
{
//first se odneuva na John, last na Doe
//[$first, $last] = $person;
var_dump("{$first} {$last}");
}
//Ako sakame samo vtoriot oelement da go zeeeme
[,$last]= ['John','Doe'];
var_dump($last);
//[$user1, $u... | true |
a7978dd2387f7788c33ef5959763acf6ae0411e0 | PHP | ncariqueor/mantigua | /mercaderia_antigua.php | UTF-8 | 10,796 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
function mercaderiaAntigua($local, $dia)
{
ini_set('max_execution_time', 0);
date_default_timezone_set("America/Asuncion");
$local->query("delete from mercaderia_antigua where dia = $dia");
$division = array('HOMBRES', 'DEPORTES', 'MUJER', 'ACCESORIOS', 'INFANTIL', 'TECNOLOGIA', 'DECO-HOGAR', '... | true |
797f2fe3e727f21b96ff5663d2035aca18588694 | PHP | thebear008/ged | /index.php | UTF-8 | 25,314 | 2.71875 | 3 | [
"MIT"
] | permissive | <?php
session_start();
include('class.DB.php');
include('class.Search.php');
include('class.Log.php');
function slugify($text)
{
// replace non letter or digits by -
$text = preg_replace('~[^\pL\d]+~u', '-', $text);
// transliterate
$text = iconv('utf-8', 'us-ascii//TRANSLIT', $text);
// remove unwanted ... | true |
392cda9ea4b84838a247ad7bd2bdb989705b2bcb | PHP | muhammetakkus/TestCIProject | /solid/IoC/Item/Ucgen.php | UTF-8 | 168 | 2.765625 | 3 | [] | no_license | <?php namespace Solid\IoC\Item;
use Solid\IoC\SquareInterface;
class Ucgen implements SquareInterface
{
public function draw()
{
return "Üçgen çizildi..";
}
} | true |
129ef5f2c68ed4b5f85d8190384426223b3d7507 | PHP | qetzal/ecwid-api-playground | /ecwid_export_categories/ecwid_export_categories.php | UTF-8 | 3,277 | 2.71875 | 3 | [] | no_license | <?php
header("Content-Type: application/csv");
header("Content-Disposition: attachment; Filename=ecwid_categories.csv");
header("Pragma: no-cache");
header("Expires: 0");
$ecwid_settings = parse_ini_file("ecwid_settings.ini", false);
if( $ecwid_settings["storeid"] > 0 ) {
$storeid = $ecwid_settings["storeid"]... | true |
597f72e7724451853921fd03393093f042cfe873 | PHP | scrap-bin/unicycle | /src/R2/ORM/EntityIterator.php | UTF-8 | 1,425 | 2.828125 | 3 | [
"MIT"
] | permissive | <?php
namespace R2\ORM;
use R2\ORM\EntityRepositoryInterface as RepoInterface;
class EntityIterator extends \ArrayIterator
{
private $repo;
private $entityInstance;
/**
* Constructor
* @param RepoInterface $repo
* @param array $records
*/
public function __construct(RepoI... | true |
525bec302b4c9ba687f35eb16e0a48ecc355225c | PHP | ecommercebox/yii2-billing | /components/CurrencyLayer.php | UTF-8 | 2,355 | 2.71875 | 3 | [] | no_license | <?php
/**
* @author Harry Tang <harry@powerkernel.com>
* @link https://powerkernel.com
* @copyright Copyright (c) 2017 Power Kernel
*/
namespace powerkernel\billing\components;
use common\components\CurrencyFraction;
use Yii;
use yii\httpclient\Client;
/**
* Class CurrencyLayer
* @package powerkernel\billing... | true |
76741324828d8aa0adc6cdfa065e1bf955dcaa75 | PHP | martijnengler/moneybird_php_api | /RecurringTemplate/Subject.php | UTF-8 | 607 | 2.890625 | 3 | [
"MIT"
] | permissive | <?php
/*
* RecurringTemplate subject interface
*/
namespace Moneybird;
/**
* RecurringTemplate subject is an object that has invoices (contact or estimate)
*/
interface RecurringTemplate_Subject {
/**
* Create an invoice
*
* @return RecurringTemplate
* @access public
*/
public function createRecurr... | true |
4910324e4b980e59075da75d1db451887ecf569e | PHP | nishilshah17/HouseApp | /Server-Side/getcomments.php | UTF-8 | 1,165 | 2.53125 | 3 | [] | no_license | <?php
include 'mysqlconnect.php';
include 'getdata.php';
$postID = $json->{'postID'};
$comments = array();
$resultPost = mysql_query('SELECT * FROM posts WHERE postID = "'.$postID.'"');
$rowPost = mysql_fetch_assoc($resultPost);
$userID = $rowPost['userID'];
$resultUser = mysql_query('SELECT * FROM users WHERE use... | true |
333c0cbb437a1bdd9b6fa346b2b53f5834aebce1 | PHP | liunian/themes | /DJ_v1/functions.php | UTF-8 | 11,202 | 2.515625 | 3 | [] | no_license | <?php
register_nav_menus(array(
'primary' => 'Primary Navigation'
));
if ( ! function_exists( 'DJ_comment' ) ) :
/**
* Template for comments and pingbacks.
*
* To override this walker in a child theme without modifying the comments template
* simply create your own DJ_comment(), and that function will... | true |
a23d01e66f624964232973562335e94b05c159e9 | PHP | ismaelgomesesilva/DesignPatterns | /src/Behavioral/State/State.php | UTF-8 | 299 | 2.96875 | 3 | [] | no_license | <?php
namespace DesignPattern\Behavioral\State;
abstract class State
{
protected Context $context;
public function setContext(Context $context)
{
$this->context = $context;
}
abstract public function handle1(): void;
abstract public function handle2(): void;
}
| true |
5f61fa5face7e62c50389defd15bc1850f0996a2 | PHP | josenect/Curso-de-Manejo-de-Datos-en-PHP-Platzi-2020 | /formatodedatos.php | UTF-8 | 1,008 | 3.53125 | 4 | [] | no_license | <?php
/**
*
* Alterar Datos de Variables Ejemplo
* fundir datos en miniscula strtolower
* fundir datos en mayuscula strtoupper
* fundir la primera letra de en mayuscula ucfirst
* fundir la primera letra de en miniscula lcfirst
*/
$text = "<h1> PHP es UN LENGUAJE , año 2020 , programación</h1> ";
echo ... | true |
ceadc8f8e7913e9a5c1ca3a630566827f2be447b | PHP | jeristiano/carriepigeon | /app/Exception/Handler/ValidateExceptionHandler.php | UTF-8 | 2,237 | 2.515625 | 3 | [] | no_license | <?php
declare(strict_types=1);
/**
* This file is part of Hyperf.
*
* @link https://www.hyperf.io
* @document https://doc.hyperf.io
* @contact group@hyperf.io
* @license https://github.com/hyperf-cloud/hyperf/blob/master/LICENSE
*/
namespace App\Exception\Handler;
use App\Constants\ErrorCode;
use Hyperf\... | true |
ba63392f4ccd9200a64f447fe2e33408cda89617 | PHP | chapter-three/AppleNewsAPI | /src/Document/Styles/Fills/Gradients/GradientFill.php | UTF-8 | 1,385 | 3.0625 | 3 | [
"MIT"
] | permissive | <?php
/**
* @file
* An Apple News Document GradientFill.
*/
namespace ChapterThree\AppleNewsAPI\Document\Styles\Fills\Gradients;
use ChapterThree\AppleNewsAPI\Document\Base;
use ChapterThree\AppleNewsAPI\Document\Styles\Fills;
/**
* An Apple News Document GradientFill.
*/
abstract class GradientFill extends Fi... | true |
a7873b5ad5adb6da393040486132f0b8800b0b16 | PHP | mthomps4/Laracast | /app/Http/Controllers/NotesController.php | UTF-8 | 1,212 | 2.75 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Card;
use App\Note;
class NotesController extends Controller
{
protected $fillable = ['body'];
public function store(Request $request, Card $card) //Card Id has been passed so you can pass in full card.
{
$this->valid... | true |
116ec38f3074a61c6811da721ae169ff61dc06f2 | PHP | maryrio7/Ejercicios-php-online | /tema2/ejercicio4/ejercicio6.php | UTF-8 | 438 | 2.59375 | 3 | [] | no_license | <?php
include '../ejercicio2/cabecera.php';
include '../ejercicio2/pie.php';
cabecera('ejercicio6');
echo '<table>';
for($c=0; $c<5; $c++){
echo '<tr>';
for($f=0; $f<15; $f++){
if ($c==0 or $c==4){
echo '<td>'.'1'.'</td>';
}
else if ($f==0 or $f==14)
echo '<td>'.... | true |
948ea215dcc32ecab0133c6cbfe66f6d40fb3310 | PHP | ScARYlink/arrays_loops_tasks | /task9.php | UTF-8 | 127 | 3.28125 | 3 | [] | no_license | <?php
# 9. Выведите столбец чисел от 1 до 100.
for ($k = 1; $k <= 100; $k++) {
echo "$k"."<br>";
} | true |
72cdb6dea41d1c0f5dd78411802979c9989b8d4e | PHP | kght6123/ossnotes | /backend2/src/Resource/App/Todos.php | UTF-8 | 2,408 | 2.8125 | 3 | [
"Apache-2.0"
] | permissive | <?php
// namespace はベンダー名\アプリ名\パッケージ名\クラス名 間違うとエラー
namespace kght6123\ossnote\Resource\App;
use BEAR\Package\Annotation\ReturnCreatedResource;
use BEAR\RepositoryModule\Annotation\Cacheable;
use BEAR\Resource\ResourceObject;
use Ray\AuraSqlModule\AuraSqlInject;
/**
* ToDoクラス(検証用)
*
* $ php bin/app.php post '/tod... | true |
dd53726c16e21def22c63c700343d302c2dffedd | PHP | Ronald33/Patata-Framework | /back-end/model/dao/IUsuarioDAO.php | UTF-8 | 323 | 2.640625 | 3 | [] | no_license | <?php
interface IUsuarioDAO
{
public function selectAll();
public function selectById($id);
public function selectByUserAndPassword($user, $password);
public function insert(Usuario $usuario);
public function update(Usuario $usuario);
public function delete($id);
public function setHabilitado($id, $habilitado);... | true |
9e84e3d98db3b633c6621ce91cfbfa1981523dbe | PHP | xaraya/core | /html/lib/creole/drivers/pdosqlite/PdoSQLiteIdGenerator.php | UTF-8 | 558 | 2.5625 | 3 | [] | no_license | <?php
require_once 'creole/common/PdoIdGeneratorCommon.php';
/**
* SQLite IdGenerator implimenation.
*
* @author Hans Lellelid <hans@xmpl.org>
* @version $Revision: 1.4 $
* @package creole.drivers.sqlite
*/
class PdoSQLiteIdGenerator extends PdoIdGeneratorCommon {
// XARAYA MODIFICATION
publ... | true |
59297086e0cee6721fb1d42f422dca5d475ef159 | PHP | drom98/ESTClinic | /backend/utils.php | UTF-8 | 5,746 | 2.546875 | 3 | [] | no_license | <?php
if(!defined('JS')) define("JS", substr(dirname(__DIR__), strlen($_SERVER['DOCUMENT_ROOT'])) . '/lib/');
if(!defined('BACKEND')) define("BACKEND", substr(dirname(__DIR__), strlen($_SERVER['DOCUMENT_ROOT'])) . '/backend/');
if(!defined('ADMIN_USERS')) define("ADMIN_USERS", substr(dirname(__DIR__), strlen($_SERVER... | true |
704139f1e5b5117bde757eef92b8b974a1ba976b | PHP | fadilkun45/php-cloud-storage | /cloud storage wannabe/login.php | UTF-8 | 2,571 | 2.75 | 3 | [] | no_license | <?php
// start sesi
session_start();
require 'function.php';
// saat ada cookie
if(isset($_COOKIE['id']) && isset($_COOKIE['key']) ){
$id = $_COOKIE['id'];
$key = $_COOKIE['key'];
$result = mysqli_query($db_connect, "SELECT username FROM user WHERE id = '$id'");
$row = mysqli_fetch_assoc($result... | true |
4578043be4cd602210b9623a6f01e44d11b9ab65 | PHP | Dmutryk/Code-Alchemy-MVC-Framework-for-PHP-and-PostgreSQL | /framework/classes/Code_Alchemy/Vendors/Twilio/Twilio.php | UTF-8 | 2,003 | 2.8125 | 3 | [
"MIT"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: dgreenberg
* Date: 10/10/15
* Time: 2:24 PM
*/
namespace Code_Alchemy\Vendors\Twilio;
use Code_Alchemy\Core\Alchemist;
/**
* Class Twilio
* @package Code_Alchemy\Vendors\Twilio
*
* Twilio connector service class
*/
class Twilio extends Alchemist{
/**
* Sa... | true |
c4b72f4ec25b88b7031ca65ce8bf25fe8b5fb210 | PHP | crimiactive/AwfulPlugin | /SetBlock/src/SetBlock/SetBlock.php | UTF-8 | 1,080 | 2.9375 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace SetBlock;
use pocketmine\command\Command;
use pocketmine\command\CommandSender;
use pocketmine\level\Level;
use pocketmine\Player;
use pocketmine\plugin\PluginBase;
class SetBlock extends PluginBase{
const CMD_PREFIX = "[SetBlock]";
public function onCommand(CommandS... | true |
60372df29e9e23a2ca717999d3fa6b5bce4269c2 | PHP | kristuff/phtemail | /lib/Core/StylizedElement.php | UTF-8 | 3,377 | 2.921875 | 3 | [
"MIT"
] | permissive | <?php
/**
* ____ _ _ _ _
* | _ \| |__ | |_ ___ _ __ ___ __ _(_) |
* | |_) | '_ \| __/ _ \ '_ ` _ \ / _` | | |
* | __/| | | | || __/ | | | | | (_| | | |
* |_| |_| |_|\__\___|_| |_| |_|\__,_|_|_|
*
* This file is part of Kristuff\Phtemail.
*
* (c) Kristuff <contact@kristuff.fr... | true |
5e9e5c50ac07d0791026cc56460b037d4eadc481 | PHP | DISCOOS/rescue-me | /src/admin/locale/domain/admin.domain.php | UTF-8 | 951 | 2.59375 | 3 | [
"BSD-2-Clause"
] | permissive | <?php
namespace RescueMe\Locale\Admin;
$defined = defined('DOMAIN_ADMIN');
if($defined === FALSE) {
define('DOMAIN_ADMIN','admin');
// Define indirectly used messages
define('Not sent', T_('Not sent'));
/**
* Get json string in domain 'admin'
* @return... | true |