Click here to Skip to main content
15,896,063 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i have a application on asp.net mvc3 working perfectly , now i want
to make clone of that site with different name and i want put all that
information at one place so that i change on one place and it changes all
over the site like if i want to change

Site Name
Site Slogan
Site Logo
Site Logo ( Small )

how can i do this in asp.net mvc3 . Thanks in advance
Posted
Updated 9-Oct-12 20:29pm
v2

1 solution

Hi You can use web config to store custom setting, you have to load the dynamic value from webconfig only(like we are store connection string in web.config).

You can just copy and past your published version with different site name only you need change web config, make sure all images available in your application

<appsettings>
   <add key="SiteName" value="test" />
   <add key="SiteSlogan" value="test" />
   <add key="SiteLogo" value="imagepath" />
<add key="SiteLogoSmall" value="imagepath" />
</appsettings>


to read the web config value:
C#
ConfigurationSettings.AppSettings.Get("SiteName")


add reference of :
System.Configuration
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900