March, 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

Posted in BusinessComments (0)

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/



Posted in AJAX, JoomlaComments (5)

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

Posted in AJAX, JoomlaComments (1)

attachment_fu file rename file rename / change filename : HOWTO

I’ve been looking for a solution to change the filenames of the uploaded files and came across the great tutorial at http://the.railsi.st/2007/8/21/how-to-customize-attachment_fu-file-names/ but it was not what i was exactly looking for. I had issues with viewing the saved files because the thumbnail property does not exist for the new attachment etc.

I’m posting what I did and it changes the filenames to what ever we specify.. Works for me, and hopefully it will work for someone else as well.. :)

checkout the pastie for a better view of the code http://pastie.caboo.se/161062

class Photo < ActiveRecord::Base
	#Options for has_attachment
	has_attachment	:content_type	=> :image,
			:storage 	=> :file_system,
			:size => 1.kilobyte .. 10.megabytes,
			:resize_to => '500>',
			:thumbnails => { :thumb => '125' },
			:path_prefix => 'public/images/product_pics',
			:processor    => 'MiniMagick'
	validates_as_attachment

	belongs_to  :product

	#Filename changing stuff, these methods resides in attachement_fu plugin files..
	#and we are just modifying them to fit our needs and putting them in our model
	#so other models will not be effected
	def full_filename(thumbnail = nil)
		file_system_path = (thumbnail ? thumbnail_class : self).attachment_options[:path_prefix]
		@thumb = self.thumbnail unless (@thumb = thumbnail) #checks if thumbnails info already exist
		File.join(RAILS_ROOT, file_system_path, self.product.code, thumbnail_name_for(@thumb, self.product.code))
	end

	#Change the filenames and thumbnail suffixes
	def thumbnail_name_for(thumbnail = nil, asset = nil)
		suffix = "_#{thumbnail}" unless thumbnail.blank?  #sets suffix by the name of the thumbnail set in has_attachment options
		extension = filename.scan(/\.\w+$/) # extracts extension
		return "#{asset}#{suffix}#{extension}" # change the filename to fit your needs
	end

	before_thumbnail_saved do |record, thumbnail|
		thumbnail.product_id = record.product_id
	end

end

Posted in Ruby / RailsComments (0)