Posts

Showing posts from July, 2012

Book Review: SharePoint 2010 Plain & Simple

SharePoint 2010 Plain & Simple is a "SEE-HOW guide to SharePoint" and a good book for IT Pros or developers who are absolute beginners to SharePoint 2010. The book assumes that you already have all the required software installed & some Features activated. It shows how to perform the following 140+ Tasks with step-by-step instructions and screen-shots - Create a Site Based on the Team Site Template Create a Document Workspace  Change the Title and Description of Your Site Turn Off the Quick Launch Bar Change the Color Theme of the Site View All Site Content Save a Site as a Template Open Site Columns Browse Site Columns Create a Site Column Edit Site Columns Access Content Types Inspect Content Types Associate a Document Template with a Content Type Associate a Workflow with a Library Start a Workflow Check the Status of a Running Workflow Create a List or Library Delete a List or Library Add a List Item Edit a List Item Delete a List Item

HOW TO make columns in an ASP.NET GridView sortable with jQuery

Use the jQuery Tablesorter Plugin - see article with demo   Note that the jQuery Tablesorter Plugin requires the table generated by the GridView to have thead and tbody tags Assuming the Id of the GridView server control is set to grdEmployee, you can access the dynamically generated table's ID and build the selector like this -          gridId = $("table[id$='grdEmployee']").attr("id");          $('#' + gridid).tablesorter();  If you have a checkbox in the column header to implement Select All/De-select All functionality for items in that GridView, that will fail as the Tablesorter plugin will override the click event. To overcome that, use this trick -          $("#tablesorter").tablesorter({headers:{0:{sorter:false}}});  Also see: Yours declaratively, GridView   Beware of breaking changes in jQuery library versions  

The first 20 employees of Google

List of the first 20 employees of Google, posted by an anonymous user on Quora - 7 of the first 20 employees are still at Google. Here are all the first 20 and what they're doing now. Current employees are in bold. Sergey Brin: Google Larry Page: Google Craig Silverstein: Khan Academy [1] Heather Cairns: angel investing [2] Ray Sidney: Big George Ventures [3] Harry Cheung: angel investing [4] Amit Patel: Sunfire [5] Urs Hölzle: Google Georges Harik: imo.im, angel investing [6] Salar Kamangar: Google Omid Kordestani: Google Steve Schimmel: angel investing [7] Chris Skarakis: Blip.fm [8] Joan Braddi: Google Susan Wojcicki: Google Gerald Aigner Jim Reese Larry Schwimmer Kendra DiGirolamo: Driscoll's [9] Marissa Mayer: Yahoo! [10] Also see: The History of Microsoft The History of Apple

Power Searching with Google (and Bing)

Image
Did you know, you can even search with images of objects and not just textual keywords on Google (a feature probably first introduced in Google Goggles ). Let's say you found an interesting looking object in your attic but didn't know what it is, you can take a photo of it and use it to search. And did you know, Google queries cannot include most special characters: You may have read the book 20000 Leagues Below the Sea but have you ever tried to visualize how much is 20000 Leagues? It's 69046.7669 miles! These are tips I picked from the free online course Power Searching in Google  conducted by Daniel Russell, Senior Research Scientist at Google. You can attend it as well & apply some of the learning on Bing too.

What is the difference between Browser Mode & Document Mode in IE

Image
If you're a web developer and your job actively involves building web pages that work the same in all browsers including the last three versions of IE, you'll be no stranger to Browser  & Document Mode in Internet Explorer These options are available with IE Developer Tools (F12 keyboard shortcut). In IE9, these modes let you emulate older versions of IE8 & IE7. Microsoft provides these modes so that websites that were built to target IE7 & lower versions don't fail hopelessly in the newer & more standards-based versions. IE provides a fallback in the form of the Compatibility View button which allows content designed for older web browsers to render well in newer versions of Internet Explorer 9.  Here are the differences between Browser Mode & Document Mode - Browser Mode determines the User Agent sent to the server & the Document Mode IE defaults to. Document Mode determines the layout (rendering engine) and the JavaScript engine. Document

HOW TO find what movies two film personalities have in common

