Powered by Blogger.
Showing posts with label Ajax. Show all posts
Showing posts with label Ajax. Show all posts

Wednesday, August 18, 2010

The Total Newbie’s Guide to jQuery: Select Elements and Manipulate CSS with jQuery

This article, as well as a follow-up article coming next week, are excerpts from Chapter 2 of the new SitePoint book, jQuery: Novice to Ninja, by Earle Castledine and Craig Sharkie. You can grab the entirety of Chapter 2, as well as Chapters 1 and 7 and the complete code archive for the entire book for free here. Together, these two articles constitute an introduction to jQuery for designers who’ve only ever worked with CSS and HTML.
If you’ve been wanting to learn the basics of jQuery and start adding some dynamic interactions to your website, this is the place to start. If you’d like to follow along with the code in this article, download the sample, which includes all of the code examples from the book.

Speed Up Your Site! 8 ASP.NET Performance Tips (part 4)

How can I improve the speed of my site?
Most ASP.NET web servers perform a lot of unnecessarily repetitive work.
For example, suppose you have a page with a DataGrid bound to a table called Products. Every time a user requests the Products page, ASP.NET has to:
  1. Look up the products data in the database.

  2. Process the page.

  3. Databind the product data.

  4. Render the results to HTML.

  5. Output the results to the browser.

Tuesday, August 17, 2010

Speed Up Your Site! 8 ASP.NET Performance Tips (part 3)

How can I decrease the bandwidth that my site uses?
ASP.NET abstracts a lot of traditional web development details from the developer. Just drag and drop a few controls on a form, set some properties, write a little bit of code, and -- bam! -- you've got a functioning web site.
However, that doesn't mean the resulting HTML markup will necessarily be efficient or small. It's not unusual to see ASP.NET pages that contain more than 100 kilobytes of markup. I recommend that you keep a close eye on the HTML markup that results from your ASP.NET web pages -- to keep these file sizes in check can sometimes require additional effort, which is one reason we covered the topic of web standards in Chapter 9, ASP.NET and Web Standards.

Speed Up Your Site! 8 ASP.NET Performance Tips (part 2)

How can I decrease the size of the view state?
One convenience of ASP.NET controls is that they can preserve state across postbacks -- a topic we've covered in depth in Chapter 6, Maintaining State. This, of course, is a feature that comes at a price -- to implement it, we add a hidden field to the page to store the control settings for transmission between the client and server, but depending on the controls the page uses, the view state can sometimes become quite large.
One obvious way to reduce the size of view state is to turn it off if you don't need it. This adjustment can be performed either at the page level, or at the control level. If, for whatever reason, you can't disable the view state (for example, your page uses controls that are dependent upon the view state), there are a few other steps you can take to at least reduce its impact on your page size.

Speed Up Your Site! 8 ASP.NET Performance Tips (part 1)


Now that you've added the finishing touches to your web site and unleashed it onto the world, fame, fortune, and success will surely follow -- won't it?
Unfortunately, your web application's success can lead to something less desirable -- performance and scaling problems. On a traditional desktop application, one thousand users translate to one thousand client computers chugging away, sharing the load of running your application. The application is effectively spread among all the users' machines. When it comes to a web application, though, those same thousand users are usually serviced by a single machine -- your web server.
Success can come at a cost for web applications: a cost in bandwidth and server hardware. However, there are a few clever ways you can reduce -- and sometimes eliminate -- these problems. We'll take a look at some of the different approaches to improving the performance of an ASP.NET site in this chapter, which has been extracted from The ASP.NET 2.0 Anthology, 101 Essential Tips, Tricks & Hacks. Feel free to download this chapter -- along with three others -- for offline reference.

Adding Markers to a Map Using the Google Maps API and jQuery

