Thursday 14 February 2008 9:04:30 am
Hi, I've got another problem. I wished to improve my module by adding a new select button but I haven't expected the following beahviour : each button are working well, they provide the select interface I have chosen, but when used sequencially, I cannot dissociate it. In my module :
$browse_result_1 = eZContentBrowse::result("select1");
$browse_result_2 = eZContentBrowse::result("select2");
eZDebug::writeDebug($browse_result_1);
eZDebug::writeDebug($browse_result_2);
if (isset($browse_result_1[0]) and $browse_result_1 != '')
{
$selected_node_1 = $browse_result_1[0];
}
if (isset($browse_result_2[0]) and $browse_result_2 != '')
{
$selected_node_2 = $browse_result_2[0];
}
if ($http->hasVariable('Select1'))
{
eZContentBrowse::browse( array( 'action_name' => 'Select1', 'from_page' => 'module/function'), $module );
}
else if ($http->hasVariable('Select2') and $selected_node_1!=0)
{
eZContentBrowse::browse( array( 'action_name' => 'Select2', 'from_page' => 'module/function/'.$selected_node_1), $module );
}
And in my browse.ini :
[Select1]
StartNode=images
SelectionType=single
ReturnType=NodeID
[Select2]
StartNode=images
SelectionType=single
ReturnType=NodeID
And in the debug, I have $browse_result_1 and $browse_result_2 are the same even if I have not clicked in the second button. Where is my mistake ? Cheers.
Maxime Thomas
[email protected] | www.wascou.org | http://twitter.com/wascou
Company Blog : http://www.wascou.org/eng/Company/Blog
Technical Blog : http://share.ez.no/blogs/maxime-thomas
|