I am working on creating a form builder which loads form fields from an XML file and renders the HTML. I have multiple XML files, each has different form fields depending on what the user requires. I also have a database table which has all the columns which the forms require.
The issue I am having is creating a model that only loads the attributes and rules required for the generated form. Apart from overwriting the CModel class so validators and attributes can be set during runtime, are there any other ways for doing this?
Thank you for your reply saegeek, however I am not trying to set access rules, I am loading an AR and I want it to load custom rules and attributes after load. I think I have solved the issue in my reply above.