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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
8e8abfcebf7e84e4d426a1c31d14ecf40ec67de2 | PHP | stain92/codesend | /Proba/Services/CategoriesServices3.php | UTF-8 | 527 | 2.8125 | 3 | [] | no_license | <?php
namespace Services;
use Repository\CategoriesRepository3;
class CategoriesServices3
{
/**
* @var CategoriesRepository3
*/
private $category_services;
/**
* CategoriesServices3 constructor.
* @param CategoriesRepository3 $category_services
*/
public function __constru... | true |
f69ca7c8c894413f49fec0b60e8b63394503d00c | PHP | zhenja-ulchak/-Training-of-OOP | /date.php | UTF-8 | 3,272 | 3.453125 | 3 | [] | no_license | <?php
class Datee
{
public $date = null;
public function __construct ($date = null)
{
$this->date = $date;
if ($this->date == '') {
echo date('Y-m-d');
}
}
public function getDate()
{
$date = $this->date;
$d... | true |
ff5e650e4cdfaba6d8192eb68c47c8d2f4fb9de4 | PHP | baagee/sql-profiling | /app/Action/Page/OnlineResultPage.php | UTF-8 | 783 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php
/**
* Desc:
* User: baagee
* Date: 2019/10/26
* Time: 21:44
*/
namespace App\Action\Page;
use App\Service\DataService;
use BaAGee\NkNkn\Base\ActionAbstract;
/**
* Class OnlineResultPage
* @package App\Action\Page
*/
class OnlineResultPage extends ActionAbstract
{
/**
* @var array
*/
p... | true |
70182b7df06762b525c298dc81bd908f321c0c68 | PHP | yitec/SICCALIFORNIA | /operaciones/Clase_Clientes.php | UTF-8 | 3,607 | 2.671875 | 3 | [] | no_license | <?
session_start();
require_once('../cnx/conexion.php');
conectar();
$hoy=date("Y-m-d H:i:s");
/*****************************************************************************************************************
Accion:Ejecuta todas las operaciones sobre expedientes
Parametros: Vector con lista de parametros segun metodo... | true |
93596e0fc64d553fb5fb484935f60f0bda35866c | PHP | rsesek/hoplite | /testing/test_listener.php | UTF-8 | 9,341 | 2.59375 | 3 | [] | no_license | <?php
// Hoplite
// Copyright (c) 2011 Blue Static
//
// This program is free software: you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation, either version 3 of the License, or any later version.
//
// This program is distributed ... | true |
d7db91f5fb2af0ea22bf8c2ab044d6137bb54937 | PHP | silenttech9/lesoscm | /frontend/models/EventInvitation.php | UTF-8 | 1,491 | 2.53125 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
namespace frontend\models;
use Yii;
/**
* This is the model class for table "event_invitation".
*
* @property integer $id
* @property string $company_name
* @property string $address_1
* @property string $address_2
* @property string $address_3
* @property string $state
* @property string $email
* @p... | true |
8615d386e928abb8795e45c4a21c4c0a84100f2b | PHP | siterun/content_efile | /az_prog/Oops/Inheritance/hierarchy.php | UTF-8 | 1,053 | 3.84375 | 4 | [] | no_license | <?php
/* Hierarchy inheritance means we can access the same class i.e. Father class from the different classes i.e. Younger class and Elder class which means that now Elder class and Younger class possesses power of calling or use of all the properties and methods of the Father class but depends on the access modifiers... | true |
f46278d582030ac47bc23df97046d61e2f6b4172 | PHP | ricardosierra/changelog | /tests/unit/Renderer/JsonTest.php | UTF-8 | 1,374 | 2.71875 | 3 | [
"MIT"
] | permissive | <?php
/**
* PHP Version 5.6
* @category Library
* @package ChangeLog
* @author Steve "uru" West <steve.david.west@gmail.com>
* @license MIT http://opensource.org/licenses/MIT
* @link https://github.com/emlynwest/changelog
*/
namespace ChangeLog\Renderer;
use ChangeLog\Log;
use ChangeLog\Release;
use Codeceptio... | true |
3439ae75754426a6ab3e5014e9ed4444bdb53951 | PHP | Rakoto001/EdabitAlgoLevelDifficult | /Brick.php | UTF-8 | 598 | 3.765625 | 4 | [] | no_license | <?php
class Prime{
public function isPrime($_number)
{
for( $n = 2; $n<$_number; $n++){
if($_number % $n == 0){
return false;
}else{
return true;
}
}
}
public function detectPrime($_numberGiven)
{
... | true |
3f2f233379dc76b57abc6de66df45304949b549c | PHP | linjie4387/smpss | /app/m/deliverywithman.class.php | UTF-8 | 5,809 | 2.546875 | 3 | [
"BSD-3-Clause",
"BSD-2-Clause"
] | permissive | <?php
/**
* 发车送货员表数据模型
* @author mol
*/
class m_deliverywithman extends base_m {
public function primarykey() {
return 'withman_id';
}
public function tableName() {
return base_Constant::TABLE_PREFIX . 'deliverywithman';
}
public function relations() {
return array();
}
public function ge... | true |
28e6c9b278707e0c702bd093b070c9ab350f942c | PHP | AndreaCasentini93/laravel-boolpress | /database/seeds/PostsTableSeeder.php | UTF-8 | 561 | 2.75 | 3 | [
"MIT"
] | permissive | <?php
use Illuminate\Database\Seeder;
use Illuminate\Support\Str;
use Faker\Generator as Faker;
use App\Post;
class PostsTableSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run(Faker $faker)
{
for($i = 0; $i < 10; $i++) {
$... | true |
c217c50d2cb5011d819db7fdebdb086dae959fa0 | PHP | stromblom/OpenDominion | /src/Services/Analytics/AnalyticsEvent.php | UTF-8 | 1,173 | 3.234375 | 3 | [
"MIT"
] | permissive | <?php
namespace OpenDominion\Services\Analytics;
class AnalyticsEvent
{
/** @var string */
protected $category;
/** @var string */
protected $action;
/** @var string */
protected $label;
/** @var int */
protected $value;
/**
* AnalyticsEvent constructor.
*
* @par... | true |
ac0afc0c72c290f96dcf28886c8bbe5e571bd6a3 | PHP | vladimalldogx/stestCapstone42-2020 | /student/quiz.php | UTF-8 | 7,116 | 2.515625 | 3 | [] | no_license | <?php
require_once("connection.php");
$error_message = "";
$error = false;
$id = "";
$quemain = "";
$queopt1 = "";
$queopt2 = "";
$queopt3 = "";
$queopt4 = "";
$queans = "";
$html = "";
if(isset($_POST['btnadd'])){
... | true |
bffee1f7cacbfd33d8d9b39a406167ef13c7a324 | PHP | randi2kewl/CFLocator | /php/app.php | UTF-8 | 1,932 | 2.96875 | 3 | [
"MIT"
] | permissive | <?php
include 'db_credentials.php';
date_default_timezone_set('UTC');
ini_set("log_errors", 1);
function getLocs()
{
try
{
$db = new PDO(
'mysql:host='.HOST.';dbname='.DBNAME,
USERNAME,
PASSWORD,
array
(
PDO::ATTR_EMULATE... | true |
80f431fc9eda7ba35e2eeac43c9b895886b896a9 | PHP | JoseCastro907/virtual_forest | /puntuaciones.php | UTF-8 | 4,128 | 2.546875 | 3 | [] | no_license | <?Php
session_start();
if (!isset($_SESSION['user'])) {
header('Location: index.php');
exit;
}else{
$user = $_SESSION['user'];
}
require './database.php';
$usuarios=$database->select("usuario","nombre", [
"ORDER" => [
"puntos" => "DESC"
]
]);
$puntajes=$database->select("usuario","puntos", [
"ORDER" =>... | true |
ed6a5643203dda0f0bd92a74ad15c2d6b777d05a | PHP | Jindequan/aapf | /src/Constants/BaseConstants.php | UTF-8 | 686 | 2.859375 | 3 | [] | no_license | <?php
namespace AF\Constants;
class BaseConstants
{
private static $arrayName = '';
public static function from($arrayName = 'all')
{
self::$arrayName = $arrayName;
return new static();
}
public function getValue($k, $default = '')
{
$array_name = self::$arrayName;
... | true |
ae277b9136b4dd6babb51d7cc7466564c5af3797 | PHP | bcuper/strona | /wyslijponownie.php | UTF-8 | 648 | 2.515625 | 3 | [] | no_license | <?php
include 'funkcje.php';
if (isset($_POST['login']) || isset($_POST['haslo'])) {
//gdy przeslano login i haslo
$login = $_POST['login'];
$haslo = md5($_POST['haslo']);
$temp = bd()->prepare('SELECT imie, nazwisko, mail, hash FROM uzytkownicy WHERE login = :login AND haslo = :haslo');
$temp->bin... | true |
0febd8dd581ed24c2af4339bba4df2e3b7183f1a | PHP | ashifa454/Openion | /control/livesearch.php | UTF-8 | 1,851 | 2.609375 | 3 | [] | no_license | <?php
$xmlDoc=new DOMDocument();
$xmlDoc->load("../assets/Raw/links.xml");
$x=$xmlDoc->getElementsByTagName('link');
//get the q parameter from URL
$q=$_GET["q"];
//lookup all links from the xml file if length of q>0
if (strlen($q)>0) {
$hint="";
$hint="<h6>Suggestion</h6>";
for($i=0; $i<3; $i++) {
$y=$x->ite... | true |
9e90d18a497873a1cea6169763d3508f5a7e57a7 | PHP | LegendOfTheFox/ProgrammingJava | /delete-admin.php | UTF-8 | 923 | 2.671875 | 3 | [] | no_license | <?php
//<!--interupt the page loading so it can be redirected-->
ob_start();
//auth check
require_once('auth.php');
// capture the selected page_id from the url and store it in a variable with the same name
$user_id = $_GET['user_id'];
try{
// connect
require_once('db.php');
... | true |
64a5c36f25997c7aef9bc62ad74837a8eff2e9fb | PHP | mum-project/mum | /app/Rules/OwnPassword.php | UTF-8 | 808 | 2.6875 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
namespace App\Rules;
use Illuminate\Contracts\Validation\Rule;
use Illuminate\Support\Facades\Auth;
use function trans;
class OwnPassword implements Rule
{
/**
* Create a new rule instance.
*
* @return void
*/
public function __construct()
{
//
}
/**
* Dete... | true |
741ad98aba780c5000a81817932c9939f24e440a | PHP | Anton-Koval/PRR-new | /src/ECG/Action/DatabaseRoleAction.php | UTF-8 | 939 | 2.90625 | 3 | [] | no_license | <?php
namespace ECG\Action;
use Symfony\Component\Console\Helper\Table;
class DatabaseRoleAction extends AbstractCommandAction implements ActionInterface
{
/**
* Execute "application" role action.
*
* @return void
*/
public function execute()
{
/*
* Render tables for ... | true |
72e6b0c7e7ea9b20c6df21ee2f25bed18545ca9d | PHP | citrus-framework/framework | /old/src/Mail/Header/Item.class.php | UTF-8 | 3,846 | 2.625 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
/**
* @copyright Copyright 2020, CitrusFramework. All Rights Reserved.
* @author take64 <take64@citrus.tk>
* @license http://www.citrus.tk/
*/
namespace Citrus\Mail\Header;
use Citrus\Variable\Structs;
use stdClass;
/**
* メールヘッダーアイテム
*/
class Item
{
use Structs;
... | true |
17274c4249ad5b1113d1e033a93b8a28eb983702 | PHP | Danyels0310/recuperacionPHP | /videoclub/funciones.php | UTF-8 | 1,397 | 2.578125 | 3 | [] | no_license | <?php
function nombrecliente($conn ,$sesion){
$select_value="SELECT first_name, last_name FROM customer where customer_id=$sesion";
$idk3=mysqli_query($conn,$select_value);
$fila3=mysqli_fetch_assoc($idk3);
$nombre=$fila3['first_name'];
$apellido=$fila3['last_name'];
$n=$nombre." ".$apellido;
return $... | true |
8d61b3632d9ab4f1029c206574c33a55f4c193a6 | PHP | ghostong/LiMsDemo | /Schedule.php | UTF-8 | 1,107 | 3 | 3 | [] | no_license | <?php
/**
* LitMs 定时任务
*/
//每300秒执行一次非阻塞
//Lit\Ms\LitMsSchedule::every(300,function(){
// echo "every 300 second \n";
//},"MyEvent");
//每200秒执行一次阻塞
//Lit\Ms\LitMsSchedule::loop(200,function(){
// echo "loop 200 second \n";
//},"MyLoop");
//启动后10秒执行一次
//Lit\Ms\LitMsSchedule::after( 10, function (){
// echo... | true |
0a15a69ebb241bd88c96c634c41c26341fe3fee7 | PHP | rkkadam818/multiplication-program | /src/multiplication.php | UTF-8 | 321 | 2.984375 | 3 | [] | no_license | <?php
namespace rkadam01\Multiplication;
/**
*
*/
class Multiplication
{
public function getMultiplication( $data ) {
echo "here";
$firstElement = array_shift($data);
if( false == ctype_digit(implode('',$data))){
return 'Please enter the valid parameters.';
} else {
return array_sum($data);
}
}
}
?... | true |
075ec7ad1d7f77a434ec960951847d80ff8b006f | PHP | prosperos/cogniance-techtalk-php-5.5 | /2-finally/3-nested-throwing-and-finally.php | UTF-8 | 419 | 3.671875 | 4 | [] | no_license | <?php
/**
* Representation of nested throwing/catching/finally calls.
*/
try {
try {
throw new Exception('first exception called');
} catch (Exception $e) {
echo 'first catch' . PHP_EOL;
throw $e;
} finally {
echo 'first finally' . PHP_EOL;
}
} catch (Exception $e) {
... | true |
470e2b24288e3c568f713344cda86cf026d09527 | PHP | fahmifayyadh/WaterChecker-Api | /app/Http/Controllers/DataController.php | UTF-8 | 927 | 2.546875 | 3 | [] | no_license | <?php
namespace App\Http\Controllers;
use App\Data;
use Illuminate\Http\Request;
class DataController extends Controller
{
public function index(){
$data = Data::all();
return response($data);
}
public function show($id){
$data = Data::where('id',$id)->get();
return respons... | true |
1cddbcaf4d5b8fca171bb21d747b3e1d42b13a43 | PHP | Pikerstrow/east_medecine_center | /admin_panel/includes_admin/view_all_news.php | UTF-8 | 4,679 | 2.609375 | 3 | [] | no_license | <?php
use Clinic\Classes\News;
/*Delete news section*/
if ($request->has(['delete_news', 'token'])) {
$news_id = $request->getStringParam('delete_news', true, true);
$token = $request->getStringParam('token');
if ($token != $session->getId()) {
redirect('../login.php');
} else {
$news = New... | true |
2014a90549523281220b25fb71cc35ea5d51292e | PHP | LailyAkter/student_information | /app/Http/Controllers/Admin/CourseController.php | UTF-8 | 2,396 | 2.578125 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers\Admin;
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use App\Course;
use Response;
class CourseController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\Response
*/
public function index()... | true |
2b96ab25672996ec47e35c091aea5110845a7b3d | PHP | ksmistry1991/allegro-api | /src/Soap/Types/doSetFreeDeliveryAmountResponse.php | UTF-8 | 724 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
namespace Ircykk\AllegroApi;
class doSetFreeDeliveryAmountResponse
{
/**
* @var boolean $responseStatus
*/
protected $responseStatus = null;
/**
* @param boolean $responseStatus
*/
public function __construct($responseStatus = null)
{
$this->responseStatus = $resp... | true |
315b2535ed3453d56b3d115f229373f823018689 | PHP | garcanm8852/Cliente | /Ejercicios/Ejercicios_PHP/PHP/pizzeria.php | UTF-8 | 1,897 | 2.9375 | 3 | [] | no_license | <html>
<head>
<title>Problema</title>
</head>
<body>
<?php
$cantidadJamon = $_REQUEST['cantjamonqueso'];
$CantidadNapo = $_REQUEST['cantnapolitana'];
$CantidadMuza = $_REQUEST["cantmuzzarella"];
$precioJamon = ($CantidadNapo * 4.75);
$precioNapo = ($CantidadNapo * 5.25);
$precioMuza =... | true |
90860d47a7f586b7d57adaa2a5210fcefd1d5f5e | PHP | smarthomeblogger/Smarthome-Server | /scenes/getScenes.php | UTF-8 | 859 | 3.21875 | 3 | [] | no_license | <?php
function getScenes($room, $db){
//Szenen aus Datenbank laden
//INFO: Es werden alle Szenen abgefragt, die entweder dem Raum des Parameters $room oder dem Raum 'NONE' zugewiesen sind
$results = $db->prepare("SELECT * FROM 'SCENES' WHERE ROOM == :room OR ROOM == 'NONE'");
$results->execute(array('room' => $ro... | true |
04b749a177942871acd1e6a8792e280106eecbdc | PHP | Orclyx/php-fedex-api-wrapper | /src/FedEx/CloseService/ComplexType/CloseSmartPostDetail.php | UTF-8 | 2,681 | 2.6875 | 3 | [] | no_license | <?php
namespace FedEx\CloseService\ComplexType;
use FedEx\AbstractComplexType;
/**
* CloseSmartPostDetail
*
* @author Jeremy Dunn <jeremy@jsdunn.info>
* @package PHP FedEx API wrapper
* @subpackage Close Service
*/
class CloseSmartPostDetail
extends AbstractComplexType
{
/**
* Name of th... | true |
887a7df604b4db7d20a3d871a0338d3036d90180 | PHP | devsavage/slim-3-demo-app | /app/Savage/Http/Filters/BasicFilter.php | UTF-8 | 552 | 2.6875 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
namespace Savage\Http\Filters;
use Slim\App as Site;
class BasicFilter
{
protected $site;
protected $json;
public function __construct($site, $json = false) {
$this->site = $site;
$this->json = $json;
}
protected function getContainer() {
return $this->site->getCont... | true |
f1305063e48828cb51391dd3242859eaddc8c5e8 | PHP | andrecurvello/armwebstation | /www/php/testes.php | UTF-8 | 2,568 | 3.015625 | 3 | [] | no_license | <?php
//modo mais dificil esse mundo de echo...
// concentrar scripts php e facilitar a vida com html/js!
echo "<html>";
echo "<head>";
echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\"/s>";
echo "</head>";
echo "<body>";
/*
echo "<script type=\"text/javascript\">
var digital = new Date()... | true |
3d2f335403c56df6137e2e29b25d2e8e11d3d797 | PHP | vincseize/Slim3-Boilerplate | /src/models/Connect.php | UTF-8 | 1,849 | 3.234375 | 3 | [
"MIT"
] | permissive | <?php
/**
*
* @author jul.mora
*
*/
class Connect
{
private $connection = null;
private $credentials = null;
function __construct()
{
$this->initCredentials();
}
function initCredentials()
{
global $settings;
$this->credentials = $settings['settings']['db'];
}
function _... | true |
a170fc46d68c88b5a22cd8fc263ecb706237d35a | PHP | TristanLemire/tp_php_tristan | /src/Service/GeoApi.php | UTF-8 | 1,098 | 2.640625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Service;
use Symfony\Component\GuzzleHttp\Client;
class GeoApi
{
public function getCommune($cityName,$postalcode): array
{
$client = new \GuzzleHttp\Client();
if($cityName === ""){
$uri = "https://geo.api.gouv.fr/communes?codePostal=".$postalcode."&fields=nom,... | true |
b1971b4b395813551663f381030585d005020350 | PHP | molegame/molesdk-pro | /app/Models/Game/Channel.php | UTF-8 | 1,346 | 2.515625 | 3 | [] | no_license | <?php
namespace App\Models\Game;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Arr;
class Channel extends Model
{
/**
* Indicates if the IDs are auto-incrementing.
*
* @var bool
*/
public $incrementing = false;
/**
* The table associated with the model.
*
... | true |
25384e1c74fa35c54371ed17d2a6758fa829a890 | PHP | se364/week5 | /index.php | UTF-8 | 687 | 2.59375 | 3 | [] | no_license | <?php
/*
* Shah Emran
* 4/17/2020
*
*/
//Turn on error reporting -- this is critical!
ini_set('display_errors', 1);
error_reporting(E_ALL);
//Require the autoload file
require_once("vendor/autoload.php");
// Create an instance of the Base Class
$f3 = Base::instance();
// Define a default rout... | true |
15583344652176e5d65f2054509313f35f1ed7eb | PHP | Artaped/Boardroom | /src/controllers/Controller.php | UTF-8 | 774 | 2.84375 | 3 | [] | no_license | <?php
namespace App\controllers;
class Controller
{
/**
* @param String $input
* @return string after clean
*/
public function sanitizeOne($input)
{
return htmlspecialchars(trim($input));
}
/**
* @param array $array
* @return array after clean
*/
publi... | true |
9fb60e2ee07383d95a5fb70782eae797dde656e3 | PHP | Edilson-DEV/TallerdeBase | /Vista/Conexion.php | UTF-8 | 634 | 3 | 3 | [
"MIT"
] | permissive | <?php
/**
* Clase de conexion a la DB
*/
class Conexion extends PDO
{
private $tipoDB = 'mysql';
private $servidor = 'localhost';
private $user = 'root';
private $password = '';
private $db = 'elecciones';
public function __construct()
{
try {
parent::__construct($this... | true |
ddf5ecfbbcade63a13f2982bd453eded531b8efb | PHP | MrAntoine/LibWav-2.0 | /vues/Signalement/Signalements_List.php | UTF-8 | 2,736 | 3.015625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: Antoine
* Date: 17/01/2019
* Time: 20:36
*/
$autorisation = false;
if (isset($_SESSION["id"])) {
$role = getUserInfo($_SESSION["id"])['statut'];
if ($role >= roleUser("admin")) {
$autorisation = true;
}
}
if ($autorisation === true) {
// Affichage de... | true |
1cf6777f56f19a36c88e6bb8b737211ce6dc464f | PHP | nicolas-devynck/nicolas-devynck | /php/mail.php | UTF-8 | 3,194 | 3.046875 | 3 | [] | no_license | <?php
// paramètre
$to = 'info@nicolas-devynck.fr'; // Destinataire
$headMsg = 'vous a envoyer un message depuis votre CV'; // Tete du message
// on passe les $_POST dans des variables, avec addslashes pour les champs qui n'on pas de paterne (on c'est jamais) et wordwrap qui ajoute un retour de ligne tout les 70 ca... | true |
8b8b39040cc6f7735c27d379746b59638f693c4f | PHP | apps-selusin/pembayaran6 | /v01_siswarutinmaster.php | UTF-8 | 3,621 | 2.515625 | 3 | [] | no_license | <?php
// id
// siswa_id
// nis
// nama
// rutin_id
// tahunajaran_id
// nilai
// total
?>
<?php if ($v01_siswarutin->Visible) { ?>
<!-- <h4 class="ewMasterCaption"><?php echo $v01_siswarutin->TableCaption() ?></h4> -->
<table id="tbl_v01_siswarutinmaster" class="table table-bordered table-striped ewViewTable">
<?php ... | true |
91793f47b7c802ba88cebce97c89005a60d24619 | PHP | HumanReborn/humanReborn | /src/EIP/HRBundle/Entity/HRUnit.php | UTF-8 | 3,028 | 2.65625 | 3 | [] | no_license | <?php
namespace EIP\HRBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* \class HRUnit
* \brief Unit entity, contained in an army
*
* \cond @ORM\Table(name="units") \endcond
* \cond @ORM\Entity(repositoryClass="EIP\HRBundle\Entity\HRUnitRepository") \endcond
*/
class HRUnit
{
/**
* \cond @ORM\Colum... | true |
8a436904ec36a6706e68d0ab682ade277388fd63 | PHP | Hrachya777/social-blog | /app/Http/Requests/user/UserUpdatePasswordRequest.php | UTF-8 | 1,014 | 2.625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Requests\user;
use Illuminate\Foundation\Http\FormRequest;
class UserUpdatePasswordRequest extends FormRequest
{
/**
* Determine if the user is authorized to make this request.
*
* @return bool
*/
public function authorize()
{
return true;
}
/... | true |
d16fba44d3b7f7b896dca2bf60802e27bc24d825 | PHP | dierickd/CV_PHP | /public/traitement/send.php | UTF-8 | 706 | 2.796875 | 3 | [] | no_license | <?php
session_start();
$postSecure = [];
$error = [];
foreach ($_POST as $key => $value) {
$postSecure[$key] = trim($value);
}
if (empty($postSecure['name'])) {
$error['name'] = 'Votre nom n\'est pas valide';
}
if (empty($postSecure['email']) || !filter_var($postSecure['email'], FILTER_VALIDATE_EMAIL)) {
... | true |
874abff00d21b00cca01869b0643f756e3df1ad8 | PHP | TobyMellor/compress | /server/app/Article.php | UTF-8 | 1,136 | 2.734375 | 3 | [] | no_license | <?php
namespace App;
use Illuminate\Database\Eloquent\Model;
use Carbon\Carbon;
class Article extends Model
{
protected $table = 'article';
public $timestamps = false;
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'title',
... | true |
5879d37fbbf72759d9e78750837c50652593ba3b | PHP | imtms/DHL-SOAP-3.0 | /app/DHL/ServiceconfigurationUnfree.php | UTF-8 | 1,726 | 2.703125 | 3 | [] | no_license | <?php
namespace App\DHL;
class ServiceconfigurationUnfree
{
/**
* @var anonymous192 $active
*/
protected $active = null;
/**
* @var anonymous193 $PaymentType
*/
protected $PaymentType = null;
/**
* @var anonymous194 $CustomerNumber
*/
protected $CustomerNumber ... | true |
0e53edb362544254d6c43d8719ff5933fa7a4dc7 | PHP | vs-project-management-system/addressing | /Model/Zone.php | UTF-8 | 1,037 | 2.703125 | 3 | [] | no_license | <?php
namespace PMS\Component\Addressing\Model;
class Zone implements \PMS\Component\Interfaces\ZoneInterface
{
protected $name;
protected $country;
protected $code;
protected $locale;
public function getName()
{
return $this->name;
}
public function set... | true |
13279aeaaceb5115fe5124f202c515a824dd47df | PHP | LeonardoCor/LeoCor | /src/Exception/Data/NotAString.php | UTF-8 | 1,387 | 2.75 | 3 | [] | no_license | <?php
/*
* Copyright (C) 2019 Leonardo Corazzi <leonardo.corazzi@outlook.it>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any la... | true |
6d57eb08efee51e65b14080d591e1ddd3f7f404e | PHP | alfred-nutile-inc/fixturizer | /tests/FixturizerTest.php | UTF-8 | 3,680 | 2.640625 | 3 | [] | no_license | <?php namespace AlfredNutileInc\Tests;
use AlfredNutileInc\Fixturizer\Reader;
use AlfredNutileInc\Fixturizer\Writer;
use PHPUnit_Framework_TestCase;
class FixturizerTest extends PHPUnit_Framework_TestCase {
/**
* @test
*/
public function should_save_as_yaml()
{
$this->cleanUpFile();
... | true |
6a5702ea6b7eee0a148f5bf5fe9c9f82a51a4bf2 | PHP | allflame/vain-core | /src/Config/Data/Handler/AbstractHandler.php | UTF-8 | 1,001 | 2.8125 | 3 | [] | no_license | <?php
/**
* Vain Framework
*
* PHP Version 7
*
* @package vain-config
* @license https://opensource.org/licenses/MIT MIT License
* @link https://github.com/allflame/vain-config
*/
declare(strict_types = 1);
namespace Vain\Core\Config\Data\Handler;
/**
* Class AbstractHandler
*
* @author Taras P. G... | true |
bc2dbcf2b984e64074cc07205f76e4229ab462c2 | PHP | turbovitalik/rest | /api/v1/src/controllers/JsonController.php | UTF-8 | 684 | 2.828125 | 3 | [] | no_license | <?php
namespace Rest\Controllers;
use Pimple\Container;
use Rest\views\JsonView;
class JsonController
{
/**
* @var Container
*/
protected $container;
/**
* @var JsonView
*/
protected $view;
/**
* @param $serviceId string
* @return mixed
*/
public function ... | true |
3019ef5bd3485bb67cf657e92f35ba297d81f70b | PHP | jsoby/mediawiki-trunk-extensions | /FlaggedRevs/maintenance/flagToSemiProtect.php | UTF-8 | 4,667 | 2.6875 | 3 | [] | no_license | <?php
/**
* @ingroup Maintenance
*/
if ( getenv( 'MW_INSTALL_PATH' ) ) {
$IP = getenv( 'MW_INSTALL_PATH' );
} else {
$IP = dirname(__FILE__).'/../../..';
}
require_once( "$IP/maintenance/Maintenance.php" );
class FlagProtectToSemiProtect extends Maintenance {
public function __construct() {
$this->mDescriptio... | true |
46f8a146f72a41596a1ec9e03b0f0d656946cfa0 | PHP | SelinaDressoe/uni | /dbi/cw2/views/trackForm.php | UTF-8 | 1,193 | 2.515625 | 3 | [] | no_license | <?php require 'views/header.php'; global $params; ?>
<h1><?php echo PAGE_TITLE; ?></h1>
<form id="details" method="post" action="/tracks/<?php echo EDIT? 'edit' : 'add'; ?> ">
<label>Title
<input maxlength="100" id="name" name="Title"
<?php if ( EDIT ) echo ' value="'. $params['Title'] .'"'; ?>
req... | true |
8020a115747555791b173c46436ffdd5f3093c34 | PHP | elbgoods/nova-address-field | /src/NovaAddressField.php | UTF-8 | 3,136 | 2.65625 | 3 | [] | no_license | <?php
namespace Elbgoods\NovaAddressField;
use Elbgoods\LaravelAddressable\Models\Address;
use Laravel\Nova\Fields\Field;
use Laravel\Nova\Http\Requests\NovaRequest;
class NovaAddressField extends Field
{
/**
* The field's component.
*
* @var string
*/
public $component = 'nova-address-fi... | true |
d3027a55553782fd06552f410f8c6d8e46764633 | PHP | hongker/Blog | /apps/core/operations/CommentOperation.php | UTF-8 | 2,964 | 2.953125 | 3 | [] | no_license | <?php
namespace Blog\Operations;
use Blog\Models\Comments;
/**
* 评论操作类
* @author hongker
* @version 1.0
*/
class CommentOperation extends BaseOperation implements Operation {
public function __construct($di) {
parent::__construct($di);
}
/**
* 根据id获取评论信息
* @param int $id
* @return ... | true |
8796f92e8e1b21ec27953a7e4fb12ae7c8e56f8a | PHP | ligang1109/yueyue | /route/general.php | UTF-8 | 1,757 | 2.59375 | 3 | [] | no_license | <?php
/**
* @file general.php
* @brief general route use tradition controller action, e.g. /controller/action
* @author ligang
* @version 1.0
* @date 2014-10-30
*/
namespace YueYue\Route;
class General extends \YueYue\Route\Base
{/*{{{*/
const DEF_CONTROLLER = 'index';
const DEF_ACTION = 'index';
pr... | true |
d05fd26fe08057dd1c7effce136857ea1cd9a9ab | PHP | liuchen-0109/teacher-Choose | /app/Teacher.php | UTF-8 | 1,070 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
namespace App;
class Teacher extends Model
{
protected $table = 'teacher';
public function getCampus()
{
return $this->belongsTo(\App\Campus::class, 'campus', 'id');
}
public function getSubject()
{
return $this->hasMany(\App\SubjectRelation::class,'teacher_id','id');
... | true |
ac6a5d52d8c34c4aed14e0bbea0a5b25cd78cd16 | PHP | codeforest/wp-rest-starter | /src/Core/Route/Route.php | UTF-8 | 1,293 | 3.0625 | 3 | [
"MIT"
] | permissive | <?php # -*- coding: utf-8 -*-
declare( strict_types = 1 );
namespace Inpsyde\WPRESTStarter\Core\Route;
use Inpsyde\WPRESTStarter\Common;
/**
* Route implementation using the route options data type.
*
* @package Inpsyde\WPRESTStarter\Core\Route
* @since 1.0.0
* @since 2.0.0 Made the class final.
*/
final ... | true |
5c6e7b95824a0d0cd3a8b883f13b80513e8687e0 | PHP | jhankee/leagueTracker | /team/getTeamInfo2.php | UTF-8 | 1,510 | 2.53125 | 3 | [] | no_license | <!DOCTYPE html>
<html>
<head>
<title>Baseball Team Information</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css">
</head>
<body>
<div style="text-align:center">
<h2 style="text-align:center">Team Information</h2>
<h3><a href="http://localhost/leagueTra... | true |
fd57068b7cea3a931c27dd9c737d2dcb915554ab | PHP | alen2608/paradis-back | /ProductDAO.php | UTF-8 | 8,136 | 2.703125 | 3 | [] | no_license | <?php
require("ProductVO.php");
require("ProductSortDAO.php");
require("ProductSortVO.php");
// require_once("dbLinkConfig.php");
class ProductDAO{
//fetch
// public $sql_fetchAll = "SELECT * FROM Products";
public $sql_fetchAll = "SELECT * FROM Products";
static public $sql_getProductPricesB... | true |
b73fc09d2a05fe630b6c6aec042c41ff38fe92c1 | PHP | iamsukanta/PHP-Full-Registration-System | /Registration/addpost.php | UTF-8 | 1,791 | 2.71875 | 3 | [] | no_license | <?php
require('index.php');
$msg = "";
if (empty($_SESSION['email'])) {
header('location: login.php');
}
if(isset($_POST['submit'])) {
$image = $_FILES['image']['name'];
$target = "images/".basename($image);
$title = mysqli_real_escape_string($conn, $_POST['title']);
$author = mysqli_real_escape_string... | true |
a6c54c9cda04e6773c581bdc6d1a443774819f58 | PHP | nhirata/arewefastyet | /website/internals.php | UTF-8 | 1,479 | 2.546875 | 3 | [] | no_license | <?php
// vim: set ts=4 sw=4 tw=99 et:
function init_database()
{
mysql_connect("localhost", "***", "***") or die("ERROR: " . mysql_error());
mysql_select_db("dvander") or die("ERROR: " . mysql_error());
}
function GET_int($name)
{
if (isset($_GET[$name]))
return intval($_GET[$name]);
return 0;... | true |
83fca70629f7977f0deb06510c3a37287499f081 | PHP | rafaelgodinho-wunderman/lps-vivo | /sources/backend/getTime.php | UTF-8 | 821 | 2.953125 | 3 | [] | no_license | <?php
header('Content-Type: application/json;');
header('Access-Control-Allow-Origin: *');
date_default_timezone_set("Brazil/East");
$day_of_week = date("w");
if( $day_of_week >= 1 && $day_of_week <= 5){ // Seg a Sex
$open = "7:00";
$close = "23:50";
}else if ( $day_of_week === 6 ){ // Sabado
$open =... | true |
fa4090990a80f9349f519de49b7d41c71ebe3eb3 | PHP | JohannaCh/bienesraices | /controllers/LoginController.php | UTF-8 | 1,956 | 2.890625 | 3 | [] | no_license | <?php
namespace Controllers; //le asigno su etiqueta
use MVC\Router;
use Model\Admin; //importo los modelos
class LoginController{
public static function login(Router $router){ //le paso el objeto router
$errores = [];
if($_SERVER['REQUEST_METHOD'] === 'POST') {
$auth = new Admin($_... | true |
21bbb338d2f8980b07564099f7b6b3420cd476c8 | PHP | Donsilor/gdzb | /common/enums/FlowMethodEnum.php | UTF-8 | 482 | 2.734375 | 3 | [
"Apache-2.0"
] | permissive | <?php
namespace common\enums;
/**
* 流程方式
*
* Class StatusEnum
* @package common\enums
* @author jianyan74 <751393839@qq.com>
*/
class FlowMethodEnum extends BaseEnum
{
const IN_ORDER = 1;//按顺序
const NO_ORDER = 2;//不按顺序
/**
* @return array
*/
public static function getMap(): array... | true |
18006405e834162c76c5be5b500214477b40fba9 | PHP | alexsegura/Oops | /library/Oops/Db/Propel/MemcachedServersQuery.php | UTF-8 | 13,571 | 2.796875 | 3 | [] | no_license | <?php
/**
* Base class that represents a query for the 'memcached_servers' table.
*
*
*
* @method Oops_Db_MemcachedServersQuery orderByIdMemcachedServer($order = Criteria::ASC) Order by the id_memcached_server column
* @method Oops_Db_MemcachedServersQuery orderByIp($order = Criteria::ASC) Order by the... | true |
f579b582af853be8ad66fdf13efcc7528677cd51 | PHP | paresy/symcon_exporter | /Prometheus/module.php | UTF-8 | 1,942 | 2.578125 | 3 | [] | no_license | <?php
declare(strict_types=1);
include __DIR__ . '/../libs/WebHookModule.php';
class Prometheus extends WebHookModule
{
public function __construct($InstanceID)
{
parent::__construct($InstanceID, 'metrics');
}
public function Create()
{
//Never delete this line!
parent::... | true |
7e0fefdf19b1c9335e7899c5bcde4204cb49af01 | PHP | v8st/push | /Push.php | UTF-8 | 5,899 | 2.828125 | 3 | [] | no_license | <?php
/**
* @author zzw
* @date 2015-03-26
* @note
*/
if (!defined('API_ROOT_PATH')) {
define('API_ROOT_PATH', dirname(__FILE__));
}
require_once ( API_ROOT_PATH . '/Push/Channel.class.php' );
class Push {
public static $_instance = NULL;
//接收人的user_id
public $_user_id = '';
//接收类型
public... | true |
2406797fa130a78aa4b1033b295a5418c8498e08 | PHP | ahmadelmalah/Learning-Project-Symfony-Restaurants-Orders | /orderat/src/AppBundle/Entity/State.php | UTF-8 | 1,983 | 2.609375 | 3 | [
"BSD-3-Clause",
"MIT"
] | permissive | <?php
namespace AppBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* State
*
* @ORM\Table(name="state")
* @ORM\Entity(repositoryClass="AppBundle\Repository\StateRepository")
*/
class State
{
const ACTIVE = 1;
const READY = 2;
const WAITING = 3;
const DELIVERED = 4;
const COMPLE... | true |
77ef0487aff03071e04ef52965ee5e2b4a1ea2bc | PHP | budkovsky/dsig-xml-builder | /src/Abstraction/AdapterAbstract.php | UTF-8 | 4,671 | 2.84375 | 3 | [] | no_license | <?php
declare(strict_types = 1);
namespace Budkovsky\DsigXmlBuilder\Abstraction;
use Budkovsky\Aid\Abstraction\EntityInterface;
use Budkovsky\DsigXmlBuilder\Exception\AdapterException;
use Budkovsky\DsigXmlBuilder\Enum\Attribute;
use Budkovsky\DsigXmlBuilder\Enum\XmlNs;
use DOMDocument;
use DOMElement;
/**
* Abstra... | true |
128689dbc0b3111febeaa5dab9aa9a9366784ab3 | PHP | BackupTheBerlios/docswell | /docswell/include/box.inc | UTF-8 | 4,393 | 2.796875 | 3 | [] | no_license | <?php
######################################################################
# The HTML Table Library
# ===================================================================
#
# Copyright (c) 2001 by
# Lutz Henckel (lutz.henckel@fokus.gmd.de) and
# Gregorio Robles (grex@scouts-es.org)
#
# BerliOS - The ... | true |
e364a7850270ffaba2923549a56f82a55b53afb2 | PHP | andileka/off-track- | /project/qcubed/Jqui/ChartJS.php | UTF-8 | 2,874 | 2.625 | 3 | [] | no_license | <?php
namespace QCubed\Project\Jqui;
class ChartJS extends \QCubed\Control\Panel{
/**
*
* @var Panel
*/
public $pnlChart;
public function __construct($objParentObject, $strControlId = null) {
parent::__construct($objParentObject, $strControlId);
$this->addCssFile(__VIRTUAL_DIRECTORY__."/project/asse... | true |
d9e6573163b37b7e54d42e9dd9f81b13e43bc3be | PHP | luigif/WsdlToPhp | /samples/serviceobjects-fast-tax/Tax/Multi/SOFastTaxTypeTaxInfoMulti.php | UTF-8 | 2,084 | 2.609375 | 3 | [] | no_license | <?php
/**
* Class file for SOFastTaxTypeTaxInfoMulti
* @date 08/07/2012
*/
/**
* Class SOFastTaxTypeTaxInfoMulti
* @date 08/07/2012
*/
class SOFastTaxTypeTaxInfoMulti extends SOFastTaxWsdlClass
{
/**
* The TaxInfo
* Meta informations :
* - minOccurs : 0
* - maxOccurs : unbounded
* @var SOFastTaxTypeT... | true |
865efa4d780f1322d7e3b60ccd5c63ce7e95366f | PHP | bschmitt/laravel-amqp | /src/Amqp.php | UTF-8 | 3,732 | 2.671875 | 3 | [
"MIT"
] | permissive | <?php
namespace Bschmitt\Amqp;
use Closure;
use Bschmitt\Amqp\Request;
use Bschmitt\Amqp\Message;
use PhpAmqpLib\Wire\AMQPTable;
use Illuminate\Support\Facades\App;
/**
* @author Björn Schmitt <code@bjoern.io>
*/
class Amqp
{
protected static $batchMessages = [];
/**
* @param string $routing
* @... | true |
6bc8a5214799008fba16aed7858e14dd55ad5563 | PHP | shyam-maurya/cardemo | /classes/inventory.php | UTF-8 | 1,275 | 2.75 | 3 | [] | no_license | <?php
require_once 'config.php';
class Inventory{
function __construct() {
}
function getAllInventory() {
global $conn;
$arr_records = array();
$sql = "SELECT sm_car_models.ModelId,sm_car_models.ModelName,count(sm_car_models.`ModelName`) as CarCount,sm_manufacturer.Manufa... | true |
68a1dd1e543df1563c73cd0a78a29c6fd1fa9212 | PHP | vw1234/copy1 | /src/Nwp/AssessmentBundle/Entity/Nav.php | UTF-8 | 5,422 | 2.515625 | 3 | [] | no_license | <?php
namespace Nwp\AssessmentBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* Nav
*
* @ORM\Table(name="nav")
* @ORM\Entity
*/
class Nav
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer", nullable=false)
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
... | true |
1889ea92ba7c8d73eb217cc0c5a3711d0a720040 | PHP | iRAP-software/MySQL-Syncer | /src/project/TableConnection.php | UTF-8 | 26,880 | 3 | 3 | [
"MIT"
] | permissive | <?php
class TableConnection
{
private $m_table;
private $m_columns;
private $m_mysqliConn;
private $m_primary_key;
/**
* Factory method to create a TableConnection more simply through the use of an already existing
* DatabaseConnection object.
* @param DatabaseConnection $c... | true |
8a355d75b10a5af710fecd7c117f70a89943b060 | PHP | agravelot/laravel-font-awesome | /tests/BladeRendererTest.php | UTF-8 | 1,454 | 2.578125 | 3 | [
"MIT"
] | permissive | <?php
namespace Jerodev\LaraFontAwesome\Tests;
use Jerodev\LaraFontAwesome\BladeRenderer;
class BladeRendererTest extends TestCase
{
public function testFabRenderWithClass()
{
$render = BladeRenderer::renderWithLibrary('\'laravel\', \'spin\'', 'fab');
$this->assertStringEndsWith('(\'laravel\... | true |
8c6d0ea81ff1ab3116462347fbfbc0231e53da71 | PHP | lawrencecs17/ServCom | /model/Egreso.php | UTF-8 | 4,386 | 2.984375 | 3 | [] | no_license | <?php
/**
* Description of Banco
*
* @author Lawrence
*/
require_once 'ConexionBD.php';
class Egreso {
private $idEgreso;
private $nombre;
private $descripcion;
private $status;
private $fkTipo;
private $fecha;
private $fkPersona;
private $tipo;
private $persona;
public function getNombre()
{
retur... | true |
5f808aabbaa28ce24cb8c3aeaf8357a433cfd3ad | PHP | EmpireDemocratiqueDuPoulpe/Pollygon | /php/survey/set_survey_title.php | UTF-8 | 907 | 2.65625 | 3 | [
"MIT"
] | permissive | <?php
require_once "../../init.php";
$SurveyManager = new Survey($db);
############################
# Check vars
############################
$survey_id = $_POST["survey_id"] ?? null;
$survey_name = $_POST["survey_name"] ?? null;
if (is_null($survey_id)) { setError(SURVEY_NOT_FOUND); redirectTo(CREATE_SURVEY_PAGE); ... | true |
38277bd575eddd835278f4e0fa2809543ac3f1a1 | PHP | Izaaaajy/ScholarshipOjt | /database/migrations/2021_10_27_065133_create_scholarship_details_table.php | UTF-8 | 915 | 2.53125 | 3 | [
"MIT"
] | permissive | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateScholarshipDetailsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('scho... | true |
49b3de8b7fc2084e76d3ef503758af5acde61e4d | PHP | horakdani/gyakorlas | /osztalyok/circle_OBJ.php | UTF-8 | 1,073 | 3.796875 | 4 | [] | no_license | <?php
$circle1 = new Circle(5.1766);
$circle2 = new Circle(4.23);
echo "\nA kör sugara: " . $circle1->getRadius() . " egység." . "\n";
echo "\nA kör kerülete: " . $circle1->circumference() . " egység." . "\n";
echo "\nA kör területe: " . $circle1->area() . " egység." . "\n";
echo "\nA körök területének összeg... | true |
4df28215be97b36c281142c20d925b0c626afc62 | PHP | mochila/mochila | /getTitles.php | UTF-8 | 411 | 2.953125 | 3 | [] | no_license | <?php
// Get all the titles of DAGRS from the database
$mysqli = new mysqli("localhost", "root", "dude1313", "mochila_db");
$result = $mysqli->query("SELECT DAGR_TITLE FROM DAGRS WHERE DAGR_TYPE='parent'");
// Create an array from the result set
$rows = array();
while($row = $result->fetch_assoc()) {
$rows[] = $row... | true |
e11f4721c7fe774f8ebd2b5536d1a69a51eeea54 | PHP | joaobelarmino/Helpp | /application/models/ProfessorDAO.class.php | UTF-8 | 1,040 | 2.828125 | 3 | [] | no_license | <?php
/**
* ProfessorDAO.class [ TIPO ]
* Descricao
* @copyright (c) year, Geovana M. Melo
*/
class ProfessorDAO{
//put your code here
public function cadastrarProfessor(Usuario $u) {
$query = "INSERT INTO professor (rmUsuario, rmProfessor) values (?,?)";
$cadastrar = Conn::getConn()... | true |
69237cd3cbbf66cdc09827dadf694c39d741a200 | PHP | AlexEvesDeveloper/hl-stuff | /hosted-api/src/Barbon/HostedApi/AppBundle/Form/Common/Model/BrandOptions/Urls.php | UTF-8 | 1,132 | 2.609375 | 3 | [
"BSD-3-Clause",
"MIT"
] | permissive | <?php
namespace Barbon\HostedApi\AppBundle\Form\Common\Model\BrandOptions;
use Barbon\IrisRestClient\Annotation as Iris;
use JsonSerializable;
class Urls implements JsonSerializable
{
/**
* For detailed help information hosted on an integrator's website.
*/
const URL_HELP = 'help';
/**
* ... | true |
ea7fb38ba83b5d06f6704560fc1a297e57e28ff8 | PHP | Anveshd/Online_Quiz_PHP | /online.php | UTF-8 | 4,378 | 2.53125 | 3 | [] | no_license | <!DOCTYPE>
<html>
<head>
<link href="quiz.css" rel="stylesheet" type="text/css">
</head>
<h1>
Online Quiz
</h1>
<body>
<?php
session_start();
$dbhost = "localhost";
$dbuser = "root";
$dbpass = "";
$conn = mysql_connect($dbhost, $dbuser, $dbpass);
if(! $conn )
{
die('Could not connect: ' . mysql_error())... | true |
06400477d6ec3468aa0535f7935e910cc02470c7 | PHP | arielalvesdutra/Registro-de-Horas-Backend | /src/Database/Factories/Tables/TimeRecordsTable.php | UTF-8 | 1,597 | 2.765625 | 3 | [] | no_license | <?php
namespace App\Database\Factories\Tables;
use App\Database;
use App\Database\Enum\ColumnType\IntType;
use App\Database\Enum\ColumnType\VarcharType;
use App\Database\Enum\MySQLEngine\InnoDb;
class TimeRecordsTable implements TableFactoryInterface
{
public static function create()
{
$database = n... | true |
bd834e453e95c3e2f2380407ca7acfce320cf1db | PHP | manh-trinhquoc/awesome-wordpress | /plugins/cart66/models/Cart66CartWidget.php | UTF-8 | 4,569 | 2.609375 | 3 | [] | no_license | <?php
class Cart66CartWidget extends WP_Widget {
private $_items = array();
public function Cart66CartWidget() {
$widget_ops = array('classname' => 'Cart66CartWidget', 'description' => 'Sidebar shopping cart for Cart66' );
$this->WP_Widget('Cart66CartWidget', 'Cart66 Shopping Cart', $widget_ops);
}
p... | true |
210a9f40714da961463d318afe6877d0767290bc | PHP | FinalEnd/FE | /FinalEnd/class/DatabaseObjects/cls_RouteManager.php | UTF-8 | 3,206 | 2.765625 | 3 | [] | no_license | <?php
class RouteManager extends SystemManager
{
public function updateResources(Planet $Planet)
{
$Sql="UPDATE `tbl_planet` SET `i_Metal` = '".$Planet->getMetal()."',
`i_Hydrogen` = '".$Planet->getHydrogen()."',
`i_Biomass` = '".$Planet->getBiomass()."',
`i_Crystal` = '".$Planet->getCrystal()."',
`i_Ref... | true |
6f1a8cb1c4d1bc3f1f8e6e973cdb857908a7cafc | PHP | quer/News-Feed-Web | /php/api/login.php | UTF-8 | 791 | 2.875 | 3 | [] | no_license | <?php
header("Access-Control-Allow-Origin: *");
header('Content-type: application/json');
$json = array();
include_once '../includes/db_connect.php';
include_once '../includes/functions.php';
sec_session_start(); // Our custom secure way of starting a PHP session.
if (isset($_POST['username'], $_POST['password'])) {
... | true |
a2862151f22fe4d1e39ecaf7b967beee9c1af1ab | PHP | treilhes/riot-decode | /riotDecode/common/BaseFile.php | UTF-8 | 2,461 | 2.75 | 3 | [] | no_license | <?php
namespace riotDecode\common;
abstract class BaseFile implements \ArrayAccess {
protected $indexable = false;
protected $file;
protected $values;
public function __construct($file) {
$this->file = $file;
}
public function isIndexable()
{
return $this->indexable;
}
public function loadFileC... | true |
b214e8d1b1c1d5b188582a5797e746ca4f232ba4 | PHP | yuralucky/parseUrl | /app/ShowReport.php | UTF-8 | 1,013 | 2.96875 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: yura
* Date: 13.12.18
* Time: 16:35
*/
namespace Project1;
class ShowReport
{
/**
* @var string
*/
private $url;
/**
* ShowReport constructor.
* @param GetFilename $url
*/
public function __construct(GetFilename $url)
{
... | true |
ed246ea8be6a7e8aa7dd728425d8ab0e45de0df0 | PHP | APO-Epsilon/apo-website | /includes/upload_photo_process.php | UTF-8 | 3,327 | 2.671875 | 3 | [] | no_license | <?php
session_start();
$exec_page = false;
$active_page = true;
$public_page = false;
require_once("../permissions.php");
function show_active() {
//Code based on example at https://vikasmahajan.wordpress.com/2010/07/07/inserting-and-displaying-images-in-mysql-using-php/
include('../mysql_access.php... | true |
66f8c46b040a2655bc9817bf06a6201db29c1d60 | PHP | baskuis/werock | /public/modules/MapTable/objects/MapTableIndexObject.class.php | UTF-8 | 3,655 | 2.515625 | 3 | [] | no_license | <?php
class MapTableIndexObject {
public $table;
public $nonUnique;
public $keyName;
public $seqInIndex;
public $columnName;
public $collation;
public $cardinality;
public $subPart;
public $packed;
public $null;
public $indexType;
public $comment;
public $indexComme... | true |
911f045535a496def3247d3987455872f536c8ea | PHP | ChathuriniPerera/Restaurant-System | /calender/editcalender.php | UTF-8 | 4,940 | 2.90625 | 3 | [] | no_license | <?php
include '../header.php';
include '../nav.php';
//Include Database Connection
include '../conn.php';
?>
<?php
$id = $day = $open_time = $close_time = null;
if ($_SERVER['REQUEST_METHOD'] == "POST" && @$_POST['operate'] == "update_calender") {
$e = array();
$id = clean_data($_POST['id']);
$day = cle... | true |
c58698e4cfdabe63cf60b24e8f78b38f96ec8cbe | PHP | cleemansen/comalyser | /Server/robot.php | ISO-8859-2 | 7,436 | 2.984375 | 3 | [] | no_license | <?php
/*
* Cookies:
* http://coderscult.com/php/php-curl/2008/05/20/php-curl-cookies-example/
*
* Redirect:
* http://php.net/manual/en/function.curl-setopt.php
*/
function curl_download($Url){
// is cURL installed yet?
if (!function_exists('curl_init')){
die('Sorry cURL is not installed!');
... | true |
0d2acee56d0c5099f0f249bbf60dccc8c90263aa | PHP | ProblemSPb/PHP | /array_functions.php | UTF-8 | 2,422 | 4.09375 | 4 | [] | no_license | <?php
// usort - сортирует массив по значения, используя пользовательскую функцию для сравнения элементов
function compare($a, $b) {
if($a == $b) {
return 0;
}
return ($a < $b) ? -1 : 1;
}
$new_array = array(3, 5, 2, 6, 1);
usort($new_array, "compare");
print_r($new_array);
echo "<br>";
// is_arr... | true |