This topic is locked
[SOLVED]

 Place message on list page

5/15/2012 6:14:42 PM
PHPRunner General questions
P
Philip author

I often place some information on top of the list page. I do that with echos in the Before display event.
I would like that PHPR places the message just above the grid (instead of just below the header).

How can I achieve that?
Philip

C
cgphp 5/15/2012

Create a template var in the Visual editor, just above the grid, like this one:

{$grid_message}


and enter the following code in the "Before display" event:

$xt->assign("grid_message","Here it is a sample message");


More info here: http://xlinesoft.com/phprunner/docs/smarty_templates.htm

P
Philip author 5/15/2012



Create a template var in the Visual editor, just above the grid, like this one:

{$grid_message}


and enter the following code in the "Before display" event:

$xt->assign("grid_message","Here it is a sample message");


More info here: http://xlinesoft.com/phprunner/docs/smarty_templates.htm


Christian,
thanks for this quick and helpfull advise. I could make that running by editing the list page in visual editor.
But what I'm realy looking for is an approach to change "once and forever". I'm used to modify the list.ly file to my needs. Can I do this (or similar thing) as well for this message placement?
Thanks,

Philip

C
cgphp 5/15/2012

You can edit the templates files located in the visual folder of the PHPrunner project. More info here: http://xlinesoft.com/phprunner/docs/working_with_projects.htm

P
Philip author 5/15/2012



You can edit the templates files located in the visual folder of the PHPrunner project. More info here: http://xlinesoft.com/phprunner/docs/working_with_projects.htm


Hm... will this change influence just this project or all (future) projects?

Philip

C
cgphp 5/15/2012

Every project has its own folder.

P
Philip author 5/15/2012



Every project has its own folder.



and several list pages ...
In this case this way doesn't make sense for what I'm looking for.

Maybe I will rahter put it to a snippet then.
What I dont't understand ist that $message can be used in EDIT pages exactly the way I want. Why can't this not be used on LIST page?

Sergey Kornilov admin 5/15/2012

Display message (error message in fact) is a built-in Edit/Add page functionality. There is no such functionality on the list page which means you need to implement it manually.

P
Philip author 5/16/2012



Display message (error message in fact) is a built-in Edit/Add page functionality. There is no such functionality on the list page which means you need to implement it manually.


Thanks Sergey