Getting the Autosuggest/Autocomplete jQuery plugin to work on Multilingual Sites
by Royston Olivera on Aug.28, 2010, under Technical
I have been a big fan of DevBridge’s Autocomplete jQuery plugin and have used it on most of the sites that I have developed. But this plugin did not work for an Arabic site that I was developing. Just by monitoring the Ajax calls made by the plugin I noticed that the plugin wasn’t UTF encoding the arabic string before making the request. A minor tweak to the plugin and it started working fine.
All I did was that I edited the plugin to UTF-8 encode the string before it makes the Ajax call.
Once you have downloaded the plugin from DevBridge open the jquery.autocomplete.js file in your favorite editor and scroll down to the getSuggestions function. Now just replace the line
me.options.params.query = q;
with
me.options.params.query = unescape(encodeURIComponent(q));
In the server side script to which the ajax request is being made UTF-8 decode(in PHP use the utf8_decode( string $data ) function) the string before querying your DB for the string. Now your autosuggest will work smoothly for all the writing systems on the web.
Hope this post helps other developers.
Lessons I learnt…
by Royston Olivera on Feb.17, 2010, under Miscellaneous
Now with two years into professional life, things have been really awesome, thanks to my 1st company that I was working with till late last month. I have now moved on to see how a change would make a difference to my career and life. Change is difficult(and this change was indeed difficult), but it is said that if you look back at life, the most rewarding experiences were when you were open to change. So as I look forward to my future rewards, I thought of doing some retrospection and putting down the lessons I learnt till date in my professional life. These are the lessons I learnt from my colleagues, by making mistakes and by watching others make mistakes.
Small Company vs Big Company…
The above comparison shouldn’t bother you, what should bother you is the WORK you get at the company. It could happen that you get the best and most challenging job at an small-mid size company while a mere documentation or QC job at an big company.
Stay Hungry…
Set targets not limits to the work that your doing. Be restless to learn what your colleague knows and you do not. Having and doing loads of work is good as it helps keep the fire burning within us.
Be on the right side of the rotten apple…
You may have that arrogant creative guy or lethargic technical lead in your team, but remember that they hold that position because they have some talent. Isolating yourself from them is a loss to your growth. Be on the right side of the rotten apple, learn what makes that other guy a good tech. lead or creative person and try to become a non-lethargic non-arrogant creative tech. lead.
Get into complexity before your pushed into it…
I have seen a lot of this happening, when a team is asked to pick up their own tasks there a major set of people that pick the simpler one’s first and leave the complex tasks to that small set of people who always do it and love to do it. If you belong to that major set, its high time that you move to the smaller set. Coz the day when you do not have that small set of people around you and your manager assigns the task to you, that complex task may seem to be an impossible task.
Don’t Expect Training…
I have seen a lot of freshers ask this question as they join their first company ’Do we get training here?’ referring to 3-6 months of training that most of the Indian IT companies provide to freshers. My question to them has always been, What have you done in the past 3-4 years? Isn’t 4 years enough of time to train yourself? If you couldn’t train yourself in 4years, are you expecting some kind of miracle in the 3 months of training. I am not against training but there is a different kind of a joy in molding yourself than being molded by others, coz in the former you get to choose what you like, which mostly is not possible in the later. I have always looked at my career as one big training class and that has helped me big time.
Give back…
Remember it is your seniors who helped you when you were a junior and now its your responsibility to help your juniors. And this would help you too to revise your basics. I realized that I had forgot the basics and history of PHP when I was preparing slides for a PHP talk to be given at a college Techfest.
Measure of Success…
Before you party on your weekend, look back at the week gone by and see have learned enough? Was your week fruitful? Are you tired? If you have a positive answer to all these questions then go ahead party/relax else, get back to work. The best way to measure your success at the end of the year is not by checking the CTC you draw, but by counting the number of weekends you partied/relaxed and your achievements for the year. Your CTC will always be proportional to your professional achievements, so strive to achieve more.
Network…
One of the biggest mistake in the first 2 years of my career was to be an introvert and confining my network to just friends and office colleagues. If you go beyond this, you will find that there are a hell lot of amazing and like minded people out there to connect with and learn from. Facebook, LinkedIn and other forums were mainly built to facilitate this connect( not play silly games) and these channels have truly helped me meet and connect with some really good people in the past 6 months. Infact, some of the job offers that I got were via LinkedIn
These are some of the lessons that I have learnt from my professional life so far. Some people may differ from my thoughts and without doubt they have every right to do so.
What lessons have you learnt? Share it with me in the comments :)
HOW TO : As a Company/Business make best use of SlideShare
by Royston Olivera on Dec.13, 2009, under Social Media
In my 1st post on SlideShare, I tried giving a low down on what SlideShare has in store for all and why it becomes an upcoming Social Media channel. In this post, I will try and put together a set of steps that businesses/companies could follow to make the best use of SlideShare to share information and their branding.
Create your Profile…
You need to start off by first creating your account and selecting the appropriate Account Type. For a business it would mostly be “company”, unless your a Marketing/PR firm or a Non-Profit who have their specific account types. Once you have confirmed your account, login and complete your profile by giving the description of your company, uploading your logo and entering the tags that best describe your company and the work done. It would be best to fill in every information in a detailed manner, as that is what people are going to look at first when they stumble upon your company on SlideShare.
Upload Great Content…
Now its time to dig out all the content(Tuesday TechTalk slides, White papers written by your employees, presentations that you made to your clients) that your company has generated over the years and is just lying under virtual dust in your Content Management System and post it to SlideShare. Any content that you think would be of great help to others and could draw some eyeballs to your account is a good post. Post content that acts as a proof to the profile information that you provided. Remember we are trying to use SlideShare not only as a knowledge sharing medium but also for your branding, so before you upload your content you need to dress it up.
- Design 1 or 2 good templates and push your presentations in these templates before uploading them to SlideShare. By doing this people who have already viewed and liked some of your presentations before will be able to identify your other presentations in the search listings and prefer to pick them over others.
- Let the first slide of your presentations have the company logo, authors name and company website along with the subject of the presentation.
- Make sure your template has your company logo and/or your company name in the footnote on every slide, certifying that the content is yours and at the same time giving it a professional look.
- The last slide of each presentation could have a citation to the author, when and where was this presented, a link to the blog or document that briefly describes this presentation and the email id for feedback or more information on this presentation.
Publish your presentations with the appropriate title, description and tags so that people get a good idea of the presentation before they scan it slide-by-slide.
Socialize…
SlideShare provides quiet a few social networking features that would help you build your social graph. Start of by searching for people and company profiles in your field and start following them. Review their content and provide them with feedback, favorite presentations that you really liked, comment on them, provide them with a link to your own presentations on the same topic and ask for feedback. Basically you need to start a conversation, social media is all about starting a conversation, collaborating with people and building communities.
Share your Content…
Socializing within SlideShare is a good thing to do, but you can even attract people from outside SlideShare by embedding and sharing your presentations on blogs and other social networking platforms. Make sure that you blog about each of your presentation giving in-depth explanation of your presentation and using the embed code provided by SlideShare to embed your presentation in your blog post. SlideShare has even built apps. on Facebook and LinkedIn, so you could even add these apps to display your content on your companies profile or fan page on these social networks.
One of my personal favorite offerings from SlideShare are their wide range of widgets and presentation playlists that you can embed on your blog and website to display a feed of your presentations.
SlideShare Business…
SlideShare recently launched SlideShare Business that provides a new way to reach professional audience, connect with more and the right people by advertising your content to them, but I would recommend to go for this only after you have built a good profile by following the above few steps.
The above steps provided by me are by no means exhaustive, there would be many other ways by which you could make use of SlideShare as a social media channel to promote your company and its work.
How are you using SlideShare to promote your business? Share it with me in the comments