Image
1) Use this special Search page on IMDb to find information about common cast/crew between two titles or two people who have worked together See what movies A R Rahman & Mani Ratnam have worked on ( Source: How do I query IMDb for movies that two actors have in common? ) 2) WolframAlpha can find movies two actors were in, if you try a query like this - movies with adam sandler and drew barrymore Also see: Does IMDb provide an API?

Google institutes MVP/GDE award to recognize developer community contributions

Possibly inspired by Microsoft's MVP award, Google has started a Google Developers Expert (GDE) program "that recognizes and rewards outstanding developers". There are lots of similarities to Microsoft's MVP award - the GDE award too is annual, it provides awardees access to Product teams & developer releases, and an invitation to an annual summit at Google headquarters (MS has it in Seattle/Redmond). There is similarly even a member directory & a badge for winners. There is no mention of any material rewards though. Microsoft gifts MVP awardees an MSDN/Technet Subscription & other goodies now & then. The GDE awards will be given out in the areas of Android, Cloud, HTML5, Chrome, and Google Maps to experts who contribute to the developer community. Also see: MS MVP Authors from India

HOW TO work with a JSON/JSONP feed locally

When you're working with a JSONP feed  like the one returned by Twitter Search API or Google News, the different results that show up each time may distract you from the functionality that you're building. You can instead work with a copy of the JSON resultset locally and hook up the code to the actual JSONP feed when you're done. A JSONP feed is just JSON-formatted response wrapped in a function call. You can grab the JSONP content generated by an API by going to the Network Tab within Developer Tools (F12 keyboard shortcut) of Chrome or IE or Firebug within Firefox. When a JSONP feed is called through jQuery, it will look something like this - jQuery17109422175763174891_1337695981767({ json }) To work with the dynamically generated JSON, we need the content within the brackets - { json } Save that content within a text file & give it some name & a ".js" extension. To use the JSON content locally, specify the file name as the first parameter to

Building a dynamic jQuery Selector for an element whose ID contains braces

For doing some table formatting through jQuery on a table generated dynamically by Sharepoint 2010 in a Web Part, I tried to pick the ID of a table so that I could use it as a selector. I needed to conditionally highlight a cell in each row of a table based on the value of an adjacent cell in the same row. The problem was, a typical ID value of a table dynamically generated by Sharepoint 2010 for a Web Part looks like this - {8CC7EF38-31D8-4786-8C20-7E6D56E49AE2}-{E60CE5E2-6E64-4350-A884-654B72DA5A53} Going by the rules, the value of an ID attribute can be only be alpha-numeric & include the underscore and hyphen character . To simulate the Sharepoint 2010 requirement, I wrote some sample code that has a table with 2 columns and enclosed the ID of a dummy table within braces - {myTable}  ...and "escaped" the brace character - \{myTable\}   ...using the following regular expression to get at the rows - var regex = /[}{]+/g; var rows = '#' + tableid.

NOBR - a non-standard HTML tag that all browsers support

I ran into a NOBR tag within the code generated by Sharepoint 2010. That didn't look like a standard HTML tag and I was able to confirm that by looking up my favorite HTML Reference - W3Schools   Here's what the SitePoint Reference says - The nobr element is a proprietary (as it is not based on any standard) one that was used to define sections of text that the browser should not allow to wrap, regardless of what may happen, for example the user resizing the window to a small viewport. As it is deprecated - and the effects can be achieved using CSS - you should not use the element; this is here for reference only.  The nobr element has good support in modern browsers (for backwards-compatibility reasons) but should not be used.  rel="nofollow" is a non-standard attribute-value that popular browsers support for the sake of search engines.

HOW TO convert HTML content to plain text - with Excel!

There may be times when you need to extract just the text from a glob of HTML copied from the source as the content couldn't be copied or the text on the web page was hidden. Recently, I wanted to get the subtitles of a YouTube video, but it wasn't easy to copy it from the transcript. I couldn't also locate the timedtext file that contains the subtitles so I had to point at the Transcript block using Developer Tools (F12 keyboard shortcut) and get the HTML. Here's the trick I tried - Now that I had the text in HTML format, I copied it to Excel, selected Ctrl+H to invoke the Replace dialog box and in the Find What textbox I typed <*> and hit the Replace All button after leaving the Replace With textbox blank. That removed all the tags alongwith its attributes and left just the text. Also see - HOW TO strip HTML tags and show just web page text programmatically and with EditPlus

