Components for the PHP-based yii framework
Questions tagged [yii-widgets]
64 questions
0
votes
1 answer
2amigos DataRangePicker. Display over input.
Problem
I set orientation, but it's still at the bottom. What's the problem?
Code
=$form->field($contactUsModel, 'planningToTravelFrom')
->widget(\dosamigos\datepicker\DateRangePicker::className(), [
…

D.R.
- 2,540
- 3
- 24
- 49
0
votes
1 answer
yii 1 CJuiDatePicker inside custom widget
I create new widget like this:
class Schedule extends CWidget
{
public $address = null;
public $order = null;//order
public function init()
{
if(isset($this->order))
$this->address = $this->order->address;
…

Александр Волошиновский
- 1,123
- 8
- 21
0
votes
0 answers
Trying to get property of non-object in yii widget
I faced with error
Trying to get property of non-object
The error disappears when I use my own widget. Here is the code of this widget
class OtherProductionWidget extends CmsWidget
{
public $category;
public $product;
public…

YuriiChmil
- 441
- 1
- 5
- 18
0
votes
1 answer
I want to display menu items dynamically from database also static in my yii2 frontend
I just want to display menus from database in yii2 advanced template frontend. Also i have static menus. I am using menu widget
Here is my code
['class' =>…

Sivabalan
- 971
- 2
- 18
- 43
0
votes
1 answer
How to save a binary directly to a database table field (JSON data) in Yii?
I'm working on a Yii project with a database, containing a table, where almost all it's data is saved in a field as JSON (it's crazy, but it is so as it is):
id INTEGER
user_id INTEGER
data LONGTEXT
This "JSON field" data has following…

automatix
- 14,018
- 26
- 105
- 230
0
votes
2 answers
Yii Framework Undefined Offset: 0
I am trying to use CGridView with custom query, and trying to build a very simple with no sorting and stuff.
My View contains simple CGridView
$this->widget('zii.widgets.grid.CGridView', array(
'dataProvider'=>$dataProvider,
));
And my…

mdanishs
- 1,996
- 8
- 24
- 50
0
votes
1 answer
Yii2, what the model parameter does in widget?
echo Select2::widget([
'model' => $vendorModel,
'attribute' => 'id',
'data' => $vendor,
'options' => ['placeholder' => 'Select a vendor ...'],
'pluginOptions' => [
'allowClear' => true
],
]);
The above Select2 widget…

Nerd
- 121
- 1
- 10
0
votes
3 answers
Yii, CJuiDatePicker how to block certain days of the Month
So I have this widget on my Yii _form.php page.
Is it possible to do things like blocking a certain day of the month? Or maybe blocking all the Mondays of the Month, disallowing users to select any Monday.
UPDATES based on hamed's answer