?
Solved

VS2012 MVC 4 total page paint after reroute to new page

Posted on 2014-03-18
2
Medium Priority
?
499 Views
Last Modified: 2014-03-19
I am very new to Asp.net MVC and still learning. I have been developing a portal type website to display database data. In development and testing on my local computer I was very enthusiastic about the fact that when re-routing to a new page (all pages use _layout as header section) that there was NOT a total page repaint. However, I have just recently published to live Website and have noticed that on each reroute to new page that it is re-painting everything including the _layout header section. Am I missing something? I thought that was one of the advantages to MVC. All of my redirections are either @html.actionlink or @url.action with appropriate "controller" and "action" calls. Again, everything works awesome in test on development computer but when live on website, I get total page re-paints. Any insight appreciated!
0
Comment
Question by:Cubbybulin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 75

Accepted Solution

by:
käµfm³d   👽 earned 2000 total points
ID: 39939652
MVC has nothing to do with whether or not your page partially or completely posts (the term "paint" isn't really used in web development...well, maybe if your talking about the Canvas object it would be). MVC is an architectural style defining how your application connects is display layer to its service layer to its data layer. What your talking about is basically encapsulated in the "V" of "MVC", but nothing about MVC commands that what you are talking about should happen.

You have to remember that when you are developing locally, there is no latency (or it is very minimal)--you are making requests on the same machine that will respond to those requests. Everything is going to be faster when you work locally. Once you deploy, you now introduce the network as a bottleneck.

Partial posts are typically accomplished through AJAX. If you want to go that route, then I would offer the following tutorials as starting points:

http://www.w3schools.com/ajax/default.ASP
http://www.w3schools.com/ajax/ajax_intro.asp
https://developer.mozilla.org/en-US/docs/AJAX/Getting_Started

You might consider working with JQuery, a Javascript framework that simplifies many mundane Javascript tasks, including AJAX calls:

http://learn.jquery.com/about-jquery/how-jquery-works/
http://www.w3schools.com/jquery/jquery_intro.asp
0
 

Author Closing Comment

by:Cubbybulin
ID: 39939781
Got it. Very good explanation. I appreciate the insight and the links to the other resources.
Thanks!
0

Featured Post

Want to be a Web Developer? Get Certified Today!

Enroll in the Certified Web Development Professional course package to learn HTML, Javascript, and PHP. Build a solid foundation to work toward your dream job!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
Australian government abolished Visa 457 earlier this April and this article describes how this decision might affect Australian IT scene and IT experts.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Progress
Suggested Courses
Course of the Month8 days, 9 hours left to enroll

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question