I’m new to this framework and I am still trying to find out if this framework is just right for me. I’ve read the manual (it took some time to understand everything, practiced a bit) but still standing with some unanswered questions.
When I use the CFormModel or widgets, it will automatically include the JQuery script files to the output. I think that’s not always wanted for me. For example, when I will create a new theme which will function as a mobile layout, then I don’t want those unnessecary script files to be included. I got this feeling that I actually don’t have the fully control over these script files and am forced to use JQuery. Now my question, is it possible to take over control and include my own script files by myself? And if I actually want to disable JQuery, is that also possible? Or is this framework just not made for me?
The good news is: Pretty much everything is possible with Yii . In the simplest case it’s just a matter of disabling an option. If there is no option, you can always override some of Yii’s default components with your custom class.
But how can I use the form model without jquery now? Do I need to rewrite the class or do I need to avoid form models?
I will actually use JQuery on my own website, but want to include it manually per theme. Can I change the views of the widgets per theme, so I can say it may use jquery with this theme and not by the other?
Oh haha I see. Sorry, my fault… I really thought I copied my own view file, but I think I didn’t overwrite or something like that.
But now I just want to know if I can customize widgets to use or not use jquery. I saw this skinning feature, but does this work like the same way as views in theming? Or is it just changing properties and not changing php&html code? I hope I can change the output of the widgets so I can enable or disable jquery per theme.