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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
eac4cc8227d3d6c834d80e22710df1f8b9c2bcee | PHP | isaWebDev/SecondTest | /isaLancerDeDesWidget.php | UTF-8 | 13,408 | 2.546875 | 3 | [] | no_license | <?php
/*
Plugin Name: Widget Lancer De Des
Plugin URI: http://localhost/wordpress/plugin
Description: Lancer des dés
Version: 1.0.0
Author: Isa
*/
//lorqu'on lance l'initialisation des widgets dans wordpress on lance la fonction widget_lancer_init de ce plugin
add_action('widgets_init', 'widget_lancer_init... | true |
75d23d9bccd60610743ae0877b3c6f8162fe47c4 | PHP | jorgenils/zend-framework | /laboratory/library/Zend/Filter/Array.php | UTF-8 | 2,811 | 2.890625 | 3 | [] | no_license | <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of th... | true |
15174ae9b2043fad1c4609c8d706c8e34ffbd3e9 | PHP | mohammedmatar/horrible-test | /tests/HeroAgencyTest.php | UTF-8 | 2,967 | 2.65625 | 3 | [
"MIT"
] | permissive | <?php
/**
* Created by PhpStorm.
* User: Mohammed Matar
* Date: 02/08/17
* Time: 11:58 ص
*/
namespace SimpleApp;
use \SampleApp\HeroAgency;
use PHPUnit\Framework\TestCase;
use \SampleApp\IHero;
use Illuminate\Database\Capsule\Manager as Capsule;
use Faker\Factory;
/**
* @codeCoverageIgnore
*/
class HeroAgencyT... | true |
0c2eea19ad65313ff2d74e876a83a8c4fb4435a0 | PHP | ILopez2/Proyecto-cines-programacion-2019 | /dao/CinemaRoomDao.php | UTF-8 | 6,267 | 3.453125 | 3 | [] | no_license | <?php namespace dao;
use dao\Connection as Connection;
use dao\SeatDao as SeatDao;
use models\ClassSeat as Seat;
use models\ClassCinemaRoom as CinemaRoom;
class CinemaRoomDao implements InterfaceDao{
//ATRIBUTES
private $connection;
//CONSTRUCT
publ... | true |
fede85f96bd9a15ae14af754fe4d6c7fd20ae0fa | PHP | rommmy/skeletapp | /src/Router/HttpRouter.php | UTF-8 | 1,728 | 2.96875 | 3 | [] | no_license | <?php
namespace Skeletapp\Router;
/**
* Dummy wrapper on top of the awesome fastRoute package
* by nikiC.
*
* https://github.com/nikic/FastRoute
* @package default
*/
class HttpRouter implements Router
{
protected $routes = [];
protected $dispatcher = null;
protected static $allowedMethods = [
... | true |
237ee87b4bf09776e2529723ae7d7be2bccedf78 | PHP | Alexis-hub10/RepasoPHP | /conversion.php | UTF-8 | 2,156 | 2.65625 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Convertir</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<section id="conversion">
<form method="post"><section>
<select name="moneda1">
<option >Selecciona..</option>
<option value="Dolares">Dolar</option>
<option valu... | true |
005835f5c4daea8a0e238c2f91899b326f2534d0 | PHP | ChayBB/Multivendor-Ecommerce | /app/Model/User.php | UTF-8 | 1,663 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Model;
use Illuminate\Contracts\Auth\MustVerifyEmail;
use Illuminate\Database\Eloquent\SoftDeletes;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Notifications\Notifiable;
use Illuminate\Support\Facades\Auth;
class User extends Authenticatable
{
use Notifiable;
us... | true |
0382c06861896a4227a05793ea385e7999f2b4f5 | PHP | ircmaxell/php-math-parser | /lib/PHPMathParser/TerminalExpression.php | UTF-8 | 1,965 | 3.28125 | 3 | [
"MIT"
] | permissive | <?php
/*
* The PHP Math Parser library
*
* @author Anthony Ferrara <ircmaxell@ircmaxell.com>
* @copyright 2011 The Authors
* @license http://www.opensource.org/licenses/mit-license.html MIT License
* @version Build @@version@@
*/
namespace PHPMathParser;
use PHPMathParser\Expressions\Addition;
use ... | true |
ea296b26659db01e3051ff7471e5ce0eec9b1080 | PHP | pramodvkadam/onlineinterview | /eecrm/include/charts/chart-helpers.php | UTF-8 | 972 | 3.21875 | 3 | [] | no_license | <?php
function getDates($arr) {
return $arr['action_date'];
}
function formatDates($arr) {
return date("d M,y",strtotime($arr));
}
function getUsers($arr) {
return $arr['user_id'];
}
function getUsersName($arr) {
return $arr['first_name']." ".$arr['last_name'];
}
function getCalls($callsArray) {
... | true |
a1a1b46d208ae0dc1cd7f679ae50561e52afb016 | PHP | Bukashk0zzz/MicrobiltCreditscore | /Status_/Type/MicrobiltStructStatus_Type.php | UTF-8 | 5,224 | 2.921875 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
/**
* File for class MicrobiltStructStatus_Type
* @package Microbilt
* @subpackage Structs
* @author WsdlToPhp Team <contact@wsdltophp.com>
* @version 20150429-01
* @date 2015-11-26
*/
/**
* This class stands for MicrobiltStructStatus_Type originally named Status_Type
* Meta informations extracted from t... | true |
44ddfd4f19479aa6f22e29934d824dc0cacbff95 | PHP | GM-Alex/user-access-manager | /src/Setup/Database/DatabaseUpdate.php | UTF-8 | 1,106 | 2.578125 | 3 | [] | no_license | <?php
/**
* Update.php
*
* The Update class file.
*
* PHP versions 5
*
* @author Alexander Schneider <alexanderschneider85@gmail.com>
* @copyright 2008-2017 Alexander Schneider
* @license http://www.gnu.org/licenses/gpl-2.0.html GNU General Public License, version 2
* @version SVN: $id$
* @link ... | true |
adf2e446ff5a3630015a9b8b09d92f80ee7b50a3 | PHP | CrazyBobik/allotaxi.test | /framework/k/ctree.php | UTF-8 | 19,964 | 2.65625 | 3 | [] | no_license | <?php defined('K_PATH') or die('DIRECT ACCESS IS NOT ALLOWED');
class K_cTree {
private $type; // определят тип ноды в деревер, от типа зависит из какой таблицы будет выбираться информация для нод
public function __construct($type = false)
{
if (self::typeExists($type))
{
$this->type = $type;
}
else
... | true |
14f58007c7dd9dce2080fc8e8767d5048c2b6855 | PHP | hhzzk/metube | /database/tb_group.php | UTF-8 | 1,167 | 2.84375 | 3 | [] | no_license | <?php
include_once("db_conn.php");
if(!isset($_GET['func']))
{echo "the func doesn't be set";}
else if($_GET["func"] == "set_message")
{set_message($name,$msg);}
else if ($_GET["func"] == "get_message")
{get_message();}
function set_message($name,$msg)
{
$user = $_GET["name"];
$dt = date("Y-m-d H:i:s");
... | true |
4d4f00c1544af2c396131ecc92f30547bfb47423 | PHP | sevensth/DWPF | /lib/cache/module.cache.lib.php | UTF-8 | 602 | 2.703125 | 3 | [] | no_license | <?php
Class DWLibCacheModule extends DWLibCacheSubdirectory
{
public static function sharedInstance()
{
static $instance = null;
if ($instance === null)
{
$baseDir = CACHE_DIR . DIRECTORY_SEPARATOR . 'modulecaches';
$instance = new self($baseDir);
}
return $instance;
}
public function setCache($... | true |
c240e18019a8350ad43dd9c6d35aa2fa804a6d37 | PHP | linuxserver/Heimdall | /vendor/league/commonmark/src/Extension/CommonMark/Node/Inline/AbstractWebResource.php | UTF-8 | 851 | 2.546875 | 3 | [
"MIT",
"BSD-3-Clause"
] | permissive | <?php
declare(strict_types=1);
/*
* This file is part of the league/commonmark package.
*
* (c) Colin O'Dell <colinodell@gmail.com>
*
* Original code based on the CommonMark JS reference parser (https://bitly.com/commonmark-js)
* - (c) John MacFarlane
*
* For the full copyright and license information, pleas... | true |
d2e69373d2df44b589dfa7315e5c4f5bd31ec755 | PHP | busywarrior/QCmvc | /core/Router.php | UTF-8 | 2,240 | 2.703125 | 3 | [] | no_license | <?php
class Router{
public static $instance;
var $class;
var $classobj;
var $method;
var $paras;
var $default_controller;
private function __construct(){
}
public static function getInstance(){
if (self::$instance == null) {
self::$instance = new Router();
}
return self::$in... | true |
f975f26af8668b1153dd30ed41e5c89c325ee6e5 | PHP | klnjmm/csv2json | /src/RowParser.php | UTF-8 | 487 | 2.9375 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace Klnjmm;
class RowParser
{
private FieldParserInterface $fieldParser;
public function __construct(FieldParserInterface $fieldParser)
{
$this->fieldParser = $fieldParser;
}
public function parseRow(array $row): array
{
$parsedRow = [];
... | true |
5c42859cd55c9da2877b5ad45eca375e441da3cc | PHP | AhmedAfifMonrat/Design4Green | /api/dentists/removeContact.php | UTF-8 | 1,111 | 2.5625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: Orsola
* Date: 23-Nov-17
* Time: 10:06 AM
*/
include_once "../../database/config.php";
session_start();
$data = file_get_contents('php://input');
$data = json_decode($data, true);
if (isset($data['id']) && is_numeric($data['id'])) {
$dentist_id = mysqli_real_escape_s... | true |
c88226e8951057ab7da7b85d5727beaa4220e857 | PHP | vacelet/trocmaison | /mode/admin/article/list.php | UTF-8 | 3,667 | 2.671875 | 3 | [] | no_license | <?php
#-----------------------------------
#
# listearticle.php : Show all articles order by categorie
# Available only for admin account
# Author : Nicolas Vacelet
# Last update : 17/03/2015
#
#-----------------------------------
require_once($_SERVER['DOCUMENT_ROOT']."/include/libraries.php");
$req = SQLQuery('SEL... | true |
21468bf365e193bf888fd971e12b62d0d3c9cf99 | PHP | shubho65/oop_assignment | /Audi.php | UTF-8 | 327 | 3.234375 | 3 | [] | no_license | <?php
include 'Car.php';
Class Audi extends Car{
private $color;
private $seats;
public function setColor($color){
$this->color=$color;
}
public function setSeats($seats){
$this->seats=$seats;
}
public function getColor(){
return $this->color;
}
public function getSeats(){
return $this->seats;
... | true |
207cb274e352ec05056727cc4115e468c110ff72 | PHP | nikakirkitadze/forecast-api | /include/Retriever.php | UTF-8 | 7,302 | 2.8125 | 3 | [] | no_license | <?php
class Retriever {
public function getCurrentWeather() {
// cities array
$cities = array('Tbilisi', 'Batumi', 'Kobuleti', 'Kutaisi', 'Zugdidi', 'Kazbegi', 'Telavi');
//$cities = array('Tbilisi');
$response = array();
for ($i=0; $i < sizeof($cities); $i++) {
$locationUrl =... | true |
2a478a3444cdf90acdfa683669497927e3d01e22 | PHP | JBris/drupal-enterprise-stack | /app/modules/contrib/graphql/src/GraphQL/Execution/FieldContext.php | UTF-8 | 2,573 | 2.578125 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference",
"GPL-2.0-only"
] | permissive | <?php
namespace Drupal\graphql\GraphQL\Execution;
use Drupal\Core\Cache\RefinableCacheableDependencyInterface;
use Drupal\Core\Cache\RefinableCacheableDependencyTrait;
use GraphQL\Type\Definition\ResolveInfo;
class FieldContext implements RefinableCacheableDependencyInterface {
use RefinableCacheableDependencyTrai... | true |
9e15f00e3a12362b803d29f09c1fccf352bbe643 | PHP | JeremyGi-Dev/exercices | /chapitre9/exercice5.php | UTF-8 | 2,439 | 3.25 | 3 | [] | no_license | <?php
include "exercice4.php";
// Créez une sous-classe nommée form2 en dérivant la classe form de l’exercice 4.
// Cette nouvelle classe doit permettre de créer des formulaires ayant en plus des boutons radio et des cases à cocher.
// Elle doit donc avoir les méthodes supplémentaires qui correspondent à ces création... | true |
2fd8630437367eada64bbe74daf5e3e42dd9a359 | PHP | HashandSalt/Kirby3-Gilmour | /vendor/james-heinrich/getid3/getid3/module.archive.tar.php | UTF-8 | 6,797 | 2.625 | 3 | [
"GPL-2.0-or-later",
"GPL-3.0-only",
"GPL-2.0-only",
"GPL-1.0-or-later",
"MPL-2.0",
"LicenseRef-scancode-commercial-license",
"LGPL-3.0-only",
"GPL-1.0-only",
"LicenseRef-scancode-other-copyleft",
"LicenseRef-scancode-unknown-license-reference",
"LGPL-2.0-or-later",
"MIT",
"LicenseRef-scancod... | permissive | <?php
/////////////////////////////////////////////////////////////////
/// getID3() by James Heinrich <info@getid3.org> //
// available at https://github.com/JamesHeinrich/getID3 //
// or https://www.getid3.org //
// or http://getid3.sourceforge.net ... | true |
e2d6b2da2f245d86eee4639d71e5b4a248264f84 | PHP | happyabbi/excelsparser | /app/models/WalkwayFeature.php | UTF-8 | 774 | 2.6875 | 3 | [] | no_license | <?php
class WalkwayFeature extends \Phalcon\Mvc\Model
{
/**
*
* @var integer
*/
public $sn;
/**
*
* @var string
*/
public $walkway_id;
/**
*
* @var integer
*/
public $feature_id;
/**
* Independent Column Mapping.
*/
public functi... | true |
44515c4bb0ff464de9bd2ba33d65be5e2c5bdb49 | PHP | josepaiva94/zoho-recruit-client-php | /src/Request/ChangeStatus.php | UTF-8 | 1,740 | 2.765625 | 3 | [
"MIT"
] | permissive | <?php
namespace Apora\ZohoRecruitClient\Request;
/**
* Zoho Recruit method to change the candidate status with respect to the job openings in Zoho Recruit
*/
class ChangeStatus extends ZohoRecruitRequest
{
/**
* Specify uniqueID of the Job Opening record for which the associated candidate status has to be c... | true |
5483f1e1dfb4effcfefa9fbd94805282700e4a72 | PHP | OmerBhatti/Online-PHP-Compiler | /listFiles.php | UTF-8 | 487 | 2.703125 | 3 | [] | no_license | <?php
if ($handle = opendir('.')) {
$i=1;
while (false !== ($entry = readdir($handle))) {
if ($entry != "." && $entry != ".." && $entry != ".git"
&& $entry != "index.php" && $entry != "listFiles.php" && $entry != "README.md"
&& $entry != "result.php" && $entry != "style.less") {
... | true |
b5b4fa8f7c0b5fe89b73de270cbca9fc2e34d02e | PHP | david-inusah/Expert_Finder | /classes/RequestCollaboration.php | UTF-8 | 3,129 | 2.65625 | 3 | [] | no_license | <?php
/**
*
*/
class RequestCollaboration
{
// $requestid="";
public static function sendRequest($userid, $followerid){
$requestSent=False;
if ($userid != $followerid) {
DB::query('INSERT INTO collaboration_requests VALUES (\'\', :userid, :followerid,0 ,0)', array(':userid'=>$u... | true |
82d40237552f6711823617a4df00ff4c28d6a92f | PHP | AngelaBanuelos/Awesomenauts | /php/controller/login-verify.php | UTF-8 | 578 | 3.03125 | 3 | [
"MIT"
] | permissive | <?php
//we require config file so we can use the info we need
require_once(__DIR__ . "/../model/config.php");
//checks if their is a session variable and if its true
//if its not true, the user isnt logged in
//the if statements is used to check if session authenticated hasnt been set
//to verify if user has logg... | true |
203e4d0cff2d102acf8dfbc1c3fc060b097b2bbf | PHP | camycode/z-repository | /src/Zhaohehe/Repositories/Eloquent/Repository.php | UTF-8 | 10,757 | 2.546875 | 3 | [] | no_license | <?php
namespace Zhaohehe\Repositories\Eloquent;
use Illuminate\Contracts\Pagination\LengthAwarePaginator;
use Illuminate\Support\Collection;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Container\Container as App;
use Zhaohehe\Repositories\Contracts\ModelEventInterface;
use Zhaohehe\Repositories\Contracts\R... | true |
987c631afcf4b2c372f9e39333a1e30bc8a2b70c | PHP | MeidiniRA/training-NF | /jenis.php | UTF-8 | 2,041 | 2.703125 | 3 | [] | no_license | <?php
$sesi = $_SESSION['MEMBER'];
if(isset($sesi) && $sesi['level'] != 'Karyawan' ){
$ar_judul = ['No','Nama'];
//ciptakan object dari class dari PegawaiModel
//fungsi - fungsi CRUD
$model = new JenisModel();
$rs = $model->getAll();
?>
<h3>Daftar Jenis Cuti</h3>
<!-- ---------------------- awal modal--------------... | true |
9cf11b0690c76b46961aa64a1707fc4e67643071 | PHP | XonneX/adventofcode | /tests/AdventOfCode/Y2021/Solutions/Day2/Day2Test.php | UTF-8 | 953 | 3.0625 | 3 | [] | no_license | <?php
declare(strict_types=1);
namespace XonneX\AdventOfCode\Y2021\Solutions\Day2;
use PHPUnit\Framework\TestCase;
class Day2Test extends TestCase
{
public function testSolvePartOneExample(): void
{
$day2 = new Day2();
$day2->setDebugInput(<<<TXT
forward 5
down 5
forward 8
up 3
down 8
forwa... | true |
972b04ed818ab45eb98cbb974a91160311b39924 | PHP | gatorv/gecko_fw1 | /library/Gecko/Filter/PasswordHash.php | UTF-8 | 865 | 2.734375 | 3 | [
"Apache-2.0"
] | permissive | <?php
//
// +------------------------------------------------------------------------+
// | Gecko Framework |
// +------------------------------------------------------------------------+
//
require_once('Zend/Filter/Interface.php');
/**
* PasswordHash Filter
* ... | true |
98823807112a24c9c7bd817a097954c07eebd99b | PHP | kataoka787/DDDS-transplant | /application/libraries/Pdf.php | UTF-8 | 19,809 | 2.71875 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php defined('BASEPATH') or exit('No direct script access allowed');
class Pdf
{
private $pdf = null;
private $landscape = false;
private $newLine = true;
private $maxWidth = 0;
private $maxHeight = 0;
private $minX = 0;
private $minY = 0;
private $maxX = 0;
private $maxY = 0;
... | true |
49e671296013135219bceb205d74f120e2777743 | PHP | ldevapp/buscacep | /tests/BuscarTest.php | UTF-8 | 2,128 | 2.734375 | 3 | [] | no_license | <?php
use PHPUnit\Framework\TestCase;
use Codeslcs\BuscaCep\Buscar;
class BuscarTest extends TestCase {
/**
* @dataProvider dadosTeste
*/
public function testGetEnderecoCepDefaultUsage(string $cep, array $enderecoEsperado) {
// USO COM CONJUNTO DE DADOS DATAPROVIDER
$re... | true |
ebc499f4ed2f279559426685936f8c3696c9ca5e | PHP | JordiBBZOTE/Pagina-web-con-base-de-datos | /AE/NEmp.php | UTF-8 | 832 | 2.671875 | 3 | [] | no_license | <?php
$conexion=mysqli_connect("localhost","root","","compañia");
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>inserta en empleado</title>
<link rel="stylesheet" href="/login/css/tablas.css">
</head>
<body>
<?php
$sql="
INSERT INTO empleado
(NOMBREP, ... | true |
2d0df33fc28995c61984e7e93dae4f3e509b7bc8 | PHP | guian615/PhotoGAlSpecialiZationLARAVEL | /app/Http/Controllers/ImageController.php | UTF-8 | 3,342 | 2.609375 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use Illuminate\Support\Facades\Session;
use Illuminate\Support\Facades\Auth;
use Illuminate\Http\Request;
use App\Models\Image;
class ImageController extends Controller
{
// function to search or get caption and category value to display
public function index(Request $... | true |
e6922f1116499e55094934433ad35f04077e2e12 | PHP | samuraiseoul/Essence | /src/Http/Messages/Request/EssenceRequest.php | UTF-8 | 1,196 | 2.796875 | 3 | [
"MIT"
] | permissive | <?php
namespace Essence\Http\Messages\Request;
use Essence\Http\Messages\Body\EssenceBodyInterface;
use Essence\Http\Messages\Headers\EssenceHeadersInterface;
use Essence\Http\Messages\Request\StartLine\EssenceRequestStartLineInterface;
use Essence\Http\Messages\EssenceStartLineInterface;
final class EssenceRequest... | true |
86e33dd29c6a6d08ce0313f74638b25504637c68 | PHP | inamjung/Yiiproject | /modules/risk/models/Levels.php | UTF-8 | 855 | 2.53125 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
namespace app\modules\risk\models;
use Yii;
/**
* This is the model class for table "levels".
*
* @property integer $id
* @property string $name
* @property string $namecode
*/
class Levels extends \yii\db\ActiveRecord
{
/**
* @inheritdoc
*/
public static function tableName()
{
... | true |
c6d52d174bf838588c6a220dcd5f3716b8bc1eae | PHP | larensimahligai/PIF456 | /modul2/tugas1.php | UTF-8 | 1,747 | 2.703125 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<title>Larensi Mahligai(Tugas)</title>
</head>
<body>
<script language="JavaScript" type="text/javascript">
function checkusername(input) {
re = /^\D{4,}$/;
return re.test(input);
}
function checkpassword(input) {
re = /^\D{4,}$/;
return re.test(input);
}
funct... | true |
1d24e48a984ed12e485c0b8e37148a451019860c | PHP | GabrielPora/WeThinkCode_PHP_BootCamp | /Day_01/ex06/ssap.php | UTF-8 | 412 | 2.90625 | 3 | [] | no_license | #!/usr/bin/php
<?php
if ($argc < 2)
return ;
$count = 0;
foreach ($argv as $elem_arg)
{
if ($count == 0)
$count = 1;
else
{
if (!$str)
$str = $elem_arg;
else
$str = "$str $elem_arg";
}
}
$str = eregi_replace("[ ]+", " ", $str);
$ret = explode(" ", $str);
so... | true |
97dcaa2e4b2bd2cdbaa31b7892919c1119490e3a | PHP | hectorcrispens/SoapV2 | /src/Clases/Expose.php | UTF-8 | 1,952 | 2.71875 | 3 | [] | no_license | <?php
require_once(__DIR__ .'/../interfaces/iNucleoEntidad.php');
require __DIR__ .'/../Dto/ExposeDTO.php';
class Expose implements iNucleoEntidad{
/**
* Implement ComplexType struc Data
*/
function AddComplex($server){
$server->wsdl->addComplexType(
'exposeResponse',
'complexType',
... | true |
4b0325c426264e2203f22f58466634ae6ef47fc4 | PHP | macressler/brick | /src/Money/MoneyParseException.php | UTF-8 | 620 | 3.171875 | 3 | [
"MIT"
] | permissive | <?php
namespace Brick\Money;
/**
* Exception thrown when a string cannot be parsed as a Money.
*/
class MoneyParseException extends \RuntimeException
{
/**
* @param string $string
*
* @return MoneyParseException
*/
public static function invalidFormat($string)
{
... | true |
b415fff8aec187cd529471d1372ea80455baa4df | PHP | chigix/php-io-component | /src/FileInputStream.php | UTF-8 | 3,254 | 3.234375 | 3 | [
"MIT"
] | permissive | <?php
/*
* This file is part of the IO-Component package.
*
* (c) Richard Lea <chigix@zoho.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Chigi\Component\IO;
/**
* A FileInputStream obtains input bytes from a ... | true |
bc5fecbcc04790ecaaadb0b00d9f701d4443664c | PHP | kachejunior/samea | /lib/Autobuses.php | UTF-8 | 3,010 | 2.984375 | 3 | [] | no_license | <?php
class Autobuses {
private $placa;
private $marca;
private $modelo;
private $asientos;
public function __construct() {
$this->placa = null;
$this->marca = null;
$this->modelo = null;
$this->asientos = null;
}
/*Devuelve la placa del Autobus*/
... | true |
ce23bb081e1a3fae28cd3c1e442b0403483b8bcb | PHP | Lsickle/Lprosarc2 | /database/migrations/2019_02_18_082551_create_data_definitions_table.php | UTF-8 | 1,909 | 2.578125 | 3 | [] | no_license | <?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateDataDefinitionsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('data_de... | true |
04afebcd86cc652efa6f4f6b31635b828cda838c | PHP | JaHernandez22/Curso_PHP | /BaseDeDatos/49 - mysqli (POO) - listado tabla rubros.php | UTF-8 | 1,404 | 2.71875 | 3 | [] | no_license | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
.tablalistado {
border-collapse: collapse;
box-shadow: 0... | true |
4a2dac4ba3d20528bcc9cad43a838a04027ec476 | PHP | Brandon-Crosby/project-5test | /src/routes.php | UTF-8 | 981 | 2.53125 | 3 | [] | no_license | <?php
use Slim\App;
use Slim\Http\Request;
use Slim\Http\Response;
use App\Comments;
use App\Post;
//routes
//Display Home Page
return function(App $app){
$container = $app->getContainer();
$app->get('/', function (Request $request, Response $response, array $args) use ($container) {
// Sample log message
... | true |
d6adaa3961ff46bc12ee40acc649bc6204050947 | PHP | Svish/triangelos | /src/Model/Webshop.php | UTF-8 | 1,532 | 2.8125 | 3 | [] | no_license | <?php
namespace Model;
use Config;
/**
* Webshop model.
*
* @see https://developer.paypal.com/docs/classic/paypal-payments-standard/integration-guide/Appx_websitestandard_htmlvariables/#id08A6HH0D0TA
*/
class Webshop extends \Model
{
private $config;
public function __construct()
{
$this->config = Config::w... | true |
53005e444da417aa441e9a3987197a2f049a8dee | PHP | yusidabcs/skomisi | /app/class/Agent.php | UTF-8 | 2,382 | 2.984375 | 3 | [] | no_license | <?php
class Agent extends Database{
private $table = 'agents';
public function all(){
$conn = $this->connect();
try {
$sth = $conn->query('SELECT * FROM agents');
$rows = $sth->fetchAll(PDO::FETCH_ASSOC);
return $rows;
} catch(PDOException $e) {
echo $e->getMessage();
}
}
public... | true |
86edbd0985531dad15f2ad7c4d3adf8d6b4bd2de | PHP | zhang1career/phpcmd | /app/Repos/DbRepo/DataType.php | UTF-8 | 1,786 | 3.0625 | 3 | [] | no_license | <?php
namespace App\Repos\DbRepo;
class DataType
{
const DATA_TYPE_UNKNOWN = 0;
const DATA_TYPE_UINT = 1;
const DATA_TYPE_INT = 2;
const DATA_TYPE_CHAR = 11;
const DATA_TYPE_VARCHAR = 12;
public static function getDataType($column) {
$type = DataType::DATA_TYPE_UNKNOWN;
... | true |
bb95b18e6c5274a4c65dbb34a29ead69d5d21584 | PHP | Liferbis/Proyectos | /DWES/Extraordinaria/EV1/Ud3/Hoja1/Ejercicio5.php | UTF-8 | 312 | 3.28125 | 3 | [] | no_license | <html>
<head>
<title>Ejercicio 5 Lidia</title>
</head>
<body>
<h1>Genera valores de la siguiente serie 1/2, 2/4, 3/8, 4/16....</h1>
<?php
$i=1;
$k=2;
echo $i."/".$k." ,";
$i++;
while( $i<=20){
$k=$k*2;
echo "</br> $i /".$k." , ";
if($i==20){
echo "....";
}
$i++;
}
?>
</body>
</html> | true |
3404b8c8363b5738b0a5e4374f056c7e54e0343e | PHP | biglier/Blog | /Controller/Adminhtml/Article/Save.php | UTF-8 | 2,902 | 2.546875 | 3 | [] | no_license | <?php
/**
* class Save
*
* @category Slavik\Blog\Controller\Adminhtml\Article;
* @package Slavik\Blog
* @author Stanislav Lelyuk <lelyuk.stanislav@gmail.com>
* @copyright 2019 Stanislav Lelyuk
*/
namespace Slavik\Blog\Controller\Adminhtml\Article;
use Magento\Backend\App\Action;
use Magento\Framework\App... | true |
080adb415bec12379d141b2c1b78eb4f076d7739 | PHP | Pandrome/Datagrid | /src/DataGrid/DataRenderer.php | UTF-8 | 1,013 | 2.6875 | 3 | [
"MIT"
] | permissive | <?php
namespace Pandrome\Datagrid\DataGrid;
use Pandrome\Datagrid\DataGrid\Column\Builder as ColumnBuilder;
use Pandrome\Datagrid\DataGrid\Filter\Builder as FilterBuilder;
class DataRenderer
{
protected $pagination;
protected $columnBuilder;
protected $filterBuilder;
protected $orderBy;
protecte... | true |
e9042b84d6cd0949cfbe4c6a07c3f8d7300e85d7 | PHP | Ariuw/poronga | /core/classes/Module.php | UTF-8 | 1,603 | 3.125 | 3 | [
"Apache-2.0"
] | permissive | <?php
/*
* Made by Samerton
* https://github.com/NamelessMC/Nameless/
* NamelessMC version 2.0.0-pr5
*
* License: MIT
*
* Modules class
*/
abstract class Module {
private static $_modules = array();
private $_name, $_author, $_version, $_nameless_version;
public function __construct($module, $name, $au... | true |
b0141f9b6302fbd25e46beae701b2223ee969fc5 | PHP | cursointegradorsissoft/S_Gestion_Incidencias | /controller/clases/pdf/tcpdf/clases/parsingHtml.class.php | UTF-8 | 12,543 | 2.953125 | 3 | [] | no_license | <?php
class HTML2PDF_parsingHtml
{
protected $_html = ''; // HTML code to parse
protected $_num = 0; // table number
protected $_level = 0; // table level
protected $_encoding = ''; // encoding
public $code = array(); // parsed HTML ... | true |
34c44e4370b40cf7145f95ff276581aed265f72a | PHP | LegilsonBrito/uninove | /programacao-web/aula-05/array-unshift.php | UTF-8 | 120 | 2.53125 | 3 | [] | no_license | <?php
$cesta = array("laranja", "banana");
array_unshift($cesta, "melancia", "morango");
print_r($cesta);
?> | true |
505fb697433f7df9476d070d4f83a81dde0e76bd | PHP | bartosz-rogowski/database-1-project | /bazydanych/osoba/osoba_change_pass_form.php | UTF-8 | 1,098 | 2.609375 | 3 | [] | no_license | <!DOCTYPE html>
<html lang="pl">
<head>
<meta charset="utf-8" />
<meta name="Author" content="Bartosz Rogowski" />
<title>
Zmień hasło
</title>
<link rel="stylesheet" href="../style.css" type="text/css" />
</head>
<body>
<div id="container">
<?php
... | true |
6bea249f9412db82d131e840279d0008b58490a4 | PHP | SheseR/simpaas | /src/Console/Command/Management/KeyGenerateCommand.php | UTF-8 | 4,525 | 2.78125 | 3 | [] | no_license | <?php
namespace Levtechdev\Simpaas\Console\Command\Management;
use Illuminate\Console\ConfirmableTrait;
use Levtechdev\Simpaas\Console\Command\AbstractCommand;
class KeyGenerateCommand extends AbstractCommand
{
use ConfirmableTrait;
const ALLOWED_KEY_NAMES = [
'SENSITIVE_DATA_TOKEN',
];
/**... | true |
4515d6f6e358481f874198c2d873c3502c2dc5c2 | PHP | kctus9/AreYouGreen | /app/src/Entity/Questions.php | UTF-8 | 3,665 | 2.578125 | 3 | [] | no_license | <?php
namespace App\Entity;
use App\Repository\QuestionsRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=QuestionsRepository::class)
*/
class Questions
{
/**
* @ORM\Id
* @ORM\Gen... | true |
b44f3e0117239fafe7d02c914ba1064d43000274 | PHP | supercgeek/ICS4U1 | /1_Projects/20_Activity_2-5/activity-2-5b.php | UTF-8 | 800 | 2.953125 | 3 | [] | no_license | <!DOCTYPE HTML>
<html>
<head>
<title>Activity 2.5b Output - FOR Loops</title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<!--STYLESHEET LOAD-->
<link rel="stylesheet" type="text/css" href="styles_b.css">
<script src="http://use.edgefonts.net/lekton:n7,i4,n4:all.js"></script>
</hea... | true |
e3dee23d92a27035a4b8db22102865fb033d5578 | PHP | Mohit-Singh/AssignSeat | /libraries/validation.class.php | UTF-8 | 30,826 | 2.890625 | 3 | [] | no_license | <?php
/**
* **************************** Creation Log *******************************
* File Name - Validate.php
* Project Name - AssignSeat
* @Version - 1.0
* Created by - Chetan Sharma
* Created on - August 10, 2013
* ***... | true |
f8bf21bdf48ce8cd8ec0af69990ec310330df702 | PHP | novichkovv/ddetox | /public_html_old/backend/vote/preview.php | UTF-8 | 1,019 | 2.75 | 3 | [] | no_license | <?php
/********************************************/
/* This is a simple demonstration on how to */
/* place the poll on your pages. */
/********************************************/
?>
<html>
<head>
<title>Simple PHP Poll Demonstration</title>
<!-- The JavaScript makes the pop-up window. -->
<script type=... | true |
641941d6f56783e90153c5f556b49de7040566c6 | PHP | funkistz/mis | /database/seeds/RaceSeeder.php | UTF-8 | 1,087 | 2.5625 | 3 | [
"MIT"
] | permissive | <?php
use Illuminate\Database\Seeder;
use App\Models\Race;
class RaceSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
\DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // disable foreign key constraints
Race::truncate();
... | true |
e3d72a9282d6d088f09800522609086b7070b78c | PHP | michaelZhu/zhu0yu | /console/controllers/SwooleController.php | UTF-8 | 793 | 2.515625 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
namespace console\controllers;
use Yii;
use yii\console\Controller;
use yii\base\Module;
class SwooleController extends Controller
{
private $swoole;
public function __construct($id, Module $module, array $config=[])
{
parent::__construct($id, $module, $config);
$this->swoole = Yii::... | true |
aac5c8ec4ac39fe69f08e6724cebed2fce1bf288 | PHP | confusingSmile/Veilinghuis | /Controller/kavel/nieuweKavel.php | UTF-8 | 1,261 | 2.5625 | 3 | [] | no_license | <?php
namespace Controllers;
session_start();
if(!isSet($_SESSION['user'])){
header("location: /index.php");
exit;
}
require_once '../../vendor/autoload.php';
use Database\EntityManager;
use Veilinghuis\Kavel;
$em = new EntityManager();
if(isset($_POST['kavelOmschrijving'])){
$kavelOmschrijving = ... | true |
15e207c7683a60a6b00bfb365ead4059425eea11 | PHP | mozilla/community-portal | /plugins/events-manager/forms/event/group.php | UTF-8 | 1,448 | 2.5625 | 3 | [] | no_license | <?php
/**
* Group input for events
*
* @package WordPress
* @subpackage community-portal
* @version 1.0.0
* @author Playground Inc.
*/
global $EM_Event;
if ( ! function_exists( 'bp_is_active' ) || ! bp_is_active( 'groups' ) ) {
return false;
}
$user_groups = groups_get_user_groups( get_current_user_id()... | true |
b3a20215d2f3b662f21ddf2d4ef9e319fb709957 | PHP | WawanVrz/theangkringancms | /app/Http/Controllers/Auth/LoginController.php | UTF-8 | 3,483 | 2.625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers\Auth;
use App\Http\Controllers\FrontendController;
use Illuminate\Foundation\Auth\AuthenticatesUsers;
use Illuminate\Http\Request;
use Auth;
use Route;
class LoginController extends FrontendController
{
/*
|-----------------------------------------------------------------... | true |
c5ab6853de1f79767535806ca34bda8eddf76757 | PHP | smsapi/smsapi-php-client | /tests/Unit/Feature/Sms/Bag/BagWithMultipleParamsTestCase.php | UTF-8 | 901 | 2.65625 | 3 | [
"Apache-2.0"
] | permissive | <?php
declare(strict_types=1);
namespace Smsapi\Client\Tests\Unit\Feature\Sms\Bag;
use PHPUnit\Framework\TestCase;
abstract class BagWithMultipleParamsTestCase extends TestCase
{
abstract public function createBagWithParams(array $params);
/**
* @test
*/
public function it_should_assign_param... | true |
9c66114da31d5ecfcbdf5cb94ea5722f946936ab | PHP | mustafaabduljalil/ibtikar_task | /app/Services/PostService.php | UTF-8 | 596 | 2.78125 | 3 | [] | no_license | <?php
namespace App\Services;
use App\Repositories\PostRepository;
class PostService
{
protected $postRepository;
public function __construct(PostRepository $postRepository)
{
$this->postRepository = $postRepository;
}
/**
* Store new post.
*
* @return \App\Post $post
... | true |
846145086eeb8081652e11e19d8781df10c62625 | PHP | skoolyardllc/allweatherhelp | /forgetpasswordmail.php | UTF-8 | 1,404 | 2.515625 | 3 | [] | no_license | <?php
require_once "lib/core.php";
$request = json_decode(file_get_contents('php://input'),true);
if(isset($request['forgotPass']) && isset($request['email']))
{
$email = $conn->real_escape_string($request['email']);
$sql = "select * from users where email ='$email'";
if($res=... | true |
cbdc25c69b1e56ca0a802a9e6c3891f63cef92b4 | PHP | matrix-lab/laravel-advanced-search | /src/ModelScope.php | UTF-8 | 1,002 | 2.90625 | 3 | [
"MIT"
] | permissive | <?php
namespace MatrixLab\LaravelAdvancedSearch;
class ModelScope
{
/**
* 类名.
*
* @var
*/
protected $className;
/**
* scope 方法名称.
*
* @var
*/
private $scopeName;
/**
* 构造参数.
*
* @var array
*/
private $args;
public function __co... | true |
f36fe9fc46c999c05146994a581d9fcb83bce6ed | PHP | rasseljandavid/medical | /app/Http/Controllers/HomeController.php | UTF-8 | 1,900 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use App\Patient;
use DB;
class HomeController extends Controller
{
/**
* Create a new controller instance.
*
* @return void
*/
/**
* Show the application dashboard.
*
... | true |
a7836a3ef39b7b68408d71bfd8806cacfd25e45e | PHP | Niknikus/YetiCave | /sign-up.php | UTF-8 | 4,926 | 2.71875 | 3 | [] | no_license | <?php
session_start();
require_once "functions.php";
$category = get_category($link);
// Проверям метод запроса, если get то:
if ($_SERVER['REQUEST_METHOD'] != "POST") {
$content_page = render_template("templates/sign-up.php", []);
renderPage("templates/layout.php", ["content" => $content_page, "title" => "Рег... | true |
b1f22da1e36935c2e3841f44893980f642f13a47 | PHP | ultranaut/recipe4living.com | /backend/recipe4living/models/MigrationModel.php | UTF-8 | 30,027 | 2.71875 | 3 | [] | no_license | <?php
/**
* Migration
*
* @package BluApplication
* @subpackage BackendModels
*/
class ClientBackendMigrationModel extends BackendMigrationModel
{
/**
* Datasource
*
* @access protected
* @var MSSQLDatabase
*/
protected $_source;
/**
* Content-to-article mapping
*
* @acce... | true |
449373f99dc7ebf826e527210f0071b98c733787 | PHP | mjoc1985/BookingManager | /database/factories/Bookings/BookingFactory.php | UTF-8 | 2,193 | 2.65625 | 3 | [
"MIT"
] | permissive | <?php
namespace Database\Factories\Bookings;
use App\Models\Agent;
use App\Models\Bookings\Booking;
use App\Models\Product;
use Carbon\Carbon;
use Illuminate\Database\Eloquent\Factories\Factory;
use Illuminate\Support\Str;
class BookingFactory extends Factory
{
/**
* The name of the factory's corresponding ... | true |
fe6fe704d7da6ec85c5f81ae4b5452d3df4f8e97 | PHP | bughou/izheko.cn | /grab/run | UTF-8 | 583 | 2.5625 | 3 | [] | no_license | #!/usr/bin/php
<?php
# vim: ft=php
define('APP_ROOT', dirname(__FILE__));
class App
{
static function run_command()
{
ini_set('log_errors', 1);
ini_set('display_errors', 0);
global $argv;
$run = array_shift($argv);
if(!isset($argv[0]) || !($target = $argv[0]))
{... | true |
c73fe7d18da7133ee742132b43aa9ef532bc5e83 | PHP | QortexDevs/facepalm | /src/Facepalm/PostProcessing/AmfProcessor.php | UTF-8 | 4,714 | 2.734375 | 3 | [] | no_license | <?php
/**
* Action-Model-Field (AMF) processor
*/
namespace Facepalm\PostProcessing;
use Facepalm\Cms\CmsCommon;
use Facepalm\Models\ModelFactory;
use Facepalm\Models\Foundation\AbstractEntity;
use Facepalm\PostProcessing\AmfActions\AbstractAction;
use Illuminate\Support\Arr;
use Illuminate\Support\Facades\Session;... | true |
533825cacc89fe0231d107aeb00b527f9fde13e2 | PHP | VikashOraon/Budget-manager | /planDistribution.php | UTF-8 | 7,615 | 2.671875 | 3 | [] | no_license | <?php
include'include/common.php';
//To fetch Budget details
if(isset($_GET['plan_id'])){
$plan_id=$_GET['plan_id'];
}
$datas=array();
$data=array();
$rowIndex=0;
//To check if there are any expenses
$expense="SELECT * FROM expense WHERE pid=$plan_id";
... | true |
4462527727e11881b9bb5d23886d5db4e91a085c | PHP | ArthurPatriot/onvif-ptz-php | /Service/AudioEncoder2Configuration.php | UTF-8 | 2,556 | 2.859375 | 3 | [] | no_license | <?php
class AudioEncoder2Configuration extends ConfigurationEntity
{
/**
* @var string $Encoding
*/
protected $Encoding = null;
/**
* @var MulticastConfiguration $Multicast
*/
protected $Multicast = null;
/**
* @var int $Bitrate
*/
protected $Bitrate = null;
... | true |
e959f346e012707a8e305fe9b2f01ad73a453617 | PHP | beraht/PHP | /杂七杂八/公众号消息推送.PHP | UTF-8 | 7,030 | 2.578125 | 3 | [] | no_license | <?php
// 字符编码
header("Content-Type:text/html; charset=utf-8");
// 微信接口类
class WeChat{
private static $appid;
private static $appsecret;
function __construct(){
self::$appid = ''; // 开发者ID(AppID)
self::$appsecret = ''; // 开发者密码(AppSecret)
}
// 微信授权地址
public... | true |
1a065e668519c96ced0184ad47b22b34592cb7aa | PHP | rashmigandhe/HHMobile | /application/models/User.php | UTF-8 | 5,699 | 2.515625 | 3 | [] | no_license | <?php
class App_Model_User extends Zend_Db_Table
{
protected $_name = "users";
public function addUserModel($data)
{
$is_new="";
$current_date=date("Y-m-d");
try
{
$this->_name='users';
$select = $this->select()->where('email = ?', $data['Email']);
$dup_out = $this->fetchRow($select);
if($du... | true |
19bb615dcbb7eb8e3cad00a00b6ea32879b4ac40 | PHP | aminulemrul/product-api-backend | /app/Http/Controllers/ProductsController.php | UTF-8 | 3,284 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use App\Products;
use Illuminate\Http\Request;
class ProductsController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\Response
*/
public function index()
{
$products = Products::all();
r... | true |
e4e612b40600791e1ab11f255f7cb2fcfd6f522b | PHP | Shamil93/GITshop | /include/loadcart.php | UTF-8 | 1,300 | 2.625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: zhalnin
* Date: 17/08/14
* Time: 16:15
*/
/**
* Обработчик для обновления стоимости и количества товаров
* выводит результат рядом с иконкой корзины
*/
require_once ('DB.php');
require_once ('../utility/getIP.php');
require_once ('../utility/groupPrice.php');
require_onc... | true |
832f5d41bf5469f98ad07b01b997867effa07de8 | PHP | malmax/phplessons | /Lesson07HW/lib/ModelUser.php | UTF-8 | 1,160 | 2.953125 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: malma
* Date: 25.11.2016
* Time: 12:32
*/
/**
* CREATE TABLE IF NOT EXISTS `user` (
`userId` int(11) NOT NULL,
`login` varchar(50) NOT NULL,
`password` varchar(255) NOT NULL,
`name` varchar(100) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
*/
class ModelUser {
publi... | true |
97a4925aabbf289bcb6f5f73bee7e906dd097246 | PHP | gregmag/navplan2 | /src/php/NavplanTest/Traffic/Rest/RestTrafficOgnReadRequestTest.php | UTF-8 | 4,976 | 2.546875 | 3 | [] | no_license | <?php declare(strict_types=1);
namespace NavplanTest\Traffic\Rest;
use InvalidArgumentException;
use Navplan\Geometry\Domain\TimeUnit;
use Navplan\Traffic\Rest\RestTrafficOgnReadRequest;
use PHPUnit\Framework\TestCase;
class RestTrafficOgnReadRequestTest extends TestCase {
private $args;
protected function... | true |
72a208ffc026944da4367d6533da828ba47ac78c | PHP | zfbase/zfe | /library/ZFE/View/Helper/Period.php | UTF-8 | 1,361 | 2.9375 | 3 | [] | no_license | <?php
/*
* ZFE – платформа для построения редакторских интерфейсов.
*/
/**
* Форматировать период.
*/
class ZFE_View_Helper_Period extends Zend_View_Helper_Abstract
{
/**
* Форматировать период.
*
* @param DateTime|string $start
* @param DateTime|string $end
* @param bool $... | true |
599d1642d724ce86f5e44f7ab5c9fb71bbabefbe | PHP | Dezzpil/cards-sort | /src/Debugger.php | UTF-8 | 1,410 | 3.0625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: norlov
* Date: 13.06.18
* Time: 14:05
*/
namespace Src;
class Debugger
{
protected $time;
protected $memory;
protected $verbose;
protected $ps;
public function __construct($verbose = true)
{
$this->verbose = $verbose;
$this->time ... | true |
f8cd2232f5fda2f4b65c2f0de458d4cf0f229372 | PHP | zhongjiacong/2013 | /frame/pager.php | UTF-8 | 1,623 | 3.015625 | 3 | [] | no_license | <?php
class pager {
var $standard_page_num;
var $current_page;
// 总条目数量
var $sum_item;
// 总页数
var $sum_page;
// 参数
var $query_string;
function pager($sum_item) {
$this->standard_page_num = 10;
$this->current_page = ($_GET['page'] == null)?1:$_GET['page'];
$this->sum_item = $sum_item;
... | true |
c7c3fdaafe878cb341080116b3d394aa01bbe80d | PHP | michaelalvin/tip-calculator | /tipcalculator.php | UTF-8 | 2,630 | 2.703125 | 3 | [
"Apache-2.0"
] | permissive | <html>
<head>
<title>Welcome</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body background = "back.jpg"; background-size: 80px 60px;
background-repeat: no-repeat;>
<div id = "pagewrap">
<h2>Tip Calculator</h2>
<form action= 'tipcalculator.php' method='post'>
<p>Bill amount: ... | true |
2edd0721cb264e240a5f75a3df4b3ac4f9c7d8e7 | PHP | isha1111/tiny_url | /app/Models/TinyUrl.php | UTF-8 | 3,756 | 3 | 3 | [] | no_license | <?php
namespace App\Models;
use Carbon\Carbon;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class TinyUrl extends Model
{
use HasFactory;
/**
* Constructs the class
*/
public function __construct() {
}
/**
* Get tinyUrl from longU... | true |
8c67e555c50afd8c0eac9c04e08bf0930e18c887 | PHP | onursimsek/payuclient | /src/Payu/Builder/SellerRequestBuilder.php | UTF-8 | 844 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
namespace Payu\Builder;
use Payu\Component\Seller;
use Payu\Request\SellerRequest;
use Payu\Serializer\SellerRequestSerializer;
use Payu\Validator\SellerRequestValidator;
class SellerRequestBuilder extends BuilderAbstract
{
protected $seller;
/**
* @param Seller $seller
*
* @return $thi... | true |
b7092ed243b7ba1ad0a4125fbdd67f9b86540dcf | PHP | cyrielleC/test-grading-system | /symfony/src/Entity/Grade.php | UTF-8 | 1,400 | 2.578125 | 3 | [] | no_license | <?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass="App\Repository\GradeRepository")
* @ORM\Table(indexes={@ORM\Index(name="subject", columns={"subject"}),@ORM\Index(name="mark", columns={"mark"})})
*/
class Grade
{
/**
* @ORM\Id()
* @ORM\GeneratedValue()
... | true |
df16f6cd81b0108ce9020382efc9055a5419b7ad | PHP | tlan16/Sign_Cube | /core/main/entity/3rdparty/ThirdPartyWordVideo.php | UTF-8 | 2,368 | 2.890625 | 3 | [] | no_license | <?php
/**
* Third Party Word-Video Relationship Entity
*
* @package Core
* @subpackage Entity
* @author lhe<helin16@gmail.com>
*/
class ThirdPartyWordVideo extends BaseEntityAbstract
{
/**
* The ThirdPartyWord of the ThirdPartyVideo
*
* @var ThirdPartyWord
*/
protected $thirdParty... | true |
674a71c1ba8af2baa1a24779d67adc3501232774 | PHP | Saryanto1983/uas_aplikasi_inventaris | /application/controllers/Merk.php | UTF-8 | 8,063 | 2.53125 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
if (!defined('BASEPATH')) exit('No direct script access allowed');
// Deklarasi pembuatan class Merk
class Merk extends CI_Controller
{
// Konstrutor
function __construct()
{
parent::__construct();
$this->load->model('MerkModel'); // Memanggil MerkModel yang terdapat pada models
... | true |
94344eafd9a1fba51fdf67440e2f9ca7d0fe83c2 | PHP | dracul-aid/PhpMocker | /tests/Managers/ClassManagerTest.php | UTF-8 | 9,398 | 2.71875 | 3 | [
"Apache-2.0"
] | permissive | <?php
namespace DraculAid\PhpMocker\tests\Managers;
use DraculAid\PhpMocker\Creator\SoftMocker;
use DraculAid\PhpMocker\Managers\ClassManager;
use DraculAid\PhpMocker\Managers\MethodManager;
use DraculAid\PhpMocker\Managers\ObjectManager;
use DraculAid\PhpMocker\Reader\ReflectionReader;
use PHPUnit\Framework\TestCase... | true |
03753b78cca1f2b7965177a79b4da81b2e2112d0 | PHP | bilardi/hashcode | /2016/preparation/painting.php | UTF-8 | 8,286 | 2.84375 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
$lines = file('./logo.in');
list($rows, $cols) = explode(" ", $lines[0]);
unset($lines[0]);
$m = array();
foreach($lines as $line){
$line = trim($line);
$m[] = str_split($line);
}
// how many horizontal lines?
$hlines = array();
$hline = 0;
$hstart = 0;
for($i=0;$i<$rows;$i++){
for($j=0;$j<$cols;$j++){
if... | true |
7367030c4139028384ff56c16fba4581d1a49289 | PHP | savalonso/SIGE | /data/dtProducto.php | UTF-8 | 767 | 2.875 | 3 | [] | no_license | <?php
include_once("dtConnection.php");
class dtProducto{
public function dtProducto(){}
public function obtenerProductos(){
include_once("../../dominio/dProducto.php");
$conec = new dtConnection;
$listaProducto = array();
if($conec->conect() == true){
$query = "SELECT * FROM tbproducto";
$resultado... | true |
450a7bde96f28dfe662b244a9460dac50648cfe4 | PHP | a354123417/duckchat-plugin | /RedPacket/lib/wpf/Wpf_Controller.php | UTF-8 | 1,192 | 2.640625 | 3 | [] | no_license | <?php
abstract class Wpf_Controller {
protected $ctx;
public function __construct(Wpf_Ctx $context) {
$this->ctx = $context;
}
public function doIndex() {
}
public function response($data=array(), $errorCode=0, $errorInfo="") {
$output = array(
'errorCode' => $errorCode,
'errorInfo' => $errorInf... | true |
d9d4ffaea801e48d530860574f39c4f1d9a0523b | PHP | yashpathak19/recipe-bank | /addNewsletter.php | UTF-8 | 2,805 | 2.625 | 3 | [] | no_license | <?php
require_once 'Newsletter.php';
require_once 'database/database.php';
$subjecterr = $bodyerr = "";
$subject = $body = "";
if(isset($_POST['addletter'])) {
//validating the subject input
if(empty($_POST['subject'])){
$subjecterr = "Please enter the subject.";
}
else{
$subject = $_POST['subject... | true |