Skip to content

Fix highlighting #3497

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 22, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions book/propel.rst
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ configuration file (``config.yml``):

propel:
dbal:
driver: "%database_driver%"
user: "%database_user%"
password: "%database_password%"
dsn: "%database_driver%:host=%database_host%;dbname=%database_name%;charset=%database_charset%"
driver: "%database_driver%"
user: "%database_user%"
password: "%database_password%"
dsn: "%database_driver%:host=%database_host%;dbname=%database_name%;charset=%database_charset%"

Now that Propel knows about your database, Symfony2 can create the database for
you:
Expand Down
21 changes: 11 additions & 10 deletions book/security.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ authentication (i.e. the old-school username/password box):
security:
firewalls:
secured_area:
pattern: ^/
pattern: ^/
anonymous: ~
http_basic:
realm: "Secured Demo Area"
Expand Down Expand Up @@ -300,11 +300,11 @@ First, enable form login under your firewall:
security:
firewalls:
secured_area:
pattern: ^/
pattern: ^/
anonymous: ~
form_login:
login_path: login
check_path: login_check
login_path: login
check_path: login_check

.. code-block:: xml

Expand Down Expand Up @@ -373,10 +373,10 @@ submission (i.e. ``/login_check``):

# app/config/routing.yml
login:
path: /login
defaults: { _controller: AcmeSecurityBundle:Security:login }
path: /login
defaults: { _controller: AcmeSecurityBundle:Security:login }
login_check:
path: /login_check
path: /login_check

.. code-block:: xml

Expand Down Expand Up @@ -637,8 +637,8 @@ see :doc:`/cookbook/security/form_login`.

firewalls:
login_firewall:
pattern: ^/login$
anonymous: ~
pattern: ^/login$
anonymous: ~
secured_area:
pattern: ^/
form_login: ~
Expand Down Expand Up @@ -1094,13 +1094,14 @@ aren't stored anywhere in a database. The actual user object is provided
by Symfony (:class:`Symfony\\Component\\Security\\Core\\User\\User`).

.. tip::

Any user provider can load users directly from configuration by specifying
the ``users`` configuration parameter and listing the users beneath it.

.. caution::

If your username is completely numeric (e.g. ``77``) or contains a dash
(e.g. ``user-name``), you should use that alternative syntax when specifying
(e.g. ``user-name``), you should use an alternative syntax when specifying
users in YAML:

.. code-block:: yaml
Expand Down
4 changes: 2 additions & 2 deletions book/translation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -452,8 +452,8 @@ by the routing system using the special ``_locale`` parameter:
.. code-block:: yaml

contact:
path: /{_locale}/contact
defaults: { _controller: AcmeDemoBundle:Contact:index, _locale: en }
path: /{_locale}/contact
defaults: { _controller: AcmeDemoBundle:Contact:index, _locale: en }
requirements:
_locale: en|fr|de

Expand Down
16 changes: 8 additions & 8 deletions components/config/definition.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ applied to it (like: "the value for ``auto_connect`` must be a boolean value"):
default_connection: mysql
connections:
mysql:
host: localhost
driver: mysql
host: localhost
driver: mysql
username: user
password: pass
sqlite:
host: localhost
driver: sqlite
memory: true
host: localhost
driver: sqlite
memory: true
username: user
password: pass

Expand Down Expand Up @@ -473,9 +473,9 @@ in this config:
.. code-block:: yaml

connection:
name: my_mysql_connection
host: localhost
driver: mysql
name: my_mysql_connection
host: localhost
driver: mysql
username: user
password: pass

Expand Down
4 changes: 2 additions & 2 deletions components/dependency_injection/parameters.rst
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,8 @@ making the class of a service a parameter:

services:
mailer:
class: '%mailer.class%'
arguments: ['%mailer.transport%']
class: "%mailer.class%"
arguments: ["%mailer.transport%"]

.. code-block:: xml

