![]() |
|
gmDumpVarPlugin - 1.1.2Display list of vars assigned to view. |
|
The gmDumpVarPlugin is a symfony plugin witch display list of vars assigned to view, and dump var easily on screen.
Installation
symfony plugin:install gmDumpVarPlugin
symfony cc
Dump var
GmDebug::dump($var_name);
GmDebug::dump($var_name, 'title');
Dump var and die script
GmDebug::dumpEnd($var_name);
GmDebug::dumpEnd($var_name, 'title');
Dump var to file
GmDebug::dumpFile($var_name);
GmDebug::dumpFile($var_name, 'title');
By default, The file is maked at sf_log_dir/var_dump.log.You can change it.
If you want to change only file name
GmDebug::dumpFile($var_name, 'title', 'filename.txt');
change directory too, write in your sf_root/config/settings.yml
all:
gm_dump_var_plugin:
file_dir: ~
filename: ~
To dislplay all vars assigned to template, you use filter.
In your apps/config/filters.yml
# insert your own filters here
display_var:
class: GmDumpAssignVarFilter
When your application's environment is 'dev' and debug mode is true, display all vars assigned below your screen.
Enable to execute getter method and display value,
in your settings.yml
all:
gm_dump_var_plugin:
exec_pass: 1234
and add to url
http://www.example.com/test?gm_exec=1234
All method that name is get~ and is public execute.
all:
gm_dump_var_plugin:
execute_sf_pager: on
Display inceluded object in sfPager.If you enable to this option, send SELECT query agein once.
All settings is here.
all:
gm_dump_var_plugin:
file_dir: ~
filename: ~
exec_pass: 1919
style_outer: ~
style_title: ~
style_pre: ~
execute_sf_pager: off