Websites that track traffic in Indian cities

Image
Although currently not very accurate, there are websites that track traffic in Indian cities - * (7/Sept/2012 Update) Google Maps Live Traffic -  Google Maps has started offering live traffic information for major roads in six large Indian cities and their surrounding suburbs: Bengaluru, Mumbai, New Delhi, Chennai, Pune and Hyderabad. The Google Maps feature of showing “typical” traffic conditions for a particular day and time, based on historical data is interesting. The live traffic info does not currently appear to be accurate. I've been following their map along the route I take & though Google Maps shows there is congestion (represented in red) the road has been unusually traffic free. In comparison, MapMyIndia does a better job - *  Traffic.MapMyIndia.com  - Currently shows traffic conditions in Delhi, Mumbai & Bangalore MapMyIndia uses information gathered from vehicle tracking systems that it has deployed with call centres as an enterprise solution,

Web Apps Watch - 2

Image
* Hotmail single user code - Many services now use your phone number to send passcodes through text messages for additional authentication. Hotmail provides a disposable single-use code when you're browsing from a public internet connection.  Wonder if this feature will come to Live Connect  (the new name for Microsoft's single sign-on Passport Authentication technique)?  *   Google Search miscalculates - If a Google Search result points to a question on a discussion Forum, it may display the number of answers. The way it tries to guess may be faulty. The StackOverflow question link referenced in the result (shown in image above) has just one answer & four comments but Google counts it as 5 answers *   WebRTC can enable video chat without browser plugins -  Google's open sourced technology for real time communications, WebRTC , MAY be used on Google Hangout and Skype on the browser  in the future. WebRTC will allow developers to create voice and video c

NLPCaptcha - yet another CAPTCHA implementation

Image
I don't like CAPTCHAs. CAPTCHA or Completely Automated Public Turing Test To Tell Computers and Humans Apart, is a technique to to stop bots from signing up for online accounts or automatically filling up forms. I think they are time-wasters and they seem to be a complex way to fight spam. I don't bother filling any form that has a CAPTCHA unless there is a strong motivation or incentive. There are even automated ways to break a CAPTCHA, like the Firefox add-on called Captcha Monster that completes these tests automatically (Thanks Mateusz). Google's reCaptcha ( used by even its competitor Microsoft ) cleverly adapted the traditional CAPTCHA to authenticate text in Google Books, its vast project to digitize and disseminate rare and out-of-print texts on the Internet and also to " improve data in Google Maps by having users identify things like street names and business addresses. " Google estimates say that over 200 million Captchas are filled every day and

Free APIs for HTML5 Geolocation apps, mashups

HTML5 Geolocation is now supported by newer versions of all popular browsers. Explore these free APIs to build geo-location apps & mashups - Twitter   Google Maps   Bing Maps   GeoNames  (HTTPS calls supported only for premium customers) OpenStreetMap   Foursquare   Data.gov   Data.gov.uk   Data.gov.in Wunderground Weather API   (supports HTTP & HTTPS calls) Flickr  (supports HTTP & HTTPS calls) work in progress... Also see: There is an app for that?

HOW TO read long text messages on the Samsung Omnia 652

Image
Samsung Omnia 652 clumps text messages from a single recepient together. Scrolling through a message doesn't reveal the entire message if it is long. The fix I've found is to choose Copy/Paste from the Menu & then "Select Text" (Menu > 6 > 1) The images below shows commands for Google's search service by SMS in India  that is available  through their 9773300000 mobile number - This service can even get you the PNR status of a reserved train ticket after you send an SMS with you PNR number in the specified format. Indian Railways offers a similar service through its 139 number but mobile operators charge Rs.3 for sending each message to 139. Google offers its service for free but I've lately found it to be unreliable - it returns a standard message: "Indian Railways servers are very busy. Please try after some time."  You may find the other commands useful when you are on the move.