Showing 61-80 of 163 items.

Using Nginx and Apache2 in separate distributed servers (ie, Amazon EC2 instances)

Created 13 years ago by Luis Lobo Borobia Luis Lobo Borobia, updated 9 years ago by Luis Lobo Borobia Luis Lobo Borobia. 0 comments

We are running one frontend running NGINX and several app servers running Apache2. There are several issues we have come across but right now I'll be documenting one of them. I'll be completing this article when I get more time.

2 0
2
Viewed: 18 522 times
Version: all
Category: Tips

Debugging CActiveRecord failed save() attempts

Created 13 years ago by Boaz Boaz, updated 12 years ago by Boaz Boaz. 0 comments

When you're filling up a form of a CActiveRecord (using CActiveForm for example), usually you'll construct your code so that in case of validation error you'll get back the form with the error displayed back to you, typically when CActiveForm.errorSummary() is used. This is how its done by Gii.

4 0
2
Viewed: 43 732 times
Version: 1.1
Category: Tips

CGridView: Adding behaviors from configuration, and template items from behaviors to CGridView

Created 13 years ago by le_top le_top, updated 13 years ago by le_top le_top. 0 comments

Changing the way a CGridView is rendered from the configuration file, or through behaviors specified at the moment it is used, is handy to extend a CGridView without creating tons of different classes for it. I am surprised that this is not in the default implementation, so I made my default CGridView implementation.

3 0
3
Viewed: 18 410 times
Version: 1.1
Category: Tips

CjuiDatepicker

Created 13 years ago by hiral darji hiral darji, updated 13 years ago by hiral darji hiral darji. 1 comment

If you have two datepicker in one form and you want that a date of from date shold be minimum date of todate then put following code in Cjuidatepicker widget options array:

'onSelect'=>'js:function(selected) {
$("#HostelRoomStatusMaster_room_status_master_end_date").datepicker("option","minDate",selected);
				}',
1 0
5
Viewed: 13 902 times
Version: 1.1
Category: Tips

Adding a date range search for CGridView the easy way

Created 13 years ago by mikewalen mikewalen, updated 12 years ago by mikewalen mikewalen. 6 comments
  1. Create an Active Record Behavior that builds the criteria for the search() method and attach it to your model
  2. Modify the search() method of the model to merge the behavior's criteria in with the rest of the searchable attributes
  3. Modify the _search form view to add the date range inputs
6 0
11
Viewed: 46 227 times
Version: 1.1
Category: Tips

Fixing extensions without modifying their code

Created 13 years ago by schmunk schmunk, updated 13 years ago by schmunk schmunk. 3 comments

If you're working a lot with extensions you often stumble upon problems, when you want to include them into your custom web application, like hardcoded or absolute path aliases or classes extended from core application components, which implement addiditonal features.

6 0
10
Viewed: 21 995 times
Version: 1.1
Category: Tips