|
ZEN.Как передать данные формы на другую страницу?
|
|||
---|---|---|---|
#18+
Помогите разобраться Вот код ZEN-страницы:/// Created using the page template: Default Class tmp.testform Extends %ZEN.Component.page { /// Class name of application this page belongs to. Parameter APPLICATION = ""; /// Displayed name of this page. Parameter PAGENAME = ""; /// Domain used for localization. Parameter DOMAIN = ""; /// This Style block contains page-specific CSS style definitions. XData Style { <style type="text/css"> </style> } /// This XML block defines the contents of this page. XData Contents [XMLNamespace=" http://www.intersystems.com/zen" ] { <page xmlns=" http://www.intersystems.com/zen" title=""> <form id="MyForm" nextPage="test.csp"> <text id="txtName" name="txtName" /> <submit id="btnSubmit" name="btnSubmit" caption="Click to submit form" nextPage="test.csp" /> </form> </page> } } Вот код csp-страницы:<html> <head> <!-- Put your page Title here --> <title> Cache Server Page </title> </head> <body> <!-- Put your page code here --> My page body #(%request.Get("txtName"))# </body> </html> Подскажите, что делаю не так? Почему не могу вытащить из %request данные формы? Что надо сделать, чтобы они там появились? Спасибо. ... |
|||
:
Нравится:
Не нравится:
|
|||
14.02.2014, 11:24 |
|
ZEN.Как передать данные формы на другую страницу?
|
|||
---|---|---|---|
#18+
nextpage Page to redirect to after a submit. Все потому что submit происходит все равно на Zen странице, а только потом редиректит на nextpage, но уже не передав туда параметров с формы ... |
|||
:
Нравится:
Не нравится:
|
|||
14.02.2014, 11:54 |
|
ZEN.Как передать данные формы на другую страницу?
|
|||
---|---|---|---|
#18+
DAiMor, Совсем все забыл, как это давно было ClassMethod %OnSubmit(pSubmit As %ZEN.Submit) As %Status { Set %response.Context("txtName") = pSubmit.%GetValue("txtName") Quit $$$OK }и будет мне счастие ... |
|||
:
Нравится:
Не нравится:
|
|||
14.02.2014, 12:07 |
|
|
start [/forum/topic.php?fid=39&msg=38560829&tid=1556955]: |
0ms |
get settings: |
11ms |
get forum list: |
13ms |
check forum access: |
4ms |
check topic access: |
4ms |
track hit: |
37ms |
get topic data: |
13ms |
get forum data: |
2ms |
get page messages: |
47ms |
get tp. blocked users: |
2ms |
others: | 298ms |
total: | 431ms |
0 / 0 |