From 6babe058740e05a82aa5deef07378c3be804ba00 Mon Sep 17 00:00:00 2001 From: David Grudl Date: Tue, 6 Mar 2018 19:26:31 +0100 Subject: [PATCH] di-configuration: info about passing params --- cs/di-configuration.texy | 4 ++++ en/di-configuration.texy | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/cs/di-configuration.texy b/cs/di-configuration.texy index b0984205c6..8359ed87f2 100644 --- a/cs/di-configuration.texy +++ b/cs/di-configuration.texy @@ -59,6 +59,10 @@ services: database: factory: PDO(%dsn%, %user%, %password%) + # s názvy parametrů (na pořadí nezáleží) + database: + factory: PDO(dsn: %dsn%, username: %user%) + # nebo ve třech řádcích :-) database: factory: PDO diff --git a/en/di-configuration.texy b/en/di-configuration.texy index 90b5b53b8f..1a26c4dbf8 100644 --- a/en/di-configuration.texy +++ b/en/di-configuration.texy @@ -59,6 +59,10 @@ services: database: factory: PDO(%dsn%, %user%, %password%) + # with parameter names (the order does not matter) + database: + factory: PDO(dsn: %dsn%, username: %user%) + # or more multi-lines :-) database: factory: PDO