LeoTheKid
(Leothekid)
March 19, 2013, 9:38pm
1
YiiBooster Error: Alias "bootstrap.widgets.TbButton" is invalid.
Hi all,
I installed YiiBooster-1.0.5 as suggested but apparently I’m having issues with Aliases. Yii can’t find TbButton. Where did I go wrong?
I have attached file excerpts. If it makes any difference, the Yii core files are outside this application ($yii=’/var/www/html/yii/framework/yii.php’ and this app is at /var/www/html/MyWebsite
Thx for your assistance!
Leo
jacmoe
(Jacob Moen)
March 19, 2013, 9:40pm
2
[color="#006400 "]/* moved from Miscellaneous */[/color]
mirunho
(D Mirecki)
March 20, 2013, 9:12am
3
LeoTheKid:
YiiBooster Error: Alias "bootstrap.widgets.TbButton" is invalid.
Hi all,
I installed YiiBooster-1.0.5 as suggested but apparently I’m having issues with Aliases. Yii can’t find TbButton. Where did I go wrong?
I have attached file excerpts. If it makes any difference, the Yii core files are outside this application ($yii=’/var/www/html/yii/framework/yii.php’ and this app is at /var/www/html/MyWebsite
Thx for your assistance!
Leo
try to change:
'bootstrap'=>array(
'class'=>'bootstrap.components.Bootstrap',
),
LeoTheKid
(Leothekid)
March 20, 2013, 11:30am
4
Thanks for your suggestion, Mirunho, but I’ve already tried ‘class’=>‘bootstrap.components.Bootstrap’ and it doesn’t solve the problem. Any other suggestions?
Leo
mirunho
(D Mirecki)
March 20, 2013, 1:01pm
5
Maybe you PathOfAlias is wrong?
You can try
Yii::setPathOfAlias('bootstrap', dirname(__FILE__).'/../extensions/bootstrap');
depends on your real path.
And did You copy bootrstrap files to extensions folder ?
LeoTheKid
(Leothekid)
March 20, 2013, 2:50pm
6
mirunho:
Maybe you PathOfAlias is wrong?
You can try
Yii::setPathOfAlias('bootstrap', dirname(__FILE__).'/../extensions/bootstrap');
depends on your real path.
And did You copy bootrstrap files to extensions folder ?
Yes, the bootstrap files are located under the extension folder.
I originally used Yii::setPathOfAlias(‘bootstrap’, dirname(FILE ).’/../extensions/bootstrap’) but it does not work either.
LeoTheKid
(Leothekid)
March 20, 2013, 10:42pm
7
Issue RESOLVED!!
I misspelled the bootstrap folder name when I placed the files under the application’s extensions sub-directory.
Thanks all for your help and I’ll try to be more careful in the future!
gerhard
(gerhard@ecolar.co.za)
April 2, 2013, 4:48pm
8
I only load Bootstrap when needed, based on Joblo’s comment (#11204 ) in this wiki.
But if you forget to load Bootstrap before using its widgets, you will also get this "Invalid Alias …" error.