Life, Surf, Code and everything in between
WebLog Posts in Category jQuery
Replacing jQuery.live() with jQuery.on()
June 12, 2013 @ 11:40am
In jQuery 1.9 and later the jQuery.live() function has finally been removed which has caused me a bit of upgrade trouble. While jQuery.live() has been deprecated for a while now since 1.7, 1.9 actually removes the function. In this post I describe how you can use the .on() function to replace existing .live() code with a little bit of extra work.
A Key Code Checker for DOM Keyboard Events
December 08, 2011 @ 3:47am
jQuery Time Entry with Time Navigation Keys
November 30, 2011 @ 2:23am
How do you display editable time values in Web applications? While date display has a pretty clear UI choice with date pickers, visual time picking isn't very efficient. In this post I show a keyboard based alternative to navigating and entering time (and date values) values using hotkeys hooked up through a jQuery plugin.
Using the West Wind Web Toolkit to set up AJAX and REST Services
November 03, 2011 @ 4:55am
Loading jQuery Consistently in a .NET Web App
October 10, 2011 @ 12:56pm
Loading jQuery into a page consistently across the lifetime of an application involves, managing versions and updating urls frequently. In this post I look at my preferred way to load jQuery and how to manage the script reference that gets embedded into the page with a single update location.
Building a jQuery Plug-in to make an HTML Table scrollable
May 28, 2011 @ 1:21pm
Table displays in limited space require some rendering alternatives. While paging is a common way to address fixed size displays, it's not an end-all solution. Sometimes it's necessary to display larger amounts of data in a small fixed space on an HTML page. Scrollable list are fairly easy to do with most HTML structures, but HTML tables are notoriously difficult to manage when it comes to scrolling. In this post I describe a jQuery plug-in that attempts to make any table scrollable by decomposing and reassembling the table into two distinct areas.
Restricting Input in HTML Textboxes to Numeric Values
April 22, 2011 @ 4:25am
There are lots of examples limiting HTML textbox input to numeric values only but most examples fail to capture valid keys like navigation and edit keys properly so as to not interfere with normal textbox behaviors. Here's a simple plug-in that takes special keys into account.
A jQuery Plug-in to monitor Html Element CSS Changes
February 22, 2011 @ 1:17am
Changing an HTML Form's Target with jQuery
January 30, 2011 @ 3:44am
A Closable jQuery Plug-in
November 29, 2010 @ 12:30pm
I've found it very useful to have a closeable plug-in that hide the content of an HTML element providing a visual close image cue. Almost every UI I build these days requires either closing pop up windows or even more commonly requires that items are removed and visually hidden which usually implies 'close' behavior. In addition to removing a bunch of HTML markup, having a plug-in is also quite useful for server controls especially if multiple behaviors (plug-ins) need to be applied.
Adding proper THEAD sections to a GridView
November 18, 2010 @ 5:12pm
ASP.NET's GridViews (and the older DataGrid) don't generate the best HTML and one of the common problems I run into is that headers aren't generated with proper thead tags. With a little jQuery script help this can be fixed easily when the page loads. Here's how.
Microsoft and jQuery
November 01, 2010 @ 1:51pm
Using jQuery to POST Form Data to an ASP.NET ASMX AJAX Web Service
September 07, 2010 @ 10:40pm
ASP.NET and WCF AJAX Web Services and PageMethods natively don't accept urlencoded POST requests and so standard mechanisms for sending form POST data don't work directly with these services. However, with a few adjustments and using jQuery's .serizalizeArray() function it's possible to POST form data to ASP.NET Services and easily consume the form data.
Non-Dom Element Event Binding with jQuery
May 27, 2010 @ 4:14pm
DevConnections jQuery Session Slides and Samples posted
April 19, 2010 @ 1:55pm
I've posted my slides and samples from the DevConnections VS 2010 Launch event last week in Vegas.
jQuery 1.4 Opacity and IE Filters
January 25, 2010 @ 12:42am
Ran into a small compatibility issue with jQuery 1.4 where the $.css("opacity") function overwrites existing IE filter settings rather than additively applying them which has caused me a few problems with some components that heavily rely on opacity as well as a couple of other IE filters.
$.fadeTo/fadeOut() operations on Table Rows in IE fail
November 09, 2009 @ 12:20am
There's a rather sneaky bug in jQuery and Internet Explorer that causes jQuery's various fade methods like fadeIn/fadeOut/fadeTo to not work with table elements in any version of IE. The fade behavior doesn't have any effect on tables, rows, headers, but luckily the end result - a removed or visible element still works. Only the fade effect seems to go missing in action.
A generic way to find ASP.NET ClientIDs with jQuery
October 15, 2009 @ 2:04am
ASP.NET ClientIDs and NamingContainer naming are a nuisance when working with jQuery as these long IDs complicate finding elements on the page. In this post I show a very simple way to retrieve munged ClientIDs by just their ID names with a small helper function that still returns the jQuery wrapped set.
Making jQuery calls to WCF/ASMX with a ServiceProxy Client
September 15, 2009 @ 8:31pm
This post revisits the WCF/ASMX ServiceProxy that can be used to make native jQuery calls to ASMX and WCF AJAX services. The component is self contained and provides JSON conversions including dates, as well as a simple class interface for simple one line service calls and consistent error trapping. This is an update that handles native JSON parsers. Includes examples and a detailed walk through on how it works.
jQuery UI Datepicker and z-Index
September 12, 2009 @ 8:12pm
The jQuery UI datepicker is a nice and easy to use datepicker control but if you're using it with other components that use absolute positioning you might run into issues with z-Index precendence. Here's a discussion of the problem and a couple of easy solutions around it.
Implementing a jQuery-Datepicker ASP.NET Control
September 10, 2009 @ 4:33pm
Updated the jQueryDatePicker control from an old version of Mark Grabansiki's jQuery calendar to the latest version of jQuery.ui. This is an easy to use wrapper around the control to make it easy to drop the control onto a page with minimal configuration fuss and provide POST back functionality on the inline behavior.
Getting and setting max zIndex with jQuery
August 31, 2009 @ 12:14am
Finding the largest zOrder is a useful feature if you are building applications that use pop up windows, use modal dialogs or otherwise allow dragging and dropping of content around a page. Here's a small jQuery plug-in that makes it easy to find the highest zOrder or assign a new higher zOrder to a jQuery selected element(s).
Speaking at the Portland Area .NET User Group on Tuesday Sept 1st
August 27, 2009 @ 9:49pm
I’ll be speaking at the PADNUG meeting next week in Portland at the Microsoft office. Rich Hubbins asked me to present on jQuery again as I did last year. A lot has changed in the last year and when I gave the last presentation jQuery was just starting to get some attention in the .NET world. By now many more people have been using jQuery for a while so this talk likely will hit a different...
On the Fly DropDown Editing with jQuery
August 24, 2009 @ 2:04am
One neat feature I've been using in HTML forms recently is to use dynamic pop up drop down lists for editing of list content. The idea is that you have plain text or link labels that when edited are turned into drop-downs for making selections from, which provides a nice interactive effect while editing document content. Here's an example that demonstrates how to dynamically create a drop down, load it up with data and display results using jQuery, MVC and the West Wind Web Toolkit.
Creating a quick and dirty jQuery contentEditable Plugin
May 25, 2009 @ 11:20pm
Inline editing content is a feature that's novel and highly useful at the same time. I've been using it in a number of admin interfaces to provide very easy and quick text updates to existing content. There are a number of ways to accomplish this but in this post I'll discuss a contentEditable jQuery plugin that makes any content inline editable using the DOM's contentEditable attribute that maintains text formatting in the editable text.
jQuery Sortable Plug-in and unwanted Clicks
May 12, 2009 @ 11:52am
The jQuery .sortable plug-in is one of the nicest jquery.ui components. It looks and feels great, is easy to use and provides a common feature for user interfaces. However I've run into an issue a few times with the .sortable behavior triggering clicks when items are dropped at the end of a sort operation. Here's how to get around this.
jQuery and ASP.NET Article Part 2 Posted
December 03, 2008 @ 2:26am
I've posted Part 2 of my jQuery with ASP.NET article series. Part 2 deals almost entirely with making AJAX callbacks to ASP.NET using several different mechanisms to retrieve data from the server for client side consumption. Covered are external content retrieval, same page callbacks, WCF/ASMX and a pluggable custom callback implementation that can be used with any application. Also covered is client side templating for managing HTML in one place.
ASP.NET Connection Session Slides and Samples Posted
November 17, 2008 @ 12:45am
I've published my session slides and samples from the Fall 2008 ASP.NET Connections conference. The sessions include: jQuery and ASP.NET, WCF REST and JSON with ASP.NET and Dealing with Long Running Requests in ASP.NET.
jQuery Intellisense Updates from Microsoft
November 09, 2008 @ 4:13pm
With Microsoft's recent releases of the jQuery Intellisense file plus the hotfix released this week using jQuery in Visual Studio has become a lot easier and more convenient. Here is a little more detail on what you need and how it works.
Using jQuery to search Content and creating custom Selector Filters
October 24, 2008 @ 12:57am
jQuery makes it easy to search content of matched elements by using the :content filter which allows for some pretty cool search effects you can implement with a couple of lines of code. Unfortunately :contains is case sensitive though, but never fear jQuery allows creation of custom filters that allow you to provide a custom case insensitive version.
Making Element Position Absolute with jQuery
October 21, 2008 @ 1:15pm
It's common for me to create DOM elements that pop up ontop of existing content by making them absolutely positioned. Here's a quick plug-in that makes an element absolute.
Client Templating with jQuery
October 13, 2008 @ 5:32pm
No Empty Selector in jQuery
October 03, 2008 @ 12:41am
One thing that bugs me about jQuery selectors is that empty or null selectors return the HTML document object, rather than an empty jQuery object. This has bitten me on a number of occasions and requires some
Introduction to jQuery Article posted
September 28, 2008 @ 2:04pm
jQuery.position() on Invisible Elements fails
September 20, 2008 @ 4:02am
Ran into a little issue today with jQuery.position() failing when elements are not visible. Apparently when elements are hidden jQuery is unable to retrieve the computed styles necessary to get the positioning information and bombs. Making the element visible first fixes the problem.
jQuery CSS Property Monitoring Plug-in updated
September 12, 2008 @ 3:30am
I've revisited a jQuery plug-in that can be used to monitor changes in CSS properties and be notified when a specific property changes providing an Observer style callback. This can be a handy feature when building behavior components that attach functionality to other elements and need to keep these behaviors in sync with the original object. This update utilizes a more efficient approach and allows monitoring many properties at once.
jQuery Form Serialization without ASP.NET ViewState
September 04, 2008 @ 2:31am
When building AJAX applications that send client form content to the server, ViewState and EventValidation fields can get in the way. Using jQuery you can make short work skipping over these fields and send only the raw POST data to the server.
A simple jQuery Client Centering Plugin
August 21, 2008 @ 9:30am
Centering content is a useful client side UI feature especially when working with pop ups or popup windows when displayed for the first time. Here's a little jQuery plug in that handles centering in the window and in other container elements easily.
jQuery with ASP.NET Presentation at Portland .NET User Group on Tuesday
August 01, 2008 @ 8:42am
July 07, 2008 @ 4:05am
Updated jQuery and WCF 3.5 JSON Samples posted
June 25, 2008 @ 5:58am
I've updated my slides and samples for last spring's Devconnection's sessions to reflect some of the recent updates in jQuery and jQuery.ui, which now have been updated to release versions. In addition there have been a few bug fixes and better configuration documentation for the samples.
Crashing WCF 3.5 JSON Services with DateTime.MinValue
June 23, 2008 @ 5:53am
Ran into some odd issues with WCF 3.5 and HTTP JSON services hanging up an ASP.NET application. It appears that there are a couple of problems with null serialization and small date value serialization that are causing this problem.
A jQuery Client Status Bar
June 13, 2008 @ 2:29am
Status bars are very useful in client applications to display well status information and having a reusable and easily callable and configured status component to display messages is extremely handy. Here's an implementation that uses jQuery plus a bit of CSS to make short work of displaying status content.
jQuery Code Magazine Editorial Posted
June 09, 2008 @ 4:45pm
My jQuery editorial for the Code Magazine Newsletter went live today. It turned into a rather lengthy affair (what else is new?) even though it's a high level editorial and so doesn't show code. The piece discusses jQuery's functionality, benefits and some considerations for ASP.NET integration, but keep in mind that this is an editorial discussion rather than a 'how to article' (which will...
jQuery Books Review
May 27, 2008 @ 2:10am
Here's a review of three jQuery books I've read over the last few months.
jQuery puts the fun back into Client Scripting
May 10, 2008 @ 3:18am
April 28, 2008 @ 12:59am
Sortable lists are a common thing to work on and jQuery.ui's Sortable plug in makes it super easy to create very nice looking sortable lists that work consistently even in complex layouts.
jQuery AJAX calls to a WCF REST Service
April 21, 2008 @ 12:52pm
Here's an overview of how to call WCF REST services with jQuery. The basic process is very easy, but if you want to handle the formats that Microsoft sends down reliably, you have to make some format choices and deal with JSON encoding and decoding that is not native to jQuery.
Client Side Templating with jQuery
April 03, 2008 @ 4:22am
When building AJAX applications there's often the requirement to choose between client and server side rendering. Server side ASP.NET controls provide rich templating, but updating those controls on the client can be difficult. Or is it? Here's one approach using jQuery and HTML templates in markup script to dynamically create complex layout on the client without writing reams of script code.
jQuery Intellisense in Visual Studio
February 11, 2008 @ 12:51am
Getting jQuery to work with Intellisense in Visual Studio is now possible after Microsoft updated script parsing code in a recent hotfix. Although there are improvements in basic parsing and some Intellisense is supported, by making some very minor comment changes to jQuery.js can improve Intellisense support drastically.
Creating an In-Place Editing Component for Table Editing with jQuery
January 28, 2008 @ 5:02am
Here's a jQuery based implementation of an Editable extender that makes any simple text element editable. You can apply it against simple tags or entire tables or grids and make them editable. Callbacks fire when data changes and there are host of useful features like editing anchor text, limited keyboard navigation, visual change indication and more...
JSON and Date Embedding
December 24, 2007 @ 7:35am
I'm a bit mystified by various JSON implementations out there that don't seem to be dealing with dates correctly. I've been using Douglas Crockford's JSON implementation from JSON.org and originally I had to fix up the date processing so that it would work on both ends for serializing and...
Updated jQuery Calendar to jQuery DatePicker
December 21, 2007 @ 3:14pm
A couple of months ago I posted an ASP.NET wrapper around Marc Garbanski's Calendar control. Just so was my luck that a couple of weeks after I created the control Marc rev'd the jQuery control, renamed it and basically overhauled the control for it's inclusion as part of the jQuery UI suite....
Charts for HTML
December 07, 2007 @ 5:03pm
It must be my lucky day. Earlier today I decided I needed to replace some old graphics code based on a now defunct tool. As I was browsing through my feeds today I noticed two cool things that relate: Google Chart API Basic charting, but dirt simple - the way it should be. I replaced my three...
October 26, 2007 @ 5:26pm
Implementing a jQuery-Calendar ASP.NET Control
October 08, 2007 @ 1:52pm
I've posted a wrapper ASP.NET around the jQuery-calendar control from Marc Garbanski. This small client side calendar control is compact, looks nice and is very easy to use and I've added an ASP.NET wrapper around it so it can more easily be more easily used with ASP.NET applications by dragging and dropping onto a form and supporting postbacks of the SelectedDate.
December, 2013 (1)
November, 2013 (5)
October, 2013 (4)
September, 2013 (3)
August, 2013 (2)
July, 2013 (3)
June, 2013 (4)
May, 2013 (2)
April, 2013 (5)
March, 2013 (4)
February, 2013 (2)
December, 2012 (2)
November, 2012 (7)
October, 2012 (3)
September, 2012 (3)
August, 2012 (5)
July, 2012 (1)
June, 2012 (1)
May, 2012 (4)
April, 2012 (8)
March, 2012 (7)
February, 2012 (3)
January, 2012 (4)
December, 2011 (6)
Visual Studio (37)
Web Services (17)
Web Api (15)
Microsoft AJAX (8)
Sql Server (7)
Web Connection (7)
West Wind Ajax Toolkit (7)
Live Writer (5)
Html Help Builder (5)
Visual Studio (4)
Source Control (4)
Software Development (3)
Entity Framework (3)
Help Builder (3)
Internet Explorer (2)
Web Deployment Projects (1)
Web Design (1)
Dynamic Types (1)
Control Development (1)
© Rick Strahl, West Wind Technologies, 2005 - 2013