Yii Framework Forum: [EXTENSION] jQuery UI widgets - Yii Framework Forum

Jump to content

  • (8 Pages)
  • +
  • 1
  • 2
  • 3
  • 4
  • 5
  • Last »
  • You cannot start a new topic
  • You cannot reply to this topic

[EXTENSION] jQuery UI widgets

#41 User is offline   MetaYii 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 393
  • Joined: 07-October 08
  • Location:The Matrix

Posted 14 March 2009 - 05:26 PM

Uploaded to jQuery UI 1.7, please visit the extension in the extensions' repository
0

#42 User is offline   MetaYii 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 393
  • Joined: 07-October 08
  • Location:The Matrix

Posted 14 March 2009 - 05:27 PM

Quote

Updated to jQuery UI 1.7, please visit the extension in the extensions' repository for more info.

0

#43 User is offline   qwerty 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 315
  • Joined: 20-November 08

Posted 16 March 2009 - 11:30 AM

Hi,
I have problem with jui 2.0.

When I try dialog without buttons:

<?php $this->beginWidget('application.extensions.jui.EDialog',
    array('name'=>'dialogo',
          'theme'=>'cupertino',
          'compression'=>'packed',
          'htmlOptions'=>array('title'=>'Hello dialog'))); ?>
<p>Hello world</p>
<?php $this->endWidget('application.extensions.jui.EDialog'); ?>


I have error:

Quote

PHP Error

Description



Array to string conversion

Source File



E:\www\projects\mysite.pl\protected\extensions\jui\EDialog.php(229)



00217:

00218:      foreach ($this->callbacks as $key=>$val) {

00219:          $encodedOptions = str_replace("'callback_{$key}':'{$key}'", "{$key}: {$val}", $encodedOptions);

00220:      }

00221:

00222:      if (!empty($this->buttons)) {

00223:          $b = array();

00224:          foreach ($this->buttons as $key=>$val) {

00225:            $b[] = "'{$key}'".':'.str_replace(array("\n", "\r", "\t"), '', $val);

00226:          }

00227:          $buttons = "'buttons':{" . implode(',', $B) . '}';

00228:      }

00229: $encodedOptions = str_replace("'buttons':'buttons'", $buttons, $encodedOptions);

00230:

00231:      return $encodedOptions;

00232:    }

00233:

00234:    /**

00235:    * Generates the javascript code for the widget

00236:    *

00237:    * @return string

00238:    */

00239:    protected function jsCode($id)

00240:    {

00241:      $options = $this->makeOptions();     


What is wrong?
0

#44 User is offline   MetaYii 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 393
  • Joined: 07-October 08
  • Location:The Matrix

Posted 16 March 2009 - 11:59 AM

Hi, I couldn't reproduce it  :o
Can someone else try to reproduce this?
0

#45 User is offline   ironic 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 32
  • Joined: 09-January 09
  • Location:Germany

Posted 17 March 2009 - 12:11 AM

Quote

Can someone else try to reproduce this?


No "success". For me, the posted code worked fine.

greets
0

#46 User is offline   qwerty 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 315
  • Joined: 20-November 08

Posted 17 March 2009 - 01:59 AM

I did not do anything special. I paste the code from the example to index view file.
0

#47 User is offline   rpaulpen 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 136
  • Joined: 01-December 08

Posted 17 March 2009 - 04:31 AM

I do get the same error.  Something to do with the buttons option.  I just pasted the code in, tried it and got the same error.

R
0

#48 User is offline   Giovanni D. 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 238
  • Joined: 23-December 08
  • Location:London (UK)

Posted 19 March 2009 - 12:36 PM

Hello.. maybe this is more a question related to the jQuery UI .. but .. is it normal that on localhost if I set 'compression'=>'packed' in the dialog options it takes a lot of time and cpu to load the page?

Another thing: the date picker is shown correctly using the following code:

$this->widget('application.extensions.jui.EDatePicker',
              array(
                    'name'=>'cp',
                    'language'=>'it',
                    'mode'=>'imagebutton',
                    'theme'=>'ui-lightness',
                    'value'=>date('Y-m-d'),
                    'htmlOptions'=>array('size'=>10)
                  )
            );


but the datepicker shown is very small.. you can't even read the numbers on it.. does this happens to you too? I also tried it with an empty webapp (generated with yiic) but nothing changed..  ::)

thanks.

bye,
Giovanni.

p.s.
thanks for this great extension.. it would be great to have the tabs widget too but for me the most important are the datepicker and the dialog.


0

#49 User is offline   MetaYii 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 393
  • Joined: 07-October 08
  • Location:The Matrix

Posted 19 March 2009 - 01:53 PM

[quote author=Virtual DarKness link=topic=622.msg6945#msg6945 date=1237484168]
Hello.. maybe this is more a question related to the jQuery UI .. but .. is it normal that on localhost if I set 'compression'=>'packed' in the dialog options it takes a lot of time and cpu to load the page?
[/qoute]

Can you check which process is eating your CPU? maybe your browser of your HTTPd... also, try the minified, it's said to work better than the packed.

Quote

Another thing: the date picker is shown correctly using the following code:


Will check later, I'm not at home.

Quote

thanks for this great extension.. it would be great to have the tabs widget too but for me the most important are the datepicker and the dialog.


Sure, I'll include the tabs too.
0

#50 User is offline   Giovanni D. 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 238
  • Joined: 23-December 08
  • Location:London (UK)

Posted 20 March 2009 - 03:39 AM

Quote

Can you check which process is eating your CPU? maybe your browser of your HTTPd... also, try the minified, it's said to work better than the packed.


the process is firefox.. maybe also due to the firebug extension.. but also using chrome it takes a lot more time to load the page..

anyway.. with the minified version ("min") it runs fine :)

Quote

Sure, I'll include the tabs too.


:) great, thanks!

