Ejemplo n.º 1
0
        public ActionResult Index()
        {
            var config = CodeInsideConfig.GetConfig();

            ViewBag.Url = config.WebUrl;
            ViewBag.Id  = config.Id;

            ViewBag.NumberOfAuthors = config.Authors.Count;

            return(View());
        }
Ejemplo n.º 2
0
        public ActionResult Index()
        {
            ViewData["Message"] = "Welcome to ASP.NET MVC!";
            CodeInsideConfig config = CodeInsideConfig.GetConfig();

            ViewData["webUrl"]    = config.WebUrl;
            ViewData["startedOn"] = config.StartedOn;

            string authors = "";

            foreach (CodeInsideConfigAuthor author in config.Authors)
            {
                authors += author.Name + ",";
            }

            ViewData["authors"] = authors;

            return(View());
        }