Conditional Notifications Plugin for Gravity Forms
Based on the values of form fields selected notification settings are overridden, including e-mails and, more importantly content, and whether a notification is sent or not in the first place.
Based on the values of form fields selected notification settings are overridden, including e-mails and, more importantly content, and whether a notification is sent or not in the first place.
Functions Deprecated in WordPress 3.4 Here’s a list of functions that are now deprecated in WordPress 3.4: debug_fopen, debug_fwrite, debug_fclose, substituted by PHP’s native error_log get_themes, substituted for wp_get_themes, whereas get_theme and get_current_theme functions are replaced by wp_get_theme clean_pre is not replaced by anything, its relevant use inside the core has been replaced with good code, …
Extra Data in jQuery AJAX Requests Sometimes it’s necessary to bind some additional data to an AJAX request, data that is not sent over the wire but has to pop up in the callback. For instance: var dataStreams = ; dataStreams.push( { ‘id’: ‘A04AC’, ‘data’: ‘Hello World’ } ); dataStreams.push( { ‘id’: ‘AVM32’, ‘data’: ‘Easy does …

In any case, since my webserver of choice has long been nginx (built-in servers don’t impress me too much), having it serve Flask applications in a robust, reliable way was required. The instructions to marry nginx and Flask via uWSGI are quite clear. I compiled the uwsgi application container, read the docs and came up with the following startup command:
Before the if __name__ == '__main__': part of your application, i.e. at the very end, you have to wrap a werkzeug.debug.DebuggedApplication middleware around your app object.
Monitor Directory for Changes Here’s a simple script that I setup for my development WSGI server to reload itself once changes in source code are detected: #!/bin/bash while true; do A=`find $1 -printf ‘%t’ | md5sum`; sleep 1 B=`find $1 -printf ‘%t’ | md5sum`; if [ «$A» != «$B» ]; then echo «Detected change, doing: $2» …
tail -f | event Monitoring log files for specific keywords and firing off an event turns out to be quite simple to accomplish in bash with a `while` loop. #!/bin/bash tail -f $1 | while read line; do line=`echo -n «$line» | grep -i «$2″` if [ -n «$line» ]; then # mate-notify-send -t 0 «$2 …
keytool -genkeypair -alias androiddebugkey -dname 'CN=Android Debug,O=Android,C=US' -keystore /tmp/debug.keystore -keyalg RSA -validity 10000 generate a valid Android debug keypair (Signing in Debug Mode) with password ‘android’ for both the keystore and the keys