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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
cc1ba74b7c11564010095e900f0a1c34d667e62d | PHP | khoatran/dry | /src/Dry/ConsoleBundle/Helper/FileInputDialog.php | UTF-8 | 746 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
namespace Dry\ConsoleBundle\Helper;
use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;
class FileInputDialog extends InputDialog{
public function ask... | true |
77f22e8a6011cc295b1030a68f20fc185a096b1c | PHP | 1320174388/XiangMu_KaiFa8_coupon_module_Youhuijuan_Module | /coupon_module/working_version/v1/service/CouponService.php | UTF-8 | 4,365 | 2.59375 | 3 | [] | no_license | <?php
/**
* 版权声明 : 地老天荒科技有限公司
* 文件名称 : CouponService.php
* 创 建 者 : Shi Rui
* 创建日期 : 2018/09/03 09:28
* 文件描述 : 优惠劵逻辑层
* 历史记录 : -----------------------
*/
namespace app\coupon_module\working_version\v1\service;
use app\coupon_module\working_version\v1\dao\CouponDao;
class CouponService
{
... | true |
257a8c3f4a6be0b9df0da43adb91992fe094b11d | PHP | RoopsBhasima/OOP | /scope.php | UTF-8 | 240 | 3.296875 | 3 | [] | no_license | <?php
class A{
public $bar;
public function __construct ($bar) {
$this->bar= $bar;
}
public function myPrint (){
echo $this->bar;
}
}
$myFirstObject = new A('test');
//$myFirstObject->myPrint();
echo $myFirstObject->bar;
?> | true |
494481d2b93d84bc83d1622c05dcb3dacb89b7c0 | PHP | MCU-Sule/praktikum-4-ReinardDavid | /hitungan2.php | UTF-8 | 1,640 | 3.046875 | 3 | [] | no_license | <!DOCTYPE html>
<html lang="en">
<meta name="author" content="Reinard David 2172010">
<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>Hasil1</title>
</head>
<body align="center"... | true |
935071ff0a722cb4cd96af904b213423c15619ec | PHP | ingfelipegon/contratosSoft | /app/Models/Traslado.php | UTF-8 | 985 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class Traslado extends Model
{
protected $fillable = [
'observaciones', //STRING OBSERVACIONES
'bloque_id' , //INT ID BLOQUE
'persona_id', //INT ID PERSONA
'representante_id', //INT ... | true |
2d850601c9a5c8f5a05e5be9585a987679e8808d | PHP | CNAWebDevCP2420/labs-jongreen-developer | /Lab2/TwoTrains.php | UTF-8 | 794 | 2.609375 | 3 | [] | no_license | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<title>Contact Me</title>
</head>
<body>
<form name="twotrains" action="TwoTrains.php" method="post">
<p>Train A Speed: <input type="text" name="speeda" value="" /></p>
<p>Train B Speed: <input t... | true |
a267a1a240b0c981b21e6ca548c82e157eb5ad6c | PHP | riccardooliva91/wp-customize-nonce | /includes/WCN/Elements/Ip.php | UTF-8 | 281 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
namespace WCN\Elements;
use WCN\ElementInterface;
/**
* Class Ip
* @package WCN\Elements
*
* @codeCoverageIgnore
*/
class Ip implements ElementInterface {
/**
* @inheritDoc
*/
public function get() {
return filter_input(INPUT_SERVER, 'HTTP_X_REAL_IP');
}
} | true |
fbd8dd7e6a3a28b0f3ba4e3df5bc3441fb8b423e | PHP | jain15506/GalleryZone | /app/Http/Controllers/GalleryController.php | UTF-8 | 3,092 | 2.640625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use App\Gallery;
use Illuminate\Support\Facades\Auth;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Validator;
use Intervention\Image\Facades\Image ;
class GalleryController extends Controller
{
public function viewAllGalleryList()
{
$galleries=Gallery::orderBy(... | true |
82d0527945e6571d9ed4c218f566b6b8f83cd429 | PHP | iloading/aplans | /scripts/sc_update_settings.php | UTF-8 | 2,823 | 2.515625 | 3 | [] | no_license | <?php
require_once "../connections/connection.php";
session_start();
$data_display = array();
if (isset($_SESSION['id_user_aplans'])) {
$sucesso = 1;
$row_results_erro = array();
$data = date('Y-m-d');
$hora = date('H:i');
$dataAtual = $data . 'T' . $hora;
if(isset($_GET['tipoEven... | true |
15ddbd7018081a9ea1a03ebe3a5acf4b71f78c6e | PHP | mkentcarlo/crm | /app/Services/BrandService.php | UTF-8 | 1,889 | 2.71875 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Services;
use App\Services\WoocommerceService;
class BrandService
{
public $wooService;
public function __construct(WoocommerceService $wooService)
{
$this->wooService = $wooService;
}
public function getBrands()
{
$brands = $this->wooService->getBrands();
$data = [];
... | true |
f1a2e7f592ecb856e19d49413b2e52eff3ce0d78 | PHP | mathunjoroge/hospital | /pharmacy/drug.php | UTF-8 | 669 | 2.84375 | 3 | [
"MIT"
] | permissive | <?php
include 'config.php';
// Number of records fetch
$numberofrecords = 30;
if(isset($_POST['q'])){
// Fetch records
$search = "%".$_POST['q']."%";// Search text
// Fetch records
$result = $db->prepare("SELECT Name FROM cancer_drugs WHERE Name LIKE :Name LIMIT :limit");
$result->bindValue(':Name', $searc... | true |
b2fcc55d239389f8ccf052e8973b2bac1e67123a | PHP | shuadeputra/travel_ci | /application/models/seomodel.php | UTF-8 | 601 | 2.609375 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
class seomodel extends CI_Model {
public function __construct() {
parent::__construct();
$this->load->database();
}
public function getseo() {
$sql="SELECT * FROM seo_tbl ORDER BY seo_id DESC";
$query=$this->db->que... | true |
fc2db16ea10e81a5100a0df456552bff6a889b9a | PHP | leandroAS86/mis-ademadan-2017 | /app/models/Legal_reports.php | UTF-8 | 2,328 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
class Legal_reports extends \HXPHP\System\Model
{
static $belongs_to = array(
array('user')
);
public static function registrar($user_id, array $post)
{
$callbackObj = new \stdClass;
$callbackObj->reports=null;
$callbackObj->status=false;
$callbackObj->errors=array();
$callbackObj-... | true |
ea3ad98308180f6fa2879e851cc0e9de660691a4 | PHP | rapila/plugin-schulcms | /modules/widget/event_types_input/EventTypesInputWidgetModule.php | UTF-8 | 849 | 2.6875 | 3 | [] | no_license | <?php
/**
* @package modules.widget
*/
class EventTypesInputWidgetModule extends WidgetModule {
private $aEventTypes = array();
public function __construct() {
$this->aEventTypes = $this->getEventTypes();
$this->setSetting('available_type_coount', count($this->aEventTypes));
if(count($this->aEventTypes) === 1... | true |
bd1c67c89819a2a252d203e0c6e15e367ba9fd90 | PHP | helio/panel | /tests/Infrastructure/Utility/NotificationUtility.php | UTF-8 | 772 | 2.609375 | 3 | [] | no_license | <?php
namespace Helio\Test\Infrastructure\Utility;
class NotificationUtility extends \Helio\Panel\Utility\NotificationUtility
{
public static $mails = [];
protected static function sendMail(string $recipient, string $subject, $content, array $button, array $from = ['hello@idling.host' => 'Helio'], string $ht... | true |
07885c52ea84f96f564318662e2fe313b0b63af5 | PHP | dmitry-spor/balaklava-hospital | /app/Http/Middleware/CheckPost.php | UTF-8 | 940 | 2.703125 | 3 | [] | no_license | <?php
namespace App\Http\Middleware;
use Closure;
use Illuminate\Support\Facades\Auth;
class CheckPost
{
/**
* Handle an incoming request.
*
* @param \Illuminate\Http\Request $request
* @param \Closure $next
* @param string|null $post
* @return mixed
*/
public functi... | true |
b2d75157922f2b21ae7d2cac5405a064ce538cb5 | PHP | BenmoussaAmine/Symfo | /src/Entity/Ville.php | UTF-8 | 2,057 | 2.546875 | 3 | [] | no_license | <?php
namespace App\Entity;
use App\Repository\VilleRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=VilleRepository::class)
*/
class Ville
{
/**
* @ORM\Id
* @ORM\GeneratedValue
... | true |
0e58c1b32473fd8ddf1dc756fac661288ff17ecf | PHP | CGreweling/studip-opencast-plugin | /migrations/007_cronjob_refresh_scheduled_events.php | UTF-8 | 790 | 2.625 | 3 | [] | no_license | <?php
class CronjobRefreshScheduledEvents extends Migration
{
const FILENAME = 'public/plugins_packages/elan-ev/OpenCast/cronjobs/refresh_scheduled_events.php';
public function description()
{
return 'adds a cronjob for refreshing scheduled events of an scheduled series in Stud.IP';
}
publi... | true |
ea39babe5cd5b525b3e53fd8011c11023a237d37 | PHP | breakpoint/etsy-php | /src/Resources/UserAddress.php | UTF-8 | 1,965 | 2.859375 | 3 | [
"MIT"
] | permissive | <?php
namespace breakpoint\etsy\Resources;
use breakpoint\etsy\Classes\EtsyObject;
use breakpoint\etsy\Classes\EtsyResults;
use breakpoint\etsy\Classes\EtsyRequest;
use Psr\Http\Message\ResponseInterface;
/**
* Represents methods available at: https://www.etsy.com/developers/documentation/reference/useraddress
... | true |
7c0e263e08f58703d2fa1fefbc6db8109efa0799 | PHP | referid/HackMIT-php | /history.php | UTF-8 | 2,132 | 2.875 | 3 | [] | no_license | <?php
echo <<<_END
<html>
<head>
<link href="layout/css/core.css" rel="stylesheet" type="text/css" />
<link rel="shortcut icon" href="favicon.ico" type="image/x-icon"/>
</head>
<body>
<div id="main" class="center">
_END;
// Retreive GET parameters
if (isset($_GET['user... | true |
97b6f1a5199a69038c2f209e2fddd78e9e250925 | PHP | KNIGHTTH0R/kurma | /app/kurma/models/Kuis.php | UTF-8 | 976 | 2.625 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: akbar
* Date: 27.05.15
* Time: 12:13
*/
namespace kurma\models;
use Illuminate\Database\Eloquent\Model as Model;
class Kuis extends Model{
protected $table = "kuis";
protected $primaryKey = "id_kuis";
public function isAllowed($kurmaId, $kurmaPass){
... | true |
fd7ad4b2e8f901bc784fe8ac87c6a0b0ddcb8881 | PHP | tanayk91/electriccar | /registration/save_interests.php | UTF-8 | 1,706 | 2.515625 | 3 | [] | no_license | <?php
session_start();
include("../db/connection.php");
if ($_POST['interests-selected'] =="CONTINUE >>" ) {
if ($_POST['geom-counter'] != 0) {
$query = "INSERT INTO `ecDB`.`interests` (`userID`,`interest`,`subject`) VALUES ('{$_SESSION['userID']}','Geometry','Math')";
mysqli_query($li... | true |
1f1c23e0e53adce82c540a3ea1e1fd9fa38d9599 | PHP | Naokiyoza/Naoki | /mission_2-6.php | UTF-8 | 13,360 | 3.03125 | 3 | [] | no_license | <html>
<!-2-2で作成されたテキストファイルを読み込み、2-1のフォームのすぐ下に表示する。表示の際にループ関数を使うこと。->
<head>
<meta charset = "utf-8" />
<title>シネマよざくん</title>
</head>
<body>
<!-フォームの上部に見出しをつける->
<h1>お気に入りの映画・ドラマ・アニメ</h1>
<!-formタグでブラウザ上に入力フォームを作成する->
<form method="post" action="mission_2-6.php">
<!-編集1->
<?php
$edi = htmlspecialchars($_POST["e... | true |
1d91874c317ce830262b708fd6e025b570642124 | PHP | CyberSecurityBG/omniship-berry | /src/Http/GetPdfResponse.php | UTF-8 | 468 | 2.625 | 3 | [] | no_license | <?php
namespace Omniship\Berry\Http;
class GetPdfResponse extends AbstractResponse
{
/**
* @return bool
*/
public function getData(){
if(is_null($this->data)) {
return $this->data;
}
$pdf = isset($this->data->packages[0]->shipping_label_url) ? file_... | true |
a25358f0296c36d26f20e381f5d15f04c9ce54be | PHP | neilmcgibbon/php-simple-framework | /app/engine/classes/uploader.class.php | UTF-8 | 2,555 | 2.9375 | 3 | [] | no_license | <?php
class PHPSFW_Uploader {
public $file;
public $extension;
public $filename;
private $valid = false;
private $error = "";
final function __construct($name) {
if (!isset($_FILES[$name]))
return $this->err('File "' . $name . '" not present in $_FILES');
elseif ($_FILES[$name]['size'] == 0)
r... | true |
6b06856b96d863b7175ef5f0c85aa96cdcc2ce6c | PHP | MariaDinova/PHP | /Lesson 3/Problem 11.php | UTF-8 | 1,680 | 3.59375 | 4 | [] | no_license | <?php
/*Въведете число N и изкарайте като
резултат следния триъгълник с височина N:
*
***
*****
.................
Кaто допълнително упражнение – нарисувайте същия
триъгълник, но незапълнен.
*/
echo "Please enter an integer number, bigger than 1: ";
$n = trim(fgets(STDIN));
while (in... | true |
4f8994b36312c6528fe3dc0049a55cee0557955d | PHP | hamaco/candycane-u-nya- | /tests/SampleTest.php | UTF-8 | 175 | 2.546875 | 3 | [] | no_license | <?php
class SampleTest extends PHPUnit_Framework_TestCase
{
public function testだみー()
{
$text = "だみー";
$this->assertEquals("だみー", $text);
}
}
| true |
b5e0affefe92d444511a62979927742e177cf4b0 | PHP | petko-dimitrov/SoftUni | /PHP Web 09.2018/PHP Basics/16.InterfacesAndAbstraction-Exc/12.VehiclesExtension/index.php | UTF-8 | 802 | 3.28125 | 3 | [] | no_license | <?php
spl_autoload_register();
$vehicles = [];
for ($i = 0; $i < 3; $i++){
[$vehicle, $fuel, $consumption, $capacity] = explode(' ', readline());
try {
$vehicles[$vehicle] = new $vehicle(floatval($fuel), floatval($consumption), floatval($capacity));
} catch (Exception $e) {
echo $e->getMess... | true |
759fb7cea224dc8dd783c4ea6f8f93b0844685c7 | PHP | lyrixx/lifestream | /Lifestream/Lifestream.php | UTF-8 | 3,918 | 3.09375 | 3 | [
"MIT"
] | permissive | <?php
namespace Lyrixx\Lifestream;
use Lyrixx\Lifestream\Service\ServiceInterface;
use Lyrixx\Lifestream\Formatter\FormatterInterface;
use Lyrixx\Lifestream\Filter\FilterInterface;
/**
* Class Lifestream is the engine of Lifestream library.
*/
class Lifestream
{
private $service;
private $filters = arra... | true |
d7cf98e93a0aa5f64ec9f7694c13bbbd84892a04 | PHP | AhmedSaidAsmail/souvenir-shamr | /app/src/Cart/ShoppingCart.php | UTF-8 | 2,924 | 3.0625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Src\Cart;
use Illuminate\Http\Request;
class ShoppingCart
{
static $CartName = "cart";
/**
* @var Request $request
*/
private $request;
public function __construct(Request $request)
{
$this->request = $request;
}
/**
* Inserting attributes to c... | true |
9bbfe0e07e69b24416ca26be32fc2d9ee8043c97 | PHP | amenophis/csv2json | /src/TypeFormatter/TypeFormatter.php | UTF-8 | 181 | 2.5625 | 3 | [] | no_license | <?php
namespace Csv2Json\TypeFormatter;
interface TypeFormatter
{
public function supports(string $type, ?string $value): bool;
public function format(?string $value);
}
| true |
d19e802813eedf159c19cb1020fe01cf7a3e39b4 | PHP | thesebas/runlock | /src/Lock.php | UTF-8 | 1,647 | 2.625 | 3 | [] | no_license | <?php
namespace thesebas\runlock;
class Lock {
/**
* @var \MongoDB\Collection
*/
protected $locks;
public function __construct($config) {
$mongo = new \MongoDB\Client($config['mongo']['host']);
$dbName = $config['mongo']['dbName'];
$collectionName = $config['mongo']['... | true |
15f3e20f0914ec07aced884a5faa4ec8d059d54b | PHP | dflydev/repose-php | /lib/repose_IPropertyGenerator.php | UTF-8 | 1,054 | 2.796875 | 3 | [] | no_license | <?php
/**
* Property Generator Interface
* @package repose
*/
/**
* Property Generator Interface
* @package repose
*/
interface repose_IPropertyGenerator {
/**
* Generates an ID
* @param $session Session
* @param $clazz Mapped Class
* @param $property Mapped Class Property
* @pa... | true |
c64016020e45cc035bba3d4cb8036cd768ff362e | PHP | feeh27/intranet | /html/api/app/Infrastructure/Contracts/ValidationInterface.php | UTF-8 | 929 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Infrastructure\Contracts;
/**
* Class GroupModuleValidation: responsável pelas regras de validação da relação entre grupo e módulos
*
* @package App\Infrastructure
* @category API
* @author Felipe Dominguesche <fe.dominguesche@gmail.com>
* @version Version 0.2.0
* @access ... | true |
e68521581db08829c8339a7340c149d9bc1f3c35 | PHP | wendell1101/loan_app2 | /app/controllers/UserController.php | UTF-8 | 11,679 | 3.078125 | 3 | [] | no_license | <?php
// extends Connection class
class UserController extends Connection
{
private $data;
private $errors = [];
private static $fields = ['firstname', 'lastname', 'contact_number', 'gender', 'email', 'password1', 'password2'];
private $loginFields = ['email', 'password'];
public function __constr... | true |
783cedb6003090e5f6c1f9184c6e1aa8219dbd91 | PHP | lgandelin/w-cms-core | /tests/Webaccess/WCMSCoreTests/Interactors/Users/GetUserInteractorTest.php | UTF-8 | 923 | 2.640625 | 3 | [
"MIT"
] | permissive | <?php
use Webaccess\WCMSCore\Context;
use Webaccess\WCMSCore\Entities\User;
use Webaccess\WCMSCore\Interactors\Users\GetUserInteractor;
class GetUserInteractorTest extends PHPUnit_Framework_TestCase
{
private $interactor;
public function setUp() {
CMSTestsSuite::clean();
$this->interactor = n... | true |
862a91508c4e3ea8afb56daa34939e3801bf9032 | PHP | AlexABallWebDev/esolwordcardwebsite | /public_html/check-id.php | UTF-8 | 1,310 | 3.1875 | 3 | [] | no_license | <?php
//this script checks the database for a user_id and that
//matches the user_id in the session global array. if a matching
//user_id is not found, then the user is redirected to the login/signup page.
//start session
session_start();
//if the user is logged on, check the user_id in the database
if (isset($_SESSI... | true |
44661fa2d3782e6314140550718b4f7f72e856c7 | PHP | law909/nineparams | /src/ParameterHandler.php | UTF-8 | 3,095 | 2.953125 | 3 | [
"MIT"
] | permissive | <?php
namespace nineparams;
require_once 'IParameterHandler.php';
require_once 'TypeConverter.php';
require_once 'ISanitizer.php';
require_once 'ArrayHandler.php';
class ParameterHandler implements IParameterHandler {
private $typeconverter;
private $sanitizer;
private $paramhnd;
private $requestparamh... | true |
8d7813df5211f89bed2c21cc74526a4ef9c9f08e | PHP | mganper/Spil2 | /spil.model/RespilModelImpl.php | UTF-8 | 1,509 | 2.71875 | 3 | [] | no_license | <?php
require_once $_SERVER['DOCUMENT_ROOT'] . '/spil.model/RespilModel.php';
require_once $_SERVER['DOCUMENT_ROOT'] . '/spil.model/spil.model.persistence/spil.model.persistence.dao/RespilDAOImpl.php';
class RespilModelImpl implements RespilModel {
//private $respilController;
function __construct() {
... | true |
b3bf4fde8271cd9c87db9923c8c9398e82433888 | PHP | abdullahemad12/CS50-Finance | /public/account.php | UTF-8 | 1,563 | 2.640625 | 3 | [] | no_license | <?php
require("../includes/config.php");
// check for the request method
if($_SERVER["REQUEST_METHOD"] == "GET")
{
//renders the page
render("account_form.php", ["title"=>"Account"]);
}
else
{
// checks for the validity of the password
if(empty($_POST["password"]))
{
apolog... | true |
61884740d98d7b2431b12ca82510fb9523458d22 | PHP | s-miehlbradt/git-github-lint | /spec/PurpleBooth/GitGitHubLint/MessageImplementationSpec.php | UTF-8 | 4,713 | 2.78125 | 3 | [
"MIT"
] | permissive | <?php
namespace spec\PurpleBooth\GitGitHubLint;
use PhpSpec\ObjectBehavior;
use PurpleBooth\GitGitHubLint\Message;
use PurpleBooth\GitGitHubLint\MessageImplementation;
use PurpleBooth\GitGitHubLint\Status\Status;
class MessageImplementationSpec extends ObjectBehavior
{
function it_is_initializable()
{
... | true |
5c1283a6ecf3f9765b71ab257b563551c3cff853 | PHP | filipekp/service | /admin/core/interfaces/IDataHandler.php | UTF-8 | 1,663 | 2.671875 | 3 | [] | no_license | <?php
namespace prosys\core\interfaces;
/**
* Represents the data handleable interface.<br />
* Notice: designed for MySQL Connection, but it should be fully functional for any type of the data handling.
*
* @author Jan Svěží
* @copyright (c) 2014, Proclient s.r.o.
*/
interface IDataHandler
... | true |
589e7f2f79d91658bc13ac043d05dda517751072 | PHP | ciniki/core | /private/printHashToJSON.php | UTF-8 | 497 | 2.875 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
//
// Description
// -----------
// This function will serialize a hash structure to return to the client.
//
// Info
// ----
// Status: beta
//
// Arguments
// ---------
// name: The name the top level should be
// indent: The string for indentation, which should be spaces. Each rec... | true |
8851d4fc9c3866eb30a1b8764604e8b3dfb726ac | PHP | adamnfish/Bene | /core/CoreController.php | UTF-8 | 5,012 | 2.65625 | 3 | [] | no_license | <?php
/**
* abstract class components
* @author adamnfish
*
*/
abstract class CoreController
{
protected $errors;
protected $project;
protected $method;
protected $E;
public $request_uri;
public $get;
public $post;
// array of componenets - this would autoload each component?
// I Don't like this
// if... | true |
e0c3462d5d1e008d0011935cd030ba780755269d | PHP | Triips-TheCoder/Blog_Art_Arkitek_G1 | /BLOGART21/CLASS_CRUD/comment.class.php | UTF-8 | 1,812 | 2.890625 | 3 | [] | no_license | <?php
// CRUD STATUT (ETUD)
require_once __DIR__ . '../../CONNECT/database.php';
class COMMENT{
function get_1Comment($numSeqCom){
global $db;
$query = 'SELECT * FROM COMMENT(numSeqCom) VALUES (?);';
$result = $db->query($query);
$comment = $result->fetch();
... | true |
50fa165ea84a0ec205b934703c9076e503a95c84 | PHP | kaaterskil/traveloti | /module/Location/src/Location/Model/Location.php | UTF-8 | 6,878 | 2.546875 | 3 | [] | no_license | <?php
/**
* Traveloti Library
*
* @category Traveloti
* @package Traveloti_Location
* @subpackage Model
* @copyright Copyright (c) 2009-2012 Kaaterskil Management, LLC
* @version $Id: $
*/
namespace Location\Model;
use Zend\InputFilter\Factory as InputFactory;
use Zend\InputFilter\InputFilter;
use Zend\Inpu... | true |
8ee5749e6deba40d1e62071947a7c5a66cf7d574 | PHP | aallbrig/terra-charts_map-chat | /app/controllers/ApplicationController.php | UTF-8 | 875 | 2.53125 | 3 | [] | no_license | <?php
class ApplicationController extends \BaseController {
protected $layout = 'layouts.master';
// Pages
public function index() {
$chatCircles = ChatCircle::all();
foreach ($chatCircles as $chatCircle) {
$chatCircle->messages;
}
return $this->layout->nest('content', 'application.pages.index', ['data'... | true |
4fe87a7de8f3b9e060b8811a918132aa683ad305 | PHP | farzantesla/tsa | /backend/models/Review.php | UTF-8 | 1,754 | 2.65625 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
namespace backend\models;
use Yii;
/**
* This is the model class for table "review".
*
* @property string $id
* @property string $users_id
* @property string $vehicle_users_id
* @property string $vehicle_id
* @property string $car_id
* @property string $user_id
* @property string $comments
* @propert... | true |
e8cc084b284d2f50f3d670f236349d6ab7ea6cfe | PHP | dsvlivon/Programacion-3 | /MPP pizza/AltaVenta.php | UTF-8 | 834 | 2.796875 | 3 | [] | no_license | <?php
// VIZGARRA.LIVON.DANIEL
include_once "Venta.php";
//email del usuario y el sabor,tipo y cantidad
echo "INGRESE: mail, sabor, tipo, cantidad</br></br>";
if(isset($_POST["mail"]) && isset($_POST["sabor"]) && isset($_POST["cantidad"]) && isset($_POST["tipo"])){
$mail = $_POST["m... | true |
d35c3f127db962a0a497e528cc19f96f48a0a565 | PHP | Skit/blog | /blog/managers/CategoryManager.php | UTF-8 | 2,112 | 2.8125 | 3 | [] | permissive | <?php declare(strict_types=1);
namespace blog\managers;
use backend\models\CategoriesForm;
use blog\entities\category\Category;
use blog\entities\common\exceptions\BlogRecordsException;
use blog\entities\user\User;
use blog\repositories\category\CategoriesRepository;
use blog\repositories\exceptions\RepositoryExcepti... | true |
e3c662677abe1aec981c0e7ad6b602e8afcd0e94 | PHP | PostScripton/laravel-money | /tests/Feature/HelpersTest.php | UTF-8 | 1,144 | 2.859375 | 3 | [
"MIT"
] | permissive | <?php
namespace PostScripton\Money\Tests\Feature;
use PostScripton\Money\Enums\CurrencyPosition;
use PostScripton\Money\Money;
use PostScripton\Money\Tests\TestCase;
class HelpersTest extends TestCase
{
public function testCreateMoneyWithMoneyHelper(): void
{
$money = money('12345000');
$thi... | true |
15b92df874a502efea72231aec9a336c67dcfdcd | PHP | balmistan/asagest2 | /Ajax/ajax_report.php | UTF-8 | 2,514 | 2.53125 | 3 | [] | no_license | <?php
require_once '../Personal/config.php';
require_once '../Lib/autoload.php';
$session = new session();
if (!accesslimited::isInAutorizedGroups(user::getUserName($session->getUserId()), array("admins", "users"))) {
echo json_encode("danied");
} else {
$person = new Person();
$block = new block();
... | true |
c16e190b44b12db9b1b7065bb41ded9535f517d4 | PHP | CheruelQuentin/StageV2 | /modele/bd.enseignant.inc.php | UTF-8 | 5,675 | 2.84375 | 3 | [] | no_license | <?php
include_once "bd.inc.php";
function getEnseignantById($ENS_ID) {
try {
$cnx = connexionPDO();
$req = $cnx->prepare("select * from enseignant where ENS_ID=:ENS_ID");
$req->bindValue(':ENS_ID', $ENS_ID, PDO::PARAM_INT);
$req->execute();
$resultat = $req->fetch(PD... | true |
416f12808b88f2b04115a95ad495ae784a55226c | PHP | yifangyun/fangcloud-php-sdk | /src/Http/YfyRequestBuilder.php | UTF-8 | 7,782 | 2.734375 | 3 | [
"MIT"
] | permissive | <?php
/**
* 请求的封装类
*/
namespace Fangcloud\Http;
use Fangcloud\Upload\YfyFile;
use Fangcloud\YfyAppInfo;
use Fangcloud\YfyClient;
use Fangcloud\YfyContext;
/**
* Class YfyRequestBuilder
* @package Fangcloud
*/
class YfyRequestBuilder
{
/**
* @var string 请求方法
*/
protected $method;
/**
* ... | true |
b28153d77e4a48d2f19758d5b50f67c9c1cf8f5f | PHP | nandulaperera/aplus-student-results-management-system | /application/models/User.php | UTF-8 | 595 | 2.84375 | 3 | [
"LicenseRef-scancode-unknown-license-reference",
"MIT"
] | permissive | <?php
class User extends CI_Model
{
function addUser($userData){
return $this->db->insert("users",$userData);
}
function authenticateUser($email,$password){
$this->db->where("email",$email);
$this->db->where("password",$password);
$loginResponse = $this->db->get("users");
if($loginResponse->num_rows() =... | true |
b28942b9ff6d81f26e76c36a6457e2ad0313d429 | PHP | robert-the-bruce/test | /class/dbconn.php | UTF-8 | 1,768 | 3.15625 | 3 | [] | no_license | <?php
class Dbconn
{
private $server;
private $db;
private $user;
private $password;
private $con;
private $query;
private $param;
private $statement;
public function __construct($server, $db, $user, $password)
{
$this->server = $server;
$this->db = $db;
... | true |
07628d36126691564fb8d7f804c9fe8f131c2f86 | PHP | QuentinDess/MemoryDex | /db/updateUser.php | UTF-8 | 2,139 | 2.765625 | 3 | [] | no_license | <?php
include '../templates/header_File.php';
include '../security/security_gamer.php';
try {
// Connexion à la DB
include 'dbconnexion.php';
// Requête SQL
$dbQuery = "SELECT id, name, password FROM Users WHERE id = :id";
// Préparation de la requête
$dbCheck = $dbConnection->prepare($dbQuery);
// Exécuter la requête... | true |
c7db364418d0584937a7b191d4b9eba27da81f1b | PHP | University-Of-Akron-WebTeam/mailAll | /app/Libraries/ExcelGet.php | UTF-8 | 1,320 | 2.921875 | 3 | [] | no_license | <?
class ExcelGet {
function __construct(){
}
function asArray($fileName, $columnNames)
{
$sheetCount = 0;
$rows = array();
$sheetCount = Excel::filter('chunk')->load($fileName)->getSheetCount();
foreach(range(0, $sheetCount-1) as $sheetIndex){
Excel::se... | true |
2acb70dc4c79b5b2ce0fc026aa0e7453f96a08dc | PHP | naufalmukhbit/plantstore | /application/models/Products_model.php | UTF-8 | 1,445 | 2.59375 | 3 | [
"MIT"
] | permissive | <?php
defined('BASEPATH') or exit('No direct script access allowed');
/**
*
*/
class Products_model extends CI_Model
{
public function get_data()
{
$query = $this->db->order_by('prod_name','DESC')->get('product');
return $query->result();
}
public function save_data($data,$imgsrc)
{
$param = array(
... | true |
66c68d6ff4d66ff2c662dff6ad93931ab346d74f | PHP | vievadymen/AppMobile | /backend/src/services/calculFrais.php | UTF-8 | 806 | 2.96875 | 3 | [] | no_license | <?php
namespace App\services;
use App\Repository\TabFraisRepository;
use ProxyManager\ProxyGenerator\ValueHolder\MethodGenerator\Constructor;
Class calculFrais {
private $rep;
private $fraisMontant;
public function __construct( TabFraisRepository $rep)
{
$this->rep = $rep;
}
public ... | true |
9f1cd757716b2c07d818dabdfe2d8c368278fdcb | PHP | fatkulnurk/imgbb | /src/Imgbb.php | UTF-8 | 1,029 | 2.84375 | 3 | [] | no_license | <?php
namespace FatkulNurk\Imgbb;
class Imgbb
{
var $endPoint = "https://api.imgbb.com/1/upload";
var $curl;
public function __construct($apiKey, $imageBase64, $name)
{
return $this->curl($apiKey, $imageBase64, $name);
}
private function curl($apiKey, $image, $name)
{
if... | true |
7b33fc8d1d65fa6e7847f0b161b683eeab33e93a | PHP | Kyntaz/mart_database | /web/produtos.php | UTF-8 | 3,265 | 2.734375 | 3 | [] | no_license | <html>
<head>
<style>
table, th, td {
border: 1px solid black;
}
</style>
</head>
<body>
<h3> Novo Produto </h3>
<form action="fornecedores_secundarios.php" method="post">
<p> EAN: <input type="text" name="ean"></p>
... | true |
84144eee2f7b639535811e03d4fbed5f4a030ffc | PHP | lapb/mypersia | /src/CCaptcha.php | UTF-8 | 1,027 | 2.609375 | 3 | [] | no_license | <?php
class CCaptcha {
private $errorMessage;
public function __construct() {
$this->errorMessage = "";
}
public function __destruct() {
}
public function getHTML() {
$this->errorMessage = "";
$publicKey = reCAPTCHA_PUBLIC_KEY;
require_once TP_GLOBAL_SOURCEPATH.'/rec... | true |
8c96270e9a64d5afca082885d4dd0b532f3dd656 | PHP | mocfaisal/CI_Libraries | /Salz.php | UTF-8 | 76,772 | 2.703125 | 3 | [
"Apache-2.0"
] | permissive | <?php
/**
* Salz Library v1.18.0
* Created By Mochammad Faisal
*
* Create Date 2019-03-01 13:20
* Last Update 2023-06-15 14:37:31
*
*
*/
class Salz {
protected $CI;
private $db;
private $sess;
private $userid;
public function __construct() {
date_default_timezone_set("Asia/Jakarta")... | true |
1ac6d02a40bc3fbba99eec612beadbf01fd25bcc | PHP | rexon13/php_test | /5_if.php | UTF-8 | 367 | 3.171875 | 3 | [] | no_license | <?php
/*$shop = false;
//$money =
if ($shop){
echo 'Иду в магазин<br>';
} else{
echo 'Иду в киоск <br>';
}
echo '<hr> Иду домой';*/
$a = 1;
if ($a == 1)
echo 'One';
else
echo 'Zero';
// тернарный опратор
//echo $a == 1 ? 'One' : 'Zero';
$b = ($a == 1) ? 'One' : 'Zero';
echo $b;
?... | true |
ee505e886bc88a4331e9e04d675cb43d78d9b4b8 | PHP | michalkurzeja/cpp2php | /output.php | UTF-8 | 126 | 2.609375 | 3 | [] | no_license | <?php
include 'stdio.h';
include 'file.php';
class A {
private $x;
public function getX() {
return $x;
}
}
function main() {
5 | true |
dc3e62642d93aa2162e03de48c2acd3c8be2c9ab | PHP | moogkwon/CoolFriend_Backend | /beta/application/controllers/Admin/Call.php | UTF-8 | 2,329 | 2.53125 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Call extends CI_Controller {
/**
* Index Page for this controller.
*
* Maps to the following URL
* http://example.com/index.php/welcome
* - or -
* http://example.com/index.php/welcome/index
* - or -
* Since this ... | true |
9606804411758398f2c4d64f630c4a8387c98411 | PHP | swapon-ahamed/laravel-6-e-Exam | /app/Http/Controllers/backend/QuestionsetsController.php | UTF-8 | 2,102 | 2.59375 | 3 | [] | no_license | <?php
namespace App\Http\Controllers\Backend;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use App\Models\Questionset;
class QuestionsetsController extends Controller
{
public function __construct()
{
$this->middleware('auth:admin');
}
public function index(){
$que... | true |
aebc4d2006396cb513bd9ebb6820c1002812bf61 | PHP | vutran-vn/research-project | /system/database/mongodb/db.php | UTF-8 | 4,090 | 3 | 3 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | <?php
/**
* Reference: https://mongodb.github.io/mongo-php-driver/crud/
*/
class DB {
private $document;
private $wc; //write concern
private $rp; //read preference
private $manager; //MongoDB Manager
public function DB() {
$this->manager = new MongoDB\Driver\Manager("mongodb://localhos... | true |
20aca671562ef5fe7f99376dabcbf4636f6dcda0 | PHP | brslv/zanshin | /Zanshin/Providers/InputProvider.php | UTF-8 | 654 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
namespace Zanshin\Providers;
use Pimple\Container;
use Pimple\ServiceProviderInterface;
use Zanshin\Components\Input\InputComponent;
/**
* Class InputProvider
*
* @author brlsv
* @package Zanshin\Providers
*/
class InputProvider implements ServiceProviderInterface
{
/**
* Registers a class, which... | true |
292b298936e647a6ca5b110ba10da738ae040e2f | PHP | tpikachu/YAWIK | /module/Core/src/View/Helper/Snippet.php | UTF-8 | 3,518 | 2.546875 | 3 | [
"MIT"
] | permissive | <?php
/**
* YAWIK
*
* @filesource
* @license MIT
* @copyright 2013 - 2017 Cross Solution <http://cross-solution.de>
*/
/** */
namespace Core\View\Helper;
use Core\EventManager\EventManager;
use Zend\EventManager\EventManagerInterface;
use Zend\Stdlib\ArrayUtils;
use Zend\View\Exception;
use Zend\View\Helper\... | true |
df82e3dfde8d2a9e9c843415ea2ffd5989f7b296 | PHP | ycamus/dynamicscrm-connector | /lib/Service/SecurityService.php | UTF-8 | 2,832 | 2.703125 | 3 | [] | no_license | <?php
use \Exception;
/**
* Class SecurityService
*
* @package Sixdg\DynamicsCRMConnector\Service
*/
class SecurityService
{
/**
* @var connector\lib\Helper\SoapRequester
*/
private $soapRequester;
/**
* @param RequestBuilder $requestBuilder
* @param SoapRequester $soapRequester
... | true |
1486189b6e5e00d703d85658770306343f12e4ee | PHP | nathanael79/moocs | /app/Model/Certificate.php | UTF-8 | 569 | 2.515625 | 3 | [] | no_license | <?php
namespace App\Model;
use Illuminate\Database\Eloquent\Model;
class Certificate extends Model
{
protected $table = 'certificate';
protected $fillable =
[
'certificate_name',
'lecturer_id',
'course_id',
'user_id',
'user_type',
... | true |
9a64e3ee47a41131f5c3f615f4967f66dfaca8ee | PHP | mmockelyn/v3 | /database/seeds/WikiSeeder.php | UTF-8 | 865 | 2.734375 | 3 | [] | no_license | <?php
use Illuminate\Database\Seeder;
class WikiSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @param \Faker\Generator $faker
* @return void
*/
public function run(\Faker\Generator $faker)
{
for ($i=0; $i < 25; $i++) {
$category = rand(1,3);
... | true |
46bf8afc2c6142ad3ad4c412eb04a44b80fffd34 | PHP | valeriotto/task14 | /knowledge.inc.php | UTF-8 | 292 | 3.109375 | 3 | [] | no_license |
<?php
$a = 'Мои знания на';
$b = 100;
$c = '%';
?>
<?php
$price = 15;
if($price >= 15 && $price <= 20)
$d = 'Это число находится между 15 и 20';
?>
<?php
$e = 5;
$f = 5;
$x1 = $e + $f;
$x2 = $e % $f;
?>
<?php
$val = __LINE__;
?> | true |
c1c21e1c89982ab5d1f6220aec9f61361fe4f695 | PHP | rajveer-web/car-tours | /registration/insertprofile.php | UTF-8 | 772 | 2.625 | 3 | [
"BSD-3-Clause"
] | permissive | <?php
//connection database
$conn = mysqli_connect("localhost", "root", "", "cars");
if (isset($_POST['insert']))
{
//define variable
$id = $_POST['id'];
$name = $_POST['name'];
$mobile = $_POST['mobile'];
$address = $_POST['address'];
$city = $_POST['city'];
$email = $_POST['email'];
$quali = $_POST['quali'];
$gender ... | true |
585f530d273b32166726967d6ba5d0a4aee2e655 | PHP | claudejdev/PHP_exos | /boucles_exos.php | UTF-8 | 2,358 | 2.9375 | 3 | [] | no_license | <?php
$pronoms_personnels = array(
'Je' => 'code',
'Tu' => 'codes',
'Il/Elle' => 'code',
'Nous' => 'codons',
'Vous' => 'codez',
'Elles/Ils' => 'codent',
);
$web_development ['frontend'][] = 'xhtml';
$web_development ['backend'][] = 'Ruby on Rails';
$web_development ['frontend'][] = 'CSS';
$web_development ... | true |
a22c02b21476265d091f8e966e004b518eaad2ca | PHP | Nirjhor3029/i-Lab | /app/Mail/TwoFactorAuthenticationMail.php | UTF-8 | 860 | 2.515625 | 3 | [] | no_license | <?php
namespace App\Mail;
use App\User;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
class TwoFactorAuthenticationMail extends Mailable
{
use Queueable, SerializesModels;
public $two_factor_auth_token;
/**... | true |
43db36f7219dbe490b4f1ffe0583eddc2445ca41 | PHP | andrewroth/c4c_intranet | /objects/XMLObject.php | UTF-8 | 10,377 | 3.28125 | 3 | [] | no_license | <?php
/**
* @package AIobjects
*/
/**
* class XMLObject
* <pre>
* Written By : Johnny Hausman
* Date : 18 Aug '04
*
* This is a generic XML Object for all the objects in the Web Site. It
* provides a basic set of XML output functionality.
* </pre>
*/
class XMLObject extends SiteObject {
// CONSTANTS:... | true |
1750c03d6bb834c2a8bf6959403fe67069db20ae | PHP | gurkalov/eva-position | /src/app/Http/Controllers/Traits/CrudTrait.php | UTF-8 | 4,190 | 2.71875 | 3 | [] | no_license | <?php
namespace App\Http\Controllers\Traits;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Http\JsonResponse;
use Illuminate\Http\Request;
use Illuminate\Database\QueryException;
/**
* Description of CrudTrait
*
* @author ognestraz
*/
trait CrudTrait
{
/**
* Apply select
*
* @param Re... | true |
49c335168a5dd7727d77b60dd0c69a1f8e596488 | PHP | Kicky13/eprocurementSE | /app12/helpers/array_helper.php | UTF-8 | 2,422 | 3 | 3 | [] | no_license | <?php defined('BASEPATH') OR exit('No direct script access allowed');
$sys_helper = SYSDIR.DIRECTORY_SEPARATOR.'/helpers/array_helper.php';
file_exists($sys_helper) AND require_once($sys_helper);
if (!function_exists('array_pluck')) {
/**
* Pluck an array of values from an array.
*
* @param array... | true |
93a4c0066c868c0c711a96775de8b9b0fa72798f | PHP | rafaelyepes/php7 | /app/controllers/asociados.php | UTF-8 | 1,146 | 2.5625 | 3 | [] | no_license | <?php
require_once 'utils/utils.php';
require_once 'exceptions/FileException.php';
require_once 'exceptions/ValidationException.php';
require_once 'utils/File.php';
require_once 'entity/Asociado.php';
$errores=[];
try {
if($_SERVER['REQUEST_METHOD'] === 'POST')
{
$nombre = trim(htmlspecialchars($... | true |
e2939b390f6f9340ee951c0a149c386ed266fb0f | PHP | P79N6A/php | /ptshare/ptshare/admin/src/application/models/Lottery.php | UTF-8 | 2,627 | 2.6875 | 3 | [] | no_license | <?php
class Lottery extends Table
{
public $status = array(
'Y' => '开启',
'N' => '关闭',
);
public function __construct()
{
$this->setDBConf("MYSQL_CONF_MALL");
$this->setTableName('lottery');
}
public function getLotteryConfigDetail($issue)
{
$query ... | true |
53b5618e1fb595824dfca8c704f3476c5faef03c | PHP | litlin88/line-bot-sdk-php | /src/LINEBot/Event/Things/ThingsResultAction.php | UTF-8 | 1,494 | 2.765625 | 3 | [
"Apache-2.0"
] | permissive | <?php
/**
* Copyright 2019 LINE Corporation
*
* LINE Corporation licenses this file to you under the Apache License,
* version 2.0 (the "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at:
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* ... | true |
37a371aab71b57757f0d604066541c51a80a3f02 | PHP | bbc/newsspec_11329 | /source/data/compileData.php | UTF-8 | 873 | 2.734375 | 3 | [
"Apache-2.0"
] | permissive | <?php
$responses = array('a', 'b', 'c', 'd');
$count = 1;
$csv = fopen('user_response_permutations.csv', 'w');
foreach ($responses as $a) {
foreach ($responses as $b) {
foreach ($responses as $c) {
foreach ($responses as $d) {
foreach ($responses as $e) {
pri... | true |
5b61025ef2c8548ff8a0630e9ab81d57cd5c8bf0 | PHP | UWAA/columns-magazine | /vendor/Columns/Menus/Navigation.php | UTF-8 | 572 | 2.671875 | 3 | [] | no_license | <?php namespace Columns\Menus;
class Navigation {
function __construct() {
if ( ! function_exists( 'columns_navigation_menu' ) ) {
add_action( 'init', array($this, 'columns_navigation_menu' ));
}
}
// Register Navigation Menus
public function columns_navigation_me... | true |
7be9c9aa1aec4e6381b8239488a6ad0c809ea59c | PHP | robertthibault/Projet-Bourse-aux-livres | /backend/public/downloader.php | UTF-8 | 3,994 | 2.578125 | 3 | [] | no_license | <?php
// Bootstraping
$bootstrapPath = realpath(dirname(__FILE__) . '/../application/bootstrap.php');
require_once $bootstrapPath;
function CSVData_StatRessource($data, $exercice, $ref) {
//Déclaration du séparateur de fichier
$sep = '/';
$dataCSV = array();
$row = "";
//Ajout première ligne heade... | true |
cf9e2ab32243627224a5328bcd537f22fa49542c | PHP | HRPiksa/bd-zavrsni-rad | /app/Http/Controllers/LoginController.php | UTF-8 | 1,133 | 2.640625 | 3 | [
"MIT"
] | permissive | <?php
namespace App\Http\Controllers;
use App\Events\UserSuccessfulLogin;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
class LoginController extends Controller
{
public function index()
{
return view( 'login' );
}
public function login( Request $request )
{
$... | true |
69706b48355ee7ce7938a99e6ba3843311933197 | PHP | Aerendir/bundle-stripe | /src/Manager/StripeManager.php | UTF-8 | 19,426 | 2.609375 | 3 | [
"MIT"
] | permissive | <?php
declare(strict_types=1);
/*
* This file is part of the Serendipity HQ Stripe Bundle.
*
* Copyright (c) Adamo Aerendir Crespi <aerendir@serendipityhq.com>.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Serendipi... | true |
6bb47c3a45f6aa7c2eca2c44abddf723e1ee729b | PHP | FelipeIzquierdo/histoweb | /app/Entities/StateWay.php | UTF-8 | 371 | 2.515625 | 3 | [
"MIT"
] | permissive | <?php namespace Histoweb\Entities;
use Illuminate\Database\Eloquent\Model;
class StateWay extends Model
{
public $table = "state_ways";
public $primaryKey = "id";
public $timestamps = true;
public $fillable = [
"name",
"description",
"code"
];
public static function allLists()
{
... | true |
79acf0f00519afb59eabf57a2ede6da4cf34b70f | PHP | SMAtaurRahman/phtml | /src/Parser.php | UTF-8 | 6,328 | 2.90625 | 3 | [
"MIT"
] | permissive | <?php
namespace PHTML;
use PHTML\DOM\Index;
class Parser
{
const SELF_CLOSE_TAGS = [
'area' => true,
'base' => true,
'basefont' => true,
'br' => true,
'col' => true,
'embed' => true,
'frame' => true,
'hr' => true,
'img' => true,
'inp... | true |
95b4eb8e9409ea43e552387e387075a06f9c0034 | PHP | hcisilio/salao | /Classes/classeFisica.php | UTF-8 | 972 | 3.09375 | 3 | [] | no_license | <?php
include_once("classePessoa.php");
class Fisica extends Pessoa {
var $cpf;
var $rg;
var $sexo;
var $mail;
var $senha;
var $permissao;
//metodos get:
function getCPF() {
return $this->cpf;
}
function getRG() {
return $this->rg;
}
function getS... | true |
070c6003a89167142e65fed5d066d429f38ee484 | PHP | sunsetFog/php | /app/wq/addons/yun_shop/app/frontend/modules/deduction/orderGoods/amount/GoodsPriceProportion.php | UTF-8 | 513 | 2.609375 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: shenyang
* Date: 2017/10/13
* Time: 下午5:05
*/
namespace app\frontend\modules\deduction\orderGoods\amount;
/**
* 按比例抵扣金额
* Class Proportion
* @package app\frontend\modules\deduction\orderGoods\amount
*/
class GoodsPriceProportion extends OrderGoodsDeductionAmount
{
... | true |
d43af457db1459ca51bbb99ed1c02e74e7c1e3e9 | PHP | Basile-Lequeux/App-CEMVS | /src/Actions/ActionsPerformance.php | UTF-8 | 3,427 | 2.65625 | 3 | [] | no_license | <?php
namespace App\Actions;
use App\Entity\Competitions;
use App\Entity\Entrainement;
use App\Entity\CompetitionsUser;
use App\Entity\EntrainementUser;
class ActionsPerformance{
public function getPerfCompetition($manager,$user){
// les competitions Tirées par le tireur
$competitionsparticipa... | true |
4d18c0eae5c623fe903611c1c80e25866e6097bd | PHP | markhker/AgencySite | /send_contact.php | UTF-8 | 1,226 | 2.71875 | 3 | [] | no_license | <?php
$my_email = 'mark@karmik.com.mx';
/* Do not change any code below this line unless you are sure what you are doing. */
$name = $_POST['name'];
$email = $_POST['email'];
$phone = $_POST['phone'];
$message = $_POST['message'];
$errors = array();
if ($name == '')
{
$errors['name'] = 'Introduzca su nombre!';
}
... | true |
50068e69b929df873ce880c9a7b37fb8e4fdb516 | PHP | khozhiy/becoming | /example_of_my_code/students/models/Student.php | UTF-8 | 1,605 | 2.9375 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: Khozh
* Date: 03.10.2017
* Time: 19:14
*/
class Student
{
public static function getStudents()
{
$db = Db::getConnection();
$result = $db->query('SELECT * FROM students');
$result->setFetchMode(PDO::FETCH_ASSOC);
return $result->fe... | true |
b17ce0bcb2e56c3194583c9d928f03bcebc97f63 | PHP | fernandoinforedes/Fernandez | /src/Soma.php | UTF-8 | 509 | 3.25 | 3 | [] | no_license | <?php
/**
* Created by PhpStorm.
* User: nando
* Date: 06/06/14
* Time: 21:32
*/
class Soma {
private $numberOne;
private $numberTwo;
public function setNumberOne($numberOne)
{
$this->numberOne = $numberOne;
}
public function setNumberTwo($numberTwo)
{
$this->numbe... | true |
4912d6f262c9e24fe70d1221ec594d4a399bc8ad | PHP | npfund/adventofcode2015 | /3/3-1.php | UTF-8 | 617 | 3.265625 | 3 | [] | no_license | <?php
$directions = file_get_contents('3.txt');
$length = strlen($directions);
$position = ['x' => 0, 'y' => 0];
$houses = ['0,0'];
for ($i = 0; $i < $length; ++$i) {
switch ($directions[$i]) {
case '^':
++$position['y'];
break;
case 'v':
--$position['y'];
... | true |
17aeb0d309edaa33e3533c14c40ba3f6a9f5e6e2 | PHP | Marttyn/jobsity_chatbot | /app/Conversations/BalanceConversation.php | UTF-8 | 3,091 | 2.765625 | 3 | [] | no_license | <?php
namespace App\Conversations;
use App\User;
use Illuminate\Foundation\Inspiring;
use BotMan\BotMan\Messages\Incoming\Answer;
use BotMan\BotMan\Messages\Outgoing\Question;
use BotMan\BotMan\Messages\Outgoing\Actions\Button;
use BotMan\BotMan\Messages\Conversations\Conversation;
use Illuminate\Support\Facades\Auth... | true |
a7bcd96a7c20355c682ea31260e0e760e10e69b7 | PHP | ArtARTs36/laravel-notifications-logger | /src/Models/System.php | UTF-8 | 494 | 2.578125 | 3 | [
"MIT"
] | permissive | <?php
namespace ArtARTs36\LaravelNotificationsLogger\Models;
use Illuminate\Database\Eloquent\Model;
/**
* @property int $id
* @property string $title
* @property string $slug
*/
class System extends Model
{
public const FIELD_TITLE = 'title';
public const FIELD_SLUG = 'slug';
public $timestamps = f... | true |