General developer forum

change action url in admin settings pages

 
Picture of Hossein Poursaeedi
Re: change action url in admin settings pages
 

Thanks for your reply Tim,
let me explain you what i did,  currently i have a plugin , with some sub component which need their own settings.
In main setting page, i have listed all components with "setting" link. when user click on the setting , it will redirect back to main settings page by 'section' plus my query string (GET method) and in main setting i will check, if there is param, i will add 3 more option like configtext and configcolorbox, but as i understand, when i click on "save Changes", it will post to the same main setting page (without my query string) and those 3 extra fields will gone. so i just thinking of changing form action to "admin/settings,php?section=xxx&myvar=yyy"  or, as i understand, moodle have 3 hidden types field which one of those are 'return', so if i can assign data to it also can be fine to me.


by the way, is there any way which we have our own hidden type in admin setting?
or is it anyway we assign manually data to post? like we do in php  $_POST, when i check main moodle code, its play with cookies and i dont know if any options there,

i know i can play with sessions, but i dont wanna touch it. thanks

 
Average of ratings: -