ASP.NET + jQuery Web Forms

So, I have been programming ASP.NET MVC for a long time with jQuery and am very comfortable working with the DOM for AJAX and programming interactivity.

However, I recently started a new job that uses ASP.NET Web Forms, and I was wondering if there was any way to rely on using jquery for all of my AJAX and DOM manipulations, rather than using POST calls.

I would love to use ASP.NET MVC, but I was hoping to find a good middle ground. I want to have jQuery, plugins, and my own client code to handle DOM manipulations after the page loads.

I thought I could use simple controls, such as repeaters, to write out my HTML. I guess I want to avoid all the bloated code that adds the web form engine and use an unobtrusive approach to more conveniently share the interface with the back server.

Hope my question makes sense.

Thanks!

+4
source share
4 answers

Joe Stagner, who made a lot of training videos about Ajax Control Tookit, started an ambitious project on his blog to replace the features of the JQuery Alternatives Toolkit for ASP.NET Web Form Projects:

I will be making jQuery alternatives for ALL of my control Ajax and Ajax Microsoft video tools.

I think the first message he made about this project is:

http://www.misfitgeek.com/asp-net-rounded-corners-jquery/

All the other blogs that he posted at the same time are probably easiest to find under his tag "act" or "jquery" (they will probably overlap):

http://www.misfitgeek.com/tag/act/

http://www.misfitgeek.com/category/jquery/

Edit

(Links are tied to a new domain.)

Update: Joe Stagner no longer works at Microsoft. The project mentioned above is only a fragment and is likely to never be completed.

+2
source

We use web forms , where I work, and in the end I use ALOT from web methods . I followed this method, and everything worked out very well.

http://encosia.com/2008/05/29/using-jquery-to-directly-call-aspnet-ajax-page-methods/

Basically, you can call the web method from a jQuery ajax call like this

 url: "PageName.aspx/MethodName" 

He got rid of the need to use a ton of updatepanels and without the need for postbacks .

+1
source

You can certainly use jQuery with ASP.Net. One thing I noticed is that if you use Updatepanels as well as jQuery, everything could come across. Like in jQuery Dialog . If this failed, I found this link useful when I started with jQuery in web forms.

+1
source

You can use jQuery to create Ajax (using static page methods or web services) and DOM manipulations.

But I don’t think that you can completely avoid publishing, as the web form data is sent to the server.

0
source

Source: https://habr.com/ru/post/1345263/


All Articles