Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
[READ-ONLY] Subtree split of the Symfony HttpFoundation Component -- clone into Symfony/Component/ (master at symfony/symfony)
PHP

feature #14153 Remove the legacy PDO session handler (dosten)

This PR was merged into the 3.0-dev branch.

Discussion
----------

Remove the legacy PDO session handler

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Commits
-------

d92096a Remove the legacy PDO session handler
latest commit f2930ef7cf
@fabpot fabpot authored
Failed to load latest commit information.
File [HttpFoundation] remove getExtension method
Resources/stubs Merge branch '2.5' into 2.6
Session feature #14153 Remove the legacy PDO session handler (dosten)
Tests feature #14153 Remove the legacy PDO session handler (dosten)
.gitignore Added missing files .gitignore
AcceptHeader.php [2.3] CS And DocBlock Fixes
AcceptHeaderItem.php fixed types in phpdocs
ApacheRequest.php [HttpFoundation] do not use server variable PATH_INFO because it is a…
BinaryFileResponse.php Merge branch '2.3' into 2.6
CHANGELOG.md [HttpFoundation] implement different locking strategies for sessions
Cookie.php CS: Convert double quotes to single quotes
ExpressionRequestMatcher.php [HttpFoundation] added ExpressionRequestMatcher
FileBag.php [2.3] Static Code Analysis for Components
HeaderBag.php Merge branch '2.3' into 2.5
IpUtils.php CS: Pre incrementation/decrementation should be used if possible
JsonResponse.php [3.0] Removed some old hacks
LICENSE Updated copyright to 2015
ParameterBag.php Merge branch '2.3' into 2.6
README.md renamed composer.phar to composer to be consistent with the Symfony docs
RedirectResponse.php Docblock fixes
Request.php Merge branch '2.6' into 2.7
RequestMatcher.php [HttpFoundation] Add a way to match a specific scheme in RequestMatch…
RequestMatcherInterface.php Docblock fixes
RequestStack.php unified return null usages
Response.php Merge branch '2.3' into 2.6
ResponseHeaderBag.php Merge branch '2.5' into 2.6
ServerBag.php fix parsing of Authorization header
StreamedResponse.php [HttpFoundation] Allow Cache-Control headers on StreamedResponse
composer.json Merge branch '2.8'
phpunit.xml.dist [PhpUnitBridge] new bridge for testing with PHPUnit

README.md

HttpFoundation Component

HttpFoundation defines an object-oriented layer for the HTTP specification.

It provides an abstraction for requests, responses, uploaded files, cookies, sessions, ...

In this example, we get a Request object from the current PHP global variables:

use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;

$request = Request::createFromGlobals();
echo $request->getPathInfo();

You can also create a Request directly -- that's interesting for unit testing:

$request = Request::create('/?foo=bar', 'GET');
echo $request->getPathInfo();

And here is how to create and send a Response:

$response = new Response('Not Found', 404, array('Content-Type' => 'text/plain'));
$response->send();

The Request and the Response classes have many other methods that implement the HTTP specification.

Loading

If you are not using Composer but are using PHP 5.3.x, you must add the following to your autoloader:

// SessionHandlerInterface
if (!interface_exists('SessionHandlerInterface')) {
    $loader->registerPrefixFallback(__DIR__.'/../vendor/symfony/src/Symfony/Component/HttpFoundation/Resources/stubs');
}

Resources

You can run the unit tests with the following command:

$ cd path/to/Symfony/Component/HttpFoundation/
$ composer install
$ phpunit
Something went wrong with that request. Please try again.