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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
a83f5a03d5d8732f106728137729e37e55d7cef8 | PHP | whikloj/BagItTools | /src/PayloadManifest.php | UTF-8 | 1,731 | 2.890625 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace whikloj\BagItTools;
/**
* Payload Manifest extension of AbstractManifest.
*
* @package whikloj\BagItTools
* @author whikloj
* @since 1.0.0
*/
class PayloadManifest extends AbstractManifest
{
/**
* PayloadManifest constructor.
*
* @param \whikloj\BagIt... | true |
50ba662abc1239392fd6503352cea15f2d60e2a1 | PHP | fofokilleuz/CarsLocApplication | /fonction/connexion/insert_inscription.php | UTF-8 | 1,579 | 2.53125 | 3 | [] | no_license | <?php
//connexion base de donnée
include "config.php";
include "database.fn.php";
$link = database_connect($db);
$email = $_POST['email'];
$nom = $_POST['nom'];
$prenom = $_POST['prenom'];
$tel = $_POST['tel'];
$mot_passe = sha1($_POST['mot_passe']); //hachage du mdp avec la fonction sha1
$mot_passe2 = sha1(... | true |
59d89a72c7cc885c50d9a305c8cb4dc4692cf0ce | PHP | ni-c/md-photo-blog | /src/Post.php | UTF-8 | 3,550 | 2.953125 | 3 | [] | no_license | <?php
/**
* PHP version 5
*
* md-photo-blog : Markdown Blog for Photos
* Copyright 2012, Willi Thiel
*
* Licensed under The MIT License
* Redistributions of files must retain the above copyright notice.
*
* @copyright Copyright 2012, Willi Thiel
* @link http://ni-c.github.de/md-photo-blog
* @package md-photo... | true |
82c8c79a6f93354c10c9996ddfaf9d9c53339b5b | PHP | venkatraja007/beadloomgame | / beadloomgame/BeadLoom Website/drupalMigrate.php | UTF-8 | 647 | 2.609375 | 3 | [] | no_license | <?php
//migrate content from BeadLoom Game to Drupal
include('config.php');
include('connect.php');
$array = array();
$query = "SELECT * from CustomPuzzles WHERE published='1'";
$result = $db->query($query);
if($result)
{
while($row = $result->fetch_assoc())
{
$key = $row['user']."-".$row['puzzle']... | true |
4c4b8bf51f8ae5f326b3785965e54e2bffcc63ed | PHP | ibnoe/rsos-git | /app/Classes/Format/Format.php | UTF-8 | 6,917 | 2.578125 | 3 | [] | no_license | <?php
namespace App\Classes\Format;
use App\User;
use App\Models\ref_coa_ledger;
use App\Models\ref_konversi_satuan;
class Format{
static $seri = 1;
////////////////////////////////////// WAKTU /////////////////////////////////////////////////////
public function indoDate($waktu = ''){
if($waktu == ... | true |
1af05c7649f1a1e396cad11276e118eb14e85ecf | PHP | farizanwardeen/Journalismwebsite | /MyWebsite/evaluate.php | UTF-8 | 8,926 | 2.734375 | 3 | [] | no_license | <?php
include_once("php_includes/check_login_status.php");
include('header.php');
$idval=$_GET["id"];
?>
<h2>Evaluate Automatic Mashup</h2>
<div id="wrapper3">
<div id="webpage1" style="float:left">
<?php
$url1="/websitecopy8/MyWebsite/wikiedit.php?id=".$idval;
?>
<iframe src="<?php echo $ur... | true |
d8d6ad1bfbeae1379831f5793f7f5a760d9b1d53 | PHP | CivilianSergeant/marketplace-asianlancers | /app/models/Freelancer/Validators/PortfolioValidator.php | UTF-8 | 514 | 2.71875 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: Himel
* Date: 9/9/14
* Time: 11:14 AM
*/
class PortfolioValidator {
private static $rules = array(
'title' => 'required',
'category_name' => 'required',
'url' => 'required',
'image' => 'required'
);
pu... | true |
314330f03c876398080ebf01de19de8cb3825fdd | PHP | venkatasampath/laravel | /app/Instrument.php | UTF-8 | 2,482 | 2.75 | 3 | [
"MIT"
] | permissive | <?php
/**
* Instruments Model
*
* @category Instruments
* @package CoRA-Models
* @author Sachin Pawaskar<spawaskar@unomaha.edu>
* @copyright 2016-2018
* @license The MIT License (MIT)
* @version GIT: $Id$
* @since File available since Release 1.0.0
*/
namespace App;
use Illuminate\Data... | true |
3fc4dfcf757002c52ee5d29c04e7cd497db7f567 | PHP | jechorn/thinkphpCms | /Application/Classes/UnlimitCate.class.php | UTF-8 | 2,526 | 3 | 3 | [] | no_license | <?php
/** .-------------------------------------------------------------------
* | Software: []
* | Description:
* | Site: www.jechorn.cn
* |-------------------------------------------------------------------
* | Author: 王志传
* | Email : <jechorn@163.com>
* | CreateTime: 2017/1/10-9:09
* | C... | true |
3be0e844adb23f3c8aea220d138fb110ec2c0924 | PHP | frannkx/Monitoring | /DevEyeInInfra/controlador/ActualizarGrupo.php | UTF-8 | 987 | 2.59375 | 3 | [] | no_license | <?php
require_once('../modelo/class.conexion.php');
require_once('../modelo/class.consultas.php');
$mensaje=null;
$id_grupo=$_POST['id_grupo'] ? $_POST['id_grupo'] : NULL ;
$nombre_grupo=$_POST['nombre_grupo'] ? $_POST['nombre_grupo'] : NULL ;
$descripcion_grupo=$_POST['descripcion_grupo'] ? $_POST['de... | true |
33e6113e141723bd383996d3bcf6d86daffe7f3f | PHP | Aldilan/Attendance-With-OOP-PHP | /admin/hal_admin.php | UTF-8 | 1,585 | 2.5625 | 3 | [] | no_license | <?php
session_start();
require "../config/database.php";
require "../library/controllers.php";
$perintah = new oop();
$username = $_SESSION['username'];
$table = $_SESSION['table'];
$perintah->tampil($table);
if (empty($_SESSION['username'])) {
echo "<script>alert('Silahkan login terlebih dahulu');document.loca... | true |
8e83ca300241b661d8123192cfed3458a41b0e01 | PHP | bashierelbashier/dubai-police-events | /MODEL/fetch_users.php | UTF-8 | 1,237 | 2.6875 | 3 | [] | no_license | <?php
include "connect.php";
$query = "SELECT * FROM T_USERS";
$result = mysqli_query($connect, $query);
$output = "<table class='table table-striped table-bordered' style='font-size:medium;'>
<tr class='fixed-top' align='center' style='background-color:dimgrey;color:white' >
<td> متسلسل # </td>
<td> إسم المستخدم ... | true |
a082c080c1b0e8740ed4dc7a43fc66aad2a88f91 | PHP | TYPO3-svn-archive/auxo | /core/class.tx_auxo_debug.php | UTF-8 | 3,947 | 2.640625 | 3 | [] | no_license | <?php
/**
* @package auxo
* @subpackage core
* @author Andreas Horn <Andreas.Horn@extronaut.de>
* @copyright 2007
* @version $WCREV$
*
* LICENSE:
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published b... | true |
7b8f6b99747ec91d75f9c90e47d72b7ebc2792db | PHP | gaodonglai/cp | /Model/BankMgModel.class.php | UTF-8 | 2,423 | 2.5625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: ggbx
* Date: 2017/8/23
* Time: 21:18
*/
namespace Model;
class BankMg
{
function __construct()
{
global $wpdb;
$this->wpdb = $wpdb;
$this->table = $this->wpdb->prefix;
}
/**
* 插入信息
* @param $data_array
* @param $... | true |
6fab96572ef25d252b86e251b69ee8d71bff30ee | PHP | SJLONG98/animal | /adopt.php | UTF-8 | 2,896 | 2.59375 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<title>Angus' Animal Sanctuary</title>
</head>
<body>
<?php
include('header.php');
echo "<br><br>";
session_start();
require('menu.php');
echo "<br>";
if (isset($_SESSION["username"])) {
include('mainstyle.php');
$user = $_S... | true |
6fe8755570119974549af83435144b01d4f8ccac | PHP | CeddyG/clara-parameter | /src/Repositories/ParameterRepository.php | UTF-8 | 908 | 2.5625 | 3 | [] | no_license | <?php
namespace CeddyG\ClaraParameter\Repositories;
use CeddyG\QueryBuilderRepository\QueryBuilderRepository;
class ParameterRepository extends QueryBuilderRepository
{
protected $sTable = 'parameter';
protected $sPrimaryKey = 'id_parameter';
protected $sDateFormatToGet = 'd/m/Y';
protecte... | true |
4f43a6d3b7a4d4790d56bf9a4559b89f760d2ca4 | PHP | zamin/spera-crm | /application/models/User.php | UTF-8 | 3,824 | 2.578125 | 3 | [] | no_license | <?php
/**
* ClassName: User
* Table Name: user
**/
class User extends ActiveRecord\Model
{
static $has_many = array(
array('company_has_admins'),
array('tickets'),
array('project_has_workers'),
array('companies', 'through' => 'company_has_admins'),
array('projects', 'through' => 'pro... | true |
08089b01543a49de1105d7ea7ab8568eadd66976 | PHP | mehrdadhexe/wo2app | /register/class_custom_register.php | UTF-8 | 26,840 | 2.59375 | 3 | [] | no_license | <?php
/**
* Created by mr2app.
* User: hani
* Date: 12/13/17
* Time: 6:07 PM
*/
class class_custom_register {
function __construct(){
// echo $this->getBrowser();
// exit();
add_action( 'init', array( $this , 'mr2app_custom_register_api_regular_url' ));
add_filter( 'query_vars', array( $this ... | true |
ea017d8ad91ed9aeeb63d8669b136d49d806b05d | PHP | LudvigSten/wsp1-php | /test.php | UTF-8 | 576 | 3.4375 | 3 | [] | no_license | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>
<body>
<?php
$name = "Ludvig";
echo "Hello $name";
... | true |
95dc5d43d65e9564124eeb73a35db31b21f61522 | PHP | salustian0/camping | /app/Controllers/BaseController.php | UTF-8 | 3,301 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Controllers;
ini_set('memory_limit', '-1');
/**
* Class BaseController
*
* BaseController provides a convenient place for loading components
* and performing functions that are needed by all your controllers.
* Extend this class in any new controllers:
* class Home extends BaseController
... | true |
f7f4787090462e120033b214431d49d86be43d7f | PHP | warkhosh/variable | /VarFloat.php | UTF-8 | 7,836 | 3.34375 | 3 | [] | no_license | <?php
namespace Warkhosh\Variable;
/**
* Class VarFloat
*/
class VarFloat
{
/**
* Преобразование значения в строку
*
* @param float|int|string $var - значение числа
* @param string|null $separator - разделитель точности
* @return string
*/
static public function make... | true |
beea705d2b111aaba9434233489f1fb8ad3c51a0 | PHP | tamankoding/konfirmasi_pembayaran_spp | /tes/tes.php | UTF-8 | 1,555 | 2.9375 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<title>MENAMPILKAN DATA DARI DATABASE SESUAI TANGGAL DENGAN PHP - WWW.MALASNGODING.COM</title>
</head>
<body>
<center>
<h2>MENAMPILKAN DATA DARI DATABASE SESUAI TANGGAL DENGAN PHP<br /><a href="https://www.malasngoding.com">WWW.MALASNGODING.COM</a></h2>
<?php
... | true |
d29a3beffb29a009b34e2707c63ba23e667fbfee | PHP | tomclock/quick-laravel | /app/Http/Controllers/HelloController.php | UTF-8 | 829 | 2.765625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Models\Book;
use DB;
//a.Controller クラスを継承
class HelloController extends Controller
{
//b.アクションメソッドを定義
public function index()
{
//c.出力を戻り値
return 'こんにちは!';
}
public function view()
{
$data=[
... | true |
531fdc6ae50e95896ade57e8f67f70d7e9898689 | PHP | lionelfayolle/version-2.0 | /site/Back/del_home.php | UTF-8 | 541 | 2.5625 | 3 | [] | no_license | <?php
try
{
$bdd = new PDO('mysql:host=localhost;dbname=mydb;charset=utf8', 'root', '');
}
catch(Exception $e)
{
die('Erreur : '.$e->getMessage());
}
$req = $bdd->prepare('DELETE FROM appartement WHERE Code_appartement = :Code_appartement'); // on sélectionne le paramètre en fonction duquel on va supprimer ... | true |
124bb3041568616c9eab38d9313c2595947eb8b9 | PHP | mradcliffe/xero | /src/Form/XeroFormBuilder.php | UTF-8 | 9,154 | 2.546875 | 3 | [] | no_license | <?php
/**
* @file
* Contains \Drupal\xero\Form\XeroFormBuilder.
*/
namespace Drupal\xero\Form;
use Drupal\Component\Plugin\Exception\PluginNotFoundException;
use Drupal\Core\TypedData\ComplexDataDefinitionBase;
use Drupal\Core\TypedData\DataDefinitionInterface;
use Drupal\Core\TypedData\ListDataDefinition;
use Dru... | true |
c7c0393e928d78ee066b31f29b7d66f6625f4588 | PHP | elvison123/projetos | /controller/FornecedorController.php | UTF-8 | 5,028 | 2.65625 | 3 | [] | no_license | <?php
require_once '../model/Fornecedor.php';
//require_once '../view/cadastrar-cliente.php';
//require_once '../view/listar-cliente.php';
class FornecedorController {
private $fornecedor;
function __construct() {
try {
$this->fornecedor = new Fornecedor();
$acao = isset($... | true |
20773a2686ea933d476b1a58e8a6f5f7e52e9fe2 | PHP | FJMARG/HospitalAlejandroKorn | /controller/EstadisticoController.php | UTF-8 | 2,373 | 2.625 | 3 | [] | no_license | <?php
/**
*
*/
class EstadisticoController extends DoctrineRepository
{
private static $instance;
public static function getInstance() {
if (!isset(self::$instance)) {
self::$instance = new self();
}
return self::$instance;
}
private function __construct() {
... | true |
54d486d4e91332ef933649353b3372b44ffa8d20 | PHP | crazycajun/RAS | /www/classes/EmailService.php | UTF-8 | 551 | 2.53125 | 3 | [] | no_license | <?php
// This is the facade that will send all system emails.
class EmailService {
function sendMemberConfirm($email, $token) {
$emailBody = <<<BODY
Thank you for registering with the RAS System. Below is your account activation token.
Please navigate to our home page and click on the Account Activation button in ... | true |
bf9d860a9734cdb2ba0d17ac38d1e5663fb209fa | PHP | securitym0nk/BookStore | /new/login.php | UTF-8 | 2,398 | 2.734375 | 3 | [] | no_license | <?php
/////////////////////////////////////////////////////////////////////////////
//
// LOGIN PAGE
//
// Server-side:
// 1. Start a session
// 2. Clear the session
// 3. Generate a random challenge string
// 4. Save the challenge string in the session
// 5. Expose the challenge string... | true |
d3c8cadba4926eaee93c7bf166362a6bfef6265f | PHP | gsouf/phantomphp | /src/Message.php | UTF-8 | 787 | 3.15625 | 3 | [
"Fair"
] | permissive | <?php
/**
* @license see LICENSE
*/
namespace PhantomPhp;
class Message
{
private static $messageId = 0;
protected $id;
protected $action;
protected $data;
protected $timeout;
public function __construct($action, $data = null)
{
$this->id = ++self::$messageId;
$this->a... | true |
0b4f96a908b25861b6790298001b7773bc3ae20c | PHP | FahrulIrsyadF/Kel3_TIF-D | /Login Mila/login.php | UTF-8 | 1,406 | 2.75 | 3 | [] | no_license | <?php
require 'function.php';
if (isset($_POST["signin_submit"])){
$username = $_POST["username"];
$password = $_POST["password"];
$result = mysqli_query($conn, "SELECT username FROM pemesan
WHERE username ='$username'");
if (mysqli_num_rows($result) === 1) {
$row = mysqli_fetch_assoc ($result);
i... | true |
7945891f8716282495bb8e25be8710b4992743b7 | PHP | ss-vv/myaoya | /src/Libs/Payments/Yinxin.php | UTF-8 | 4,405 | 2.640625 | 3 | [] | no_license | <?php
namespace Weiming\Libs\Payments;
use Weiming\Libs\Payments\WMPay;
class Yinxin implements WMPay
{
/**
* 支付类型
*/
public $paymentType = [
1 => [ //微信扫码
'wxpay' => 'PC微信扫码',
],
2 => [ //支付宝扫码
'alipay' => '支付宝扫码',
],
... | true |
ea534bcae1cbac8c4c870475a82e084c1981b5d4 | PHP | Kulpreet8668/sports | /notification.php | UTF-8 | 905 | 2.734375 | 3 | [] | no_license | <?php
require_once('./_config.php');
session_start();
include_once('_utilities/_connect.php');
/*
OBJECTIVE:
1: Check the session for a 'notification' key and if there's a value:
a: If there's a value display the message.
b: If there isn't, redirect back to the home page (index.php)... | true |
d5844e45bb0777479ccfda59474a390943eede47 | PHP | falkune/instantchatAPI | /model/Send.php | UTF-8 | 2,542 | 2.9375 | 3 | [] | no_license | <?php
/*
*THIS CLASS STEN FOR SENDING MESSAGE FROM ON USER TO ANOTHER,
*THEY NEED THE USER_IDS OF TRANSMITTER AND RECEIVER THEY ALSO
*NEED THE MESSAGE BODY (THE TEXT TO SEND). MESSAGE WILL BE
*SEND ONLY IF THE TRANSMITTER IS CONNECTED.
*PARAMS WILL BE PASSED LIKE THIS : trnasmitter/receiver/message/token
*EXEPTED THE ... | true |
a156d445f386bccd079d3e570470cef3a531fda9 | PHP | sensei100/php-basics | /arrays.php | UTF-8 | 467 | 3.28125 | 3 | [] | no_license | <?php
$myArray = array("Jen", "Larry", "Jackson", "Olivia", "Oscar");
$myArray[] = "Katie";
print_r($myArray);
echo $myArray[1];
echo "<br><br>";
$anotherArray[0] = "pizza";
$anotherArray[1] = "hotdogs";
$anotherArray["myFavorite"] = "coffee ";
print_r($anotherArray);
echo "<br><br>";
$thirdArray = array("Fr... | true |
b4baa497e1873216c914655c83b662f23167dbf2 | PHP | Jarzon/UserPack | /Model/UserModel.php | UTF-8 | 2,977 | 2.59375 | 3 | [] | no_license | <?php declare(strict_types=1);
namespace UserPack\Model;
use Jarzon\QueryBuilder\Builder as QB;
use UserPack\Entity\UserEntity;
class UserModel extends \Prim\Model
{
private $user;
private $userEntity;
public function __construct($db, array $options, $user, $userEntity)
{
parent::__construct... | true |
6e7c17fe9ab9ffb7c4da77df77886605d0eacc7e | PHP | RMhmdv/ITSchool | /src/php/mail.php | UTF-8 | 957 | 2.765625 | 3 | [
"MIT"
] | permissive | <?php
$name = filter_var($_POST["name"], FILTER_SANITIZE_STRING);
$phone = filter_var($_POST["login"], FILTER_SANITIZE_STRING);
$email = filter_var($_POST["email"], FILTER_SANITIZE_STRING);
$service = filter_var($_POST["password"], FILTER_SANITIZE_STRING);
$errors;
if(empty($name)){
$errors .= "Enter your name";
}... | true |
47e8a8ac0d03855a5e7dec7aa3c8550db6d52c77 | PHP | bmottag/pqr | /application/models/General_model.php | UTF-8 | 1,614 | 2.8125 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
/**
* Clase para consultas generales a una tabla
*/
class General_model extends CI_Model {
/**
* Consulta BASICA A UNA TABLA
* @param $TABLA: nombre de la tabla
* @param $ORDEN: orden por el que se quiere organizar los dat... | true |
874d3ecb2210107054a6fe51a158c0835f2efa2c | PHP | elvisaronsp/IdeaSpace | /app/Http/Controllers/Admin/ThemesController.php | UTF-8 | 12,477 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers\Admin;
use App\Http\Controllers\Controller;
use App\Http\Requests;
use App\Theme;
use Illuminate\Http\Request;
use Illuminate\Database\Eloquent\ModelNotFoundException;
use Auth;
use App\Content\ContentType;
use File;
use Log;
class ThemesController extends Controller {
priva... | true |
d967006b12cf4e93ebe332b4309c49d3b5bd5ec1 | PHP | solid-framework/http | /src/ResourceStream.php | UTF-8 | 5,348 | 2.96875 | 3 | [
"MIT"
] | permissive | <?php
/**
* Copyright (c) 2017 Martin Pettersson
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Solid\Http;
use InvalidArgumentException;
use Psr\Http\Message\StreamInterface;
use RuntimeException;
/**
* @package Soli... | true |
eafdada5de16270ecb3f3ccf3a84d555e88d945a | PHP | MartinecUpce/schoolwork | /Webowky_Sem/semestralka/userPage.php | UTF-8 | 6,356 | 2.546875 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: Vojta
* Date: 19/01/2019
* Time: 17:24
*/
include 'elementals/header.php';
include "Connection.php";
if(!empty($_SESSION)) {
$conn = Connection::getPdoInstance();
$id = $_SESSION["user_id"];
$stmt = $conn->prepare("select * from uzivatel where idUzivatel = $i... | true |
9be37e052ba9c8afbff7b38f3769178bedb86dc3 | PHP | romkatsu/app-api | /src/Blog/PageRequest.php | UTF-8 | 612 | 2.5625 | 3 | [] | permissive | <?php
declare(strict_types=1);
namespace App\Blog;
use Yiisoft\RequestModel\RequestModel;
use OpenApi\Annotations as OA;
/**
* @OA\Parameter(
* @OA\Schema(
* type="int",
* example="2"
* ),
* in="query",
* name="page",
* parameter="PageRequest"
* )
*/
final class ... | true |
d10a3548ed29a041150abe5a76b1923d5360233d | PHP | Gavrox/mycode | /sqlzadatak/multidel.php | UTF-8 | 953 | 2.78125 | 3 | [] | no_license | <?php
include "menu.php";
require "conn.php";
$msq = "SELECT * FROM titles";
$query = mysqli_query($conn, $msq);
?>
<!doctype html>
<html>
<head>
<link href="style.css" rel="stylesheet" type="text/css">
<meta charset="utf-8">
<title>Delete multiple books</title>
</head>
<body>
<div id="wrap">
<h1>Delete books from ba... | true |
7fccae5ce742641e834c8589a92bdc1197808240 | PHP | marscore/hhvm | /hphp/test/slow/dynamic_methods/strings_with_colons.php | UTF-8 | 727 | 3.21875 | 3 | [
"Zend-2.0",
"PHP-3.01",
"MIT"
] | permissive | <?php
class W {
public function dyn() {
var_dump(static::class);
var_dump(isset($this) ? $this : null);
}
public static function stc() {
var_dump(static::class);
}
}
class X extends W {
public function ibar($s) {
$s();
}
public static function sbar($s) {
$s();
}
}
class Y extends X... | true |
3c6e5ee34de712ecd7f583797d82cc7a37cf4655 | PHP | LJ2013/app | /app/Console/Commands/TestConsole.php | UTF-8 | 1,585 | 2.9375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
class TestConsole extends Command {
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'hi{name=lj}{--over}';
/**
* The console command description.
*
* @... | true |
643fd3ff61ae387cdd5fc270946235aa52019d11 | PHP | olesmith/Sivent2 | /Common/Sql/DB.php | UTF-8 | 5,263 | 2.828125 | 3 | [] | no_license | <?php
trait Sql_DB
{
var $DBs=array();
//*
//* function Sql_DBs_Get_Query, Parameter list:
//*
//* Returns query for extracting databases on server.
//*
function Sql_DBs_Get_Query()
{
$type=$this->DB_Dialect();
$query="";
if ($type=="mysql")
{
... | true |
083f3e07e91e70d33cfff33bf37659229454b44a | PHP | eghojansu/stick | /src/Event/RequestErrorEvent.php | UTF-8 | 1,139 | 2.671875 | 3 | [
"MIT"
] | permissive | <?php
/**
* This file is part of the eghojansu/stick library.
*
* (c) Eko Kurniawan <ekokurniawanbs@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);
namespace Ekok\Stick\Event;
class RequestEr... | true |
6429114cfe26915fac925afe662fb6308205d448 | PHP | ClaudioLenin/phpapp_condueval | /Estudiante/Examen/guardarexamen.php | UTF-8 | 27,107 | 2.59375 | 3 | [] | no_license | <?php
require '../../app/conexion.php';
session_start();
if ($_POST['guardar'] && !isset($_COOKIE['establecido'])) { //ESTABLECER EL TIEMPO QUE DURA EL EXAMEN Y EL ID DE LA PRUEBA
Conexion::abrir_conexion();
$sql = "SELECT * FROM texamen WHERE codexamen = :codexamen";
$sentencia = Conexion::obtener_conexi... | true |
0725a9cb62f2f42d3638b56c500deff4fd1c629f | PHP | mahmoudelwekel/Alumni-UHB | /Code/views/colleges/edit.php | UTF-8 | 1,280 | 2.625 | 3 | [] | no_license | <?php
$page = "colleges";
require_once"../../init/init.php";
if ( !isAdmin() ) {
redirect("public");
}
if ( $_SERVER['REQUEST_METHOD'] == 'POST' ) {
/** Validating the Name */
if( $_POST['name'] != "" ) {
$name = filter_var($_POST['name'], FILTER_SANITIZE_STRING);
} else {
$_SESSION['msg'][] = "You Must Enter... | true |
cd03b4469cc03736dbcd44fc9ce69e020ae75c7a | PHP | dexbarrett/jborbon.me | /app/Services/Sitemap/SitemapBuilder.php | UTF-8 | 1,749 | 2.546875 | 3 | [] | no_license | <?php
namespace DexBarrett\Services\Sitemap;
use Carbon\Carbon;
use DexBarrett\Post;
use Tackk\Cartographer\Sitemap;
use Tackk\Cartographer\ChangeFrequency;
use Illuminate\Contracts\Cache\Repository as Cache;
class SitemapBuilder {
protected $sitemap;
protected $cache;
protected $cacheKey = 'sitemap';
... | true |
ab87404754c95d65e11a27ce71784a6ae050d8e4 | PHP | Reccy/college-rps_wadproject | /server/getscore.php | UTF-8 | 1,424 | 3.09375 | 3 | [] | no_license | <?php
//Get values required to perform function
$username = $_POST["Username"];
$field = $_POST["Field"];
$returnData; //Data to return
//If any values are null, return an error, otherwise continue.
if($username == null ||$field == null){
echo "error_unknown";
exit();
... | true |
433badffd61af607faafae3a45de3c1899d0c472 | PHP | hakirospy/fabrikaalef | /bitrix/modules/aspro.max/lib/smartseo/models/smartseoseotextiblocksectionstable.php | UTF-8 | 1,937 | 2.625 | 3 | [] | no_license | <?php
namespace Aspro\Max\Smartseo\Models;
use Aspro\Max\Smartseo\Admin\Settings\SettingSmartseo,
Bitrix\Main\Localization\Loc,
Bitrix\Main\ORM\Data\DataManager,
Bitrix\Main\ORM\Fields\IntegerField,
Bitrix\Main\ORM\Fields\Relations\Reference,
Bitrix\Main\ORM\Query\Join;
Loc::loadMessages(__FILE__);
/*... | true |
fa519f0c42128db4f90090625ee23c8089e6b95f | PHP | g4code/log | /src/Error/Exception.php | UTF-8 | 858 | 2.671875 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
namespace G4\Log\Error;
class Exception extends ErrorAbstract
{
/**
* @param \Exception|\Throwable $exception
*/
public function handle($exception)
{
$this->getErrorData()
->setCode($exception->getCode())
->setMessage($exception->getMessage())
-... | true |
6f99a0d2591823bfa020c6dff8d34c7876a7941d | PHP | purwaren/mfg-dashboard | /protected/models/ChangePassword.php | UTF-8 | 1,212 | 2.875 | 3 | [] | no_license | <?php
/**
* Change Password
* Model container for task updating password
*/
class ChangePassword extends CFormModel
{
public $username;
public $old_password;
public $password;
public $confirm_password;
/**
* Declares the validation rules.
* The rules state that username and password are requir... | true |
5fc4e666b30f3f99ed8ef752c0c9f3bd43d724dc | PHP | Go-loneliness-of-man/rw | /core/publicService.php | UTF-8 | 2,469 | 3 | 3 | [] | no_license | <?php
// 命名空间
namespace core;
use core\dao;
// 抽象类,只能被继承,不能实例化
abstract class publicService {
// 保存 dao 实例
protected $dao;
// 构造函数
public function __construct() {
}
// 标准返回格式
public function res($code, $message, $result, $total = 0) {
return json_encode([
'code' => $code,
'message' =... | true |
d8dd5f98f4a96c659272cdcd3f2cfe789cede0d4 | PHP | Jahid99/Subject_choice_processing_system | /admin/test.php | UTF-8 | 1,195 | 2.6875 | 3 | [] | no_license | <?php
$cste=array("cste","ice","eee","acce","software_engineering");
//$cste = array("teer","beer","fear");
$store = array();
for($nice=0;$nice<100;$nice++){
shuffle($cste);
$cste_str = implode(' ', $cste);
if (!in_array($cste_str, $store))
{
array_push($store,$cste_str);
}
... | true |
b3a789e7b7f89d569d7a6f3981b7e98f80bebaaf | PHP | Martiusweb/YaPhpDoc | /lib/YaPhpDoc/Tag/Param.php | UTF-8 | 1,778 | 3.3125 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
/**
* YaPhpDoc
* @author Martin Richard
* @license New BSD License
*/
/**
* Description of the parameter of a class or a function.
*
* Syntax: @param type|alt_type|... $var description
*
* You can also use this syntax as last parameter for function allowing any
* number of parameters :
*
* Alt syn... | true |
a255cbeb152d2ebe1b3f7f4c3e81dd34ce1566f9 | PHP | armandolazarte/distrigases-facturas | /app/database/migrations/2014_03_09_153241_create_factura_items_table.php | UTF-8 | 1,005 | 2.53125 | 3 | [] | no_license | <?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateFacturaItemsTable extends Migration {
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('factura_items', function(Blueprint $table)
{
$table->increments('id');... | true |
5d9e61db0cabf4151ffafe571d9267e0d6ae74e1 | PHP | shinyhouse/remp | /Mailer/app/Models/ContentGenerator/ContentGenerator.php | UTF-8 | 2,669 | 2.578125 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace Remp\MailerModule\Models\ContentGenerator;
use Nette\Database\IRow;
use Remp\MailerModule\Repositories\ActiveRow;
use Remp\MailerModule\Models\ContentGenerator\Engine\EngineFactory;
use Remp\MailerModule\Models\ContentGenerator\Replace\IReplace;
class ContentGenerator
{
p... | true |
8c728cab519beebe6ca059a162c252fb8443f845 | PHP | bgeye/webdev | /php/02_session_cookies_sort/sort/sort.php | UTF-8 | 375 | 3.46875 | 3 | [] | no_license | <?php
$fruits = array(
'd' => 'Zitrone',
'a' => 'Orange',
'b' => 'Banane',
'c' => 'Apfel'
);
//sort($fruits); //ABC aufsteigend
//rsort($fruits); //CBA absteigend
//asort($fruits); //value ABC aufsteigend
//arsort($fruits); //value BCA absteigend
ksort($fruits); //key aufsteigend
//krsort($fruits);... | true |
03c8bb1f89d996f30c5746bbb5e144ff85db621d | PHP | dohnall/historycarprague | /lib/classes/MenuList.class.php | UTF-8 | 896 | 2.515625 | 3 | [] | no_license | <?php
class MenuList extends ItemListDomain {
protected $item = "menu_id";
public function __construct() {
parent::__construct();
$this->table = Config::db_table_menu();
}
public function load($items = array(), $limit = 0, $from = 0, $orderby = "", $sort = "ASC") {
if(M... | true |
22469d0955557b0790ac08fb8bc3ac2905633cdb | PHP | p-lorenzo/openrestaurant-be | /src/Entity/MenuSection.php | UTF-8 | 2,664 | 2.625 | 3 | [] | no_license | <?php
namespace App\Entity;
use App\Repository\MenuSectionRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use Ramsey\Uuid\Uuid;
use Symfony\Component\Serializer\Annotation\Groups;
/**
* @ORM\Entity(repositoryClass=MenuSectionR... | true |
e91f125ae1125292f71aa35b6c55756a00108703 | PHP | yyxo/qk-token-system | /app/helpers.php | UTF-8 | 1,051 | 2.859375 | 3 | [] | no_license | <?php
/**
* 16进制转10进制
* @param string $hex
* @return int|string
*/
function HexDec2(string $hex){
$dec = 0;
$len = strlen($hex);
for($i = 1; $i <= $len; $i++){
$dec = bcadd($dec, bcmul(strval(hexdec($hex[$i - 1])), bcpow('16', strval($len - $i))));
}
return $dec;
}
/**
* inarray不区分大... | true |
8124f09779b59e5aed1e4f1e9897fcacb9a49e87 | PHP | vkopytich/phpAlgorithms | /dp/lab2/lab2_1.php | UTF-8 | 1,405 | 3.375 | 3 | [] | no_license | <?php
function genereate_array($size) {
$arr = array();
for($i=0; $i <= $size; $i++)
for($j=0; $j <= $i; $j++)
$arr[$i][$j] = rand(0, 9);
return $arr;
}
function print_arr($arr) {
foreach ($arr as $str) {
foreach ($str as $num)
echo $num . ' ';
echo "<br/>";
}
echo "<br/>";
}
function result_ar... | true |
d54795a25aaa74eee4d60a24a8bf13f2dfa7e3d0 | PHP | rmenendezdaw/Angular_Laravel_Go_APP | /backend/laravel/database/factories/ModelFactory.php | UTF-8 | 2,054 | 2.671875 | 3 | [
"MIT"
] | permissive | <?php
/*
|--------------------------------------------------------------------------
| Model Factories
|--------------------------------------------------------------------------
|
| Here you may define all of your model factories. Model factories give
| you a convenient way to create models for testing and seeding yo... | true |
6910cbf43a654a499292a90b179d5563e9fcf64e | PHP | kratskij/adventofcode | /2017/09/09.php | UTF-8 | 939 | 3.0625 | 3 | [] | no_license | <?php
ini_set('memory_limit','2048M');
$test = false;
$file = ($test) ? "test" : "input";
$input = explode("\n", trim(file_get_contents(__DIR__ . DIRECTORY_SEPARATOR . $file)));
$chars = str_split($input[0]);
$groups = [];
$groupPath = [];
$garbage = false;
$ignoreNext = false;
$sum = 0;
$level = 0;
$garbageCount =... | true |
38661e3b3e83da04f914aeb753383d55802b7ccc | PHP | collecthor/surveyjs-parser | /tests/Variables/SingleChoiceVariableTest.php | UTF-8 | 5,054 | 2.734375 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace Collecthor\SurveyjsParser\Tests\Variables;
use Collecthor\SurveyjsParser\ArrayDataRecord;
use Collecthor\SurveyjsParser\ArrayRecord;
use Collecthor\SurveyjsParser\Interfaces\Measure;
use Collecthor\SurveyjsParser\Interfaces\ValueOptionInterface;
use Collecthor\SurveyjsParser\... | true |
81e519f9b85f1cab8b2afaf7855233041e2c77d0 | PHP | limingxinleo/php-zephir-parser | /tests/base/001.phpt | UTF-8 | 577 | 2.5625 | 3 | [
"MIT"
] | permissive | --TEST--
zephir_parse_file() - Tests class variables
--SKIPIF--
<?php require(__DIR__ . "/../zephir_parser_skip.inc"); ?>
--FILE--
<?php require(__DIR__ . "/../zephir_parser_test.inc");
$ir = parse_file("base/class_variables.zep");
echo count($ir[1]["definition"]["properties"]) . "\n";
foreach ($ir[1]["definition"][... | true |
c566516d5ecb5caefe9a21ec37ed1cf31f3ac01a | PHP | Keny9/Lab_Hypermedia | /outils/connexion.php | UTF-8 | 669 | 3.171875 | 3 | [] | no_license | <?php
class Connexion{
private $conn;
private $dbHost = "localhost";
private $dbUser = "root";
private $dbPass = "";
private $dbName = "lab1_hypermedia";
function __construct() {
$this->conn = mysqli_connect($this->dbHost, $this->dbUser, $this->dbPass, $this->dbName);
mysqli_set_charset($this->con... | true |
95783caec7178db42ed3071549a96dcf8022e30b | PHP | AndreyLM/yii2-template | /domain/repositories/MySqlArticleRepository.php | UTF-8 | 4,436 | 2.75 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: root
* Date: 11/20/17
* Time: 2:07 PM
*/
namespace domain\repositories;
use domain\entities\Article;
use domain\mysql\Article as ARArticle;
use domain\exceptions\DomainException;
use yii\web\NotFoundHttpException;
class MySqlArticleRepository implements IArticleReposito... | true |
07a4c2ffbfa9129d8f99a157fcd77784fd5c778b | PHP | dori88/school_projects | /arc_db_SQL/UI_code/home.php | UTF-8 | 7,277 | 2.578125 | 3 | [] | no_license | <?php include "../inc/dbinfo.inc"; ?>
<html>
<head>
<style>
body{
background-color: #A8E0FF
}
</style>
</head>
<body>
<img src="ARCBanner.png" alt="ARC Banner" height="162" width="800" align="middle">
<h1 style="color:green;">ARC DATABASE</h1>
<br>
<?php
/* Connect to MySQL and select the database. Information r... | true |
695b101afebb39a0a36314b75c9bb9056ec72b19 | PHP | JAndreuSoler/Projecte | /app/Model/Comment.php | UTF-8 | 2,021 | 3.21875 | 3 | [] | no_license | <?php
class Comment extends Model {
private $id;
private $userId;
private $text;
private $responseId;
private $referenceId;
/**
* Comment constructor.
* @param $userId
* @param $text
* @param $responseId
* @param $id
*/
public function __construct($userId, $t... | true |
f91c9123850ee8230ec3451f6db5b10d2cc2b84d | PHP | aLLeXUs/phpAPI | /update.api.php | UTF-8 | 585 | 2.78125 | 3 | [] | no_license | <?php
class update extends apiBaseClass {
public function check() {
$this -> initDB(); // инициализация базы данных
if (array_key_exists('name', $this -> functionParams)) {
$arr = '';
$query = "SELECT * FROM apps WHERE name = :name";
$result = $this -> dbConnection -> query($query, array('name' => $th... | true |
0dcbdeefbb49a8a51f9b7b76936fb267b24af153 | PHP | victoriaPaez/ejercicio_CRUD_PHP | /Crud.php | UTF-8 | 2,656 | 2.96875 | 3 | [] | no_license | <?php
require_once('Conection.php');
class Crud extends Conection{
public function mostrarDatos(){
$sql ="SELECT id,
email,
pasword,
nombre,
apellido,
alias
FROM usuario";
$... | true |
8b0e40e6ecdcd7f2c79cc5f657ad11d8294017cd | PHP | t-4-h/Database-Management | /Homework 4/data.php | UTF-8 | 1,043 | 2.796875 | 3 | [] | no_license | <?php
$servername = "localhost";
$username = "root";
$password = "mysql";
$database = "yelp_db";
$conn = new mysqli($servername, $username, $password, $database);
// Check connection
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
$sql = "";
switch ($_GET[action]) {
case 'm... | true |
bad823f176005584db8a34dfe80f21a90f82fc82 | PHP | Roma41/php_blog | /public/views/new_article.php | UTF-8 | 683 | 2.6875 | 3 | [] | no_license |
<form method="post" action="<?php echo $_SERVER["PHP_SELF"]; ?>">
Title: <input type="text" name="title">
Body: <textarea name="body" cols="40" rows="5"></textarea>
<input type="submit">
</form>
<?php
if ($_SERVER["REQUEST_METHOD"] == "POST") {
// collect value of input field
require_once $_SERVER['DOCUMENT... | true |
cdf111460e13c66ba1c88f9866cf6e543a0ea204 | PHP | gabrielsanttana/rolling-tetris | /src/services/api.php | UTF-8 | 3,336 | 2.71875 | 3 | [] | no_license | <?php
require_once 'db_connection.php';
require_once 'dao/PlayerDAO.php';
require_once 'models/Player.php';
require_once 'dao/GameLogDAO.php';
require_once 'models/GameLog.php';
session_start();
if(!$_POST){
header('Location: ../containers/Login/index.php');
}
$method = $_POS... | true |
34307a88ee7bc0ae07696e9b533fef7accfe5994 | PHP | vadempur/ibs-ui | /public/contact.php | UTF-8 | 1,012 | 2.640625 | 3 | [] | no_license | <?php
if (isset($_POST['name']) && isset($_POST['email']) && isset($_POST['message']) && is_string($_POST['name']) && is_string($_POST['email']) && is_string($_POST['message'])) {
$to = 'youcef.zahariou@gmail.com';
$subject = 'Mail from ' . $_POST['name'];
$email = 'Email : ' . $_POST['email'] . ' <b... | true |
6c18a3f3567769aca383d26113b6fe0866cd1f98 | PHP | cyruschueng/weappforshop | /v2/application/common/model/Admin.php | UTF-8 | 3,051 | 2.796875 | 3 | [
"Apache-2.0"
] | permissive | <?php
namespace app\common\model;
use think\Model;
class Admin extends Model
{
protected $autoWriteTimestamp = 'timestamp';
// 定义时间戳字段名
protected $createTime = 'created_at';
protected $updateTime = 'updated_at';
public function group(){
return $this->hasOne('AuthGroup','id','group_id');
}
/**
... | true |
7a422ef62bc3402a7b73945e5dc2f14653d5edd7 | PHP | lingfan/war2game | /srv/M/Message.php | UTF-8 | 11,723 | 2.75 | 3 | [] | no_license | <?php
/**
* 消息逻辑层
* @author chenhui on 20110505
*/
class M_Message {
/** 未读消息 */
const MSG_UNREAD = 0;
/** 已读消息 */
const MSG_READ = 1;
/** 未删消息 */
const MSG_UNDEL = 0;
/** 已删消息 */
const MSG_DEL = 1;
/** 玩家消息 */
const USER_SEND = 1;
/** 系统消息 */
const SYS_SEND = 2;
/*... | true |
9a60884383ab3f7d21ad41581f9091a58f99f974 | PHP | Alejo400/Mi-tesis | /modelo/secciones.php | UTF-8 | 477 | 2.59375 | 3 | [] | no_license | <?php
class seccion {
public function registrar($seccion,$usuario,$periodo){
$sql = "INSERT INTO secciones VALUES ('$seccion','$usuario','$periodo')";
$res = mysql_query($sql);
if($res == 1){
echo "<script type='text/javascript'> alert('Sección creada con éxito'); window.location='../vista/index2.php'; </script>"... | true |
3fdd8ac51a4c426152d5ef95645d69e5d3455a3a | PHP | Tndevfactory/shoppingApp | /app/helpers/helpers.php | UTF-8 | 1,322 | 3.015625 | 3 | [
"MIT"
] | permissive | <?php
use Illuminate\Support\Str;
/**
* @param $value
* @return string
*/
function numericFormat($value){
$value = Str::replace(',', '.', $value);
$value = Str::remove(' ', $value);
$value = floatval($value) ;
return $value ;
}
/**
* @param $value
* @return string
*/
function curren... | true |
b64a69d4c1b3ab4da97e95b4c3d95fdbefcc9dea | PHP | vhotspur/nevilis-php | /lib/db.php | UTF-8 | 3,376 | 2.859375 | 3 | [] | no_license | <?php
// Uncomment if your hosting offers SQLite3 but not through PDO
// require_once 'pdo_sqlite3.php';
function db_log_query($description, $sql, $params, $result = null) {
if (! option('debug')) {
return;
}
if (! isset($GLOBALS['SQL_QUERIES'])) {
$GLOBALS['SQL_QUERIES'] = array ();
}
$GLOBALS['SQL_QUERIES'... | true |
52cc670088422c54b70b2177c02f2e4220c9f1c6 | PHP | SuRaMoN/itertools | /src/itertools/FileCsvIterator.php | UTF-8 | 2,417 | 2.8125 | 3 | [
"WTFPL"
] | permissive | <?php
namespace itertools;
use Exception;
use InvalidArgumentException;
use SplFileInfo;
class FileCsvIterator extends AbstractCsvIterator
{
protected $fileHandle;
protected $closeFileHandleOnDestruct;
protected $guzzleStream;
public function __construct($file, array $options = array())
{
... | true |
bdaa2e71a226cff9808fee8b7cd77f51dc035eaf | PHP | idqweb/taskoj | /application/models/Panelcreador_model.php | UTF-8 | 8,908 | 2.578125 | 3 | [] | no_license | <?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Panelcreador_model extends CI_Model {
public function __construct() {
parent::__construct();
}
// Modifica datos del usuario
public function modificaPerfil($data, $email) {
$this-... | true |
78bceb0c84499f15cfbf6d09ec1d5e286d034e01 | PHP | diglin/fast-map | /src/Compiler/Builder/PropertyPathBuilder.php | UTF-8 | 1,618 | 2.59375 | 3 | [] | no_license | <?php declare(strict_types=1);
namespace Kiboko\Component\ETL\FastMap\Compiler\Builder;
use PhpParser\Builder;
use PhpParser\Node;
use Symfony\Component\PropertyAccess\PropertyPath;
use Symfony\Component\PropertyAccess\PropertyPathInterface;
final class PropertyPathBuilder implements Builder
{
/** @var PropertyP... | true |
87ca21119b8cdda6f0a11e5ba7df1efe6a629fd4 | PHP | opservices/fivemetrics | /src/DataSourceBundle/Entity/Aws/CloudWatch/Metric.php | UTF-8 | 2,038 | 2.734375 | 3 | [
"Apache-2.0"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: fivemetrics
* Date: 10/02/17
* Time: 17:51
*/
namespace DataSourceBundle\Entity\Aws\CloudWatch;
use DataSourceBundle\Collection\Aws\CloudWatch\DimensionCollection;
use DataSourceBundle\Entity\Aws\EntityAbstract;
/**
* Class Metric
* @package Entity\Aws\CloudWatch
*/
c... | true |
93c2a2acf789ad5f68e94857fe626907ef6c7630 | PHP | fadykstas/symfony4-ddd-basket-task | /src/Project/Http/Controller/ItemController.php | UTF-8 | 4,622 | 2.640625 | 3 | [] | no_license | <?php
namespace App\Project\Http\Controller;
use App\Project\App\UseCases\Basket\AddItems\{
AddItemsAction,
AddItemsRequest};
use App\Project\App\UseCases\Basket\RemoveItem\RemoveItemAction;
use App\Project\App\UseCases\Basket\RemoveItem\RemoveItemRequest;
use App\Project\Http\{
Controller\Traits\JsonRe... | true |
08d544acea0caa41e9bb6f853dc001170b483e2b | PHP | kritjenwit/Music-Streaming-Website-PHP-ver. | /php/unuse/encrypt-sign-in.php | UTF-8 | 1,505 | 2.671875 | 3 | [] | no_license | <?php
require "encrypt-decrypt.php";
$conn = new mysqli("localhost","root","","project");
$_SESSION['error']= "";
// This is used to keep the user logged in website //
if((isset($_SESSION["email"])) && (isset($_SESSION["logged"]))){
header("Location: hom... | true |
ae6590ee8f186042ddb0e27cfeeb8eae2177ecf9 | PHP | maldoror278/ficha | /controlador.php | ISO-8859-10 | 5,409 | 2.578125 | 3 | [] | no_license | <?php
include("db.php");
$key=$_GET['key'];
switch($key){
case 1:
try{
//$nombre = $_SESSION['usuario'];
$nombre = $_GET['nombre'];
$vin = $_GET['vin'];
$ecu = $_GET['ecu'];
$modelo = $_GET['modelo'];
$serial = $_GET['serial'];
$version = $_GET['version'];
$fecha = $_GET['f... | true |
f7c4ac00b0ae5157c14ce06e926e97f7f8b3af8d | PHP | grueneschweiz/weblingservice | /app/Repository/Member/Merger/FieldMerger.php | UTF-8 | 1,718 | 2.890625 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace App\Repository\Member\Merger;
use App\Repository\Member\Field\Field;
use App\Repository\Member\Field\FreeField;
use App\Repository\Member\Field\SelectField;
abstract class FieldMerger
{
public function __construct(
protected Field $dst,
protected Field $sr... | true |
4ad9f21db329fa1d91e4bd9ecd8b11383d3cd418 | PHP | fendrina/sistemsurvei | /app/Models/Grafik_M.php | UTF-8 | 73,348 | 2.578125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Models;
use CodeIgniter\I18n\Time;
use CodeIgniter\Model;
class Grafik_M extends Model
{
public function getProdi(){
$nama_prodi = $this->db->table('prodi')->get()->getResultArray();
return $nama_prodi;
}
public function getGrafikProdi()
{
$tgl_skrg = Time:... | true |
2fb4d8cca886133e58a6c338403f050abd19661a | PHP | ssssaaa111/perfect_start | /app/ChainOfResponsibility.php | UTF-8 | 1,532 | 2.921875 | 3 | [
"MIT"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: zunhui
* Date: 2017/7/29
* Time: 下午5:21
*/
abstract class HomeChecker{
protected $successor;
abstract public function check(HomeStatus $home);
public function succeedWith(HomeChecker $successor){
$this->successor = $successor;
}
public functio... | true |
3c75de7f3f6bf43011aca0c10c571def802a5968 | PHP | Madylune/Blog | /data/index.php | UTF-8 | 1,505 | 2.84375 | 3 | [] | no_license | <?php
require('./config.php');
try {
$pdo = new PDO("mysql:host=$host;dbname=$dbname", $username, $password);
$sql = 'SELECT * FROM articles';
$q = $pdo->query($sql);
$q->setFetchMode(PDO::FETCH_ASSOC);
} catch (PDOException $e) {
die("Could not connect to the dat... | true |
bf40ce227ddd0466a03554d0d8d449f172174ba4 | PHP | n1c01a5/N1c0LessonBundle | /Model/ConclusionManager.php | UTF-8 | 3,485 | 2.921875 | 3 | [] | no_license | <?php
namespace N1c0\LessonBundle\Model;
use N1c0\LessonBundle\Events;
use N1c0\LessonBundle\Event\ConclusionEvent;
use N1c0\LessonBundle\Event\ConclusionPersistEvent;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
use InvalidConclusionException;
/**
* Abstract Conclusion Manager implementation whi... | true |
db3776c0125dc6519edd6b3cb5b374829ad9376f | PHP | jackmolnar/eriejobs | /app/EriePaJobs/Blog/EditBlogPostCommand.php | UTF-8 | 1,174 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: jackmolnar1982
* Date: 4/3/15
* Time: 10:06 AM
*/
namespace EriePaJobs\Blog;
use EriePaJobs\BaseCommand;
class EditBlogPostCommand extends BaseCommand {
/**
* @var
*/
private $input;
function __construct($input, $id)
{
$this->input = $... | true |
a1aad6f9aa410fa85e17b47fc667f71b3a5bed85 | PHP | punk73/mapros_system54 | /app/Observers/LineprocessObserver.php | UTF-8 | 601 | 2.53125 | 3 | [] | no_license | <?php
/**
*
*/
namespace App\Observers;
use App\Lineprocess;
use App\LineprocessStart;
class LineprocessObserver
{
public function created(Lineprocess $lineprocess){
$lineprocessStart = new LineprocessStart([
'lineprocess_id' => $lineprocess->id,
'start_id' => $lineprocess->id
]);
$lineproce... | true |
2b283e7a981b08b1e523e27d0f402783545b115f | PHP | ISPbills/isp_man | /application/controllers/Area.php | UTF-8 | 3,896 | 2.53125 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
defined('BASEPATH') OR exit('No direct script access allowed');
/**
* Area Class
*/
class Area extends CI_Controller
{
public function __construct()
{
parent::__construct();
$this->logged_id();
$this->load->model('Area_Model');
}
private function logged_id()
{
if(!$this->session->us... | true |
6f203cca3fd9efd83fdf6ef045fcc9e8cb0ed80e | PHP | MariaBelenCervo/flip-meet | /mvc/api/Responses/HttpAckResponse.php | UTF-8 | 681 | 2.984375 | 3 | [] | no_license | <?php
namespace Responses;
use Exceptions\HttpException;
/**
* Clase que arma el mensaje de respuesta de 200 OK para ackownledge (solo titulo y message, sin data en el body).
* Extiende funcionalidad de la clase base HttpResponse.
* Estructuta: [statusCode (int), statusText (string), title (string), message (stri... | true |
b0311647e293fc0b575c61d941974ba6aaddf5d2 | PHP | curtismchale/WPTT-ICS-Feeds | /wptt-ics-feeds.php | UTF-8 | 9,056 | 2.625 | 3 | [] | no_license | <?php
/*
Plugin Name: WPTT ICS Feeds
Plugin URI: https://curtismchale.ca
Description: Adds an ICS compatible feed for future posts
Version: 1.4.4
Author: curtismchale
Author URI: https://curtismchale.ca
License: GPLv2 or later
*/
/**
* @todo make sure that we can let authors define a post status
* @todo do some obfu... | true |