Theming And Organizing Directories (Discussion) Theming and Organizing directories (Discussion)
#1
Posted 19 October 2012 - 08:39 AM
Kiran Sharma.
#2
Posted 25 October 2012 - 03:59 AM
kiran sharma, on 19 October 2012 - 08:54 AM, said:
I just wanted to say that the way kiskp and hnam descried to create a theme is not like a standard yii theming.
Because if you make like they said it simply move you protected/view folder to theme folder and all your view file should be in this theme folder... that is not a theme.
Do you see what I mean?
#3
Posted 25 October 2012 - 07:33 AM
what they said is just like theming, as kiskp said that are only view files as you can see.
the controller and model files/folder will not change, if you want to use any theme you had to change in config file like 'theme'=>'classic' or 'theme'=>'mytheme' ...
Kiran Sharma.
#4
Posted 25 October 2012 - 08:55 AM
kiran sharma, on 25 October 2012 - 07:33 AM, said:
what they said is just like theming, as kiskp said that are only view files as you can see.
the controller and model files/folder will not change, if you want to use any theme you had to change in config file like 'theme'=>'classic' or 'theme'=>'mytheme' ...
You're right about saying "it's like theming" but it is not.
So is there a way to make real theming using this directory organisation?
#5
Posted 25 October 2012 - 09:03 AM
and what is real theming???
Please share if you had better idea...
Kiran Sharma.
#6
Posted 25 October 2012 - 09:11 AM
kiran sharma, on 25 October 2012 - 09:03 AM, said:
and what is real theming???
Please share if you had better idea...
When I say "real theming" I mean the way it is made with yii as usual.
#7
Posted 25 October 2012 - 09:24 AM
but i m just saying that plz share if you had any other structure/idea to make theming better
or
plz share why you think to change/update current structure... ..
Kiran Sharma.
#8
Posted 22 November 2012 - 07:53 AM
Two questions:
1. Did anyone combine this with the rights extension? How do you guys handle identical controller names on different endpoints, but different right access rules?
2. How do you create urls between endpoints? For example a link from back to front?
BR
Sebastian
#9
Posted 20 January 2013 - 01:08 PM
Thanks for a great article. I'm new to Yii, and have successfully set up a separation between backend/front following your article.
I have one problem.
When I link to internal pages by setting controller/action, they all igonre the backend/-part of the url.
Can I set this up in back.php (config), so that every url generated in backend, routes to backend/controller/action?
If I go to url backend/controller/action, I get correct view, but when links are generated, they are wrong.
No problems when creating the menu, since I just add "backend" to the link, but when I use CGridView (ie), there are a lot of autogenerated urls.
Hope someone can help:) Thanks!
#10
Posted 20 January 2013 - 01:26 PM
Just got it to work. Had to move the front-routing from main.php to front.php.
My bad:)
eeerlend, on 20 January 2013 - 01:08 PM, said:
Thanks for a great article. I'm new to Yii, and have successfully set up a separation between backend/front following your article.
I have one problem.
When I link to internal pages by setting controller/action, they all igonre the backend/-part of the url.
Can I set this up in back.php (config), so that every url generated in backend, routes to backend/controller/action?
If I go to url backend/controller/action, I get correct view, but when links are generated, they are wrong.
No problems when creating the menu, since I just add "backend" to the link, but when I use CGridView (ie), there are a lot of autogenerated urls.
Hope someone can help:) Thanks!
#11
Posted 15 April 2013 - 04:21 PM
'urlManager'=>array(
'urlFormat'=>'path',
'showScriptName'=>false,
'rules'=>array(
'backend'=>'site/index',
'backend/<_c>'=>'<_c>',
'backend/<_c>/<_a>'=>'<_c>/<_a>',
),
),
Results in the error Property "CWebApplication.urlManager" is read only.
Any way to fix this?

Help













