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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
d6dc3e0b9d0ef1f97490219fd51aa7b49547af3a | PHP | tikasukra/tugas2 | /app/Http/Controllers/MahasiswaController.php | UTF-8 | 1,465 | 2.71875 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Mahasiswa;
class MahasiswaController extends Controller
{
//
public function index(){
// mengambil data mahasiswa
$mahasiswa = Mahasiswa::all();
// mengirim data mahasiswa ke view mahasiswa
return view('mahasiswa... | true |
ea118f3e8198958c00a99447566ca0c2dfee68f9 | PHP | yumindayu/leetcode-php | /1248.php | UTF-8 | 703 | 3.828125 | 4 | [] | no_license | <?php
class Solution
{
/**
* @param Integer[] $nums
* @param Integer $k
* @return Integer
*/
public function numberOfSubarrays($nums, $k)
{
$map = [];
for ($i = 0; $i < count($nums); $i++) {
if ($nums[$i] % 2 != 0) {
array_push($map, $i);
... | true |
0a32cb6a40786db0621c59002a508981ab2ec969 | PHP | patrick-frei/CFLMS-CodeReview10-Freinschlag | /ajax/db_delete_general.php | UTF-8 | 558 | 2.671875 | 3 | [] | no_license | <?php
require_once '../php/db_connect.php';
if (!isset($table)) die("No table submitted!");
if (!isset($delete_key)) die("No delete key submitted!");
if (!isset($delete_value)) die("No delete value submitted!");
$sql = "DELETE FROM `$table` WHERE `$delete_key` = '$delete_value'";
if ($connect->query($sql) === true) {
... | true |
6ecbe9f454bd83f9bf255485f6e4d808c2299c64 | PHP | thanhtruong1992/textsdaily-vue | /app/Services/BaseService.php | UTF-8 | 7,740 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Services;
use Illuminate\Support\Facades\Session;
use Illuminate\Support\Facades\File;
use Illuminate\Support\Facades\Crypt;
use Carbon\Carbon;
class BaseService {
/**
* fn response success
*
* @param array $data
* @return object
*/
public function success($data = array()) {
return... | true |
fd40952b74a5eeb24d9b89c812f2851dc74bd56b | PHP | ASDAFF/ApelsinBitrixNew | /apls_lib/contacts-todel/DataContactsWokers.php | UTF-8 | 2,618 | 2.640625 | 3 | [] | no_license | <?php
if (!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED!==true) die();
/**
* Получение данных контактов менеджеров
*
* @author Olga Rjabchikova
* @copyright © 2010-2016, CompuProjec
* @created 01.07.2016 10:39:55
*/
class DataContactsWokers {
private $idBlock; // id инфоблока (Конт... | true |
97d670335aa7f830bf3c16a1f3973682c822abd4 | PHP | yoshiogithub/ListaCompra | /insertarMass.php | UTF-8 | 871 | 2.703125 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<title>Insertar Datos Mass</title>
<link rel="stylesheet" type="text/css" href="css/style.css">
</head>
<body>
<h1>INGRESAR DATOS MASS</h1>
<hr>
<?php
include("conexion.php");
$date=date('Y-m-d');
$fecha=$date;
$productoMass=$_POST["productoMass"];
$numAleatorio... | true |
3dc2cfe15d9c62fb36e4972f834d2123fbc46f77 | PHP | tanomartin/salguerofutbol | /backEnd/model/goleadores.php | UTF-8 | 3,004 | 2.671875 | 3 | [] | no_license | <?
include_once "mysql.class.php";
class Goleadores {
var $id;
var $nombre;
var $idEquipo;
var $idTorneo;
var $goles;
function Goleadores($id="") {
if ($id != "") {
$goleadores = $this->get($id);
$this->id = $goleadores[0]["id"];
$this->nombre = $goleadores[0]["nombre"];
$this->idEquipo = $gol... | true |
97adfa3369dde21a85ca5f9d61e735521ed66c6e | PHP | jschinasi/Projects | /SQL, PHP, HTML, CSS/11E2-Schinasi.php | UTF-8 | 2,131 | 3.375 | 3 | [] | no_license | <?
/******************************************************************
* Class Exercise 11
*****************************************************************/
echo "<br> Class Exercise 11 - Jake Schinasi";
echo "<br> The request method is " . $_SERVER['REQUEST_METHOD'];
/**********************************************... | true |
37ccf4f4c0d783eab67d8bab1097a0e961ce06da | PHP | voryx/ThruwayCommon | /src/Message/Traits/RequestTrait.php | UTF-8 | 503 | 2.828125 | 3 | [] | no_license | <?php
namespace Thruway\Message\Traits;
/**
* Class RequestTrait
* @package Thruway\Message\Traits
*/
trait RequestTrait
{
/**
* @var int
*/
private $requestId;
/**
* Get request ID
*
* @return int
*/
public function getRequestId()
{
return $this->request... | true |
ea59b863f41df715a88f030378362a518311c2ac | PHP | kaomanfen/gateway-admin | /app/Listeners/ReleaseNotification.php | UTF-8 | 888 | 2.625 | 3 | [] | no_license | <?php
namespace App\Listeners;
use App\Events\Release;
use App\Services\MessageService;
use Kmf\Ding\Services\DingService;
class ReleaseNotification
{
public $service;
private $sendType = [
1=>'分组',//分组
2=>'项目',//项目
3=>'接口发布'//项目
];
/**
* Create the event listener.
... | true |
72bb457c1e46674c81bd7c5714257a8b90e22b8a | PHP | isometriks/JsonLdDumper | /src/Dumper.php | UTF-8 | 608 | 3.09375 | 3 | [] | no_license | <?php
namespace Isometriks\JsonLdDumper;
class Dumper implements DumperInterface
{
private $parser;
public function __construct(ParserInterface $parser)
{
$this->parser = $parser;
}
public function dump($data)
{
$parsed = $this->parser->parse($data);
return $this->du... | true |
4b0c15100951a692a0d164197f0036bcde3dfd13 | PHP | casanova94/webSystem | /models/model_control.php | UTF-8 | 1,568 | 2.796875 | 3 | [] | no_license | <?php
class model_control{
private $DB;
private $controles;
function __construct(){
$this->DB = conexion::getConnetion();
$this->controles = array();
}
function get(){
$query = $this->DB->query("SELECT c.cliente_id,c.nombre,c.apellido,cs.peso,cs.medida_cintura,cs.fecha_control,cs.control... | true |
c60ab2447303e9967fe6b3c50d6176f0b31a1432 | PHP | geoffreyc/ukloancalculator | /loancalc.php | UTF-8 | 5,125 | 2.65625 | 3 | [] | no_license | <?php
define("DEBUGGING", false);
class studentLoanCalc
{
public $type;
public $salary;
public $loantotal;
private $avrgInterest = 1.5;
private $types = array(
"PRE" => 15795,
"POST" => 21000
);
private $typesyears = array(
"PRE" => 25,
"POST" => 30
);
private... | true |
fb3120003733a146c0ce1837397a39da6cb887ee | PHP | the-moominz/Forum | /dist/application/controllers/admin/delete/DeleteController.class.php | UTF-8 | 1,059 | 2.96875 | 3 | [] | no_license | <?php
// Classe pour gérer la page principale du panneau d'administration
class DeleteController {
public function httpGetMethod(Http $http, array $queryFields)
{
/*
* Méthode appelée en cas de requête HTTP GET
*
* L'argument $http est un objet permettant de faire des redirections etc.
... | true |
b4917009caf5ec496368eb010dde5d965b444281 | PHP | hoangsoft90/wordpress-theme | /inc/widgets/rt-product-slider.php | UTF-8 | 8,563 | 2.53125 | 3 | [] | no_license | <?php
if( ! class_exists( 'RT_Widget_Product' ) ) {
class RT_Widget_Product extends WP_Widget {
function __construct() {
$widget_ops = array(
'classname' => 'rt-widget rt-product-category',
'description' => 'Hiển thị danh sách sản phẩm theo chuyên mục.'
);
parent::__cons... | true |
4e6a8c47dcf33563fb40f355c9cb76dbbcd73e66 | PHP | mroien/ics325 | /Project4/product.php | UTF-8 | 1,883 | 2.625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: Tim
* Date: 4/6/2015
* Time: 9:21 PM
*/
require("header.php");
require("leftNav.php");
require("connect.php");
if (isset($_REQUEST['prod_name'])) {
$prod_name = $_REQUEST['prod_name'];
}
$result = $connection->query("SELECT * FROM product WHERE prod_name='$prod_name'"... | true |
07eef5178ac4fcab1fc333caa55934340d58f1bf | PHP | crango/prueba-tecnica | /app/controllers/Empleados.php | UTF-8 | 827 | 2.65625 | 3 | [] | no_license | <?php
/**
*
*/
class Empleados extends Controller {
/**
* @var mixed
*/
private $empleadoModel;
private $areaModel;
private $rolModel;
public function __construct() {
// The below is how we can load models with the controller
$this->empleadoModel = $this->model('Empleado');
}
public function index() ... | true |
6c57727103d0c0b8857a1175621cf15be8cb3f05 | PHP | DioguitoAndre/comp_curric_1 | /exercicios/exercicio2.php | UTF-8 | 1,570 | 3.84375 | 4 | [] | no_license | <?php
/*2. Depois da tag <h1> criar uma div #conteudo e nela adicionar o seguinte código PHP:
$nome1 = “Fulano”;
$nome2 = “Fulana”;
$nome3 = “Ciclano”;
$sexo1 = “M”;
$sexo2 = “F”;
$sexo3 = “M”;
a) Concatenar os nomes e imprimir numa tag <p>, e mostrar qual sexo predominante na equipe. Exemplo:
Se o $sexo1 for... | true |
f969e95dbe0595652c01cf3ce318a56377c2a313 | PHP | javiiglesias/AgenciaM14 | /model/Persistence/class_obra_actordb.php | UTF-8 | 1,954 | 2.859375 | 3 | [] | no_license | <?php
include_once("controller/function_AutoLoad.php");
require_once("config/config.inc.php");
require_once("config/db.inc.php");
class obra_actorDb {
public function inserir($obra_actor) {
var_dump($obra_actor);
$query = "insert into obra_actor values('', '" . $obra_actor->getObra() . "', '" . $... | true |
b0cce7c310da0a7632fd1ad94822a3aa75daebbc | PHP | toanht15/moni | /apps/classes/entities/InquirySection.php | UTF-8 | 653 | 2.75 | 3 | [] | no_license | <?php
AAFW::import ( 'jp.aainc.aafw.base.aafwEntityBase' );
class InquirySection extends aafwEntityBase {
// セクションのカテゴリ
const TYPE_MAJOR = 1; // 大
const TYPE_MEDIUM = 2; // 中
const TYPE_MINOR = 3; // 小
public static $levels = array(
self::TYPE_MAJOR,
self::TYPE_MEDI... | true |
7ffff07aa1ce35e570b8881d8944aa9144f23549 | PHP | mesibo/samples | /backend-api/php/mesiboapi.php | UTF-8 | 3,846 | 2.96875 | 3 | [] | no_license | <?php
require_once('mesiboconfig.php');
require_once('json.php');
$err = false;
if(!isset($apptoken))
$err = true;
if ($err) {
echo "ERROR: Please define your app token. If you don't have one then signup at https://mesibo.com to get one";
exit();
}
/**************************************************************... | true |
85d96b87a8478e8802da5fdd93c6f87fbd5b9733 | PHP | luigif/WsdlToPhp | /samples/xignite-bonds/Get/Price/XiBondsTypeGetDailyOpenHighLowClosePrice.php | UTF-8 | 2,338 | 2.6875 | 3 | [] | no_license | <?php
/**
* Class file for XiBondsTypeGetDailyOpenHighLowClosePrice
* @date 08/07/2012
*/
/**
* Class XiBondsTypeGetDailyOpenHighLowClosePrice
* @date 08/07/2012
*/
class XiBondsTypeGetDailyOpenHighLowClosePrice extends XiBondsWsdlClass
{
/**
* The Identifier
* Meta informations :
* - minOccurs : 0
* -... | true |
5a8f03be924c67099ce07b4006d03acdf0cbfa57 | PHP | sergpitk/cli | /src/Command/Project/RollbackProjectCommand.php | UTF-8 | 3,418 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
/*
* This file is part of Ymir command-line tool.
*
* (c) Carl Alexander <support@ymirapp.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Ymir\Cli\Command\Project;
use Carbon\Carbon... | true |
f68f1745203bc93aae52a5ec9313538f06f36119 | PHP | DickyMontiel/Gestor-de-Cuentas | /app/controller/AdicionalesController.php | UTF-8 | 1,415 | 2.921875 | 3 | [] | no_license | <?php
require "app/model/AdicionalesModel.php";
class AdicionalesController{
private $model;
private $adicionales = array();
public function __construct(){
$this->model = new AdicionalesModel;
}
public function prepareData($cuenta, $informacio... | true |
1f9fe417861e1636eef6ad82e2f705bcf415259e | PHP | harysetiawan23/water-leak-appsa | /app/Http/Controllers/Api/LineMasterController.php | UTF-8 | 7,209 | 2.515625 | 3 | [] | no_license | <?php
namespace App\Http\Controllers\Api;
use Illuminate\Support\Facades\DB;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use App\LineMaster;
use Validator;
class LineMasterController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\... | true |
f27d81d3ee80620db3ef0a0d5cd7b206bae44f4e | PHP | snickers54/dblink | /library/mail.php | UTF-8 | 4,000 | 3.25 | 3 | [] | no_license | <?php
class mail
{
//this function is used for send mail. The first parameters is the dest (string) but he can to be a array.
//For that to be a array, $tab must be equal true else one mail will be send.
//the second parameters is the subject of the mail.
//$head is for additional headers. For example, Cc, BCc... | true |
7c1634e9c56291cd4eec9485ec14ddc22c588834 | PHP | thephpleague/flysystem | /src/PathPrefixerTest.php | UTF-8 | 3,255 | 2.90625 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace League\Flysystem;
use PHPUnit\Framework\TestCase;
class PathPrefixerTest extends TestCase
{
/**
* @test
*/
public function path_prefixing_with_a_prefix(): void
{
$prefixer = new PathPrefixer('prefix');
$prefixedPath = $prefixer->prefixPa... | true |
4a541fff662c38c9704170dc2043a94d4483b57f | PHP | nodes-php/bugsnag | /src/Support/Helpers/Report.php | UTF-8 | 2,510 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
if (!function_exists('bugsnag_report')) {
/**
* Report exception to Bugsnag.
*
* @author Casper Rasmussen <cr@nodes.dk>
*
* @param $exception
* @param array $meta
* @param null $severity
*
* @return void
*/
function bugsnag_report($exception, $meta... | true |
deda67b2b23669159da07e8b2d05f6388731a016 | PHP | sealzjh/php5.4-example | /2.php | UTF-8 | 115 | 2.84375 | 3 | [] | no_license | <?php
echo 0b10; //二进制以0b开头
echo 0x1f; //十六进制以0x开头
echo 037; //八进制以0开头
| true |
5b63a0df223cd63ea5451e205334f4737134ab65 | PHP | hikmahtiar6/camar_erp_ci | /application/models/Master_model.php | UTF-8 | 3,405 | 2.671875 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
/**
* Master model
*/
class Master_model extends CI_Model {
const TABLE_SHIFT = 'Factory.Shifts';
const TABLE_LEN = 'Inventory.MasterDimensionLength';
const TABLE_MACHINE = 'Factory.Machines';
const TABLE_BILLET = 'Inventory.MasterBilletTypes';
const TABLE_FINISHING = 'Finishing';
const TABLE_NEWMASTER ... | true |
f9919488b038c4ba4c3c5061e825c6a69c57f03a | PHP | SelimAtasever/php-unittest | /CorporationRegistry/CorporationRepositoryTest.php | UTF-8 | 2,500 | 2.75 | 3 | [] | no_license | <?php
use \model\CorporationRegistry\CorporationRepository;
use \model\CorporationRegistry\Corporation;
use \model\CorporationRegistry\CorporationId;
use \model\common\IOperationReporter;
use PHPUnit\Framework\TestCase;
class CorporationRepositoryTest extends TestCase{
private static \DB $db;
public static func... | true |
05158c9351522b09b7bc50b75886c9f0ed56731c | PHP | stoyantodorovbg/PHP-Web-Development-Basics | /OOP Basics Exercises/problem11/oldestMember.php | UTF-8 | 326 | 3.390625 | 3 | [
"MIT"
] | permissive | <?php
include 'Family.php';
include 'Person.php';
$lines = trim(intval(fgets(STDIN)));
$family = new Family();
for ($i = 0; $i < $lines; $i++) {
$input = trim(fgets(STDIN));
$arr = explode(' ', $input);
$person = new Person($arr[0], $arr[1]);
$family->addMember($person);
}
echo $family->getOldestMem... | true |
3423d2ccdeda74e6c5d0877ebaa517500159c5ef | PHP | Mohammad-Fayoumi/Products-API | /product/read_paging.php | UTF-8 | 2,076 | 2.875 | 3 | [
"MIT",
"Apache-2.0"
] | permissive | <?php
// file that will output "products" JSON data with pagination.
// required headers
header('Access-Control-Allow-Origin: *');
header('Content-Type: application/json; charset-UTF-8');
header("Access-Control-Allow-Methods: GET");
// include database, core, utilities and object files
include_once '../config/database... | true |
1ece2e92a62919e943d870edfc2e62b53daae8e8 | PHP | articstudio/bitbucket-deploy | /src/Middleware/RequestParser.php | UTF-8 | 1,902 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
namespace Articstudio\Bitbucket\Middleware;
use Articstudio\Bitbucket\Middleware\AbstractMiddleware;
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\StreamInterface;
use Articstudio\Bitbucket\Header;
use Articstudio\Bitbucket\Payload;
use Articstudio\Bit... | true |
d27a9a5e2f2f8748a5456f7dab34a7d7448d1266 | PHP | verbb/knock-knock | /src/services/Logins.php | UTF-8 | 3,457 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
namespace verbb\knockknock\services;
use verbb\knockknock\KnockKnock;
use verbb\knockknock\helpers\IpHelper;
use verbb\knockknock\models\Login;
use verbb\knockknock\records\Login as LoginRecord;
use Craft;
use craft\db\Query;
use craft\helpers\DateTimeHelper;
use craft\helpers\Db;
use yii\base\Component;
use yi... | true |
26bb553b9e95729c57702a364461d57b1b0614a0 | PHP | yodarunamok/keenmvc | /lib/css2xpath/Translator.php | UTF-8 | 7,687 | 2.828125 | 3 | [
"Artistic-2.0",
"BSD-3-Clause",
"MIT"
] | permissive | <?php
/**
* Created by IntelliJ IDEA.
* User: Chris Hansen (chris@iviking.org)
* Date: 4/29/21
* Time: 12:46 PM
*/
namespace KeenMVC\CSS2XPath;
/**
* Class Translator
*/
class Translator {
/** @var array */
private $rules;
/**
* @param string $selector
* @return string
*/
p... | true |
ba21448e6155cb297e1e36a36dc0ada5f58b2ba4 | PHP | no2key/ssh-1 | /tests/SSH/Credentials/KeyCredentialTest.php | UTF-8 | 4,365 | 2.71875 | 3 | [] | no_license | <?php
namespace SSH\Credentials;
use Bravo3\SSH\Connection;
use Bravo3\SSH\Credentials\KeyCredential;
class KeyCredentialTest extends \PHPUnit_Framework_TestCase
{
const DEFAULT_USER = 'root';
const NEW_USER = 'username';
const KEYFILE_PASSWORD = 'password';
const MISSING_FILE = 'a.mis... | true |
50963bd76d46db8559ae5aede518c6033cb18470 | PHP | MERZIOX/crud | /PHP/ingresar.php | UTF-8 | 2,249 | 2.734375 | 3 | [] | no_license | <?php
$id = $_POST['cedula'];
$nombres = $_POST['nombres'];
$apellidos = $_POST['apellidos'];
$correo = $_POST['correo'];
?>
<?php
$nombresCompletos = $nombres;
$nombre = explode(" ", $nombresCompletos);
$apellidosCompletos = $apellidos;
$apellido = explode(" ", $apellidosCompletos);
$cant = ... | true |
8f1792ddaab7629826c95918fdb625c66b169aea | PHP | dcrabtree12/ark_comix | /project_final/signUp.php | UTF-8 | 4,486 | 2.5625 | 3 | [] | no_license | <?php
include ('main_header.html');
include ('includes/logout-button.php');
//<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);
?>
<!-- Sign Up Form -->
<form action="" method="post" class="layout">
<!-- Title of Form -->
<h3 class="noindent"> Create Account </h3>
<?php include ('include... | true |
3a0ca4e7f371b39ce3d774978bbeaae0ab52323f | PHP | firomero/graphity-php | /src/main/php/Graphity/Repository/Repository.php | UTF-8 | 6,676 | 2.859375 | 3 | [
"Apache-2.0"
] | permissive | <?php
/**
* Copyright 2011 Graphity Team
*
* 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 required by applicable la... | true |
61973537e2a81b250f48901e1c7cac83299e2238 | PHP | kristina1111/SoftUni-PHP-Fundamentals | /07.OOP-Fundamentals/05.PizzaCalories/PizzaApp/Core/Commands/PizzaCommand.php | UTF-8 | 478 | 3.1875 | 3 | [] | no_license | <?php
namespace PizzaApp\Core\Commands;
use PizzaApp\Entities\Pizza;
class PizzaCommand
{
/**
* @param array $args
* @return Pizza
* @throws \Exception
*/
public function execute(array $args = []) : Pizza
{
$pizza = null;
if(count($args)===3){
$pizza = new Pi... | true |
01f8469d6c10a71cd06cfbd9d0021239b38649d5 | PHP | bincms/Shop | /CommerceML/SectionFactory.php | UTF-8 | 310 | 2.625 | 3 | [] | no_license | <?php
namespace Extension\Shop\CommerceML;
class SectionFactory
{
public function create($class, $element)
{
if($element === null) {
return null;
}
$className = 'Extension\\Shop\\CommerceML\\Section\\'.$class;
return new $className($element);
}
} | true |
b8fbf548b33a02c9cf67268a8dd8c2c6bb1194c6 | PHP | cawaweb/news-server | /apps/frontend/collections/Users.php | UTF-8 | 2,693 | 2.890625 | 3 | [] | no_license | <?php
namespace NewsServer\Frontend\Collections;
use Phalcon\Mvc\Collection;
class Users extends Collection
{
public $_id;
public $name;
public $username;
public $password;
public $role = 'Admin';
public $isActive = true;
public function initialize()
{
$this->useImplicit... | true |
dab7cb1d924933671c9c994eed8b7553abd69f31 | PHP | Truong2201/Nhom4_QLDiemHS | /app/Http/Controllers/ClassController.php | UTF-8 | 3,424 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Grade;
use App\Schoolyear;
use App\LClass;
use App\LTeacher;
use DB, DateTime;
class ClassController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\Response
*/
public fun... | true |
9519dceed492c83f3add8d3465742c1c23eb52ad | PHP | michaelmcandrew/rb | /import/events.php | UTF-8 | 2,497 | 2.5625 | 3 | [] | no_license | <?php
require_once('initialise.php');
require_once('functions.php');
date_default_timezone_set('UTC');
//Fetch rows from MYSQL into data object
$select = "SELECT * FROM rb_data.training";
$results =CRM_Core_DAO::executeQuery($select);
$events=array();
while($results->fetch()){
if (!(trimString($results->col_0) AND ... | true |
5360c0e1083f5f7c06ab96a5215c04eeff9f31e2 | PHP | videouri/videouri | /app/Http/Controllers/Auth/AuthController.php | UTF-8 | 1,871 | 2.703125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers\Auth;
use App\Entities\User;
use App\Http\Controllers\Controller;
use App\Traits\SocialAuth;
use Illuminate\Foundation\Auth\AuthenticatesAndRegistersUsers;
use Illuminate\Foundation\Auth\ThrottlesLogins;
use Validator;
class AuthController extends Controller
{
use Authenticat... | true |
d2faebd02143e30f9cb5a849c44522b899cced6e | PHP | Doyeon-Lee/Internet-Programming | /example7-11.php | UTF-8 | 902 | 3.484375 | 3 | [] | no_license | <?php
//Updating a file
$fh = fopen("testfile.txt", 'r+') or die("Failed to open file");
$text = fgets($fh);
fseek($fh, 0, SEEK_END); /*move the file pointer right to the file end,
at which point the line of text that was extracted from the start of the file
(store in $text) is then appended to the file's end a... | true |
4be4f610e5dddb5ec1e81b866e1a6863d30983a2 | PHP | kssim/x509 | /src/Serializer/Certificates/CertificateSubjectSerializer.php | UTF-8 | 1,259 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
namespace Mdanter\X509\Serializer\Certificates;
use FG\X509\CertificateSubject as AsnSubject;
use Mdanter\X509\Certificates\CertificateSubject;
class CertificateSubjectSerializer
{
/**
* @param CertificateSubject $subject
* @return AsnSubject
*/
public function toAsn(CertificateSubject $... | true |
05a0f470af66b6c8838d957aad0b00ccc7701a21 | PHP | Jonascsoliveira/App-msg-Nvoip | /Dao/LogDao.php | UTF-8 | 910 | 2.890625 | 3 | [] | no_license | <?php
namespace Dao;
use \App\Conexao;
use PDO;
class LogDao{
private $conexao;
public function __construct(){
$this->conexao = Conexao::getConexao();
}
/*Método para crição persistencia de logs*/
public function create($id_cliente, $acao, $dados){
/*Variável para guardar o time... | true |
633e6d7e7c97129d414f7d9d9329a7dc68dc96d8 | PHP | aihimel/micro-social | /app/Database/Migrations/2020-12-29-154113_add_posts.php | UTF-8 | 967 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php namespace App\Database\Migrations;
use CodeIgniter\Database\Migration;
class AddPosts extends Migration
{
public function up()
{
$this->forge->addField([
'id' => [
'type' => 'INT',
'unsigned' => true,
'auto_increment' => true
],
'user_id' => [
'type' => 'INT',
'unsigned' => true... | true |
13d00233260acf962fa6b6f6a23242232a975522 | PHP | piotrkumala-zz/Project-BD | /templates/RatsInCage.php | UTF-8 | 295 | 2.71875 | 3 | [] | no_license | <table>
<?php
if($data) {
foreach ($data as $row) {
echo('<tr>');
foreach ($row as $value) {
echo('<td>' . $value . '</td>');
}
}
echo('</tr>');
}
else{
echo('Klatka jest pusta!');
}
?>
</table>
| true |
35466fb563de0d4755055e5a50540cfb42414aaf | PHP | benthud82/hep | /MySQLUpdates/tableupdate_avg_inv.php | UTF-8 | 1,778 | 2.6875 | 3 | [] | no_license | <?php
include_once '../connection/connection_details.php';
ini_set('memory_limit', '-1'); //max size 32m
$filename = 'inventory_DBP_20180509.txt'; //need to change this to look for any date
$result = array();
$fp = fopen($filename, 'r');
if (($headers = fgetcsv($fp, 0, "\t")) !== FALSE) {
if ($headers) {
... | true |
b869d2d89eb51ceb7134f4dfda9afd9638cb7313 | PHP | laptopsr/collecting | /protected/controllers/ApiController.php | UTF-8 | 11,888 | 2.609375 | 3 | [] | no_license | <?php
header("Access-Control-Allow-Origin: *");
//echo $_SERVER['HTTP_X_USERNAME'];
//var_dump($_GET);
class ApiController extends Controller
{
// Members
/**
* Key which has to be in HTTP USERNAME and PASSWORD headers
*/
Const APPLICATION_ID = 'ASCCPE';
/**
* Default response for... | true |
57807e622170858fb22ddc122e3ef80c31943a36 | PHP | sitedata/unmark | /application/libraries/Mark_Import.php | UTF-8 | 10,254 | 2.59375 | 3 | [
"Apache-2.0",
"MIT"
] | permissive | <?php
if (! defined('BASEPATH'))
exit('No direct script access allowed');
/**
* MarkImport Class
*
* Library that handles importing marks into the system
*
* @category Libraries
*/
require_once (APPPATH . 'libraries/JSONImportStateMachine/JSONImportStateStart.php');
class Mark_Import
{
/**
*... | true |
a06ae7a13b96a2b44ce54d3bc3d71cb679c7f656 | PHP | na3api/tt | /app/Services/Bicycle/BicycleBuilder.php | UTF-8 | 1,181 | 3 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: nazar
* Date: 10/05/19
* Time: 10:43
*/
namespace App\Services\Bicycle;
class BicycleBuilder
{
public $type;
public $model;
public $price;
public $size;
public $color;
public $year;
public $state;
public function setType(string $type){
... | true |
3bb274a48f14903b2d97b6336746e7e0bf755105 | PHP | oehlrich9/SeminarServer | /app/Http/Controllers/Device/DeviceController.php | UTF-8 | 3,953 | 2.515625 | 3 | [] | no_license | <?php
namespace App\Http\Controllers\Device;
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Carbon\Carbon;
use App\Models\Device;
use App\Models\DeviceToken;
use App\User;
use DateTime;
use DatePeriod;
use DateInterval;
class DeviceController extends Cont... | true |
d9e8bfdeebabf7720330b5d7fdf10eae8950ec18 | PHP | mggavrilov/SocInvitation | /models/Student_model.php | UTF-8 | 2,020 | 2.703125 | 3 | [] | no_license | <?php
require_once('Database.php');
class Student_model extends Database {
public function saveStudent($data) {
$stmt = $this->conn->prepare("INSERT INTO students (fn, name, presentation_time, post_id) VALUES (?, ?, ?, ?)");
$stmt->execute(array($data['fn'], $data['name'], $data['presentat... | true |
310a2985becdc542ce58a882bed7be27f9c9433e | PHP | eaplatt3/PHPprograms | /php_Demo/arraysDemo1.php | UTF-8 | 221 | 3.1875 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<title>PHP Arrays!</title>
</head>
<body>
<?php
$name = "Abdul wali";
$name_more = array("abdul","john","london","tom","Jerry");
echo $name_more[4];
?>
</body>
</html>
| true |
6121c0fe524746b92e578b1f3d45b06a5b4fb096 | PHP | aiksiang/CP3 | /php/initialize.php | UTF-8 | 14,166 | 2.78125 | 3 | [] | no_license | <?php
//connect MYSQL
require_once 'config.php'; // your PHP script(s) can access this, but the rest cannot
$db = new mysqli(db_host, db_uid, db_pwd, db_name);
if ($db->connect_errno)
echo("Failed to connect to MySQL: (" . $db->connect_errno . ") " . $db->connect_error);
require_once 'question.php';
require_once 'e... | true |
ef5bd653ba08afd2b05397a1c547a1494d3db998 | PHP | marcorisi/slack-hook-github-status | /slack-hook-github-status.php | UTF-8 | 1,248 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
include 'config.php';
// retrieve slack hook params
$token = isset($_POST['token']) ? $_POST['token'] : null;
$user_id = isset($_POST['user_id']) ? $_POST['user_id'] : null;
// validate request
if (SLACK_TOKEN !== $token) {
die('Invalid token');
}
// validate user whitelist
if (CHECK_USE... | true |
7c574ef07713ac596ff4d7e7c7a4eb7087c6cbf9 | PHP | Makeyko/galaxysss | /services/authclient/VKontakte.php | UTF-8 | 4,793 | 2.5625 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
/**
* VKontakte
*
* После login() и attach() устанавливает флаг $app->session->set('auth/vkontakte/isLogin') в значение 1
*/
namespace app\services\authclient;
use app\models\User;
use yii\helpers\ArrayHelper;
class VKontakte extends \yii\authclient\clients\VKontakte implements authClientInterface
{
/... | true |
855817872a74934ebc018bbc4c0a07ca5f26769f | PHP | SamuelDISN/SamuelDISN-wordpressLastVersion | /sourcesCampaign/taxonomy-sujet-post-covid-19.php | UTF-8 | 612 | 2.53125 | 3 | [] | no_license | <?php
/*
Template name: covid-19
*/
get_header(); ?>
<main>
<?php
$id = 412;
$isContainerArticleSanteCovid = get_post($id);
$title = $isContainerArticleSanteCovid->post_title;
$contenu = $isContainerArticleSanteCovid->post_content;
$contenu = apply_filters('the_content', $contenu);
$contenu = str_... | true |
799a2830c170768a8556cbec517dc0d84817d095 | PHP | iamdevice/Tasks | /src/AppBundle/Entity/Task.php | UTF-8 | 4,687 | 2.71875 | 3 | [] | no_license | <?php
namespace AppBundle\Entity;
/**
* Task
*/
class Task
{
/**
* @var integer
*/
private $taskId;
/**
* @var string
*/
private $name;
/**
* @var string
*/
private $description;
/**
* @var boolean
*/
private $isDeleted = false;
/**
... | true |
134a4ae3c94d46628572de527cd50afd4bb7647f | PHP | DawidSajdak/DinnerTime | /src/DinnerTime/Application/Factory/RestaurantFactory.php | UTF-8 | 506 | 2.671875 | 3 | [] | no_license | <?php
namespace DinnerTime\Application\Factory;
use DinnerTime\Application\Command;
use DinnerTime\Domain\Restaurant;
use DinnerTime\Domain\Restaurant\RestaurantId;
/**
* Interface RestaurantFactory
*
* @package DinnerTime\Application\Factory
*/
interface RestaurantFactory
{
/**
* @param RestaurantId $r... | true |
6ed3b1f4cd428ca8c3f67c081d1ddd2f86450a24 | PHP | epfremmer/PHP-Weekly-Issue36 | /src/Context/HexFormatContext.php | UTF-8 | 2,705 | 3.15625 | 3 | [] | no_license | <?php
/**
* File HexFormatContext.php
*
* @author Edward Pfremmer <epfremme@nerdery.com>
*/
namespace PHPWeekly\Issue36\Context;
use PHPWeekly\Issue36\Entity\Byte;
use PHPWeekly\Issue36\Entity\Hex;
use PHPWeekly\Issue36\Entity\Nibble;
use PHPWeekly\Issue36\Entity\NullNibble;
use PHPWeekly\Issue36\Enum\OrdinalEnum;... | true |
692a6e952b2e9bc7220176ad94b75f85651a7990 | PHP | GustaveKar/web_parser | /TP3/functions.php | UTF-8 | 17,343 | 2.953125 | 3 | [] | no_license | <?php
function quote( $string)
{
return "'".$string ."'";
}
abstract class FunctionBase
{
protected $TableName;
public $DateTime;
public $SessionId;
public $Username;
public $FunctionName;
public ... | true |
9440897b3529127260e3edd81b611d0921819f31 | PHP | MiguelAngelCastroMartinez/U2_clase8 | /Calculadora.php | UTF-8 | 2,394 | 2.890625 | 3 | [] | no_license | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta3/dist/css/bootstrap.min.css" rel="stylesheet" integrit... | true |
9e6e2173a72e643bb2a3ad73ffeb24727cc8f4c3 | PHP | dkf4199/vfgcontact | /ajax_fc_rep_addevent.php | UTF-8 | 6,386 | 2.734375 | 3 | [] | no_license | <?php
session_start();
$repsid = $_SESSION['rep_id'];
//Set the timezone to the rep's timezone
date_default_timezone_set($_SESSION['rep_tz']);
include ('includes/config.inc.php');
include ('includes/phpfunctions.php');
include ('includes/selectlists.php');
//DB Connection
//require_once (MYSQL);
//$_POST... | true |
48aaffd38113829082e5d4a4279d4519e0685cf9 | PHP | previateri/challengeBolton-Previateri | /Src/Core/Requests.php | UTF-8 | 2,510 | 3.140625 | 3 | [] | no_license | <?php
namespace Previateri\Bolton\Core;
/**
* Class Requests
* A classe é responsável por interagir diretamente com o pacote
* GuzzleHttp que realiza as requisições CURL. A classe provê métodos
* que podem ser utilizaodos para realização ações no Guzzle.
*/
class Requests
{
protected $client;
protected $... | true |
69fe2170f77ad642e707eed44bfeb92397f462fb | PHP | bearcherian/askcrh | /process/mentions_class.php | UTF-8 | 1,856 | 2.65625 | 3 | [] | no_license | <?php
class MentionFactory {
public function create($tweet) {
$base = new Mention($tweet);
if($base->getReplyId() || ($base->source == 'txt' && in_array('answer', $base->hashtags))) {
return new Answer($tweet);
} else {
return new Question($tweet);
}
return $base;
}
}
class Mention {
... | true |
365992975b115b6aae1489a17559b2ed3b81b3d2 | PHP | francomor/proyecto_instituto_xp | /presentacion/tablaCurso.php | UTF-8 | 6,072 | 2.59375 | 3 | [] | no_license | <?php
//Agrega la interfaz del preceptor comun a todas las secciones
include_once "GUIPreceptor.class.php";
/**
* Tabla curso
* @author
* @version 1.0
*/
if (isset($_SESSION["login"]) && $_SESSION["login"] == true) {
$gui_preceptor = new GUIPreceptor();
?>
<div class="content-wrapper">
<section clas... | true |
64f099acd8ac25e8cd8aba7ea14e053cb47f9a6f | PHP | OpenClassrooms/CustomerIO | /tests/ClientMock.php | UTF-8 | 688 | 2.671875 | 3 | [
"MIT"
] | permissive | <?php
namespace OpenClassrooms\CustomerIO\Tests;
use OpenClassrooms\CustomerIO\Client;
/**
* @author Arnaud Lefevre <arnaud.lefevre@openclassrooms.com>
* @author Bastien Rambure <bastien.rambure@openclassrooms.com>
*/
class ClientMock implements Client
{
/**
* @var string
*/
public static $delet... | true |
f86984327cfe609e672740190f5b517af867b619 | PHP | mazenmoaaz461/Restaurant_Site_PHP | /add.php | UTF-8 | 3,255 | 2.765625 | 3 | [] | no_license | <?php
$error_fields=array();
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
if (!(isset($_POST['name']) && !empty($_POST['name']))) {
$error_fields[] = "name";
}
if(!(isset($_POST['email'])&&filter_input(INPUT_POST, 'email',FILTER_VALIDATE_EMAIL))) {
$error_fields[]= "email";
}
if (!(isset($_POST['passwor... | true |
76a450bd7cee032ce356b13a9a7421d76024ab99 | PHP | JSabbatier/pimag3a | /Stat/data_test.php | UTF-8 | 1,586 | 2.609375 | 3 | [
"Apache-2.0"
] | permissive | <?php
header('Content-Type: application/json');
$json = Array();
if ( (isset ($_POST["id_fournisseur"])) && (isset ($_POST["dateDebut"])) && (isset($_POST["dateFin"])) )
{
$lots = Array();
$json["nom_fournisseur"] = "Le bon bouchon";
for ($i = 0; $i<100; $i++){
$lots["id_lot"] = 79209;
$lots["date"] = "21... | true |
ac04361c84dce65603f4fa964243fb0e5ae5de36 | PHP | ja1goncalves/badge-back | /app/Http/Controllers/BadgesController.php | UTF-8 | 1,217 | 2.703125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use App\Http\Controllers\Traits\CrudMethods;
use App\Http\Requests\BadgeCreateRequest;
use App\Services\BadgeService;
use App\Validators\BadgeValidator;
/**
* Class BadgesController.
*
* @package namespace App\Http\Controllers;
*/
class BadgesController extends Controller
{
... | true |
253d09e5735a2bfbe7abef7ff2af71db08d6fcd0 | PHP | Lutnik/Converter | /src/Converter/Format/Csv.php | UTF-8 | 1,305 | 2.9375 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: mazury
* Date: 24.03.15
* Time: 20:29
*/
namespace Mazury\Converter\Format;
use League\Csv\Reader;
use League\Csv\Writer;
use Mazury\Converter\ConverterAbstract;
use Mazury\Converter\ConverterInterface;
use SplTempFileObject;
final class Csv extends ConverterAbstract i... | true |
f67de38aaeb05ef5bb4817c77454b998d2b17b09 | PHP | XuanTuyen/botman | /app/Conversations/OnboardingConversation.php | UTF-8 | 1,172 | 2.671875 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: pc
* Date: 19-Oct-17
* Time: 03:37 PM
*/
namespace App\Conversations;
use Illuminate\Foundation\Inspiring;
use BotMan\BotMan\Messages\Incoming\Answer;
use BotMan\BotMan\Messages\Outgoing\Question;
use BotMan\BotMan\Messages\Outgoing\Actions\Button;
use BotMan\BotMan\Messag... | true |
c8f0cdc8037f8bfeda75a72c502e4e505d627b2f | PHP | vidddd/test | /application/helpers/site_helper.php | UTF-8 | 2,771 | 3.390625 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
/**
* SITE HELPERS
* *
* @package CodeIgniter
* @author Cristian Triviño
* @since Version 1.0.0
*/
/**
* print_pre function
*
* @access public
* @arr arr
* Muestra array con tabulaciones.
*/
if ( ! function_exists('p... | true |
64b17484d837031ddcf59900c95f87625bbda256 | PHP | eoko/text-kernel | /src/Model/CvModel.php | UTF-8 | 4,492 | 2.609375 | 3 | [] | no_license | <?php
/**
* Copyright (c) 2013-present, EOKO SAS, Inc.
* All rights reserved.
*
* This source code is licensed under the MIT-style license found in the
* LICENSE file in the root directory of this source tree.
**/
namespace Eoko\TextKernel\Model;
class CvModel extends XmlModelBase
{
/**
* @var array
... | true |
50bc36859187a43734b0da7c2eeea1c1743864e9 | PHP | guiinfo3333/portal-de-noticias-PHP | /Comentario.php | UTF-8 | 796 | 2.75 | 3 | [] | no_license | <?php
class Comentario {
private $idcoment;
private $idnoticia;
private $textocomentario;
private $dtacomentario;
function getIdcoment() {
return $this->idcoment;
}
function getIdnoticia() {
return $this->idnoticia;
}
function getTextocomentario() {
return $th... | true |
ab5eea0227f1cd2265fd7ad7b53729c958ea9104 | PHP | benrbowers/chore-board | /ChoreBoard/choreBoard.php | UTF-8 | 4,989 | 2.84375 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" type="text/css" href="choreBoard.css">
<title>Chore Board</title>
</head>
<body>
<h1>Chore Board</h1>
<h2>Date</h2>
<table>
<tr>
<th>Person</th>
<th>Daily Chores</th>
</tr>
<tr>
<td>Ben B</td>
<?php
$tz = 'America/Indiana/... | true |
c149c9e6144d68ffacbfe72ffadd0d45d0b888a0 | PHP | tiktock/php-papago | /Papago.php | UTF-8 | 2,462 | 2.65625 | 3 | [] | no_license | <?php
class Papago{
private $json_head;
private $data;
private $curl;
public function __construct($source = false, $target = false){
$this->data = [
'source' => $source,
'target' => $target,
];
$this->curl = curl_init();
curl_setopt($this->curl, ... | true |
e83d8312c5dd854bc8df4e58a2634b5a7286bdf2 | PHP | friedrich-che/php_basics_tasks | /1-4.php | UTF-8 | 751 | 3.046875 | 3 | [] | no_license | /*
<p>1. Создайте переменную name и присвойте ей значение, содержащее ваше имя, например "Иннокентий".</p>
<p>2. Создайте переменную age и присвойте ей значение, содержащее ваш возраст, например 20.</p>
<p>3. Выведите с помощью echo фразу "Меня зовут: %ваше_имя%", например: "Меня зовут: Иннокентий".</p>
<p>... | true |
884fe4a965db6e73be8a1c41ded268644b53f493 | PHP | adellantado/bot-rule-engine | /src/Actions/SaveVariableAction.php | UTF-8 | 1,047 | 2.671875 | 3 | [
"MIT"
] | permissive | <?php
namespace BotRuleEngine\Actions;
use BotTemplateFramework\Events\VariableChangedEvent;
class SaveVariableAction extends AbstractAction {
public $variable;
public $value;
public $userId;
public static function create($userId, $variable, $value) {
$instance = new SaveVariableAction(... | true |
de5553e9a2c3c840ca41bf668c58ff61b8fbcd19 | PHP | matheusoares/technoob | /Mobile/ADM/TO/PostTO.php | UTF-8 | 1,420 | 2.921875 | 3 | [] | no_license | <?php
class PostTO{
private $Id;
private $Titulo;
private $Autor;
private $Imagem;
private $Video;
private $CategoriaId;
private $Postagem;
public function __construct() {}
//SET
public function setId($id){
$this->Id = $id;
}
... | true |
3f2d3428735afbea2f22061194993ad588282546 | PHP | paknahad/querifier | /tests/FactoryTest.php | UTF-8 | 2,212 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
namespace Paknahad\Querifier\Tests;
use Paknahad\Querifier\Factory;
use Paknahad\Querifier\Operators;
use Paknahad\Querifier\Parts\Combiner;
use Paknahad\Querifier\Parts\Condition;
use PHPUnit\Framework\TestCase;
class FactoryTest extends TestCase
{
public function testMakeCondition()
{
$condit... | true |
e44866fcb54f0474c1345c31f7bbe3494c4efab3 | PHP | 51104389/2015_De02 | /pdfsocial_assiment/app/models/Post.php | UTF-8 | 835 | 2.71875 | 3 | [
"MIT"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: Administrator
* Date: 19/05/2015
* Time: 7:39 SA
*/
class Post extends Eloquent{
protected $table = 'post';
public function user(){
return $this->belongsTo('User');
}
public function category(){
return $this->belongsTo('Category');
}... | true |
5c308c93d03fc5274ff84937e92288ba52812df5 | PHP | bidhan948/QR_CODE-GENERATE-_WITH_LARAVEL_AND_STATISTICAL_REPORT | /app/Http/Requests/addQrSubmit.php | UTF-8 | 848 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Requests;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Http\Request;
class addQrSubmit extends FormRequest
{
/**
* Determine if the user is authorized to make this request.
*
* @return bool
*/
public function authorize()
{
return true;
... | true |
b4cf15b1723202ce51fc7e14d3a56df83969a9ff | PHP | marco-msg-ferrari/ch-test | /src/Repository/PresentationRepository.php | UTF-8 | 829 | 2.765625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: marco
* Date: 10/12/15
* Time: 14:43
*/
namespace Msg\Repository;
use League\Flysystem\Filesystem;
use Msg\Model\Presentation;
class PresentationRepository extends YamlRepository
{
protected $sectionRepo;
public function __construct(Filesystem $filesystem, Secti... | true |
4e6fc2a7110881af2815bd87636afea8e9cc7da6 | PHP | ninja2410/project_manager | /database/migrations/2020_11_19_124618_create_unit_measures_table.php | UTF-8 | 1,250 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateUnitMeasuresTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('unit_measures', function (Blueprint $table) {
... | true |
e5b55b16facc6429f2f8d566f709de971d6c3ddd | PHP | ilyaidea/ilya-CMS | /app/Library/DataTables/Ajax.php | UTF-8 | 3,959 | 2.546875 | 3 | [] | no_license | <?php
/**
* Summary File Ajax
*
* Description File Ajax
*
* ILYA CMS Created by ILYA-IDEA Company.
* @author Ali Mansoori
* Date: 10/18/2018
* Time: 10:43 AM
* @version 1.0.0
* @copyright Copyright (c) 2017-2018, ILYA-IDEA Company
*/
namespace Lib\DataTables;
use Phalcon\Mvc\User\Component;
class Ajax ex... | true |
bb6edc507a96d4648737add5cec8582d9db2b8b4 | PHP | UWAA/uwaa-2014 | /vendor/UWAA/Taxonomies/ContentSection.php | UTF-8 | 2,067 | 2.578125 | 3 | [] | no_license | <?php namespace UWAA\Taxonomies;
class ContentSection
{
function __construct()
{
add_action( 'init', array($this, 'setup_contentSection_taxonomy'), 0 );
}
public static function setup_contentSection_taxonomy()
{
$labels = array(
'name... | true |
525b2076a16470e324dea89b31e3e2a0ffd4077f | PHP | Lhfcws/ai_hw | /src/model.php | UTF-8 | 1,958 | 2.5625 | 3 | [] | no_license | <?php
/*
function die($st) {
die($st + "</br>");
}
*/
session_start();
require_once("conf.php");
$conn = mysql_connect($dbs[0], $dbs[1], $dbs[2]) or die("mysql connect failed!");
$conn = mysql_select_db('ai_hw', $conn) or die("database select failed!");
mysql_query("set names 'utf8'");
$keyword = $_SESSION[... | true |
04d9a2f0f0b66c7687c782bf8d332e98c668efdd | PHP | fluid22/modules | /src/Module.php | UTF-8 | 857 | 2.8125 | 3 | [] | no_license | <?php
namespace Fluid22\Module;
abstract class Module
{
/**
* Use this method to define actions, filters, and shortcodes
*/
abstract public function setup();
/**
* Get template as a string
*
* @param string $template
* @param array $args
* @return string... | true |
4d263baea757ec60d61eeaa6210233e0b4907b06 | PHP | flavorly/laravel-vanilla-components | /src/Datatables/Columns/Concerns/InteractsWithTableQuery.php | UTF-8 | 836 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
namespace Flavorly\VanillaComponents\Datatables\Columns\Concerns;
use Closure;
use Illuminate\Database\Eloquent\Builder;
trait InteractsWithTableQuery
{
protected ?Closure $applySortingUsing = null;
public function applySort(Builder $query, string $column, mixed $sorting): Builder
{
if ($s... | true |
5fec74bea2dc1d708d4ab9dbcd664840585ca91a | PHP | FridgePoly/Nelliel | /board_files/include/Auth/AuthRole.php | UTF-8 | 3,862 | 2.6875 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
namespace Nelliel\Auth;
use PDO;
if (!defined('NELLIEL_VERSION'))
{
die("NOPE.AVI");
}
class AuthRole extends AuthHandler
{
public $permissions = array();
function __construct($database, $role_id)
{
$this->database = $database;
$this->auth_id = $role_id;
}
public func... | true |
14975dd47b483200ad93f5e97ac4446bc7335a47 | PHP | 571856525/php-shop | /models/service/Address.php | UTF-8 | 388 | 2.671875 | 3 | [] | no_license | <?php
class Service_Address
{
private $dAddress;
public function __construct ()
{
$this->dAddress = new Dao_Address();
}
//根据ID获取收货地址信息
public function getById ($id)
{
return $this->dAddress->getById($id);
}
//根据id获取收货地址列表
public function getListByid ($id)
{
return $this->dAddress... | true |
db99ad4eda11cbed31b0ca61fec9dd10f60d24c2 | PHP | tkwalker-git/genesis | /QueryPatientInformation.php | UTF-8 | 5,966 | 2.796875 | 3 | [] | no_license | <?php
// **************** INFORMATION HEADER ****************
/*
Test:
http://50.63.174.147/GamiGen/Pangea/QueryPatientInformation.php?ClinicIC=4&PatientName=J&Hash=Nada
Test Debug:
http://50.63.174.147/GamiGen/Pangea/QueryPatientInformation.php?ClinicIC=4&PatientName=J&Hash=Nada&Debug=true
!!! Expected Pa... | true |
a4edef9a631ad5e7cc855a62dd8082adeb55d363 | PHP | itk-dev/serviceplatformen | /lib/digitaliseringskataloget/Sagdok3_0_0/FlerRelationType.php | UTF-8 | 1,441 | 2.640625 | 3 | [
"MIT"
] | permissive | <?php
namespace Digitaliseringskataloget\Sagdok3_0_0;
/**
* Class representing FlerRelationType
*
*
* XSD Type: FlerRelationType
*/
class FlerRelationType
{
/**
* @var \Digitaliseringskataloget\Sagdok3_0_0\Virkning $virkning
*/
private $virkning = null;
/**
* @var \Digitaliseringskata... | true |
de8544e717a03067a600127a4d076ed415b888cb | PHP | GubaEvgeniy/sorter-library | /bin/sort.php | UTF-8 | 636 | 3.046875 | 3 | [] | no_license | <?php
/*
*
* (c) Evgeniy Guba <evgeniyguba@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
use App\Sorter\{AscStrategy, DescStrategy, SorterStrategy};
require_once __DIR__ . '/../vendor/autoload.php';
$numbers = [4, ... | true |