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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
52da3395ca9a8d25ffa3ad07abfcac3c15658164 | PHP | SnakeWar/96fm | /app/Http/Controllers/Admin/CategoryController.php | UTF-8 | 3,474 | 2.578125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers\Admin;
use App\Http\Controllers\Controller;
use App\Http\Requests\CategoryFormRequest;
use App\Models\Category;
use Illuminate\Http\Request;
class CategoryController extends Controller
{
protected $category;
protected $title;
public function __construct(Category $cat... | true |
60e14c1d54d3b09bccd998723a517c4a427be2d2 | PHP | justmd5/quark-admin | /src/Grid/Search/Item.php | UTF-8 | 3,904 | 2.78125 | 3 | [
"MIT"
] | permissive | <?php
namespace QuarkCMS\QuarkAdmin\Grid\Search;
use Exception;
class Item
{
public $value,
$defaultValue,
$label,
$name,
$rules,
$style,
$component,
$operator,
$advanced,
$placeholder;
function __co... | true |
a42eaf53fd8aa6d3d58a63a7ddd5ca4258c810cc | PHP | emmyboy/socialdiary | /register.php | UTF-8 | 1,317 | 2.515625 | 3 | [] | no_license | <?php
// Inialize session
session_start();
// Include database connection settings
require_once 'db.php';
$db = new db();
$con = $db->getConnection();
//Verify newly registered email has not been registered yet
$latest = mysql_query("select email from logindb ORDER BY userid DESC LIMIT 1");
$email = mysql_result($late... | true |
9e303c176df953ef1efb55d15bd4d4fcf6e377ae | PHP | kevinhartarto/EventSource | /details/index.php | UTF-8 | 3,343 | 2.71875 | 3 | [] | no_license | <?php
// include('../connection.php');
include('../conn.php');
session_start();
if (isset($_GET["q"])) {
$eventId = $_GET['q'];
}else{
$eventId = $_POST['id'];
}
$sqlCommand = "SELECT * FROM event WHERE id = '$eventId'";
$result = $conn->query($sqlCommand);
$namaEvent;$periodeEvent;$jamEvent;$lokasiEvent;$... | true |
235acdcddd6c40b3eef988a40ea672c8746f664c | PHP | jeroendesloovere/sport-tracker-connector | /src/SportTrackerConnector/Workout/Loader/LoaderInterface.php | UTF-8 | 527 | 2.984375 | 3 | [
"MIT"
] | permissive | <?php
namespace SportTrackerConnector\Workout\Loader;
/**
* Interface for workout loaders.
*/
interface LoaderInterface
{
/**
* Get a workout from a string.
*
* @param string $string The data.
* @return \SportTrackerConnector\Workout\Workout
*/
public function fromString($string);
... | true |
7f2ce20e4b8df547eb52db98d07c45f2704a4ba2 | PHP | mpkelevra23/php_lvl_2 | /app/web/lesson_3/homework/models/Picture.php | UTF-8 | 5,306 | 3.234375 | 3 | [] | no_license | <?php
include_once 'Db.php';
include_once 'Transfer.php';
/**
* Класс для работы с изображениями
* Class Picture
*/
class Picture
{
/**
* TODO переделать логику метода, изменить возвращаемое значение
* Сохраняем изображение
* @return string
*/
public static function save()
{
... | true |
f4f9e2c6f1a657fc16adae3eb94a118fa8c6000d | PHP | MoQuEs/SampleCode | /backend/src/Action/Todo/CreateTodo.php | UTF-8 | 1,011 | 2.546875 | 3 | [] | no_license | <?php
declare(strict_types = 1);
namespace App\Action\Todo;
use App\Action\Action;
use App\Action\EntityManagerAction;
use App\Domain\Todo;
use App\Utils\Response;
use Doctrine\ORM\OptimisticLockException;
use Doctrine\ORM\ORMException;
use Exception;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\Ser... | true |
15bfe6acf6eb3cd251ef0d406f1306f167cbb878 | PHP | andystanton/euler | /problems/001/php/functional.php | UTF-8 | 179 | 2.71875 | 3 | [
"MIT"
] | permissive | <?php
$result = array_sum(
array_filter(range(1, 999), function ($item) {
return $item % 3 == 0 || $item % 5 == 0;
})
);
print($result)
?>
| true |
8a8c17e06245f725fcb5296894e19a73ffc2f77d | PHP | gskoropada/ScioXchange | /form_validation.php | UTF-8 | 1,293 | 3.171875 | 3 | [] | no_license | <?php
/*
* FORM VALIDATION
* Provides back-end functionality for the clients AJAX requests.
*/
if (isset($_GET['q']) && isset($_GET['email'])){
require_once 'connect.php';
echo email_exists($_GET['email'], $con);
} elseif (isset($_GET['q']) && isset($_GET['scrname'])){
require_once 'connect.php';
ech... | true |
9b25584787d335edefb61f3cd8f8a6cb6d44f3c8 | PHP | mbretter/stk-immutable | /src/Stk/Immutable/Methods/ReadIn.php | UTF-8 | 1,323 | 2.953125 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
namespace Stk\Immutable\Methods;
trait ReadIn
{
final protected function _seek(mixed &$target, array $path, ?bool &$found = true): mixed
{
$found = true;
$elem = $target;
foreach ($path as $f) {
if (is_object($elem)) {
if (!property_exists($elem, $f))... | true |
1f634981fadd88282e67ae942a0b7353a67f15a3 | PHP | COMP4711-LAB5-GROUP24/Back-end | /tests/TaskTest.php | UTF-8 | 522 | 2.578125 | 3 | [
"MIT"
] | permissive | <?php
use PHPUnit\Framework\TestCase;
class TaskTest extends TestCase
{
/**
* @dataProvider TaskDataProvider
*/
public function testSetTask($case, $property, $input, $expected)
{
$taskEntity = new Task;
$taskEntity->$property = $input;
$this->assertSame($expected, $taskEn... | true |
7ae3dc4e8a70d12f7e664419f64ce571071ceb89 | PHP | ezpublishlegacy/ez_dynamic_block | /vendor/ezsystems/demobundle/EzSystems/DemoBundle/Helper/CriteriaHelper.php | UTF-8 | 3,904 | 2.53125 | 3 | [] | no_license | <?php
/**
* File containing the CriterionHelper class.
*
* @copyright Copyright (C) 1999-2014 eZ Systems AS. All rights reserved.
* @license http://www.gnu.org/licenses/gpl-2.0.txt GNU General Public License v2
* @version //autogentag//
*/
namespace EzSystems\DemoBundle\Helper;
use eZ\Publish\API\Repository\Val... | true |
b6478d286c514da107fbd9b6420785c5a02ac03c | PHP | samhol/foobar | /samiholck/classes/MVC/Content/AbstractContentLoader.php | UTF-8 | 1,021 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
namespace Sphp\Samiholck\MVC\Content;
use Sphp\Html\Flow\Main;
/**
* Description of AbstractContentLoader
*
* @author Sam... | true |
b0b868e5a446cff94e7386a0aa7634765e940eea | PHP | 4otaku/draft | /libs/booster/abstract.php | UTF-8 | 1,447 | 2.671875 | 3 | [] | no_license | <?php
abstract class Booster_Abstract
{
protected $start_pool = array();
protected $pool = array();
protected $ids = array();
protected $id = 0;
protected $user = 0;
protected $deck = 0;
protected $land = 0;
protected $common = 11;
protected $uncommon = 3;
protected $rare = 1;
public function __construct(... | true |
92e742b1b10257b546115b2232a2f995ee5f037c | PHP | reksaning/mrptom | /app/Http/Controllers/PackagingController.php | UTF-8 | 2,272 | 2.625 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use App\Packaging;
use Illuminate\Http\Request;
class PackagingController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\Response
*/
public function index()
{
$packagings=Packaging::all();
... | true |
340e072e7c553298169f969bfc8af2d751ce06a0 | PHP | lagdo/adminer-drivers | /src/Db/Mongo/Statement.php | UTF-8 | 2,388 | 2.78125 | 3 | [
"Apache-2.0"
] | permissive | <?php
namespace Lagdo\Adminer\Drivers\Db\Mongo;
class Statement
{
/**
* Undocumented variable
*
* @var int
*/
public $num_rows;
/**
* Undocumented variable
*
* @var array
*/
public $_rows = [];
/**
* Undocumented variable
*
* @var int
*... | true |
43f050dff5ebd4ebdb06b770d6633e0dedb7f1b4 | PHP | petersoliman1/BLOGX | /admin/login.php | UTF-8 | 4,007 | 2.828125 | 3 | [] | no_license | <?php
session_start();
// file database and file the header.
include 'initialize.php';
// ["REQUEST_METHOD"] Check on the method that came from the form.
if($_SERVER["REQUEST_METHOD"] == "POST") {
// We are also verifying that the POST is of the Login type.
if(isset($_POST["admin-l... | true |
bb978b92006f55b188a7eae660db9076e0fb789f | PHP | smondalcse/UploadImageToServer | /app/src/main/java/com/example/uploadimagetoserver/Php Script/upload_image_with_volley/uploadimage.php | UTF-8 | 867 | 2.5625 | 3 | [] | no_license | <?php
$servername = "localhost";
$username = "root";
$password = "";
$dbname = "upload_image_with_volley";
// Create connection
$conn = mysqli_connect($servername, $username, $password, $dbname);
// Check connection
if ($conn) {
//echo json_encode(array('response' => 'Connection Successfully'));
$... | true |
f8ea2315d73816787f8194233746ec4f60728be4 | PHP | Loneska/dwm-php-mailinglist | /includes/SSMTP.inc.php | UTF-8 | 1,782 | 2.625 | 3 | [] | no_license | <?php
require_once './../libs/PHPMailer/PHPMailerAutoload.php';
require_once './../config/constants.php';
class SSMTP
{
private $MailInstance = null;
private static $instance = null;
const DEFAULT_SMTP_HOST = Constants::SMTP_HOST;
private function __construct()
{
$this->mailInstance = new PHPMai... | true |
e647bfbfdf9848a5e9a1b5deb6862676212738c3 | PHP | phacility/phabricator | /src/infrastructure/cluster/search/PhabricatorSearchService.php | UTF-8 | 7,161 | 2.609375 | 3 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
class PhabricatorSearchService
extends Phobject {
const KEY_REFS = 'cluster.search.refs';
protected $config;
protected $disabled;
protected $engine;
protected $hosts = array();
protected $hostsConfig;
protected $hostType;
protected $roles = array();
const STATUS_OKAY = 'okay';
const STAT... | true |
bcb768ec094d80f4e6803d4611b1b2ca614ed485 | PHP | uimcaniia/kajoo | /model/Invitation.php | UTF-8 | 3,622 | 2.984375 | 3 | [] | no_license | <?php
namespace Model;
class Invitation extends InvitationManager
{
// **************************************************
// Attributs de l'objet
// **************************************************
private $_id_invitation;
// identifiant de l'invitation
private $_id_send;
// identifian... | true |
a58aea6563f4a9d0f512db2b42dc7707fdb65648 | PHP | Xi-Plus/Teacher-Info | /export_schoollist.php | UTF-8 | 3,039 | 2.640625 | 3 | [] | no_license | <?php
require('config/config.php');
require("func/school_list.php");
if (isset($_POST["download"]) || isset($_POST["importable"])) {
header('Content-Description: File Transfer');
header('Content-Type: text/csv; charset=utf-8');
header('Content-Disposition: attachment; filename="'.$C["sitename"]."-學校列表".(isset($_POST... | true |
b73445581db8709631d5d9ba526a3ece35635149 | PHP | Zkone225/evaluation-php-crud-pdo | /details.php | UTF-8 | 1,933 | 2.75 | 3 | [] | no_license | <?php
require_once "functions/app_utils.php";
//On se connecte à la base de données
$connexion = db_connexion();
//On recupere l'id de l'mployé s'il existe
$id = htmlspecialchars($_GET['id']);
//Instruction sql de selection de l'employé
$sql = "select * from Employes where id = ?";
//On prepare la requete
$req_prep... | true |
bd8b0a2a4dbd49c4a9126021e982d43b0421affe | PHP | runfornumbers/eal | /includes/db/DB_TestResult.php | UTF-8 | 1,983 | 2.671875 | 3 | [
"Apache-2.0"
] | permissive | <?php
class DB_TestResult {
private static function getTableName (): string {
global $wpdb;
return ($wpdb->prefix) . 'eal_testresult';
}
public static function saveToDB (EAL_TestResult $testresult) {
global $wpdb;
$wpdb->replace(
self::getTableName(),
array(
'id' =... | true |
9195edc080a17b18ff4e1ae4f24400db39049e19 | PHP | itsanr-oris/easy-smartprogram | /src/Support/Http/HttpClient.php | UTF-8 | 8,042 | 2.703125 | 3 | [
"MIT"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: f-oris
* Date: 2019/6/10
* Time: 3:50 PM
*/
namespace EasySmartProgram\Support\Http;
use GuzzleHttp\Client;
use GuzzleHttp\ClientInterface;
use GuzzleHttp\HandlerStack;
use EasySmartProgram\Support\Http\Middleware\MiddlewareInterface;
/**
* Class HttpClient
* @package ... | true |
00daaab44d7b670ade79b32d9b7dac98f9387fcb | PHP | mayurs123/php-webmaster-tools-downloads | /example-daterange.php | UTF-8 | 461 | 2.671875 | 3 | [] | no_license | <?php
include 'gwtdata.php';
try {
$email = "eyecatchup@gmail.com";
$passwd = "******";
# Dates must be in valid ISO 8601 format.
$daterange = array("2012-01-10", "2012-01-12");
$gdata = new GWTdata();
if($gdata->LogIn($email, $passwd) === true)
{
$sites = $gdata->GetSites();
foreach($sites ... | true |
46358540c57e1e96abc857f43d359dfa7dd99b0f | PHP | pancevac/tn-task | /src/Application.php | UTF-8 | 1,333 | 2.921875 | 3 | [] | no_license | <?php
namespace App;
use App\Classes\Vehicles\Bus;
use App\Classes\Vehicles\Car;
use App\Classes\Vehicles\Truck;
use App\Classes\Employee;
use App\Classes\TollStation;
class Application
{
/**
* Execute task.
*/
public function boot()
{
// set time/zone of app
date_default_timez... | true |
cc94dee0b16fcd1e3bce9b8cdcff1ba5d5b559d6 | PHP | Hostname47/E-COMMERCE | /Admin/entities/product-management/ProductManager.php | UTF-8 | 15,797 | 2.828125 | 3 | [] | no_license | <?php
include "../../config/DbConnect.php";
class ProductManager {
private $link;
function __construct() {
$connection = new dbConnection();
$this->link = $connection->connect();
return $this->link;
}
function productNameExists($prod_nam... | true |
775c7c8832baa7e17a41079e6edab684e80e30db | PHP | NeilSiao/LeetCodeWithPhp | /src/ValidParen.php | UTF-8 | 1,435 | 3.765625 | 4 | [] | no_license | <?php
namespace App;
// Given a string s containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid.
// An input string is valid if:
// Open brackets must be closed by the same type of brackets.
// Open brackets must be closed in the correct order.
class ValidParen
{
... | true |
ae1fccfd674a0868ed780838a81ba7a06ef1a130 | PHP | devos1/AdWeb | /Exe_13.php | UTF-8 | 5,049 | 2.84375 | 3 | [
"MIT"
] | permissive | <!--
* User : oscar
* Date : 02.01.15
* Time : 10:20
* Comment : Le message "Vérifier votre réponse" apparait à à droite dans la version originale
* Optimisation : On pourrait colorier en rouge le texte choisi si ce n'est pas la bonne réponse
-->
<!doctype html>
<html lang="fr">
<head>... | true |
38c4fb20faba0c4ac58e7df615e60a4b418b294f | PHP | haroldpinto/paises | /includes/class-wc-cs-repayment.php | UTF-8 | 4,827 | 2.546875 | 3 | [] | no_license | <?php
defined( 'ABSPATH' ) || exit ;
/**
* Repayment.
*
* @class WC_CS_Repayment
* @package Class
*/
class WC_CS_Repayment {
/**
* The single instance of the class.
*/
protected static $instance = null ;
protected static $product_to_repay ;
/**
* Create instance for WC_CS_Repayment.
*/
public st... | true |
72efce6c80b5ff10dae5b0fc17bfd108c3435f39 | PHP | PytoCryto/PytoMVC | /src/System/Routing/Redirector.php | UTF-8 | 4,569 | 2.6875 | 3 | [
"MIT"
] | permissive | <?php
namespace PytoMVC\System\Routing;
use PytoMVC\System\Http\RedirectResponse;
use PytoMVC\System\Routing\UrlGenerator;
use PytoMVC\System\Session\SessionInterface;
/**
* This file was edited to my needs.
* This file belongs to Laravel.
* @source: https://github.com/laravel/framework/blob/5.3/src/Illuminate/Ro... | true |
293ce56880c596835e271cfc423f2c7a2238a926 | PHP | thedeviousdev/Card-Sleeves | /game_update.php | UTF-8 | 4,607 | 2.703125 | 3 | [] | no_license | <?php
// include_once("login_session.php");
include_once('directory.php');
include_once('game_update_base.php');
// Update a card's details or add a new card
if(session_status() != PHP_SESSION_NONE && $_SESSION["loggedIn"] && isset($_POST['game_id'])) {
$game_ID = $_POST['game_id'];
$sleeve = $_PO... | true |
acd9fe554cd14ebc6e70f1c1250d4114466c8235 | PHP | CHICAN0/campus2 | /application/modules/admin/Model/Orders.php | UTF-8 | 15,307 | 2.53125 | 3 | [] | no_license | <?php
class Model_Orders {
public static function getSalesStatus($whereQuery='', $type='buy') {
$db = JO_Db::getDefaultAdapter();
return $db->query("
SELECT COUNT(`id`) as `num`, SUM(`price`) as `total`, SUM(`receive`) AS `receive`
FROM `orders`
WHERE `type` = '".($type)."' AND `paid` = 'true' $where... | true |
9cab047feb2d1440d02d2ff80ee563ec4d100a72 | PHP | luisascastro13/lojavirtual | /src/controller/Cliente.controller.php | UTF-8 | 2,426 | 2.515625 | 3 | [] | no_license | <?php
session_start();
require_once('../model/Cliente.class.php');
require_once('../dao/Cliente.dao.php');
error_reporting(E_ALL);
// if(array_key_exists('a', $_GET)){
// $reqm = $_GET;
// } else if(array_key_exists('a', $_POST)){
// } else {
// header("Location: ../index.php");
// }
$reqm = $_POST;
switch($reqm... | true |
2d7ba9a16deee12e2a8975cd43ff7696ec80a93e | PHP | Esperozzz/tasks_for_beginner | /lesson7/task27.php | UTF-8 | 142 | 2.625 | 3 | [] | no_license | <?php
include_once '../header.php';
$text = 'html css php';
$delimiter = ' ';
$newArray = explode($delimiter, $text);
print_r($newArray);
| true |
78e4b01f384ff328d916d0526ff8c74dbad35aba | PHP | NatalieStout/3400finalproject | /contact-delete.php | UTF-8 | 1,978 | 2.890625 | 3 | [] | no_license | <?php
require 'config.php';
session_start();
if(!isset($_SESSION['loggedin'])){
// header('Location: login.php');
message("Please login first.", "login.php", true);
exit;
}
// Connect to MySQL
$pdo = pdo_connect_mysql();
if (isset($_GET['id'])) {
// Select the record that is going t... | true |
e2273b0896b25efe49c981f4d0678ac372318070 | PHP | Ari0chz123/CRUD-PHP-MYSQL-AJAX-Y-DATATABLE | /datatablephp/clases/Conexion.php | UTF-8 | 496 | 2.53125 | 3 | [] | no_license | <?php
class Conexion{
public static function conectado()
{
try
{
$ccn = mysqli_connect('localhost', 'root', '1234', 'datatablephp');
return $ccn;
}catch (Exception $e)
{
die($e->getMessage());
}
}
public funct... | true |
e5a1bd01acdfa040c17580984bdf3da1e1c9df00 | PHP | conorsmith/Twersona | /src/CacheInterface.php | UTF-8 | 223 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
namespace Twersona;
interface CacheInterface
{
public function isStale($timestampToCheck = null);
public function hasData();
public function fetch();
public function store($data);
}
| true |
c92152f204db60c595bfb3888aca665c67a53192 | PHP | dangquoccuong1999/Quan_Ly_Thu_Vien | /Login/LoginUser.php | UTF-8 | 1,848 | 2.765625 | 3 | [] | no_license | <?php
class LoginUser
{
public $user;
public $password;
public $dataUser;
public $conn;
public function __construct($user, $pass)
{
$this->user = $user;
$this->password = $pass;
$db = new DBconnect();
$this->conn = $db->connect();
}
public function che... | true |
7133061e9548a433eec429ddaa090bb2f176286a | PHP | salernolabs/rescuegroups | /tests/Request/Objects/IntakesServices/EditTest.php | UTF-8 | 1,803 | 2.640625 | 3 | [
"MIT"
] | permissive | <?php
/**
* IntakesServices edit Request Test
*
* @package RescueGroups
* @subpackage Tests
* @author SourceGenerator
*/
namespace RescueGroups\Tests\Request\Objects\IntakesServices;
class EditTest extends \PHPUnit\Framework\TestCase
{
use \RescueGroups\Tests\Traits\APISetup;
/**
* Test Query
... | true |
086c2e0f9664cdc211136a78397eb2b180c54be4 | PHP | JorgeHernandez/stage31 | /src/Click/GalleryBundle/DataFixtures/ORM/GalleryFixtures.php | UTF-8 | 2,070 | 2.6875 | 3 | [
"MIT"
] | permissive | <?php
namespace Click\GalleryBundle\DataFixtures\ORM;
use Doctrine\Common\DataFixtures\FixtureInterface;
use Click\GalleryBundle\Entity\Gallery;
use Click\GalleryBundle\Entity\Photo;
class GalleryFixtures implements FixtureInterface
{
public function load($manager)
{
// Gallery Fixtures
... | true |
37137e742f9be2c45a7b6b0e6f4924c7ab8fde5f | PHP | liuzhenxiulzx/B2C | /models/Category.php | UTF-8 | 1,382 | 3.078125 | 3 | [] | no_license | <?php
namespace models;
class Category extends Model
{
// 设置这个模型对应的表
protected $table = 'category';
// 设置允许接收的字段
protected $fillable = ['cat_name','parent_id','path'];
// 参数:上级分类的ID
public function getcate($parent_id=0){
return $this->findAll([
'where'=>"parent_id=$parent_... | true |
5a23e980efa1bd35e326e11ca6a57de1b14d33a1 | PHP | joebubna/Cora | /vendor/cora/cora-framework/system/classes/Mailer.php | UTF-8 | 2,285 | 2.8125 | 3 | [
"MIT"
] | permissive | <?php
namespace Cora;
class Mailer extends Framework
{
public $message;
public function __construct($PHPMailer)
{
parent::__construct(); // Call parent constructor too so we don't lose functionality.
$this->message = $PHPMailer;
$this->message->CharSet = "utf-8";
... | true |
991750609f365c9f6f8ab83ce42f3469b906f979 | PHP | ESGI-IW3-2016-01/studentbot | /src/AppBundle/Entity/Facebook/Message.php | UTF-8 | 4,004 | 2.78125 | 3 | [] | no_license | <?php
namespace AppBundle\Entity\Facebook;
use DateTime;
use DateTimeZone;
use Symfony\Component\Validator\Constraints\Date;
use AppBundle\Entity\Facebook\Attachment;
class Message
{
private $id;
private $mid;
private $seq;
private $text;
private $sender;
private $receiver... | true |
25742b4b749b886f682f9d0adeabfc98bef7f6c2 | PHP | pinodex/vianderito-server | /app/Components/Auth/UserProvider.php | UTF-8 | 2,113 | 2.609375 | 3 | [] | no_license | <?php
/*
* This file is part of the TAS System for STI College Novaliches
*
* (c) Raphael Marco <raphaelmarco@outlook.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace App\Components\Auth;
use Hash;
use Carbon\Carbo... | true |
3bfd2418877e487f16e1161ec3fd315eb35c9431 | PHP | hsisn/Munarela | /Munarela/Jour/JourControleur.php | UTF-8 | 2,077 | 2.734375 | 3 | [] | no_license | <?php
require_once("../includes/modele.inc.php");
require_once("../includes/init.php");
$tabRes = array();
function enregistrerJour() {
global $tabRes;
$nomHotel = $_POST['nomHotel'];
$urlHotel = $_POST['UrlHotel'];
$nomRestaurant = $_POST['nomRestaurant'];
$urlRestaurant = $_POST['urlRestaura... | true |
944495207058472eb9f2deeb02cc1e3bd37bc09a | PHP | HoThiMai/Myfashionshop | /Final_Project_Web/view/Login.php | UTF-8 | 2,368 | 2.78125 | 3 | [] | no_license | <?php
require_once "../database/database.php";
$sql2 = "SELECT * from users";
$result2 = $db->query($sql2)->fetch_all();
$check = true;
session_start();
error_reporting(0);
if (isset($_POST['login'])) {
$_SESSION['username'] = $_POST["accountLogin"];
$_SESSION['password'] = $_POST["passLogin"];
... | true |
581eafebbd4273753d694e4e61b550438740c894 | PHP | lucky541/Attendance.96.lt | /test.php | UTF-8 | 1,472 | 2.78125 | 3 | [] | no_license |
<?php
//error_reporting(0);
include 'db/connection.php';
/* create a prepared statement */
if($stmt = $dbConnection->prepare("SELECT username,enroll_no,department,role,studing_year,section,semester FROM valid_users_list WHERE enroll_no =?
AND password = ?")){
$input_userna... | true |
c695baaed04b34c62c5f003bda441205eb725f88 | PHP | inhere/swoft-comlib | /src/Translator/AbstractTranslator.php | UTF-8 | 790 | 2.796875 | 3 | [
"MIT"
] | permissive | <?php declare(strict_types=1);
namespace Inhere\Comlib\Translator;
use Inhere\Comlib\HttpClient;
use Swoft\Stdlib\Helper\ObjectHelper;
/**
* Class AbstractTranslator
*
* @package Inhere\Comlib\Translator
*/
abstract class AbstractTranslator
{
/**
* @var HttpClient
*/
protected $client;
pub... | true |
cb50913b176f0826fa440b659ce3af5df01f71df | PHP | Seplarui/MVC-PHP | /Pruebas/limpiar_fichero.php | UTF-8 | 670 | 2.859375 | 3 | [] | no_license | <?php
error_reporting(0);
$fichero=fopen("Marcas_Vehiculos.txt","r");
while(!feof($fichero)) {
$filas[]=fgets($fichero,999999);
}
$longitud=count($filas);
$x=0;
for ($i=0;$i<$longitud;$i++) {
if (($filas[$i]=="\r\n") || ($filas[$i]=="")){
... | true |
66fc0e9bf763623c65a348d287ebb449029c61be | PHP | ercling/auth | /base/Controller.php | UTF-8 | 7,797 | 2.703125 | 3 | [
"MIT"
] | permissive | <?php
namespace base;
use base\exceptions\BadRequestHttpException;
use base\exceptions\InvalidRouteException;
use base\helpers\HtmlPurifier;
class Controller
{
/**
* @var string the ID of the action that is used when the action ID is not specified
* in the request. Defaults to 'index'.
*/
publi... | true |
e87b4830e5412b6f1e401f0c679628f646727afb | PHP | depran7/laundry-mine | /barang-masuk/functions.php | UTF-8 | 1,339 | 2.53125 | 3 | [] | no_license | <?php
require_once('../koneksi.php');
$nama_table1 = "trs_barang_masuk";
$nama_table2 = "barang";
$nama_table3 = "history_stock_barang";
function tambah($data)
{
global $conn;
global $nama_table1;
global $nama_table2;
global $nama_table3;
$barang_id = htmlspecialchars($data["barang_id"]);
$jumlah_barang ... | true |
a107906f38b025c5b9cc35b2c25532882fa0b561 | PHP | chrismademe/ObjectsFramework | /app/plugins/objects/lib/functions/get-field.php | UTF-8 | 658 | 2.828125 | 3 | [] | no_license | <?php
function get_field( $ID, $object = null ) {
/**
* Get Objects & Fields class
*/
global $fields;
global $objects;
/**
* Get ID Type
*/
$type = (is_string($ID) && !is_numeric($ID) ? 'alias' : 'ID');
/**
* Set field ID
*/
$object = ($objects->current_obje... | true |
ea7132fbd878250f4890006fecc0e711c7691a58 | PHP | bartekmaterla11/AutoForum | /src/Controller/JavaScriptPostController.php | UTF-8 | 1,368 | 2.515625 | 3 | [] | no_license | <?php
namespace App\Controller;
use App\Service\Posts\PostMarkInterface;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Annotation\Route;
class JavaScriptPostController extends AbstractController
{
/**
* @var Post... | true |
192f949cd05d42d18bb7b5e3e52565705e6841a3 | PHP | donmashe/students-grasite | /login2.php | UTF-8 | 1,953 | 2.78125 | 3 | [] | no_license | <?php
if (!isset($_SESSION)) {
session_start();
}
include "config.php";
if (isset($_POST['login'])) {
try {
$connection = new PDO($dsn, $username, $password, $options);
$sql = "SELECT * FROM users WHERE email = :email AND password = :password;";
$email = $_POST['email'];
$passw = ... | true |
69095aa4f364c39f75599641366d1acb89f31447 | PHP | moutb/personal-gym | /old/clientes/listV2.php | UTF-8 | 6,545 | 2.59375 | 3 | [] | no_license | <?php
session_start();
$include_path = dirname(__FILE__) . '/../';
require_once($include_path . "persistence/db-connection.php");
require_once("gestionarClientes.php");
require_once("paginacion_consulta.php");
if (isset($_SESSION["cliente"])){
$libro = $_SESSION["cliente"];
unset($_S... | true |
5acefbd68f426bb808821d9e52d45db9652273f7 | PHP | DarkArtek/xivdb-v3 | /xivdb-v3-sync/src/Service/Characters/Tracking/TrackProfile.php | UTF-8 | 2,103 | 2.875 | 3 | [] | no_license | <?php
namespace App\Service\Characters\Tracking;
use App\Entity\ProfileEvent;
/**
* Event tracking such as name, server, title, etc
*/
trait TrackProfile
{
/**
* Records various data about the character
*/
private function recordProfileChanges()
{
$this->io->text('---> '. __METHOD__);... | true |
a0227f57775c15eacae4a661efbc195af212cdb2 | PHP | myegane49/php-cms | /admin/includes/edit_post.php | UTF-8 | 4,413 | 2.65625 | 3 | [] | no_license | <?php
if (isset($_GET['p_id'])) {
$postId = $_GET['p_id'];
$query = "SELECT * FROM posts WHERE post_id = {$postId}";
$result = mysqli_query($connection, $query);
$row = mysqli_fetch_assoc($result);
$postId = $row['post_id'];
$postAuthor = $row['post_author'];
$postTitle = $row['post_title'];
$postCatId... | true |
10f01175abafeeb5322a459961846793e301ff7b | PHP | ligerbots/website_2016 | /attendance-backend/api/deleteUser.php | UTF-8 | 1,202 | 2.546875 | 3 | [] | no_license | <?php
//Include the API
include("include/api.php");
//Required permission
setAccess("users.delete");
//Get the user id
if(!isSet($_GET['id'])) {
error("Invalid Data","No user was specified");
}
//Get the user
$damneduser = new User($_GET['id'], USER_SELECTOR_ID);
//Users aren't actually removed, just in case someb... | true |
603997b1e80d360d388689c0bc18dacaef5d52cc | PHP | thetribeio/stripe-test | /src/AppBundle/Services/StripeService.php | UTF-8 | 556 | 2.84375 | 3 | [] | no_license | <?php
namespace AppBundle\Services;
use Stripe\Stripe;
class StripeService
{
/**
* @param string $stripeSecretKey
*/
public function __construct($stripeSecretKey)
{
Stripe::setApiKey($stripeSecretKey);
}
/**
* @param string $token
*/
public function charge($token)
... | true |
58db539f602e2a52e49149cb33740c19637faf5d | PHP | HenryYao369/CS1300-Web-Design | /LabSectionsCode/W9-PHP_revised/activity2/php/process.php | UTF-8 | 1,739 | 3.75 | 4 | [] | no_license | <?php
// TODO: Declare the variables required for this form.
// There are 7 variables you will need to declare (or 3 if you use an array)
// If you use an array, you can store the information for all 5 classes in a variable
// First variable example: You only need to declare them with a empty value
// An ... | true |
549509541005e32b81daf1772723e1546524a4a2 | PHP | OBadolo/PHP-Exercise | /functions.php | UTF-8 | 1,112 | 3.078125 | 3 | [] | no_license | <?php
########################
### EDITED FILE ###
########################
// reading from "input.json" and returning as an array
$input_array = file_get_contents("data/input.json");
print "Loading...\n";
// array conversion to match structure in "correct-output.json"
$output_array = json_encode(json_decode(... | true |
117339af201002f4493942bdfd53b3f23a57f7a0 | PHP | baraja-core/ecommerce-standard | /src/DTO/WarehouseItemInterface.php | UTF-8 | 1,208 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
namespace Baraja\EcommerceStandard\DTO;
interface WarehouseItemInterface
{
public function getId(): int;
public function getProduct(): ?ProductInterface;
public function setProduct(?ProductInterface $product): void;
public function getProductVariant(): ?ProductVariantInterface;... | true |
360afd350a852255f0ecf9f94d1549d2bf102526 | PHP | nf-theme/core | /src/Models/Post.php | UTF-8 | 873 | 2.515625 | 3 | [] | no_license | <?php
namespace NF\Models;
use NF\Models\Model;
use NF\Models\Traits\HasAttachment;
class Post extends Model
{
use HasAttachment;
const POST_TYPE_ORIGIN = 'post';
const POST_TYPE_PAGE = 'page';
const POST_STATUS_PUBLISH = 'publish';
const POST_STATUS_DRAFT = 'auto-draft';
protected $ta... | true |
c1c090b473ee4e065526f8a21ec780d7d5ac3801 | PHP | wf3-fullstack/cours | /exos/poo-rappel.php | UTF-8 | 1,068 | 3.59375 | 4 | [] | no_license | <?php
class MaClasse
{
//-------------------------------------------
// PROPRIETES DE CLASSE COLLECTIF (static)
public static $metier = "plombier";
// METHODES DE CLASSE COLLECTIF (static)
//-------------------------------------------
// PROPRIETES D'OBJET INDIVIDUELLE (VARIABLES DANS CLASSE)... | true |
75fe969c6b706aef1103f357d5c68fecc849bec5 | PHP | Garikoitz-web/unieibar-asir2-web | /01-1-basic/prueba.php | UTF-8 | 91 | 2.96875 | 3 | [] | no_license | <?php
$t = 2;
if ($t == 2) {
echo "igual a 2";
} else {
echo "No igual a 2";
}
?> | true |
691617e9fb66f6a985806ee8986cf4bc6fd630cc | PHP | iszhange/luban-pop-php | /src/Requests/PddDdkOauthPidMediaidBindRequest.php | UTF-8 | 1,256 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
/**
* 批量绑定推广位的媒体id
*
* @link https://open.pinduoduo.com/application/document/api?id=pdd.ddk.oauth.pid.mediaid.bind
* @author zhange <kenphp@yeah.net>
* Date: 2020/12/30
* Time: 21:01
*/
namespace LuBan\Pop\Requests;
use LuBan\Pop\Exceptions\ParameterException;
use LuBan\Pop\Interfaces\Request;
use LuBan\P... | true |
d76d9787c25f3029dabda762257ea0a08bea6f30 | PHP | masticore252/simple-mailer | /src/Emailer.php | UTF-8 | 8,163 | 2.96875 | 3 | [] | no_license | <?php
namespace trebla\simpleMailer;
use Swift_Mailer;
use Swift_Message;
use RuntimeException;
use Twig_Environment;
use Twig_Loader_Filesystem;
class Mailer
{
protected $swiftmailer;
protected $username;
protected $password;
protected $to;
protected $subject;
protected $messageType;
p... | true |
14e03d6b9418b9a8d04282ce37159769bb11d5db | PHP | jikan-me/jikan | /src/Model/News/NewsListItem.php | UTF-8 | 2,924 | 2.90625 | 3 | [
"LicenseRef-scancode-free-unknown",
"MIT"
] | permissive | <?php
namespace Jikan\Model\News;
use Jikan\Model\Resource\WrapImageResource\WrapImageResource;
use Jikan\Parser\News\NewsListItemParser;
/**
* Class AnimeParser
*
* @package Jikan\Model
*/
class NewsListItem
{
/**
* @var int|null
*/
private $malId;
/**
* @var string
*/
priva... | true |
806dbd16c58deb1379447c02a492d90d99405131 | PHP | alina80/Advanced-Php-Ecercises | /1_Exercises/Day_2/4_Files_in_PHP/showImage.php | UTF-8 | 565 | 2.6875 | 3 | [] | no_license | <?php
if(isset($_GET['image']) && isset($_GET['date'])){
$file = $_GET['image'];
$hash = md5($file);
$mainDir = __DIR__ . "/" . $_GET['date'];
$firstSubDir = $mainDir . "/" . substr($hash,0,2);
$secondSubDir = $firstSubDir . "/" . substr($hash,-2,2);
$path = $secon... | true |
96c537d4361eee024a1805e58053bd4377f8569f | PHP | sorceresslulu/lulu-imageboard-engine | /src/backend/bundles/Lulu/Imageboard/Domain/Repository/PostRepositoryInterface.php | UTF-8 | 597 | 2.828125 | 3 | [
"MIT"
] | permissive | <?php
namespace Lulu\Imageboard\Domain\Repository;
use Lulu\Imageboard\Domain\Entity\Post;
use Lulu\Imageboard\Domain\Repository\Post\PostQuery;
interface PostRepositoryInterface
{
/**
* Returns post by Id
* @param $id
* @return Post
*/
public function getPostById($id);
/**
* Ret... | true |
48eeb517a1e1a2e5269935f3b07a00ce261885c7 | PHP | radthoc/coding-challenge-wholesaler-integration | /src/kollex/Services/FileService.php | UTF-8 | 911 | 3.15625 | 3 | [] | no_license | <?php
namespace kollex\Services;
class FileService implements FileServiceInterface
{
/**
* @param string $path
* @return array
*/
public function getFileContent(string $path): array
{
$productArray = [];
foreach ($this->readTheFile($path) as $row) {
$productArra... | true |
e976b21d24bac139d1bc6efdac77f46549eed9c5 | PHP | KostenkoA/bbs-order | /src/Event/OrderErrorEvent.php | UTF-8 | 916 | 2.609375 | 3 | [] | no_license | <?php
namespace App\Event;
use App\DTO\OneC\OrderStatusError1C;
use App\Entity\Order;
use App\Interfaces\OrderEventInterface;
use App\Traits\OrderPropertyTrait;
use Symfony\Component\EventDispatcher\Event;
class OrderErrorEvent extends Event implements OrderEventInterface
{
use OrderPropertyTrait;
public co... | true |
d28da54c5f57c313ca349cbc928762dcd1dd8672 | PHP | Leonard133/spotlight | /src/SpotlightCommandDependencies.php | UTF-8 | 637 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
namespace LivewireUI\Spotlight;
use Illuminate\Support\Collection;
class SpotlightCommandDependencies
{
protected Collection $dependencies;
public function __construct()
{
$this->dependencies = new Collection([]);
}
public function add(SpotlightCommandDependency $dependency): self... | true |
e95ee55dd9040937754f8000de2ac583d8262f45 | PHP | Adalberto-ortega/spa-can | /views/persona/listar.php | UTF-8 | 1,201 | 2.6875 | 3 | [] | no_license | <?php
include_once("menu.php");
if(isset($message))
echo "<p><b>$message</b></p>";
?>
<!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 rel="... | true |
66d2bffdb3646bc88c956478c59962befcfe20f9 | PHP | hatimeria/HatimeriaBankBundle | /Subscription/SubscriptionAdder.php | UTF-8 | 1,720 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
namespace Hatimeria\BankBundle\Subscription;
/**
* Subscription adder
*
* @author Michal Wujas
*/
class SubscriptionAdder
{
/**
* Subscription class
*/
private $class;
/**
* Entity manager
*/
private $em;
/**
* @var Hatimeria\BankBundle\Model\InvoiceManager
... | true |
55f103bb2eb51a43ba7309e313f7c3034c40b182 | PHP | Laimacom/PhP-projektas | /Kontroliniai/08.1.php | UTF-8 | 503 | 2.828125 | 3 | [] | no_license | <?php
/*
Sukurkite PHP skriptą, kuriame būtų aprašyta klasė “automobilis”, kuri turi savybes ‐ gamintojas, modelis, metai. Sukurkite standartinį klasės __construct metodą, kuriam perdavus tris parametrus ‐ gamintojas, modelis, metai ‐ perduotus parametrus padėtų į savo savybes.
*/
class automobilis {
public $gam;
... | true |
0a7c38d40095afcb56f94c83a575874fc13421a4 | PHP | luisgcastillos/m2-cli | /src/Environment/DirectoryName.php | UTF-8 | 294 | 2.890625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Environment;
class DirectoryName
{
/**
* @var WorkDir
*/
private $dir;
public function __construct(WorkDir $dir)
{
$this->dir = $dir;
}
public function get(): string
{
return basename($this->dir->getPath());
}
}
| true |
88de118f3c92372d9f33fd4bc9108b34dff763b5 | PHP | njhyuk/testing-jargon | /spec/Acme/RegistersUserSpec.php | UTF-8 | 957 | 2.671875 | 3 | [] | no_license | <?php
namespace spec\Acme;
use Acme\RegistersUser;
use PhpSpec\ObjectBehavior;
use Acme\UserRepository;
use Acme\Mailer;
class RegistersUserSpec extends ObjectBehavior
{
function let(UserRepository $userRepository, Mailer $mailer)
{
$this->beConstructedWith($userRepository, $mailer);
}
funct... | true |
b424ac57e65bcaf26120ebc510a88a2315b7542c | PHP | Tiqr/tiqr-server-libphp | /library/tiqr/Tiqr/UserStorage/GenericStore.php | UTF-8 | 6,768 | 2.703125 | 3 | [
"BSD-3-Clause",
"LicenseRef-scancode-warranty-disclaimer",
"BSD-2-Clause"
] | permissive | <?php
/**
* This file is part of the tiqr project.
*
* The tiqr project aims to provide an open implementation for
* authentication using mobile devices. It was initiated by
* SURFnet and developed by Egeniq.
*
* More information: http://www.tiqr.org
*
* @author Ivo Jansch <ivo@egeniq.com>
*
* @package t... | true |
a01bf0a0a2d60d5b3cbb9622ee423bfb0cb90e90 | PHP | vasylignatyev/soap | /Session.php | UTF-8 | 1,560 | 2.71875 | 3 | [] | no_license | <?php
require_once('database.php');
/**
* Created by PhpStorm.
* User: vignatyev
* Date: 19.11.2015
* Time: 8:50
*/
/**
* Class LoginRequest
* @pw_element string $user_name User Name
* @pw_element string $user_pass A string with a user password
* @pw_complex LoginRequest The complex type name definition
*/
cl... | true |
f9fb2cea6d82867e8d173288a68f9990472ecc65 | PHP | aris-creator/php | /detail_pembelian.php | UTF-8 | 2,484 | 3 | 3 | [] | no_license | <?php
include('koneksi2.php');
$query = "SELECT * FROM pembelian JOIN pelanggan ON pembelian.id_pelanggan=pelanggan.id_pelanggan WHERE pembelian.id_pembelian = '$_GET[id]'";
$result = mysqli_query($koneksi, $query);
$row = mysqli_fetch_assoc($result)
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8... | true |
3e5286d1508fcf73f20e122e637b2568a794bcbd | PHP | ramurama/lending_library | /dbconfig.php | UTF-8 | 614 | 2.609375 | 3 | [] | no_license | <?php
/*$la_time = new DateTimeZone('America/Toronto');
$datetime = new DateTime();
$datetime->setTimezone($la_time);
$cdate=$datetime->format('Y-m-d');
$ctime=$datetime->format('Y-m-d H:i:s');*/
$db['db_host']='localhost';
$db['db_user']='root';
$db['db_pass']='root';
$db['db_name']='lending_library';
foreach($db a... | true |
434475ac20cd921c7dfdb9ed95037dcaeac0e91a | PHP | dangchihao123/website_tintuc | /lib/dbCon.php | UTF-8 | 2,552 | 2.59375 | 3 | [] | no_license | <?php
// $con = mysqli_connect("localhost","root","");
// mysqli_select_db($con,"khoaphamtraining");
// mysqli_query($con,"SET NAMES 'utf8'");
?>
<?php
class ketnoidatabase1 {
public $conn = "";
public function __construct() {
$this->conn = mysqli_connect('localhost', 'root', '', 'khoaphamtraining') o... | true |
4c6894999294e169061f4ae1865c25b147e9df42 | PHP | dharrya/php-omut | /lib/Helper/JSErrorHelper.php | UTF-8 | 240 | 2.796875 | 3 | [
"MIT"
] | permissive | <?php
namespace lib\Helper;
class JSErrorHelper
{
public static function filterErrors($errors)
{
$result = array();
foreach($errors as $error) {
if($error["level"] == "SEVERE")
$result[] = $error;
}
return $result;
}
} | true |
0f01248bad5648ce000de689b0a592c25d0d9da8 | PHP | twgd/board-php | /controllers/login_check-user.php | UTF-8 | 1,418 | 3.109375 | 3 | [] | no_license | <?php
/*
檔案功能:登入操作
*/
session_start();
//判斷變數是否存在
if (isset($_POST["username"]) && isset($_POST["password"])) {
// connect
require('../connect.php');
$username = validation($_POST["username"]);
$password = validation($_POST["password"]);
// check username & password
$sql = "SELECT * FROM `users`... | true |
2fbdaa71a2c5f938b8d699447b8578242d91ca5e | PHP | fol-project/http | /src/Middlewares/Ips.php | UTF-8 | 1,373 | 3 | 3 | [] | no_license | <?php
namespace Fol\Http\Middlewares;
use Fol\Http\Request;
use Fol\Http\Response;
/**
* Middleware to get the client ip.
*/
class Ips implements MiddlewareInterface
{
protected $headers = [
'Client-Ip',
'X-Forwarded-For',
'X-Forwarded',
'X-Cluster-Client-Ip',
'Forwarded-... | true |
290b8e4cd3eae0e7bd57597d58489b4ea8e6215d | PHP | RadoslavNikolov/SoftUni | /Semester_3(Advanced Level - Front End)/PHP_Basics/Exams/Exam_2015_May_03/_02_Little_John/LittleJohn.php | UTF-8 | 1,269 | 2.890625 | 3 | [] | no_license | <?php
$input = [];
$input[] = $_GET['arrows'];
$input[] = $_GET['arrows1'];
$input[] = $_GET['arrows2'];
$input[] = $_GET['arrows3'];
//var_dump($input);
$smallArrow = 0;
$mediumArrow = 0;
$largeArrow = 0;
$largArrPattern = "/(>{3}-{5}>{2})/";
$medArrPattern = "/(>{2}-{5}>{1})/";
$smallArrPattern = "/(>{1}-{5}>{1})/";... | true |
487bf31c9b3687cf80b632cb1acb0497e5a98c0e | PHP | dmitri-liventsev/symfony-ddd-shop-sample | /src/Infrastructure/Profile/EventConsumer/UpdateProfile.php | UTF-8 | 832 | 2.671875 | 3 | [] | no_license | <?php
/**
* @author Dmitri Liventsev <dmitri.liventsev@tacticrealtime.com>
*/
namespace App\Infrastructure\Profile\EventConsumer;
use App\Domain\Profile\Event\ProfileWasUpdated;
use App\Domain\Profile\Repository\ProfileModelRepositoryInterface;
use Broadway\ReadModel\Projector;
class UpdateProfile extends Projecto... | true |
eb53da4dfed9e8f6c4e083cf351107f9e2da0582 | PHP | linuxserver/Heimdall | /vendor/laravel/framework/src/Illuminate/Console/Concerns/HasParameters.php | UTF-8 | 1,439 | 3.03125 | 3 | [
"MIT"
] | permissive | <?php
namespace Illuminate\Console\Concerns;
use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputOption;
trait HasParameters
{
/**
* Specify the arguments and options on the command.
*
* @return void
*/
protected function specifyParameters()
{
... | true |
3074e971305a6bf15039b15af2dd9da3c11baa55 | PHP | paulmichels/megamania | /application/models/Plateforme_Model.php | UTF-8 | 2,115 | 2.796875 | 3 | [] | no_license | <?php
defined('BASEPATH') OR exit('No direct script access allowed');
require_once(ENTITIES_DIR . "Plateforme_Entity.php");
class Plateforme_Model extends MY_Model {
/**
* Constructeur
*
* Hérite et overidde le constructeur du parent
* Défini la table à utiliser
* Défini le nom de la c... | true |
a3e3a7500dbc34e9ec9d8cbc347f98df7fb74a53 | PHP | quocthanh/quocthanh.github.io | /PHP/basic/form-upload/upload.php | UTF-8 | 900 | 3.265625 | 3 | [] | no_license | <?php
/**
* receive file uploaded from client
*/
//check request method
if ($_SERVER['REQUEST_METHOD'] !== 'POST') {
throw new LogicException('Not POST Request!!!');
}
echo '<h2>This is from PHP server</h2>' . '<br>';
//directory store files
$uploadDir = 'uploads/';
$uploadFile = $uploadDir . basename($_FILES['i... | true |
8f8574432baf99ae44586c21d4ee09870acbdc8c | PHP | skopa/attr-calc | /app/Http/Resources/Methods/CostMethodResource.php | UTF-8 | 744 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Resources\Methods;
use App\Models\Methods\CostMethodCalculation;
use Illuminate\Http\Request;
use Illuminate\Http\Resources\Json\JsonResource;
/**
* Class CostMethodResource
* @package App\Http\Resources
* @property-read CostMethodCalculation $resource
*/
class CostMethodResource extends... | true |
a4dd1835ac5faa6f00645d2300bbbb23d30c1177 | PHP | jethass/gestionEvenements | /src/otherArchitecture/Omea/GestionTelco/PortabilityBundle/Services/MainRepositoryService.php | UTF-8 | 8,528 | 2.53125 | 3 | [
"MIT",
"BSD-3-Clause"
] | permissive | <?php
namespace Omea\GestionTelco\PortabilityBundle\Services;
use Psr\Log\LoggerInterface;
use Doctrine\DBAL\Connection;
use Omea\GestionTelco\PortabilityBundle\Types\PortabilityStatus;
class MainRepositoryService
{
/** @var LoggerInterface */
private $logger;
/** @var array */
private $config;
... | true |
1930ab1b11c7a3c21fd24b2ead91af7213425bac | PHP | roman1925/donapi | /rate.php | UTF-8 | 845 | 2.59375 | 3 | [] | no_license | <?php
include 'coneccion.php';
$Nombre = $_POST['nombre'];
$post_rating = $_POST['vot'];
$query = "SELECT * FROM catalogo WHERE nombre='$Nombre'";
$result = $link->query($query);
if($result->num_rows>0){
while($row = $result->fetch_assoc()){
$id = $row['Id'];
$rating_actual = $row['vot'];
$hits_actual = $ro... | true |
69075f95af3672e3f8e0a555dc5a0945489590e1 | PHP | neos/contentrepository-development-collection | /Neos.EventSourcedNeosAdjustments/Classes/EventSourcedRouting/Http/BasicContentDimensionResolutionMode.php | UTF-8 | 1,773 | 2.515625 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace Neos\EventSourcedNeosAdjustments\EventSourcedRouting\Http;
/*
* This file is part of the Neos.Neos package.
*
* (c) Contributors of the Neos Project - www.neos.io
*
* This package is Open Source Software. For the full copyright and license
* information, please view the L... | true |
aa6bc6c5d2fe6016be7b671b299e6333fd6eadf3 | PHP | alpredoben/sample_project | /app/Http/Controllers/Client/CategoryController.php | UTF-8 | 3,556 | 2.546875 | 3 | [] | no_license | <?php
namespace App\Http\Controllers\Client;
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use App\Models\Category;
class CategoryController extends Controller
{
public function allCategory()
{
$records = Category::all();
return respons... | true |
b60de98b720b40edaf18cd2440ea57234a39f3e4 | PHP | josejavierromo/DesarrolloEnServidorPHP | /PROYECTO07/web/DAW/PROYECTO01/Index.php | UTF-8 | 3,147 | 2.875 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
//Autor: José Javier Romo Escobar
//Curso: 2º DAW Semipresencial
//Descripcion: Página correspondiente al Proyecto01 (Index.php), en la que se muestran imagenes en una tabla HTML, mediante código PHP.
//Fecha: 14/09/2014 21:19
?>
<!--
Autor: José Javier Romo Escobar
Curso: 2º DAW Semipresencial
Desc... | true |
fd5cb6e15ad05748dbe41fd4d14c3a1d41b253e7 | PHP | jullyana/designescolar | /src/dominio/turma.class.php | UTF-8 | 1,049 | 3.3125 | 3 | [] | no_license | <!doctotype html>
<?php
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
/**
* Description of turma
*
* @author 20112144110384
*/
class Turma {
//put your code here
public $codigo;
public $periodo;
public $turno;
/** Co... | true |