Skip to content

Commit 1e1de41

Browse files
committed
more info about functions
1 parent 8a2e9d8 commit 1e1de41

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

README.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,10 +87,15 @@ Krowinski\LaravelXSLT\XSLTServiceProvider::class,
8787
* @return Response
8888
*/
8989
public function index()
90-
{
91-
\View::addAttribute('template', 'hello');
92-
\View::addChild('template', 'hello')->addAttribute('aaaa', 'zzz');
93-
\View::addChild('test', '123');
90+
{
91+
// adds to main xml /App attributte name template with value = hello
92+
\View::addAttribute('name template ', 'hello');
93+
// create child template to /App with value hello and add aaa and zzz atribute to template.
94+
\View::addChild('template', 'hello', false)->addAttribute('aaaa', 'zzz');
95+
// creates parent example and adds childs foo and bar to it
96+
\View::addArrayToXmlByChild(['foo', 'bar'], 'example', false);
97+
// add to parent App child bar and zzz
98+
\View::addArrayToXml(['bar', 'zzz'], false);
9499

95100
return view('welcome');
96101
}

0 commit comments

Comments
 (0)