background preloader

Colindavidfoster

Facebook Twitter

JavaScript to detect iPad visitors. Wednesday, October 06, 2010 This post gives you a short JavaScript function to detect your iPad users. Without any further ado, a javascript code to detect iPad users: function isiPad(){ return (navigator.platform.indexOf("iPad") ! = -1);} You can also detect browser version and some other stuff by parsing user agent string. Here is an iPad Safari’s user agent string for your reference: Mozilla/5.0 (iPad; U; CPU OS 3_2 like Mac OS X; en-us) AppleWebKit/531.21.10 (KHTML, like Gecko) Version/4.0.4 Mobile/7B334b Safari/531.21.10 Recently a friend of mine got himself an iPad and I couldn’t not notice how his internet browsing device preferences are changing (PC & iPad). Let’s see how to do this. Redirect iPad visitors Apply different CSS file for iPad users Most of the posts on the internet related to iPad user detection are suggesting and showing you how to redirect (including myself in my previous iPhone & iPod detection post).

Monitor, control and log anything over the Internet | eZE System. Free SQL database backup software for SQL Server 2008, 2005 Express. How do you backup a database using sql server 2005 express??? One option that you could use is the SMO system, Here is a small c# application that backs up a database. You will have to compile it and change the values to reflect your server. Remember that the Visual Studio C# Express system, is free to use. using System; using System.Data; using System.Collections; using Microsoft.SqlServer.Management.Common; using Microsoft.SqlServer.Management.Smo; class Program { static void Main(string[] args) { BackupDeviceItem bdi = new BackupDeviceItem("AdventureWorks.bak", DeviceType.File); Backup bu = new Backup( ); bu.Database = "AdventureWorks"; bu.Devices.Add(bdi); bu.Initialize = true; // add percent complete and complete event handlers bu.PercentComplete += new PercentCompleteEventHandler(Backup_PercentComplete); bu.Complete +=new ServerMessageEventHandler(Backup_Complete); Server server = new Server("localhost"); bu.SqlBackup(server); Console.WriteLine(Environment.NewLine + "Press any key to continue.

"); Console.ReadKey( ); } Colorful Sliders With jQuery & CSS3. Martin Angelov In this tutorial we are using jQuery and the new transformation features brought by CSS3 to create a three dimensional dynamic slider effect. The techniques presented here – for creating sliders, and CSS dynamic resizable bars, can be used together or in part for powering all sorts of jQuery goodness. Also, be sure to go ahead and download the PSD, so you can create your own colors and shapes. Step 1 – XHTML We start off with the XHTML part of the tutorial. Demo.html In the code above, you can see that we basically have only two structures, which are duplicated three times, once for every color. Inside the slider is the slide-handle div, which is converted to a draggable jQuery UI control, the movements of which are later translated to changes in the size of the bars. The second group is the one of the colorful bars.

Lastly, we have the .perspective div. Dynamic jQuery & CSS Bars Step 2 – CSS styles.css – Part 1 The Colorful Bars styles.css – Part 2 The CSS3 Transformations. Beginner ? - How do I get a JQuery Slider to respond to touch events...? - phonegap. Working with jQuery 1.3's new Event object (jQuery.Event) Thursday, January 15, 2009 To start, in jQuery 1.3 event object has been normalized and wrapped into jQuery.Event object.

As it says in the documentation: "The event object is guaranteed to be passed to the event handler (no checks for window.event required). " Here is an jQuery.Event object overview: Attributes event.type event.target event.relatedTarget event.currentTarget event.pageX/Y event.result event.timeStamp Methods event.preventDefault() event.isDefaultPrevented() event.stopPropagation() event.isPropagationStopped() event.stopImmediatePropagation() event.isImmediatePropagationStopped() Now, how to work with jQuery.Event object? Anonymous functions that were bind to your elements will receive this new (jQuery.Event) event object and can utilize it's new attributes and methods.

$("a").click(function(event) { alert(event.type); }); The fun part starts when you trigger events with jQuery.Event. Example: // Add additional data to pass e.user = "foo"; e.pass = "bar"; Martini Lab Blog — A better jQuery slider. If you haven’t seen Apple’s prod­uct slider in action, you must check it out. It’s a hor­i­zon­tal gallery of their prod­ucts with hor­i­zon­tal slider con­trolled with javascript. I believe they are using the scrip­tac­u­lous motion for this, but there should be a way to build this in jQuery. Truth be told, I was a die-​hard fanatic for scriptaculous/​prototype, but after ExpressionEngine announce their adop­tion of jQuery for EE 2.0, it was time to grow beyond the one frame­work pony. Luckily, some­one already set out to build the slider in jQuery.

And major hat’s off to Remy Sharp for a great approach to this. The Problem Actually, there was no prob­lem until I had a client to didn’t fit into the strict mold set out for this wid­get. The slider is built on an unordered list, but doesn’t sup­port nested lists. Now, this can be resolved by man­u­ally set­ting css val­ues.

Also, the slider needs to work with­out javascript. The Solution I built this out back­wards, but it works. Using jQuery with ASP.NET - A Beginner's Guide. Posted by: Suprotim Agarwal , on 11/18/2008, in Category jQuery and ASP.NET Abstract: This article is a guide for getting started with jQuery using ASP.NET and Visual Studio 2008/2010. The article also shows you how to use Visual Studio intellisense feature to develop jQuery and ASP.NET applications. Using jQuery with ASP.NET - A Beginner's Guide Did you hear about jQuery.. NO...? It’s fantastic!! Ok, the million dollar question - What is jQuery anyways?

jQuery is a fast, lightweight JavaScript library that is CSS3 compliant and supports many browsers. What is the difference between JavaScript and jQuery? JavaScript is a language whereas jQuery is a library written using JavaScript. Where can I download jQuery? The version of jQuery as of this writing is jQuery 1.2.6 and can be downloaded from here. [Update 2] Instead of downloading the jQuery files, you can also reference the files directly using a Content Delivery Network (CDN). Microsoft also provides jquery over CDN. // add code here. Standalone jQuery "touch" method. jQuery UI slider - can't slide to 0. Javascript finger and mouse swipe demo tutorial | James Lin's Blog.

Application Development

Web Development. Pearltrees videos. Help.