[jifty-devel] Re-use of PageRegions and Fragments

Steve H s_t_e_v_e_h at hotmail.com
Thu Nov 8 21:54:40 EST 2007


Hi,
I was experiencing some unanticipated behaviour when I created multiple instances of a page region that referred to the same fragment.  
I have for example a table that lists order headers. In a row beneath the order header details, I create a page region whose associated fragment has code that, depending on it's arg values, will display a link like 'show items' or a nested table of the items and a link of 'hide items'.  (i.e there would be page region created for each order header listed).
In my proof of concept code/test, I had 2 order headers that dutifully display along with the 'show items' link in the region/fragment under them.  When clicking on the link for order header 1, the fragment then dutifully changes to show the items, along with the 'hide items' link.  Problem was though, that when I clicked the 'show items' beneath the 2nd order hearder, it again updated the fragment under the 1st order header... albeit displaying items belonging to the order header 2; the link under order header 2 remained as 'show items.  
In the main fragment that creates these n page regions beneath their respective order headers, I also tried specifying a unique name... to no avail.  In the 'show/hide item' links, I merely declare them with name=> and args=>;  are there any other params that I should specify to cause them to target/update the correct page region (i.e. the one in which the link appears)?
Does that explain the issue? or might I need to send code samples?
thanks
SteveH

_________________________________________________________________
Overpaid or Underpaid? Check our comprehensive Salary Centre
http://a.ninemsn.com.au/b.aspx?URL=http%3A%2F%2Fcontent%2Emycareer%2Ecom%2Eau%2Fsalary%2Dcentre%3Fs%5Fcid%3D595810&_t=766724125&_r=Hotmail_Email_Tagline_MyCareer_Oct07&_m=EXT


More information about the jifty-devel mailing list