conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "Update namespace and add one more function in order to override csrf_token field\n" }, { "from": "human", "value": "<?php\n\nnamespace AppBundle\\Form;\n\nuse Symfony\\Component\\Form\\AbstractType;\nuse \\Symfony\\Component\\Form\\FormBuilderInterface;\nuse FOS\\Us...
php
chosen
[ { "from": "system", "value": "Add link to club name\n" }, { "from": "human", "value": "<h1>打卡紀錄</h1>\n<ul class=\"list-group\">\n @forelse($records as $record)\n <li class=\"list-group-item\">\n <div>\n <h4>{{ $record->club->name }}\n {!! $r...
php
chosen
[ { "from": "system", "value": "Fix require glide configuration for tests\n\nAdd 'source' and 'cache' for glide.options\n" }, { "from": "human", "value": "<?php\n\nuse Assembly\\Container\\Container;\nuse GlideModule\\GlideDefinitionProvider;\n\nclass GlideDefinitionProviderTest extends \\PHPUnit_...
php
chosen
[ { "from": "system", "value": "Add empty line at EOF\n" }, { "from": "human", "value": "<?php namespace Modules\\Blog\\Repositories\\Cache;\n\nuse Modules\\Blog\\Repositories\\TagRepository;\nuse Modules\\Core\\Repositories\\Cache\\BaseCacheDecorator;\n\nclass CacheTagDecorator extends BaseCacheD...
php
chosen
[ { "from": "system", "value": "Update example for repository autowired\n\nThe example was a fast copy/paste from the ORM version.\r\nThe ODM one is a little different" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Doctrine\\Bundle\\MongoDBBundle\\Repository;\n\nus...
php
chosen
[ { "from": "system", "value": "Move abstract declaration in front to precede visibility\n" }, { "from": "human", "value": "<?php\n/**\n * This file is part of HookMeUp.\n *\n * (c) Sebastian Feldmann <sf@sebastian.feldmann.info>\n *\n * For the full copyright and license information, please view ...
php
chosen
[ { "from": "system", "value": "Read only to force the use of the time picker\n" }, { "from": "human", "value": "<div class=\"input-append bootstrap-timepicker\">\n <input name=\"<?php echo $nameform ?>\" type=\"text\" class=\"timepicker\" value=\"<?php echo $value ?>\">\n <span class=\"add...
php
chosen
[ { "from": "system", "value": "Make sami/sami config PSR1/2 compliant\n" }, { "from": "human", "value": "<?php\n\nuse Sami\\Sami;\nuse Sami\\Version\\GitVersionCollection;\nuse Symfony\\Component\\Finder\\Finder;\n\n$dir = __DIR__ . '/src';\n$iterator = Finder::create()\n ->files()\n ->name...
php
chosen
[ { "from": "system", "value": "Disable the linking form - javascript loading problem.\n\nPrevents the linking form from being visible at all.\n" }, { "from": "human", "value": "<?php\n\nDirector::addRules(60, array(\n\t'extadmin' => 'ExternalContentAdmin',\n\t'extcon' => 'ExternalContentPage_Cont...
php
chosen
[ { "from": "system", "value": "Revert \"The url for the modal file window was corrected\"\n\nThis reverts commit 4d357db0a731837900a88dfdb4535f0268885a9e." }, { "from": "human", "value": "<?php\n\nuse pendalf89\\filemanager\\Module;\nuse pendalf89\\filemanager\\assets\\ModalAsset;\nuse yii\\helpe...
php
chosen
[ { "from": "system", "value": "Fix RedirectUrl for Password Resets\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Controllers\\Auth;\n\nuse App\\Http\\Controllers\\Controller;\nuse Illuminate\\Foundation\\Auth\\ResetsPasswords;\n\nclass ResetPasswordController extends Controller...
php
chosen
[ { "from": "system", "value": "Stop script execution after output of json-data so content type header is correct.\n" }, { "from": "human", "value": "<?php\nnamespace ShinyGeoip\\Responder;\n\nuse ShinyGeoip\\Core\\Responder;\n\nclass ApiRequestResponder extends Responder\n{\n /**\n * Echos...
php
chosen
[ { "from": "system", "value": "Mark SSH2 Test as Incomplete on Travis PHP 5.3.3 and below for now.\n" }, { "from": "human", "value": "<?php\n\n/**\n * @author Andreas Fischer <bantu@phpbb.com>\n * @copyright MMXIV Andreas Fischer\n * @license http://www.opensource.org/licenses/mit-license.ht...
php
chosen
[ { "from": "system", "value": "Add comments link to the HN thread" }, { "from": "human", "value": "<?php\n\nnamespace j0k3r\\FeedBundle\\Parser;\n\n/**\n * HackernewsParser\n *\n * This class provides a custom parser for news.ycombinator.com feed\n */\nclass HackernewsParser extends DefaultParser...
php
chosen
[ { "from": "system", "value": "Create a method that generates a concatenated list of Bootstrap CSS col-*-* classes suitable for thumbnails.\n" }, { "from": "human", "value": "<?php\n\n/**\n * Class GalleryImageExtension\n *\n * @property Image|GalleryImageExtension $owner\n */\nclass GalleryImage...
php
chosen
[ { "from": "system", "value": "Add correct namespace to webservice and add project id to querydata\n" }, { "from": "human", "value": "<?php\n\nnamespace fennecweb\\ajax\\details;\n\nclass ProjectsTest extends \\PHPUnit_Framework_TestCase\n{\n const NICKNAME = 'detailsProjectsTestUser';\n co...
php
chosen
[ { "from": "system", "value": "Fix typo in json string\n" }, { "from": "human", "value": "<?php\n\nnamespace spec\\SearchApi\\Providers;\n\nuse SearchApi;\nuse SearchApi\\Models;\nuse SearchApi\\Services\\Search;\nuse SearchApi\\Builders\\QueryBuilder;\nuse SearchApi\\Clients\\HttpClient;\n\nuse ...
php
chosen
[ { "from": "system", "value": "Fix the divs, do away with the 4/8 format" }, { "from": "human", "value": "<?php\n/*\n * Basic page\n */\n?>\n\n<div class=\"container-fluid\">\n\t<h1><?php echo _('Heading')?></h1>\n\t<div class=\"well well-info\">\n\t\t<?php echo _('Page info')?>\n\t</div>\n\t<div...
php
chosen
[ { "from": "system", "value": "Stop passing middleware to Processor constructor\n\nThe middleware is no longer used by the processor.\n" }, { "from": "human", "value": "<?php\n\nnamespace Lstr\\Sprintf;\n\nclass Sprintf\n{\n /**\n * @var callable\n */\n private $middleware;\n\n /...
php
chosen
[ { "from": "system", "value": "Add helper function for asset\n" }, { "from": "human", "value": "<?php\n" }, { "from": "gpt", "value": "<?php\n\nif ( ! function_exists('fs_asset')) {\n function fs_asset($assetFolder, $afterPath, $force = false)\n {\n return \\Reshadman\\Fi...
php
chosen
[ { "from": "system", "value": "Add autofocus to login form\n" }, { "from": "human", "value": "<?php\n\tsession_start();\n?>\n<!DOCTYPE html>\n<html lang=\"de\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\n\t\t<title>SSBO Ticketing - Login</title>\n\t\t<meta name=\"description\" content=\"SSBO Ti...
php
chosen
[ { "from": "system", "value": "Fix join condition and remove QueryDriver::free statement\n" }, { "from": "human", "value": "<?php\n\nclass MigrationRunnerTest extends PHPUnit_Framework_TestCase\n{\n function testRunner()\n {\n LazyRecord\\QueryDriver::free();\n $connm = LazyRe...
php
chosen
[ { "from": "system", "value": "Make abstract method final to avoid unwanted overloading\n" }, { "from": "human", "value": "<?php\n\nnamespace Trappar\\AliceGenerator\\Metadata\\Resolver\\Faker;\n\nuse Trappar\\AliceGenerator\\DataStorage\\ValueContext;\nuse Trappar\\AliceGenerator\\Faker\\FakerGe...
php
chosen
[ { "from": "system", "value": "Remove no longer needed methods\n" }, { "from": "human", "value": "<?php\n\nnamespace Drupal\\AppConsole\\Command\\Helper;\n\nuse Symfony\\Component\\Console\\Helper\\DialogHelper as BaseDialogHelper;\nuse Symfony\\Component\\Console\\Output\\OutputInterface;\n\ncla...
php
chosen
[ { "from": "system", "value": "Set is_public on create note\n" }, { "from": "human", "value": "<?php\n\nnamespace AppBundle\\Controller;\n\nuse AppBundle\\Entity\\Note;\nuse Sensio\\Bundle\\FrameworkExtraBundle\\Configuration\\Route;\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller;\...
php
chosen
[ { "from": "system", "value": "[Chopbox] Arrange imports from shortest to longest\n" }, { "from": "human", "value": "<?php\n\nnamespace ChopBox\\Http\\Controllers;\n\nuse Illuminate\\Http\\Request;\n\nuse ChopBox\\Http\\Requests;\nuse ChopBox\\Http\\Controllers\\Controller;\n\nclass HelpAndPrivac...
php
chosen
[ { "from": "system", "value": "Move the package registration to the service provider boot() method\n" }, { "from": "human", "value": "<?php namespace Watson\\Active;\n\nuse Illuminate\\Support\\ServiceProvider;\n\nclass ActiveServiceProvider extends ServiceProvider {\n\n\t/**\n\t * Indicates if l...
php
chosen
[ { "from": "system", "value": "Address Scrutinizer issue on empty catch block.\n" }, { "from": "human", "value": "<?php\nnamespace common\\models;\n\nuse common\\helpers\\Utils;\nuse yii\\helpers\\ArrayHelper;\nuse yii\\helpers\\Json;\n\nclass EventLog extends EventLogBase\n{\n /**\n * @re...
php
chosen
[ { "from": "system", "value": "Add another field to the host page\nIts important to know what platform you're playing on! Well, it can be.\nAlso add required attributes where useful.\n" }, { "from": "human", "value": "<!DOCTYPE html>\n<html>\n<head>\n\t<?php include(\"../include/common.html\"); ?...
php
chosen
[ { "from": "system", "value": "Correct relative link to the categories\n" }, { "from": "human", "value": "<aside id=\"blog-sidebar\">\n\t<section class=\"latest-posts\">\n\t\t<h3>Latest Posts</h3>\n\t\t<ul>\n\t\t<?php\n\t\t\tglobal $post;\n\t\t\t$args = array( 'numberposts' => 5 );\n\t\t\t$mypost...
php
chosen
[ { "from": "system", "value": "Fix misnamed SwatHtmltag\nThis was probably never caught because we seldom (if ever) use SwatDisplableContainer's own display() method\n\n\nsvn commit r10293\n" }, { "from": "human", "value": "<?php\n\nrequire_once 'Swat/SwatContainer.php';\n\n/**\n * Base class for...
php
chosen
[ { "from": "system", "value": "Use the correct class name.\n\n\nsvn commit r7882\n" }, { "from": "human", "value": "<?php\n\nrequire_once 'Swat/SwatContainer.php';\n\n/**\n * Base class for containers that display an XHTML element\n *\n * @package Swat\n * @copyright 2006 silverorange\n * @lice...
php
chosen
[ { "from": "system", "value": "Use txn_load_full() method so we get all the data we need\n" }, { "from": "human", "value": "<?\ninclude '../scat.php';\ninclude '../lib/txn.php';\n\n$id= (int)$_REQUEST['id'];\n\n$type= $_REQUEST['type'];\n$number= (int)$_REQUEST['number'];\n\nif (!$id && $type) {\...
php
chosen
[ { "from": "system", "value": "Remove timestamps from role_user table\n" }, { "from": "human", "value": "<?php\n\nuse Illuminate\\Database\\Migrations\\Migration;\nuse Illuminate\\Database\\Schema\\Blueprint;\n\nclass CreateRoleUserTable extends Migration {\n\n /**\n * Run the migrations.\n ...
php
chosen
[ { "from": "system", "value": "Use the plugin() method instead of __call()\n" }, { "from": "human", "value": "<?php\nnamespace SxBootstrap\\View\\Helper\\Bootstrap;\n\n//use SxBootstrap\\Exception;\nuse Zend\\View\\Helper\\AbstractHelper;\n\n/**\n * ViewHelper to add twitter bootstrap to the head...
php
chosen
[ { "from": "system", "value": "Add correct i18n for layout\n" }, { "from": "human", "value": "<?php\n\n\n$app['i18n']['en'] = array(\n 'template' => array(\n 'code_placeholder' => 'code',\n 'button_save' => 'Save',\n '' => '',\n '' => '',\n '' => '',\n ...
php
chosen
[ { "from": "system", "value": "Check interfaces, and abstract classes\n" }, { "from": "human", "value": "<?php\r\n\r\nnamespace Tests;\r\n\r\nuse PHPUnit\\Framework\\TestCase;\r\nuse App\\Contracts\\SortingAlgorithm;\r\n\r\nclass AlgorithmTest extends TestCase\r\n{\r\n /**\r\n * List of al...
php
chosen
[ { "from": "system", "value": "Add lang to `html` tag\n\nh/t shivampaw\n" }, { "from": "human", "value": "<!doctype html>\n<html amp>\n<head>\n\t<meta charset=\"utf-8\">\n\t<meta name=\"viewport\" content=\"width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no\">\n\t...
php
chosen
[ { "from": "system", "value": "Add Last Modified date and author" }, { "from": "human", "value": "#!/usr/bin/env php\n<?php\n\nif (empty($argv[1])) {\n fputs(STDERR, \"1st argument is empty; Pass me a text file which contains file list\\n\");\n exit(1);\n}\nif (empty($argv[2])) {\n fputs...
php
chosen
[ { "from": "system", "value": "Fix static and private combination\n" }, { "from": "human", "value": "<?php\n/**\n * Part of CI PHPUnit Test\n *\n * @author Kenji Suzuki <https://github.com/kenjis>\n * @license MIT License\n * @copyright 2015 Kenji Suzuki\n * @link https://github.com...
php
chosen
[ { "from": "system", "value": "Remove exception when key doesn't exist just return null\n" }, { "from": "human", "value": "<?php\n\nnamespace Nisaac2fly\\AuthSamlWrapper\\Laravel;\n\nuse Exception;\n\nclass Attributes {\n\n /**\n * @var array\n */\n protected $attributes = [];\n\n ...
php
chosen
[ { "from": "system", "value": "Add activation auth method, needed for lost password in tests\n" }, { "from": "human", "value": "<?php\nclass Kwf_User_AuthPassword_FnF extends Kwf_Model_FnF\n{\n protected $_toStringField = 'email';\n protected $_hasDeletedFlag = true;\n\n protected functi...
php
chosen
[ { "from": "system", "value": "Fix socket web request interface\n" }, { "from": "human", "value": "<?php\n\n/**\n * This file is part of the RequestStream package\n *\n * (c) Vitaliy Zhuk <zhuk2205@gmail.com>\n *\n * For the full copyright and license information, please view the LICENSE\n * file...
php
chosen
[ { "from": "system", "value": "Revert \"Change return type hinting to reference the Proxy class\"\n\nThis reverts commit 9ea4df8541c682097304bc9b1b42f68307f8d57e.\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace ProxyManager\\ProxyGenerator\\NullObject\\MethodGene...
php
chosen
[ { "from": "system", "value": "Add Comments to Controller Classifier\n" }, { "from": "human", "value": "<?php\n\nnamespace Wnx\\LaravelStats\\Classifiers;\n\nuse Wnx\\LaravelStats\\ReflectionClass;\nuse Wnx\\LaravelStats\\Contracts\\Classifier;\n\nclass ControllerClassifier implements Classifier\...
php
chosen
[ { "from": "system", "value": "Include test with multiple tokens\n" }, { "from": "human", "value": "<?php\n\nnamespace RomansTest\\Parser;\n\nuse PHPUnit\\Framework\\TestCase;\nuse Romans\\Grammar\\Grammar;\nuse Romans\\Parser\\Parser;\n\n/**\n * Parser Test\n */\nclass ParserTest extends TestCas...
php
chosen
[ { "from": "system", "value": "Make plugin compatible with FoC/Crud\n\nThey made a similar solution: https://github.com/FriendsOfCake/crud/blob/master/aliases.php\r\n\r\nhowever I get following error \r\n```\r\nPHP Warning: Cannot declare class Cake\\Http\\Exception\\NotFoundException, because the name is a...
php
chosen
[ { "from": "system", "value": "Move code content to center of view\n" }, { "from": "human", "value": "@extends(\"layout.base\")\n\n@section(\"title\", \"Wdi Paste - {$paste->name}\")\n\n@section(\"container\")\n <h1 class=\"display-1\">{{ $paste->name }}<small>.{{$paste->extension}}</small></h...
php
chosen
[ { "from": "system", "value": "Make IDE stop complaining about syntax error\n" }, { "from": "human", "value": "<?php\n\nnamespace PHPFastCGI\\FastCGIDaemon\\Driver;\n\nclass DriverContainer implements DriverContainerInterface\n{\n /**\n * @var array\n */\n private $drivers;\n\n /...
php
chosen
[ { "from": "system", "value": "Remove id attribute from input\n" }, { "from": "human", "value": "<?php\n\nnamespace Banklink\\Request;\n\n/**\n * Generic request representation\n *\n * @author Roman Marintsenko <inoryy@gmail.com>\n * @since 31.10.2012\n */\nabstract class Request\n{\n protect...
php
chosen
[ { "from": "system", "value": "Make exception more specific when retrieving a calendar type that does not exist in the calendar factory.\n" }, { "from": "human", "value": "<?php\n\nnamespace Plummer\\Calendarful\\Calendar;\n\nclass CalendarFactory implements CalendarFactoryInterface\n{\n\tprivate...
php
chosen
[ { "from": "system", "value": "Add Sonata\nDebug : user_type in RegistrationForm2\n" }, { "from": "human", "value": "<?php\n\nnamespace FaimfonyBundle\\Form;\n\nuse Symfony\\Component\\Form\\AbstractType;\nuse Symfony\\Component\\Form\\FormBuilderInterface;\n\nclass RegistrationType extends Abstr...
php
chosen
[ { "from": "system", "value": "Fix issue where parent slug was not being included on NEW entries\n" }, { "from": "human", "value": "<?php namespace Anomaly\\PagesModule\\Page\\Form;\n\nuse Anomaly\\PagesModule\\Page\\Command\\GetRealPath;\nuse Anomaly\\PagesModule\\Page\\Contract\\PageInterface;\...
php
chosen
[ { "from": "system", "value": "Replace the hard coded dictionary path with a variable." }, { "from": "human", "value": "<?php\n\nnamespace TuxOne\\ValidationBundle\\Validator\\Constraints;\n\nuse Symfony\\Component\\Validator\\Constraint;\nuse Symfony\\Component\\Validator\\ConstraintValidator;\n...
php
chosen
[ { "from": "system", "value": "Move '$theme' injection in partial method\n" }, { "from": "human", "value": "<?php\n\nnamespace Bloge\\Renderers;\n\nuse Bloge\\NotFoundException;\n\n/**\n * Basic renderer\n * \n * This renderer renders raw PHP templates\n * \n * @package bloge\n */\nclass PHP impl...
php
chosen
[ { "from": "system", "value": "Support for pulling out a single service point by product + reference\n" }, { "from": "human", "value": "<?php\nnamespace Sendworks;\n\nclass ServicePointsCollection {\n protected $connection;\n\n function __construct($connection) {\n $this->connection = $conne...
php
chosen
[ { "from": "system", "value": "Refactor (Registration Controller): Define security acces level\n" }, { "from": "human", "value": "<?php\n\nnamespace AppBundle\\Controller;\n\nuse Sensio\\Bundle\\FrameworkExtraBundle\\Configuration\\Route;\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Control...
php
chosen
[ { "from": "system", "value": "Revert upload_history tabs to tabs instead of pills\n\nSigned-off-by: Florian Pritz <753f544d2d01592750fb4bd29251b78abcfc8ecd@xinu.at>\n" }, { "from": "human", "value": "<ul class=\"nav nav-pills nav-history\">\n<?php\n$nav = array(\n\t\"List\" => \"file/upload_hist...
php
chosen
[ { "from": "system", "value": "Fix database connection in test\n" }, { "from": "human", "value": "<?php\n\nnamespace geotime\\Test;\n\nuse PHPUnit_Framework_TestCase;\nuse geotime\\models\\Map;\n\n\nclass MapTest extends \\PHPUnit_Framework_TestCase {\n\n static function setUpBeforeClass() {\n...
php
chosen
[ { "from": "system", "value": "Disable connector to run in beast.\n\ngit-svn-id: d46fe582d22b46b457d3ac1c55a88da2fbe913a1@1410 baf6b65b-9124-4dc3-b1c0-01155b4af546\n" }, { "from": "human", "value": "<?php\n//exit; \n/* connector for Turbellarian\nestimated execution time: 2 hrs.\nThis connector g...
php
chosen
[ { "from": "system", "value": "Fix test: use sortable because builtin does not accept third parameter.\n" }, { "from": "human", "value": "<?php\n\nnamespace Mimic\\Test;\n\nuse PHPUnit_Framework_TestCase;\nuse Mimic\\Functional as F;\n\n/**\n * Unit Test for sort Mimic library function.\n *\n * @...
php
chosen
[ { "from": "system", "value": "Update the client manipulator interface's user return to match up with the security token types" }, { "from": "human", "value": "<?php declare(strict_types=1);\n\nnamespace Gos\\Bundle\\WebSocketBundle\\Client;\n\nuse Ratchet\\ConnectionInterface;\nuse Ratchet\\Wamp...
php
chosen
[ { "from": "system", "value": "Fix for VIP Pricing, French State Display, VIP Links to LoginLink, Fixes for UTF8 display of states.\n" }, { "from": "human", "value": "<?php\n\nnamespace Rcm\\Controller;\nuse Rcm\\Controller\\EntityMgrAwareController;\n\n\nclass StateApiController extends EntityMg...
php
chosen
[ { "from": "system", "value": "Simplify assertion; testing for empty content is done by the parent\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace SimpleSAML\\SAML2\\XML\\md;\n\nuse SimpleSAML\\Assert\\Assert;\nuse SimpleSAML\\SAML2\\Exception\\ProtocolViolationE...
php
chosen
[ { "from": "system", "value": "Update test depending on environment (BO or FO)\n" }, { "from": "human", "value": "<?php\n\nnamespace OpenOrchestra\\ModelBundle\\Tests\\Functional\\Repository;\n\nuse OpenOrchestra\\ModelInterface\\Repository\\ContentTypeRepositoryInterface;\nuse Symfony\\Bundle\\F...
php
chosen
[ { "from": "system", "value": "Replace hard-coded English at top of settings menu\n" }, { "from": "human", "value": "@extends('layout')\n\n@section('body')\n <div class=\"wrapper my-3\">\n <div class=\"row\">\n <div class=\"row__column mr-3\" style=\"max-width: 300px;\">\n ...
php
chosen
[ { "from": "system", "value": "Replace money_format since it is not available on Windows (!2)\n" }, { "from": "human", "value": "<?php\nif ( ! function_exists('format_money')) {\n /**\n * Formats a price. Adds the currency if provided.\n *\n * @param string $value\n * @param nu...
php
chosen
[ { "from": "system", "value": "Fix undefined function without parameter\n" }, { "from": "human", "value": "<?php\ndeclare(strict_types = 1);\n\nnamespace Embed\\Detectors;\n\nclass Languages extends Detector\n{\n /**\n * @return \\Psr\\Http\\Message\\UriInterface[]\n */\n public fun...
php
chosen
[ { "from": "system", "value": "Add an isActiveWhen on the dashbaord sidebar class\n" }, { "from": "human", "value": "<?php namespace Modules\\Dashboard\\Sidebar;\n\nuse Maatwebsite\\Sidebar\\Group;\nuse Maatwebsite\\Sidebar\\Item;\nuse Maatwebsite\\Sidebar\\Menu;\nuse Modules\\Core\\Contracts\\Au...
php
chosen
[ { "from": "system", "value": "Fix conflict AbstractPluginManager::valdatePlugin with DiAbstractFactory\n" }, { "from": "human", "value": "<?php\n/**\n * Zend Framework (http://framework.zend.com/)\n *\n * @link http://github.com/zendframework/zf2 for the canonical source repository\n * @cop...
php
chosen
[ { "from": "system", "value": "Change Webservice in order to limit the entrys\n" }, { "from": "human", "value": "<?php\n\nnamespace ajax\\listing;\n\nuse \\PDO as PDO;\n\n/**\n * Web Service.\n * Returns Organisms with given ids\n */\nclass Organisms extends \\WebService {\n\n /**\n * @par...
php
chosen
[ { "from": "system", "value": "Add documentation url and update version number\n" }, { "from": "human", "value": "<?php\nnamespace Craft;\n\nclass AssetRevPlugin extends BasePlugin\n{\n\t/**\n\t * @return string\n\t */\n\tpublic function getName()\n\t{\n\t\treturn 'Asset Rev';\n\t}\n\n\t/**\n\t *...
php
chosen
[ { "from": "system", "value": "Use public methods as per tighten coding standards.\n" }, { "from": "human", "value": "<?php\n\n\nnamespace App;\n\n\ntrait LogsToConsole\n{\n public function alert(string $message)\n {\n app('console')->alert($message);\n }\n\n public function wa...
php
chosen
[ { "from": "system", "value": "Update query method to catch client errors & parse data result\n" }, { "from": "human", "value": "<?php\n\nnamespace Rogue\\Services;\n\nuse Softonic\\GraphQL\\ClientBuilder;\n\nclass GraphQL\n{\n /**\n * Build a new GraphQL client.\n */\n public funct...
php
chosen
[ { "from": "system", "value": "Add gettype() PHP Function to Twig Extension\n" }, { "from": "human", "value": "<?php\n\nnamespace Umpirsky\\Twig\\Extension;\n\nuse Twig_Extension;\nuse Twig_SimpleFunction;\nuse BadFunctionCallException;\n\nclass PhpFunctionExtension extends Twig_Extension\n{\n ...
php
chosen
[ { "from": "system", "value": "Add serialise and normalise for default field content\n" }, { "from": "human", "value": "<?php\nnamespace verbb\\feedme\\fields;\n\nuse verbb\\feedme\\base\\Field;\nuse verbb\\feedme\\base\\FieldInterface;\n\nuse Craft;\n\nuse Cake\\Utility\\Hash;\n\nclass DefaultFi...
php
chosen
[ { "from": "system", "value": "Hide Live Stream URL, making it valid for 10 seconds" }, { "from": "human", "value": "<?php\r\nrequire_once '../../videos/configuration.php';\r\nrequire_once $global['systemRootPath'] . 'plugin/Live/Objects/LiveTransmition.php';\r\n$t = LiveTransmition::getValidPlay...
php
chosen
[ { "from": "system", "value": "Enable SQL logging only in debug mode\n" }, { "from": "human", "value": "<?php\n\nnamespace Miniflux\\Database;\n\nuse Miniflux\\Schema;\nuse RuntimeException;\nuse PicoDb;\n\nfunction get_connection()\n{\n $db = new PicoDb\\Database(get_connection_parameters());...
php
chosen
[ { "from": "system", "value": "Change support message to be more explicit about the enterprise edition\n" }, { "from": "human", "value": "<?php\n/**\n * Copyright (c) 2014 Thomas Müller <deepdiver@owncloud.com>\n * This file is licensed under the Affero General Public License version 3 or\n * lat...
php
chosen
[ { "from": "system", "value": "Install script ready? who knows\n" }, { "from": "human", "value": "#!/usr/bin/env php\n<?php\n\n$zip = \"http://getsparks.org/static/install/spark-manager-0.0.1.zip\";\n$loader = \"http://getsparks.org/static/install/Loader.php.txt\";\n\nif(!file_exists(\"applica...
php
chosen
[ { "from": "system", "value": "Update code to reflect usage of secure functions\n" }, { "from": "human", "value": "<?php\n if (!isset($_SESSION)) {\n session_start();\n }\n \n?>\n<!DOCTYPE html>\n<html lang=\"en\">\n<?php\n $beginning = '<div class=\"container\"><nav class=\"navb...
php
chosen
[ { "from": "system", "value": "Use getToken() instead of deprecated token()\n" }, { "from": "human", "value": "<?php\n\nnamespace Openbuildings\\Postmark\\Test;\n\nuse Openbuildings\\Postmark\\Swift_PostmarkTransport;\nuse PHPUnit_Framework_TestCase;\nuse Swift_DependencyContainer;\n\n/**\n * @gr...
php
chosen
[ { "from": "system", "value": "Adjust check for sites running under a subdir\n" }, { "from": "human", "value": "<?php\n\nnamespace Croogo\\Core\\Routing\\Filter;\n\nuse Cake\\Core\\Configure;\nuse Cake\\Event\\Event;\nuse Cake\\Routing\\DispatcherFilter;\nuse Croogo\\Core\\Utility\\StringConverte...
php
chosen
[ { "from": "system", "value": "Add CSS class names depending on the type" }, { "from": "human", "value": "\n<?php\n $socialLinks = [\n 'Facebook' => 'https://www.facebook.com/',\n 'Twitter' => 'https://twitter.com/',\n 'Twitch' => 'https://www.twitch.tv/',\n 'YouTub...
php
chosen
[ { "from": "system", "value": "Change TestCase namespace from Base to TestCase\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of the Active Collab Cookies project.\n *\n * (c) A51 doo <info@activecollab.com>. All rights reserved.\n */\n\ndefined('BASE_PATH') || define('BASE_...
php
chosen
[ { "from": "system", "value": "Allow to load multiple macros in load_macro()\n" }, { "from": "human", "value": "<?php\ndeclare(strict_types=1);\n\nnamespace Baethon\\Phln;\n\n/**\n * Check if value is valid object.\n *\n * Value is considered as object if its an array\n * or class instance.\n *\n...
php
chosen
[ { "from": "system", "value": "Make it a singleton instead\n" }, { "from": "human", "value": "<?php namespace AuraIsHere\\LaravelMultiTenant;\n\nuse Illuminate\\Foundation\\AliasLoader;\nuse Illuminate\\Support\\ServiceProvider;\n\nclass LaravelMultiTenantServiceProvider extends ServiceProvider\n...
php
chosen
[ { "from": "system", "value": "Enable only if really needed\n" }, { "from": "human", "value": "<?php\nuse Timber\\Loader;\nuse Timber\\Menu;\nuse Timber\\Site;\nuse Timber\\Timber;\n\nclass TheSite extends Site\n{\n\n function __construct()\n {\n add_filter('timber_context', [$this, ...
php
chosen
[ { "from": "system", "value": "Fix an issue with attempting to index comments on packages\n\nSummary: See rPcd14194a329788d5fff6365bcade278fd18f3612 for a similar change. Implement `getApplicationTransactionCommentObject()` to return `null` explicitly.\n\nTest Plan: Ran `bin/search index --type ownerspackage...
php
chosen
[ { "from": "system", "value": "Comment added about making new defines file.\n" }, { "from": "human", "value": "<?php\n// 1 : smtp\n// 2 : sendmail\n// 3 : was mail and is deprecated, do not use\ndefine('SWIFT_MAIL_TRANSPORT_TYPE', 2);\n\n// depends on the choice above\n// 1 : server location\n// ...
php
chosen
[ { "from": "system", "value": "Revert \"Enabled a custom mapping\"\n\nThis reverts commit ca094beb7e2effd0b38faeba1dd95b2437ffb443.\n" }, { "from": "human", "value": "<?php\n\nnamespace Xidea\\Bundle\\BaseBundle;\n\nuse Symfony\\Component\\HttpKernel\\Bundle\\Bundle,\n Symfony\\Component\\Depe...
php
chosen
[ { "from": "system", "value": "Revert \"add import options to interface\"\n\nThis reverts commit 17b978e86a33826c4499255e71a27b862ed19380.\n" }, { "from": "human", "value": "<?php\n\nnamespace Keboola\\Db\\Import;\n\nuse Keboola\\Csv\\CsvFile;\n\ninterface ImportInterface\n{\n /**\n * @...
php
chosen
[ { "from": "system", "value": "Set correct time zone after loading datetime from database\n" }, { "from": "human", "value": "<?php\n\nnamespace Common\\Doctrine\\Type;\n\nuse DateTime;\nuse DateTimeZone;\nuse Doctrine\\DBAL\\Platforms\\AbstractPlatform;\nuse Doctrine\\DBAL\\Types\\ConversionExcep...
php
chosen
[ { "from": "system", "value": "Enable Featured Image Functionality on Home Page\n" }, { "from": "human", "value": "<?php \n\n/**\n * Home Page Template\n * Template Name: Home Page\n *\n */\n\nget_header(); ?>\n\n <div class=\"hero-header\" data-parallax=\"scroll\" data-image-src=\"http://lo...
php
chosen
[ { "from": "system", "value": "Make this code use a different session than the default PHPSESSID so it doesn't clash with 3rd party shopping cart's sessions." }, { "from": "human", "value": "<?php\n/**\n * This makes our life easier when dealing with paths. Everything is relative\n * to the appli...
php
chosen
[ { "from": "system", "value": "Add possibility to add example data via hook\n" }, { "from": "human", "value": "<?php\n/**\n * @Author: Timi Wahalahti\n * @Date: 2021-05-11 14:34:14\n * @Last Modified by: Roni Laukkarinen\n * @Last Modified time: 2021-05-11 15:04:45\n * @package air-light\n */...
php
chosen
[ { "from": "system", "value": "Revert \"Logging on cli mode\"\n\nThis reverts commit 66dbfea49de3584da69436f9ca9f719b66875617.\n" }, { "from": "human", "value": "<?php\n/**\n * CakePHP(tm) : Rapid Development Framework (http://cakephp.org)\n * Copyright (c) Cake Software Foundation, Inc. (http://...
php
chosen
[ { "from": "system", "value": "Fix api controller lookup dir\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Controllers\\API;\n\nuse function OpenApi\\scan;\n\n/**\n * @OA\\OpenApi(\n * openapi=\"3.0.0\",\n * @OA\\Info(\n * title=\"OParl Developer Platform API\",...
php
chosen
[ { "from": "system", "value": "Disable Rest API and XMLRPC\n" }, { "from": "human", "value": "<?php\n\nadd_filter('sanitize_file_name', 'remove_accents');\n\nremove_action('do_feed_rdf', 'do_feed_rdf' , 10, 1);\nremove_action('do_feed_rss', 'do_feed_rss' , 10, 1);\nremove_action('do_feed_rss2', '...
php
chosen
[ { "from": "system", "value": "Revert \"Test for updating production site\"\n\nThis reverts commit 0fdb2421faaf616ce8af119f1d59026b33166266.\n" }, { "from": "human", "value": "<aside id=\"sidebar\" class=\"small-12 medium-3 columns\">\n\t<div class=\"row\">\n\t\t<h1 class=\"text-center\"><a href=...
php
chosen