The Google Maps API provides a sophisticated way for developers and webmasters to add custom interactive maps to their websites. Version 3 of the API, released in May of 2009, represents a complete overhaul of the API in response to several years worth of user feedback on the previous version.
In this tutorial we’ll cover a few of the API’s simpler features by showing you how to add a map with a set of location markers to a website. Each marker will have an associated info bubble with the name and address of the location. What’s more, we’ll be loading the location data via Ajax, so this can be used as the first step towards developing a more sophisticated map-based application.

Friday, July 23, 2010

Using PageMethods and JSON in ASP.NET AJAX

Introduction
After going through this article, you will be able to understand how to submit data to the server using ASP.NET AJAX PageMethods and get the response. At the end of the article, you will also know how to Serialize any object into JSON format and access its properties in plain JavaScript.
To describe above things, I have taken a sample web form in whichI have two textbox Forename, Surname and a Submit button. In order to show how to serialize and return the object in JSON, I have a class called Person as well that has two properties Forename and Surname.
Lets start our short journey of learning PageMethods and JSON.

Accessing Webservice by using Sys.Net.WebRequest

Introduction
Let us understand what is Sys.Net.WebRequest. WebRequest is the abstract base class for the .NET Framework's request/response model for accessing data from the Internet. An application that uses the request/response model can request data from the Internet in a protocol-agnostic manner, in which the application works with instances of the WebRequest class while protocol-specific descendant classes carry out the details of the request.

Requests are sent from an application to a particular URI, such as a Web page on a server. The URI determines the proper descendant class to create from a list of WebRequest descendants registered for the application. WebRequest descendants are typically registered to handle a specific protocol, such as HTTP or FTP, but can be registered to handle a request to a specific server or path on a server.

WebRequest Class throws an exception when error occurs. The Status is the property of WebExceptionStatus.

jQuery and ASP.NET AJAX UpdatePanel

Introduction
jQuery being common and mostly used these days, usually we come across scenario in which we have to use jQuery for those HTML elements that are placed under the ASP.NET AJAX UpdatePanel. This works fine unless partial postback is done, but in case of postback, we loose the style or behavior of these html elements. This article describes different ways of solving this problem.
Solution - jQuery with UpdatePanel
To explain the solution of above problem, I have taken a simple example of placing GridView that has paging enabled and have placed it inside UpdatePanel and I am trying to click different pages of the GridView to do partial postback and get that page records.

How to use UpdateProgress Control ASP.NET Ajax


Introduction 

Every user that uses any type of Application  needs to know for sure that something is happening every time a button is Clicked, every time a page load, and every take an action has been taken. It is a responsibility of a software developer to put press indicator where needed so that the user can know that in the background something is happening. In this Article I am going to demonstrate to you, on how to use an Updateprogress Control from our Ajax toolbox section.

Background 

 In this Article I am going explain how to create your own date picker with the Controls you have on your Visual Studio tool.

Thursday, July 15, 2010

ASP.NET Client Side TextBox Validation

Like most programming tasks, client validation can be as simple or as more complex .In this article I am going to explain the Client Side Texbox Number/Characters Validation with JavaScript .
ASP.NET Client Side TextBox Validation
Like most programming tasks, client validation can be as simple or as more complex . Consider Employee Payroll Form , I am having Emp name, Salary, Address ,etc.
If any user trying to enter the characters into salary (Textbox) mean’s, It does'nt accepts the characters and it will show alert message and if trying to enter numbers into Emp Name Field also it will raise alert messages respectively.

jQuery 1.4.1 Intellisense with Visual Studio

A few people have emailed me recently asking about the availability of a Visual Studio –vsdoc intellisense hint file for jQuery 1.4.1. 
I blogged about –vsdoc files in the past – they provide additional intellisense help information for Visual Studio, and enable you to get a richer intellisense experience with dynamic Javascript libraries.  If you are using VS 2008 SP1 you’ll want to download and install this patch in order to have VS 2008 automatically use –vsdoc files with intellisense.  VS 2010 has support for –vsdoc files built-in.

  ©Template by Dicas Blogger.

TOPO