Commits
-------
6d8c4a8 change nested collection indentation from 2 to 4
Discussion
----------
Changed Yaml Dumper nested collection indentation
This PR changes the dumpers nested collection indentation from 2 to 4 which seems to be the standard.
Commits
-------
022a9a7 [Security] Make saving target_path extendible
Discussion
----------
[Security] Make saving target_path extendible
The problem lies in how Security component handles ``target_path`` - the latest request URI is always stored. This can lead to problems in following scenarios:
a) The response type of the request is not HTML (think JSON, XML ..)
b) The URI matches a route that does not listen to HTTP GET
I opened a [PR](https://github.com/symfony/symfony/pull/604) months ago, to partly solve scenario A, which did not make it. Now I am proposing a different solution - user can extend ``ExceptionListener`` and override the logic behind setting the ``target_path`` to match his precise needs.
In my simplified scenario, I would be using:
```
protected function setTargetPath(Request $request)
{
if ($request->isXmlHttpRequest() || 'GET' !== $request->getMethod()) {
return;
}
$request->getSession()->set('_security.target_path', $request->getUri());
}
```
@Seldaek, @schmittjoh, @lsmith77, thoughts?
---------------------------------------------------------------------------
by Seldaek at 2011/09/21 02:37:02 -0700
Seems like a better solution for flexibility's sake. Would be quite awesome if you could add a cookbook entry to symfony/symfony-docs about this, otherwise I'm afraid we'll have to explain it over and over again :)
---------------------------------------------------------------------------
by helmer at 2011/09/21 03:38:57 -0700
[Cookbook](b22c5e666e) entry done. Perhaps though I rushed ahead ..
---------------------------------------------------------------------------
by Seldaek at 2011/09/21 03:52:01 -0700
Thanks. You can already do a pull request against symfony-docs, just reference this pull request in it so it's not merged before this is merged.
Commits
-------
e1aabd2 [FrameworkBundle] Updated the Russian translations.
Discussion
----------
[FrameworkBundle] Updated the Russian translations.
Added translations for a new error messages of image validator.
Added translations for the user password validator.
Commits
-------
fea74db Added information page with better messages for Profiler
Discussion
----------
[WebProfiler] Added information page with better messages
---------------------------------------------------------------------------
by stloyd at 2011/08/30 23:29:27 -0700
@fabpot Any decision about this ?
Commits
-------
132fbe3 [WebProfilerBundle] Merge position and css_position
defdb82 [WebProfilerBundle] Remove unused line
69a50ab [WebProfilerBundle] Add the posibility to specify position of toolbar
Discussion
----------
[WebProfilerBundle] Add the posibility to specify position of toolbar
I'm facing a project where everything is at the bottom of the page, positioned with CSS.
This PR adds the possibility to specify the position of the toolbar, with configuration :
web_profiler:
toolbar: true
intercept_redirects: false
css_position: top
---------------------------------------------------------------------------
by stof at 2011/09/06 12:11:27 -0700
Looking at the code rendering the toolbar, there is already a ``position`` parameter used to display the toolbar on top in the profiler. Maybe we could look into reusing it instead of having a second one named ``css_position``.
But the phpdoc says ``bottom, normal, or null -- automatically guessed``. Using ``bottom`` will result in ``position: bottom`` in the CSS, which is broken. @fabpot is it simply a left-over of a previous version ?
---------------------------------------------------------------------------
by alexandresalome at 2011/09/16 00:56:11 -0700
I merged parameters and changed the documentation for 3 values : ```bottom, top or normal```.
Commits
-------
4ca09a9 [Validator] Validate object with it's own entity manager by default
Discussion
----------
[Validator] Validate object with it's own entity manager by default
While working with multiple object managers the default validation uses default entity manager, requiring the dev to create own validation services for each entity using other entity managers. This commit causes entity to be validated (by default) by it's own entity manager, while still preserving a possiblity to specifiy $constraint->em.
This is was a pull request to 2.0, changed to master according to stof's suggestion.
Commits
-------
7d3c2df [SecurityBundle] added a validator for the user password
Discussion
----------
[SecurityBundle] added a validator for the user password
This validator is useful when you want to validate that an input value
is equal to the user current password (in a form where the user can change
his password for instance).
Note that this should not be used to validate a login form as this is
done automatically by the built-in security mechanism.
---------------------------------------------------------------------------
by Palleas at 2011/09/21 08:36:14 -0700
This is kinda what I wrote for my project 2 days ago, I'm definitely +1 on this ;-)
---------------------------------------------------------------------------
by stealth35 at 2011/09/21 08:45:55 -0700
👍
Commits
-------
e13998d updated indonesian translation for image validator
Discussion
----------
Updated indonesian translation for image validator
---------------------------------------------------------------------------
by stof at 2011/09/21 10:49:48 -0700
Can you send a PR to the 2.0 branch for the trans-unit 41 ?
---------------------------------------------------------------------------
by alifity at 2011/09/21 11:05:48 -0700
Hi @stof, I've sent another PR for trans-unit-41 :)
This validator is useful when you want to validate that an input value
is equal to the user current password (in a form where the user can change
his password for instance).
Note that this should not be used to validate a login form as this is
done automatically by the built-in security mechanism.
Commits
-------
cf736cc [DomCrawler] Add test for ChoiceFormField without value
bca551e [DomCrawler] ChoiceFormField should take the content when value is unavailable
Discussion
----------
[DomCrawler] ChoiceFormField should take the content when value is unavai
[DomCrawler] ChoiceFormField should take the content when value is unavailable
---------------------------------------------------------------------------
by fabpot at 2011/09/20 09:15:21 -0700
Can you some unit tests?
Commits
-------
a0329c3 Added lifetime/cleanup support.
365e73a Fixed the find() method and changed the way the profile data is stored.
beeec5e Allow socket dsn (for example mongodb:///tmp/mongodb-27017.sock).
218eaba Fixed storage of time value.
85c3806 Added support for sorting by time like other profiler storage implementations.
73692c6 Fixed MongoDbProfilerStorage::find() when passing empty parameters.
4cd2dec Use token as identifier to make usage of the automatically created index.
Discussion
----------
[2.1] [HttpKernel] MongoDB profiler updates
I fixed one issue within the MongoDbProfilerStorage::find() function and made some more changes.
---------------------------------------------------------------------------
by snc at 2011/09/11 02:28:35 -0700
Please don't merge this in yet. There are some more commits pending...
---------------------------------------------------------------------------
by fabpot at 2011/09/14 01:07:39 -0700
@snc: is it ready for a merge?
---------------------------------------------------------------------------
by snc at 2011/09/14 01:20:32 -0700
Unfortunately not... while testing I found out that the currently merged in implementation does not work completely. The web profiler search function errors because the find function returns the wrong data. I fixed this already but now I have some strange "maximum function nesting level reached" errors when viewing profiles with children. I will work on it later today.
---------------------------------------------------------------------------
by snc at 2011/09/14 13:27:50 -0700
Now only one thing is missing... the generated container code looks like this:
`$this->services['profiler'] = $instance = new \Symfony\Component\HttpKernel\Profiler\Profiler(new \Symfony\Component\HttpKernel\Profiler\MongoDbProfilerStorage('mongodb://localhost/sf2-mongo-profiler/profiler', '', '', 86400), $a);`
The current constructor only uses the first parameter (dsn). What about the username, password and lifetime? Username and passwort can already be passed via the dsn... but the lifetime feature is not part of the interface... should I implement it?
---------------------------------------------------------------------------
by fabpot at 2011/09/15 11:03:02 -0700
The `lifetime` is used to cleanup the database (see https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/Profiler/PdoProfilerStorage.php#L136). So, it should probably be implemented for MongoDB as well (but it can probably be done in another PR).
---------------------------------------------------------------------------
by snc at 2011/09/19 13:42:52 -0700
Sorry for the delay, lifetime support is now implemented. What do you think about an AbstractProfilerStorageTest class to share some testing code between the different implementations (of cause in a separate PR)?
Commits
-------
83199ae [FrameworkBundle] Fix unintuitive merging behavior for assets_base_urls
4061114 [FrameworkBundle] fixes unintuitive merging behavior
Discussion
----------
[FrameworkBundle] fixes unintuitive merging behavior
---------------------------------------------------------------------------
by fabpot at 2011/09/16 10:04:53 -0700
I think this is a "bug", no? If this is the case, then we need to fix the 2.0 branch.
---------------------------------------------------------------------------
by schmittjoh at 2011/09/17 00:34:14 -0700
It is a change in behavior, but whether or how you want to merge this is really up to you.
---------------------------------------------------------------------------
by jmikola at 2011/09/19 08:09:26 -0700
I was about to create a PR for this very same quirk, as this was causing my CDN's for various environments to all get merged together. I think we can get away with merging it directly to 2.0 since `assets_base_urls` are hardly covered in the documentation at all.
Once this gets merged, I wouldn't mind writing up a blurb on them to explain how the shorthand syntax works and this merging strategy.
---------------------------------------------------------------------------
by jmikola at 2011/09/19 08:28:21 -0700
I just noticed this PR only fixes the `base_urls` config option under `packages`. We should also correct this behavior for `assets_base_urls`, which appears further up in FrameworkBundle's Configuration.php file.
---------------------------------------------------------------------------
by jmikola at 2011/09/19 08:44:57 -0700
@schmittjoh: I have the second commit for this sitting in https://github.com/jmikola/symfony/tree/configFix (rebased on your branch) if you'd prefer to merge that into your branch to update this PR.
---------------------------------------------------------------------------
by schmittjoh at 2011/09/19 08:55:42 -0700
Merged it in. Thanks.
---------------------------------------------------------------------------
by fabpot at 2011/09/19 09:01:27 -0700
ok, I'm going to merge this into master.
@jmikola: Can you submit documentation for the new way?