Showing 301-320 of 373 items.

How to translate and do the translations the easy way

Created 14 years ago by Roman Solomatin Roman Solomatin, updated 10 years ago by Roman Solomatin Roman Solomatin. 3 comments

I wanted to keep all the I18N related translations in separate files, so that I would not need to modify the view files or the model files every time I need to update or fix the translations of application's source language.

Authenticating against phpass hashes with Yii

Created 14 years ago by Da:Sourcerer Da:Sourcerer, updated 12 years ago by Da:Sourcerer Da:Sourcerer. 18 comments
  • iteration_count_log2 controls the number of iterations for key stretching. A setting of 8 means the hash algorithm will be applied 2^8 = 256 times. This setting should be kept between 4 and 31.
  • portable_hashes controls whether portable hashes should be used or not. Portable hashes are salted MD5 hashes prefixed by $P$.
22 0
28
Viewed: 45 644 times
Version: 1.1
Category: How-tos

Using a CDbDataReader (sql query result) in a zii widget (such as CGridView or CListView)

Created 15 years ago by Revelis Luc Bonnin Revelis Luc Bonnin, updated 15 years ago by Revelis Luc Bonnin Revelis Luc Bonnin. 2 comments

If in your application you have to proceed to a complex SQL query that is not associated to a model, you will use CDbDataReader like it is described in the Yii documentation. An example could be

ISA hierarchy of tables inside a database and how to implement a single form

Created 15 years ago by pligor pligor, updated 15 years ago by pligor pligor. 2 comments

Please consider the following Dear software engineers imagine I have a simple ISA hierarchy: parent A with children B and C. So let's say we have the corresponding tables named "a", "b", "c" and (created with the help of the gii model creator) the classes A, B, C The following is a screenshot from MySQL workbench: ![MySQL workbench screenshot](http://s4.postimage.org/4tuwkm43d/Screenshot.pn...

1 0
3
Viewed: 19 551 times
Version: 1.1
Category: How-tos

Creating a CSS Driven Drop Down Menu using CMenu

Created 15 years ago by blindMoe blindMoe, updated 14 years ago by blindMoe blindMoe. 10 comments

[CMenu] offers great functionality and the ability to customize just about every aspect of the output. There are many times when I need to create a drop down menu or simply modify the look to make the designers happy. Because this seems to be a common task for me, I figured I would share my code to create a very simple drop down menu that other people could use.

19 1
25
Viewed: 103 277 times
Version: 1.1
Category: How-tos

How to use an application behavior to maintain runtime configuration

Created 15 years ago by zaccaria zaccaria, updated 14 years ago by Pablovp Pablovp. 3 comments

In this tutorial will be explained a method to manage some configuration runtime. This excellent tutorial follows a similar approach, but requires to write a masterclass which all controllers are supposed to extend, following this wiki you can achieve the same by only editing the configuration.

26 0
25
Viewed: 47 922 times
Version: 1.1
Category: How-tos

How to show ajax delete status in CGridView like flash messages

Created 15 years ago by hasanavi hasanavi, updated 13 years ago by adlersd adlersd. 12 comments

I've seen many tickets regarding how to show friendly delete confirmation using CGridView's CButtonColumn in ajax request. If you are using relational database, after producing CRUD functionality when you try to delete a record in ajax mode which has child record it can't be deleted and you can see the ajax loader forever. By this way you can't show the users if a record has been successfully dele...

17 0
30
Viewed: 61 448 times
Version: 1.1
Category: How-tos

Sub-domains with different databases in Yii!

Created 15 years ago by jwerd jwerd, updated 15 years ago by jwerd jwerd. 5 comments

I used another example posted here a while back where the person was modifying the index.php and adding in a switch case for different domains and loading separate config files. This was actually too much for me, because all my portals are the exact same (as far as routes, modules, extensions, etc) and if I ever wanted to add another route it wouldn't be feasible opening up all the config files t...

2 0
12
Viewed: 29 124 times
Version: 1.1
Category: How-tos