Yii Framework Forum: Yii::app()->CJuiWidget->registerCoreScripts(); - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Yii::app()->CJuiWidget->registerCoreScripts(); Rate Topic: -----

#1 User is offline   bas_vdl 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 215
  • Joined: 01-April 09

Posted 17 February 2010 - 09:48 AM

why is this not working?


Code:
<?php Yii::app()->CJuiWidget->registerCoreScripts('CJuiTabs'); ?>


Exception
CException
Description

Property "CWebApplication.CJuiWidget" is not defined.

0

#2 User is offline   Jaz Manister 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 109
  • Joined: 27-October 09
  • Location:Rural Western New York, USA

Posted 17 February 2010 - 09:56 PM

View Postbas_vdl, on 17 February 2010 - 09:48 AM, said:


<?php Yii::app()->CJuiWidget->registerCoreScripts('CJuiTabs'); ?>




Try something like this..
<?php Yii::app()->clientScript->registerCoreScript('CJuiTabs'); ?>


It's registerCoreScript singular, not plural.
0

#3 User is offline   bas_vdl 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 215
  • Joined: 01-April 09

Posted 18 February 2010 - 04:22 PM

View PostJaz Manister, on 17 February 2010 - 09:56 PM, said:

Try something like this..
<?php Yii::app()->clientScript->registerCoreScript('CJuiTabs'); ?>


It's registerCoreScript singular, not plural.


nope, it's still not loading the script and css files you need for the jquery ui tabs
0

#4 User is offline   Jaz Manister 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 109
  • Joined: 27-October 09
  • Location:Rural Western New York, USA

Posted 18 February 2010 - 09:14 PM

View Postbas_vdl, on 18 February 2010 - 04:22 PM, said:

nope, it's still not loading the script and css files you need for the jquery ui tabs


Well, I'm confused as to why you would need to register any scripts to use the CJuiTabs. If you instantiate the widget, I believe it will take care of that on its own. Is it not doing that?
0

#5 User is offline   bas_vdl 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 215
  • Joined: 01-April 09

Posted 19 February 2010 - 02:09 AM

i need more than one widget tabs on a page and the widgets are loaded into the page using a ajax call. using the default widget it's not working. so i want to load the core files and write my own tabs...

have a look at my other topic: http://www.yiiframew...-cjuiaccordion/
0

#6 User is offline   bas_vdl 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 215
  • Joined: 01-April 09

Posted 22 February 2010 - 03:32 PM

guys how to load the core file for the cjuitabs widget without using the yii cjuitab widget
0

#7 User is offline   bas_vdl 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 215
  • Joined: 01-April 09

Posted 23 March 2010 - 08:24 AM

still didn't find a solution to load the ui jquery script files using yii framework
0

#8 User is offline   qwerty 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 290
  • Joined: 20-November 08

Posted 23 March 2010 - 10:49 AM

In main config file set clientScript component. Look this cookbook
0

#9 User is offline   brent.ertz 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 2
  • Joined: 06-November 09

Posted 13 May 2010 - 01:05 PM

View Postbas_vdl, on 22 February 2010 - 03:32 PM, said:

guys how to load the core file for the cjuitabs widget without using the yii cjuitab widget


You could try the following, though if you plan on changing the theme, you'd need to point to an alternate CSS.
$basePath = Yii::getPathOfAlias('zii.vendors.jui');
$baseUrl = Yii::app()->getAssetManager()->publish($basePath);
$cs = Yii::app()->getClientScript();
$cs->registerCssFile($baseUrl.'/css/base/jquery-ui.css');
$cs->registerScriptFile($baseUrl.'/js/jquery-ui.min.js');

0

#10 User is offline   jayrulez 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 348
  • Joined: 29-July 09

Posted 13 May 2010 - 04:40 PM

http://www.yiiframew...-with-yii-1-1-1
php:
foreach(array('cat', 'dog', 'cow') as $animal) echo $animal."\n";

python:
[(animal, print(animal)) for animal in ['cat', 'dog', 'cow']]

ruby:
['cat', 'dog', 'cow'].each {|animal| puts animal}


You say Tomato, I say Tomato.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users