File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -87,10 +87,15 @@ Krowinski\LaravelXSLT\XSLTServiceProvider::class,
87
87
* @return Response
88
88
*/
89
89
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);
94
99
95
100
return view('welcome');
96
101
}
You can’t perform that action at this time.
0 commit comments