Expand Down
8 changes: 4 additions & 4 deletions components/dependency_injection/parentservices.rst
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ The service config for these classes would look something like this:
my_email_formatter:
# ...
newsletter_manager:
class: "%newsletter_manager.class%"
class: "%newsletter_manager.class%"
calls:
- [setMailer, ["@my_mailer"]]
- [setEmailFormatter, ["@my_email_formatter"]]
Expand Down Expand Up @@ -196,7 +196,7 @@ a parent for a service.
- [setEmailFormatter, ["@my_email_formatter"]]

newsletter_manager:
class: "%newsletter_manager.class%"
class: "%newsletter_manager.class%"
parent: mail_manager

greeting_card_manager:
Expand Down Expand Up @@ -321,13 +321,13 @@ to the ``NewsletterManager`` class, the config would look like this:
- [setEmailFormatter, ["@my_email_formatter"]]

newsletter_manager:
class: "%newsletter_manager.class%"
class: "%newsletter_manager.class%"
parent: mail_manager
calls:
- [setMailer, ["@my_alternative_mailer"]]

greeting_card_manager:
class: "%greeting_card_manager.class%"
class: "%greeting_card_manager.class%"
parent: mail_manager

.. code-block:: xml
Expand Down
2 changes: 1 addition & 1 deletion components/dependency_injection/types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ Another possibility is just setting public fields of the class directly::
my_mailer:
# ...
newsletter_manager:
class: NewsletterManager
class: NewsletterManager
properties:
mailer: "@my_mailer"

Expand Down
14 changes: 7 additions & 7 deletions cookbook/assetic/apply_to_option.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ An example configuration might look like this:
assetic:
filters:
coffee:
bin: /usr/bin/coffee
node: /usr/bin/node
node_paths: [ /usr/lib/node_modules/ ]
bin: /usr/bin/coffee
node: /usr/bin/node
node_paths: [/usr/lib/node_modules/]

.. code-block:: xml

Expand Down Expand Up @@ -130,10 +130,10 @@ applied to all ``.coffee`` files:
assetic:
filters:
coffee:
bin: /usr/bin/coffee
node: /usr/bin/node
node_paths: [ /usr/lib/node_modules/ ]
apply_to: "\.coffee$"
bin: /usr/bin/coffee
node: /usr/bin/node
node_paths: [/usr/lib/node_modules/]
apply_to: "\.coffee$"

.. code-block:: xml

Expand Down
2 changes: 2 additions & 0 deletions cookbook/assetic/uglifyjs.rst
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ your JavaScripts:

