Moving Notice

This blog has been moved to http://kill3rmedia.com/blog/ . Comment posting has been disabled in this blog (please leave comments at new address..) Sorry for the inconvenience guys..


Wednesday, May 21, 2008

Simple Rails helper for using OnClick on div, tr and other tags

I came across the issue of making set of div tags' OnClick event to be connected with a remote function, yet I couldn't find a helper method to that and I made a simple and stupid helper method by cannibalizing link_to_remote and link_to_function helper methods.

usage: just like using link_to_remote, yet we don't specify "name", since there's no text going inside the tag except the onclick event info
e.g: <div <%= onclick_to_remote :url => my_restful_url %> class="my_1">

I works for me and get the work done.. arguments such as :with are supported.. Posting it here hoping someone will find it useful or may be improve it as well.

check out the pastie for better viewing pleasure and understanding http://pastie.caboo.se/200546

def onclick_to_remote(options = {})
*args = remote_function(options)
function = args[0] || ''
function = update_page(&block) if block_given?
"onclick=\"#{function}; return false;\""
end


Friday, May 2, 2008

Evil Facebook Apps: Your identity belongs to us..

according to BBC research, people can steal your identity through facebook and screw up your life... My guess is, only if you got such a life to be kept in secrecy.. What if your posted details are completely inaccurate, now who's laughing :)

http://news.bbc.co.uk/1/hi/technology/7376738.stm

Sunday, March 30, 2008

Welcome the Business Etiquette & Keep Informania Out

According to an article published on Times Online people who regularly juggle between work, email and text messages has to pay an 10 point IQ penalty whether they like it or not. Smoking pot or marijuana would be less harmful where it only cuts off 4 points.

Meeting Etiquette: Keep your mobile turned off at meetings. This habit was first force fed to me by one of my former bosses. Keeping a mobile phone turned on can make you look like someone who does not belong to that meeting. If we assume we attend meetings to make important decisions and not to look stupid, it would always help keeping the mobile phone turned off. Silent mode may not be helpful, since you might have to fight the temptations to check what has happened to the world while you were not caring enough (of the outside world)

Bonus Points: According to the study, keeping your mobile turned on can take out 10 points of your IQ. So it increase your chances of looking stupid at a meeting at the same time. If you are low on IQ (which can also cause keeping your mobile turned on) that 10 points can be significant.

Ring-tone to ruin them all: Setting explicit or silly ring-tone may give out early warnings about you to the people you meet. It's always good idea to be discrete rather than being loudly stupid. Have several profiles for Outside, Office, Factory, Home etc. Set office ringing volume to low and tone to be less irritating to enhance your professional image.


Juggling between Email, Text Messages and Work: This also seems to take 10 points off and cause Low Productivity at the same time. I have my own experience on that as well. About 4 months ago I discovered I've been wasting lot of time on Juggling between emails, instant messages and work. I made it a habit not to log into instant messengers unless there's an prearranged discussion. If there's anything important people will leave an offline message. I check my email by following a set schedule.

What Times Online suggest is to use the dead-time, such as your traveling time to check text messages.

For many others; these approaches may not be ideal. For me these simply works. I'm not a Fire Chief, God or someone who's willing to pay 10 IQ points penalty and settle for a less-productive day.

reference: TIMESONLINE

Friday, March 28, 2008

Ajax Banner Rotator (uses JQuery) & Mootools conflict diffused (hopefully :)

There was an issue reported by Revive Coffeehouse about mootools conflicting with the Ajax Banner Rotator.

Revive Coffeehouse said... Hey, Just as a heads up.. when using this module, it seems to disable the mootools menu effects, reverting them to standard CSS driven menus. So, I have a fancy banner rotator, but no fancy menus : ) Any idea if this can be fixed??

Possibly this is due to conflict of Mootools and JQuery. http://forum.mootools.net/viewtopic.php?pid=26204 hopefully it's been fixed on newer JQuery release (which I've used here). Please keep me posted on that issue.

I never expected to keep this thing up to date and fixing bugs (I'm no coder by profession as well as I've turned my evil eye towards RubyOnRails these days). But seems the rule that parents responsible of taking care of children applies here as well :)

V0.3b and 0.4b has also fixed the IE issue where the whole page becoming a link
Anonymous said... i love how this module works unfortunately its not working properly with my site its making the whole page a link


Download Module and read release notes http://joomlacode.org/gf/project/ajax_banner/




Thursday, March 27, 2008

Ajax Banner Rotator Updated - Now Supports Joomla 1.5 Natively

Just updated the Ajax Banner Rotator for Joomla 1.5 and now supports 1.5 without the legacy mode. Randomizing banners are still disabled since IE giving some error that I cant understand.. something to do with randomizing on jqrotator.js file. Comments welcome..

Thanks for the patience. I forgot to update the plug-in, even though I marked it supports 1.5 ;)


Download Module and read release notes http://joomlacode.org/gf/project/ajax_banner/



Read other posts on update, first release