⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

URI strings in view flexigrid



mavershim

mavershim
  • profile picture
  • Member

Posted 12 November 2012 - 07:14 AM

Hi,

I'm trying to edit the edit form of flexigrid and want to show additional buttons base on uri string. but I can't access or show it. if I try this


echo $this->uri->segment(3);


on the edit template a error is produce. I also try

echo CI_URI::segment(3);


but no result is found.


How can I get the segments

Thank you.. Grocerycrud rocks...

victor

victor
  • profile picture
  • Member

Posted 12 November 2012 - 07:51 AM

Hi! try this:

$ci = &get_instance();
echo $this->ci->uri->segment(3);

mavershim

mavershim
  • profile picture
  • Member

Posted 13 November 2012 - 03:21 AM

Thanks Victor.. Now its working. I have another question how can I get the value of the fields pass by crud so I can enable or show different buttons on add/edit templates