I faced many issues when hosted our company website on AppFog.
I faced many issues when hosted our company website on AppFog.
Does your application need to know user's details on browser details, os and device type? We can use PHP's misc. function to achieve that provided you have an update copy of browsercap.ini
This is not actually Yii involved.
What I want to achieve:
Modern browsers support SVG, older browsers do not. This replacement for CHtml::image() allows you to handle to propose SVG in an efficient way with PNG as a fallback.
Hi I had made simple archive system for blog system that can handle tbl_post. I had used simple CDbCriteria not more than that. I know there is more and many better way to this but I think this will give some idea to users to generate new idea or customized or modified this version of code.
some times we want to show the serialNo on cgridview .
This topic is related with langhandler extension
Yii has a neat "trick" that will assign default values to new CActiveRecords. When performing a search() though, this is pretty annoying as they automatically apply as filter values.
As we know Using crud generator creates menu items in view files (for each view file have a varius menu items)
If you are about to create a graph, the best option i would suggest is the jqbargraph.
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);
}',
Sometimes writing views like
in model add the following code:
So you want to use CForm (form builder), but need to preload dropdowns in a form? It's simpler than it seems.
You got your CFormModel, CForm and the actual Form, right?
Let's say you have the typical State -> City dependent dropdowns, so you would want to load the from with the State and City selected.
I'm developing a web project for a company using Yii framework. We are using a git vcs in our development process. We like to use Yii extensions. But only if they are good.
The usual way to find out what Yii has created for an SQL query is to mutilate the SQL in the sourcecode and call the program again so that the SQL statement with errors is displayed. Or you can use the SQL logger, which must be switched on and off each time and logs all SQL statements, which leads to an enormous slowdown in program execution and decelerates your workflow.
If you are testing your app and use urlManager in your config, sometimes you will find a problem: you want to test your site independing from urlManager settings. in that way you need to extend your WebTestCase class by this method:
Almost all the information you need whilst working with yii is written in the Class Reference.