<!-- app/config/config.xml -->
<assetic:config>
<!-- bin: the path to the uglifyjs executable -->
<assetic:filter
name="uglifyjs2"
bin="/usr/local/bin/uglifyjs" />
Expand All @@ -86,6 +87,7 @@ your JavaScripts:
$container->loadFromExtension('assetic', array(
'filters' => array(
'uglifyjs2' => array(
// the path to the uglifyjs executable
'bin' => '/usr/local/bin/uglifyjs',
),
),
Expand Down
2 changes: 1 addition & 1 deletion cookbook/bundles/override.rst
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ in the core FrameworkBundle:

# app/config/config.yml
parameters:
translator.class: Acme\HelloBundle\Translation\Translator
translator.class: Acme\HelloBundle\Translation\Translator

.. code-block:: xml

Expand Down
3 changes: 0 additions & 3 deletions cookbook/bundles/prepend_extension.rst
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ for ``acme_hello`` is set to ``non_default``:
.. code-block:: yaml

# app/config/config.yml

acme_something:
# ...
use_acme_goodbye: false
Expand All @@ -112,7 +111,6 @@ for ``acme_hello`` is set to ``non_default``:
.. code-block:: xml

<!-- app/config/config.xml -->

<acme-something:config use-acme-goodbye="false">
<acme-something:entity-manager-name>non_default</acme-something:entity-manager-name>
</acme-something:config>
Expand All @@ -122,7 +120,6 @@ for ``acme_hello`` is set to ``non_default``:
.. code-block:: php

// app/config/config.php

$container->loadFromExtension('acme_something', array(
...,
'use_acme_goodbye' => false,
Expand Down
2 changes: 1 addition & 1 deletion cookbook/configuration/apache_router.rst
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ To test that it's working, let's create a very basic route for the AcmeDemoBundl

# app/config/routing.yml
hello:
path: /hello/{name}
path: /hello/{name}
defaults: { _controller: AcmeDemoBundle:Demo:hello }

.. code-block:: xml
Expand Down
7 changes: 5 additions & 2 deletions cookbook/configuration/environments.rst
Original file line number Diff line number Diff line change
Expand Up @@ -64,18 +64,21 @@ easily and transparently:

imports:
- { resource: config.yml }

# ...

.. code-block:: xml

<imports>
<import resource="config.xml" />
</imports>

<!-- ... -->

.. code-block:: php

$loader->import('config.php');

// ...

To share common configuration, each environment's configuration file
Expand Down Expand Up @@ -188,12 +191,12 @@ environment by using this code and changing the environment string.

doctrine:
dbal:
logging: "%kernel.debug%"
logging: "%kernel.debug%"
# ...

.. code-block:: xml

<doctrine:dbal logging="%kernel.debug%" ... />
<doctrine:dbal logging="%kernel.debug%" />

.. code-block:: php

Expand Down
2 changes: 1 addition & 1 deletion cookbook/configuration/pdo_session_storage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ configuration format of your choice):
framework:
session:
# ...
handler_id: session.handler.pdo
handler_id: session.handler.pdo

parameters:
pdo.db_options:
Expand Down
6 changes: 3 additions & 3 deletions cookbook/controller/service.rst
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Then you can define it as a service as follows:

services:
acme.hello.controller:
class: "%acme.controller.hello.class%"
class: "%acme.controller.hello.class%"

.. code-block:: xml

Expand Down Expand Up @@ -112,8 +112,8 @@ the route ``_controller`` value:

# app/config/routing.yml
hello:
path: /hello
defaults: { _controller: acme.hello.controller:indexAction }
path: /hello
defaults: { _controller: acme.hello.controller:indexAction }

.. code-block:: xml

Expand Down
6 changes: 4 additions & 2 deletions cookbook/doctrine/dbal.rst
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ mapping types, read Doctrine's `Custom Mapping Types`_ section of their document
doctrine:
dbal:
types:
custom_first: Acme\HelloBundle\Type\CustomFirst
custom_first: Acme\HelloBundle\Type\CustomFirst
custom_second: Acme\HelloBundle\Type\CustomSecond

.. code-block:: xml
Expand Down Expand Up @@ -143,7 +143,7 @@ mapping type:
dbal:
connections:
default:
// Other connections parameters
# other connections parameters
mapping_types:
enum: string

Expand All @@ -160,6 +160,7 @@ mapping type:
<doctrine:dbal>
<doctrine:dbal default-connection="default">
<doctrine:connection>
<!-- other connections parameters -->
<doctrine:mapping-type name="enum">string</doctrine:mapping-type>
</doctrine:connection>
</doctrine:dbal>
Expand All @@ -173,6 +174,7 @@ mapping type:
'dbal' => array(
'connections' => array(
'default' => array(
// other connection parameers
'mapping_types' => array(
'enum' => 'string',
),
Expand Down
11 changes: 5 additions & 6 deletions cookbook/doctrine/multiple_entity_managers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ The following configuration code shows how you can configure two entity managers

doctrine:
dbal:
default_connection: default
default_connection: default
connections:
default:
driver: "%database_driver%"
Expand All @@ -44,22 +44,21 @@ The following configuration code shows how you can configure two entity managers
charset: UTF8

orm:
default_entity_manager: default
default_entity_manager: default
entity_managers:
default:
connection: default
connection: default
mappings:
AcmeDemoBundle: ~
AcmeDemoBundle: ~
AcmeStoreBundle: ~
customer:
connection: customer
connection: customer
mappings:
AcmeCustomerBundle: ~

.. code-block:: xml

<?xml version="1.0" encoding="UTF-8"?>

<srv:container xmlns="http://symfony.com/schema/dic/doctrine"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:srv="http://symfony.com/schema/dic/services"
Expand Down
Loading