bye,
Giovanni.
0

#51 User is offline   MetaYii 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 393
  • Joined: 07-October 08
  • Location:The Matrix

Posted 23 March 2009 - 11:44 PM

New release (2.1), including ETabs (and ETab). Wrapper for the Tabs widget. It works in two modes (see the extension). ETab is a container for a tab (in normal mode), and ETabs is the tab panel (works also in Ajax mode)


0

#52 User is offline   Giovanni D. 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 238
  • Joined: 23-December 08
  • Location:London (UK)

Posted 24 March 2009 - 10:47 AM


Thanks a lot!

Happy that you implemented it so that it works in ajax mode too!!  :)

bye,
Giovanni.
0

#53 User is offline   Giovanni D. 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 238
  • Joined: 23-December 08
  • Location:London (UK)

Posted 25 March 2009 - 04:27 AM

Hi,
on the documentation could you please add also the "theme" option? It took me some time to figure it  :P

something like:
<?php $this->beginWidget('application.extensions.jui.ETabs', array('name'=>'tabpanel1', 'theme'=>'ui-lightness')); ?>


thanks.

also.. about the dialog box.. would be useful / time saving to have a small example that shows how to open a dialog by clicking on a link .. like a small simulation of a "delete" icon clicked or something like this..  ::) ..anyway I'll have to look at it so if you don't have it already I'll post it here.

bye,
Giovanni.

p.s.
I still have the problem with the calendar widget that makes the calendar looks too small.. did you checked this? thanks.
0

#54 User is offline   qwerty 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 315
  • Joined: 20-November 08

Posted 25 March 2009 - 06:04 AM

Hi,
try set fontSize atribute.
0

#55 User is offline   Giovanni D. 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 238
  • Joined: 23-December 08
  • Location:London (UK)

Posted 25 March 2009 - 11:50 AM

Quote

try set fontSize atribute.


hi, seems to work.. but don't understand why, if I change it inside EDatePicker.php (just for a test) it works, but if I change it in my code like this:

$this->widget('application.extensions.jui.EDatePicker',
              array(
                'name'=>'cp',
'fontSize'=>'2em',
'effect'=>'fadeIn',
...


it doesn't do anything..  ::)

thanks.

bye,
Giovanni.
0

#56 User is offline   qwerty 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 315
  • Joined: 20-November 08

Posted 25 March 2009 - 04:27 PM

Hi,
maybe try to clear the assets folder?
0

#57 User is offline   Giovanni D. 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 238
  • Joined: 23-December 08
  • Location:London (UK)

Posted 26 March 2009 - 04:21 AM

hi,
tried to clear the assets folder but didn't helped..

as you can see from my piece of code I've also tried to change the effect property and that one works fine, just the fontSize seems to be ignored. But I guess I'm missing something :P  ::)

anyway, thanks for your help  :)

bye,
Giovanni.
0

#58 User is offline   arsitek 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 141
  • Joined: 10-October 08

Posted 28 March 2009 - 11:15 PM

I wanna include timeFormat (yy-m-d H:i:s) in field datepicker.

How to do that?

Thanks
0

#59 User is offline   SlowDown 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 27
  • Joined: 18-March 09

Posted 05 April 2009 - 11:40 PM

I'm using jui 2.0, it was working good on yii 1.0.3 until this morning when I upgrade to yii 1.0.4 it stop working and threw this error :

Quote

PHP Error

Description



Object of class EDatePicker could not be converted to string

Source File



/public_html/pay/protected/views/peg/_form.php(63)



00051: <div class="simple">

00052: <?php

00053:      echo CHtml::activeLabelEx($peg,'tlahir_a');

00054:      echo ($showform ? CHtml::encode($peg->tlahir_a) :

00055:              $this->widget('application.extensions.jui.EDatePicker',array(

00056:                    'model'=>$peg,

00057:                      'attribute'=>'tlahir_a',

00058:                      'language'=>'',

00059:                      'theme'=>'redmond',

00060:                      'compression'=>'none',

00061:                      'mode'=>'imagebutton'

00062:      ))

00063: );


Any idea how to workaround?

-majin-
0

#60 User is offline   qwerty 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 315
  • Joined: 20-November 08

Posted 06 April 2009 - 01:47 AM

Hi,
try clear your assets folder.
0

Share this topic:


  • (8 Pages)
  • +
  • 1
  • 2
  • 3
  • 4
  • 5
  • Last »
  • 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