Solved

MVC 2 master page data

Posted on 2015-02-02
1
107 Views
Last Modified: 2015-02-03
I need to read a query string value and if it exists, change a phone number on the master page of an mvc 2 website. I'm not sure how to do this and stay within the MVC model? I've found this solution but I'm still struggling to apply this to what I need to do: http://www.asp.net/mvc/overview/older-versions-1/views/passing-data-to-view-master-pages-cs
0
Comment
Question by:robanddeanna
1 Comment
 
LVL 52

Accepted Solution

by:
Carl Tawn earned 500 total points
ID: 40585876
Which part are you having trouble with?  The article you pointed to is essentially saying to use the ViewData dictionary object to provide data for the master page.

The ViewData dictionary is essentially a dumping ground for bits of data and is available across views, so can be used to feed your master page.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
I designed this idea while studying technology in the classroom.  This is a semester long project.  Students are asked to take photographs on a specific topic which they find meaningful, it can be a place or situation such as travel or homelessness.…
This is a video that shows how the OnPage alerts system integrates into ConnectWise, how a trigger is set, how a page is sent via the trigger, and how the SENT, DELIVERED, READ & REPLIED receipts get entered into the internal tab of the ConnectWise …

919 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now