Articles in category "tips", sorted by ratingX
Displaying 71-80 of 153 result(s).

Create thermometer using rgraph

Created 3 years ago by Ankit ModiTips2 comments – viewed 6,841 times – ( +4 )
Hi friends,

How to catch and log MySQL deadlock errors

Created 4 years ago by sebTips1 comment – viewed 11,871 times – ( +4 ) – version 1.1
This method allows to log InnoDB monitor output when deadlock error occured. This way we will have much more useful data to find and fix deadlock.
tags: database

Access log output from unit tests

Created 4 years ago by MikeTips2 comments – viewed 7,313 times – ( +4 ) – version 1.1
Say, you want to write a test for a component which provides a caching feature. How would you know, that some method of your component returns a cached result? With the solution described here you can inspect all log outputs. So you could search the logs for accesses to the DB to really make sure, that the result was served from cache.

Get notified about the status of a Facebook user in your web app using periodic Ajax calls.

Created 4 years ago by sirin kTips0 comments – viewed 7,047 times – ( +4 ) – version 1.1
hello, This article is helpful only if you have the following situation: A web app which uses facebook login to login its users and if a user is logged out from his/her facebook account through another browser tab, then your app dont know that he is logged out out or not from his facebook account and he/she will remain as logged in your web application.Its ok if you have no problem with this situation.But if you want to forcefully logout the user from your application if he is logged out from his facebook account means you can try this example.This example uses periodic ajax calls to facebook's graph api to check whether the user is logged in or not.
tags: facebook, user

Preventing CJuiTabs from hiding drop-down CMenu items

Created 5 years ago by Steve FriedlTips1 comment – viewed 10,306 times – ( +4 ) – version 1.1
Almost all Yii applications use CMenu at the top of each page to show options available to the user, and many include drop-down components to allow more fine-grained selection.

Yii2 default values for Index data Provider

Created 2 years ago by CTalaTips2 comments – viewed 13,473 times – ( +4 ) – version 2.0

Syntax check

Created 5 years ago by Russell EnglandTips2 comments – viewed 8,184 times – ( +4 ) – version 1.1
So I've been busy making lots of modifications to my views/models/controllers - came to test the app and got a blank screen. Nothing in the application.log file so must be a syntax error somewhere... But which file?
tags: php, syntax

adding class and links to Ctreeview node

Created 5 years ago by bingjie2680Tips2 comments – viewed 14,262 times – ( +4 ) – version 1.1
This article will show you how to add links and class to each node in ctreeview. so you can attach events in js by obtaining handler on anchor or class.
tags: ctreeview, link, class

Send asset folder path to a javascript of a widget

Created 5 years ago by sensorarioTips4 comments – viewed 22,102 times – ( +4 ) – version 1.1
When you develop a widget, you could need one image that is in the assets folder, you can use it simply within a css. You can load a css or javascript script doing this:

embedded javascript block in your view with IDE checking or intellisense

Created 2 years ago by yiqing95Tips0 comments – viewed 4,535 times – ( +4 ) – version 2.0
this is my way for embed js code block in view file: