SlideShare a Scribd company logo
2
Most read
3
Most read
4
Most read
Name: Toushik Paul , ID : 143-15-4497
Subject: Web Engineering
Submitted to: Dewan Ziaul Karim
Daffodil International University
ASSIGNMENT
What is Framework?
The word FRAMEWORK is thecombination of two words, i.e., FRAME and WORK. It means, one FRAMEhas already been
designed and developer has to WORK on that FRAMEto meet his/her project requirements. It’s just a tool, which helps a
developer to code better and faster.
In computer language, a Framework is a universal, reusable softwareplatformto develop softwareapplications, products and
solutions. In other words, we can say it is some kind of library, a piece of software, which provides web developers with code
base and consistent standardized ways of creating web applications.
Back when PHP and other technology started, developers were writing their own customcode for each functionality. Later, some
peoplerealized that, writing thesame code every time, in every page, not reusing it extensively, plain PHP is not so effective.
Afterwards, as the PHP object model developed (especially with thelaunch of PHP 5), framework development really came into
action and became so popular.
So, let’s check what are the key benefits of using a Framework, especially in PHP.
 Organizing Code and File
 The MVC Pattern
 Enforcing of Good Coding Standards
 Utilities and Libraries
 Less Code & Faster Development
 Security
 Performance Tools
 Simplified and Pretty URLs
 Efficiently Access Database
WhatisMVC framework?
The Model-View-Controller(MVC) is an architectural pattern that separates an application into three main logical components:
the model, the view, and the controller. Each of these components are built to handle specific development aspects of an
application. MVC is one of the most frequently used industry-standard web development framework to create scalable and
extensible projects.
MVCComponents
Following are the components of MVC −
Model
The Modelcomponent corresponds to all the data-related logic that the user works with. This can represent either the data that is
being transferred between theView and Controller components or any other business logic-related data. For example, a Customer
object will retrieve the customer information from the database, manipulate it and updateit data back to the database or use it to
render data.
View
The View component is used for all the UI logic of the application. For example, the Customer view will include all the UI
components such as text boxes, dropdowns, etc. that the final user interacts with.
Controller
Controllers act as an interface between Model and View components to process all the business logic and incoming requests,
manipulate data using the Model component and interact with the Views to render the final output. For example, the Customer
controller will handle all theinteractions and inputs fromthe Customer View and updatethe database using theCustomer Model.
The same controller will be used to view the Customer data.
ASP.NETMVC
ASP.NET supports three major development models: Web Pages, Web Forms and MVC (Model View Controller). ASP.NET
MVC framework is a lightweight, highly testable presentation framework that is integrated with the existing ASP.NET features,
such as master pages, authentication, etc. Within .NET, this framework is defined in the System.Web.Mvcassembly. The latest
version of the MVC Framework is 5.0. We use Visual Studio to create ASP.NET MVC applications which can be added as a
template in Visual Studio.
ASP.NET MVC Features
ASP.NET MVC provides the following features −
 Ideal for developing complex but lightweight applications.
 Provides an extensible and pluggable framework, which can be easily replaced and customized. For example, if you do
not wish to use the in-built Razor or ASPX View Engine, then you can use any other third-party view engines or even
customize the existing ones.
 Utilizes the component-based design of the application by logically dividing it into Model, View, and Controller
components. This enables the developers to manage the complexity of large-scale projects and work on individual
components.
 MVC structureenhances the test-driven development and testability of the application, since all the components can be
designed interface-based and tested using mock objects. Hence, ASP.NET MVC Framework is ideal for projects with
large team of web developers.
 Supports all the existing vast ASP.NET functionalities, such as Authorization and Authentication, Master Pages, Data
Binding, User Controls, Memberships, ASP.NET Routing, etc.
ASP.NetFramework:MVC, Web Api , Entity Framework ,Web Forms ,Empty Forms etc.
Example application using one of framework: In here we are using MVC and Entity Framework and
build and run this sample as-is, you must have Visual Studio 2013 or Visual Studio 2013 Express for Web installed. If you have
Visual Studio 2015, change theconnection string in theWeb.config file so that the SQL Server instance name is
MSSQLLocalDB instead of v11.0.
In most cases you can run the application by following these steps:
1. Download and extract the .zip file.
2. Open the solution file in Visual Studio.
3. Build thesolution, which automatically installs themissing NuGet packages.
4. Open the Package Manager Console, and run the update-databasecommand to create the database.
5. Run the application.
If you have any problems with thoseinstructions, follow theselonger instructions.
1. Download the .zip file.
2. In File Explorer, right-click the.zip file and click Properties, then in the Properties window click Unblock.
3. Unzip thefile.
4. Double-click the.sln file to launch Visual Studio.
5. From the Tools menu, click Library Package Manager, then Package Manager Console.
6. In the Package Manager Console (PMC), click Restore.
7. Each migration will run, then the seed method will run. You can now run theapplication.
Running the Sample
To run the sample, hit F5 or choose the Debug | Start Debugging menu command. You will see the home page which
includes a menu bar. (In a narrow browser window you'll have to click the symbol at the top right of the page in order
to see the menu).From this page you can select any of the tabs to perform various actions such as display a list of
students, add new students, display a list of instructors, and so forth.
Screenshots:
MVCsourceCode:
Conroller:
using System;
using System.Collections.Generic;
using System.Data.Entity;
using System.Data.Entity.Migrations;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
using practice_Much.Models;
using Practice2.Models;
namespace practice_Much.Controllers
{
public class RestauarantManagementController : ApiController
{
public ApplicationDbContext _Context;
private object foodItem;
public RestauarantManagementController()
{
_Context = new ApplicationDbContext();
}
[HttpGet]
[Route("api/Menu")]
public SetMenuVIewModel SetMenuVIewModel()
{
///var foodItem = _Context.FoodItems.GroupBy(p => p).ToDictionary(p => p.
Key.Name, p => p.ToList());
var setMenu = _Context.SetMenus.Include(a => a.SetMenuItem).ToList();
var menu = new SetMenuVIewModel() { SetMenus = setMenu, FoodCategories =
foodItem };
return menu;
}
}
}
Route Directory:
Model: using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace Practice2.Models
{
public class SetMenuItem
{
public int Id { get; set; }
public SetMenu SetMenu{ get; set; }
public int SetMenuId { get; set; }
public FoodItem FoodItem { get; set; }
public int FoodItemId { get; set; }
public int Quantity { get; set; }
}
}
Reference
http://www.phpandstuff.com/articles/top-10-reasons-why-you-should-use-a-php-framework
http://code.tutsplus.com/tutorials/10-compelling-reasons-to-use-zend-framework--net-12214
https://code.msdn.microsoft.com/ASPNET-MVC-Application-b01a9fe8

More Related Content

PDF
PDF
MVC Seminar Presantation
ODP
What is MVC?
PPTX
Model view controller (mvc)
PPT
Ppt of Basic MVC Structure
PPTX
Introduction to mvc architecture
PPT
Why MVC?
PPTX
No brainer
MVC Seminar Presantation
What is MVC?
Model view controller (mvc)
Ppt of Basic MVC Structure
Introduction to mvc architecture
Why MVC?
No brainer

What's hot (20)

PPTX
MVC for Desktop Application - Part 2
PPTX
MVC for Desktop Application - Part 3
PPTX
MVC for Desktop Application - Part 1
PPTX
MVC for Desktop Application - Part 4
PPT
MVC(Model View Controller),Web,Enterprise,Mobile
PDF
Introduction to Angular Js
PDF
ASP.NET MVC Introduction
PPTX
7 must have word press plugins for web developers
PDF
Basics of asp.net mvc
PPTX
MVVM ( Model View ViewModel )
PPTX
Model View Presenter (MVP) In Aspnet
PPT
Mvc 130330091359-phpapp01
PDF
Php framework
PPTX
MVVM presentation
PPTX
An overview of microsoft mvc dot net
PPTX
Ps02 cint24 mvc in php
PDF
MVC architecture
PPTX
10 top web development frameworks (new version 21 11)
PDF
MVC for Desktop Application - Part 2
MVC for Desktop Application - Part 3
MVC for Desktop Application - Part 1
MVC for Desktop Application - Part 4
MVC(Model View Controller),Web,Enterprise,Mobile
Introduction to Angular Js
ASP.NET MVC Introduction
7 must have word press plugins for web developers
Basics of asp.net mvc
MVVM ( Model View ViewModel )
Model View Presenter (MVP) In Aspnet
Mvc 130330091359-phpapp01
Php framework
MVVM presentation
An overview of microsoft mvc dot net
Ps02 cint24 mvc in php
MVC architecture
10 top web development frameworks (new version 21 11)
Ad

Similar to A report on mvc using the information (20)

PPTX
ASP.NET Presentation
PPTX
Session 1
PDF
Aspnetmvc 1
PDF
Asp 1a-aspnetmvc
PPTX
PDF
ChircuVictor StefircaMadalin rad_aspmvc3_wcf_vs2010
PPTX
MVC Framework
PPT
Introduction to ASP.NET MVC 1.0
PPT
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
PPTX
MVC 6 Introduction
PPTX
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
PPTX
ASP.net MVC Introduction Wikilogia (nov 2014)
PPTX
Getting started with MVC 5 and Visual Studio 2013
PPTX
Introduction to ASP.Net MVC
PPT
AspMVC4 start101
PDF
Asp.net mvc basic introduction
PDF
Introduction to ASP.NET MVC
ODP
Mvc
PPTX
ASP.NET MVC Fundamental
ASP.NET Presentation
Session 1
Aspnetmvc 1
Asp 1a-aspnetmvc
ChircuVictor StefircaMadalin rad_aspmvc3_wcf_vs2010
MVC Framework
Introduction to ASP.NET MVC 1.0
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
MVC 6 Introduction
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
ASP.net MVC Introduction Wikilogia (nov 2014)
Getting started with MVC 5 and Visual Studio 2013
Introduction to ASP.Net MVC
AspMVC4 start101
Asp.net mvc basic introduction
Introduction to ASP.NET MVC
Mvc
ASP.NET MVC Fundamental
Ad

More from Toushik Paul (6)

PPTX
3D Display
PPTX
Diagnosis of lung cancer prediction system using data mining Classification T...
PDF
How to remove shortcut virus from pendrive bangla
PPTX
Http-protocol
DOCX
Gas & smoke detector Report
PPTX
Gas & smoke detector
3D Display
Diagnosis of lung cancer prediction system using data mining Classification T...
How to remove shortcut virus from pendrive bangla
Http-protocol
Gas & smoke detector Report
Gas & smoke detector

Recently uploaded (20)

PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PPTX
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PDF
Well-logging-methods_new................
PPTX
Internet of Things (IOT) - A guide to understanding
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PPTX
Sustainable Sites - Green Building Construction
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPTX
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
PPTX
Strings in CPP - Strings in C++ are sequences of characters used to store and...
PPT
Mechanical Engineering MATERIALS Selection
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
PDF
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
PPTX
Welding lecture in detail for understanding
PDF
Digital Logic Computer Design lecture notes
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PPTX
UNIT-1 - COAL BASED THERMAL POWER PLANTS
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PDF
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
Well-logging-methods_new................
Internet of Things (IOT) - A guide to understanding
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
Sustainable Sites - Green Building Construction
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
Strings in CPP - Strings in C++ are sequences of characters used to store and...
Mechanical Engineering MATERIALS Selection
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
Welding lecture in detail for understanding
Digital Logic Computer Design lecture notes
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
UNIT-1 - COAL BASED THERMAL POWER PLANTS
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf

A report on mvc using the information

  • 1. Name: Toushik Paul , ID : 143-15-4497 Subject: Web Engineering Submitted to: Dewan Ziaul Karim Daffodil International University ASSIGNMENT
  • 2. What is Framework? The word FRAMEWORK is thecombination of two words, i.e., FRAME and WORK. It means, one FRAMEhas already been designed and developer has to WORK on that FRAMEto meet his/her project requirements. It’s just a tool, which helps a developer to code better and faster. In computer language, a Framework is a universal, reusable softwareplatformto develop softwareapplications, products and solutions. In other words, we can say it is some kind of library, a piece of software, which provides web developers with code base and consistent standardized ways of creating web applications. Back when PHP and other technology started, developers were writing their own customcode for each functionality. Later, some peoplerealized that, writing thesame code every time, in every page, not reusing it extensively, plain PHP is not so effective. Afterwards, as the PHP object model developed (especially with thelaunch of PHP 5), framework development really came into action and became so popular. So, let’s check what are the key benefits of using a Framework, especially in PHP.  Organizing Code and File  The MVC Pattern  Enforcing of Good Coding Standards  Utilities and Libraries  Less Code & Faster Development  Security  Performance Tools  Simplified and Pretty URLs  Efficiently Access Database WhatisMVC framework? The Model-View-Controller(MVC) is an architectural pattern that separates an application into three main logical components: the model, the view, and the controller. Each of these components are built to handle specific development aspects of an application. MVC is one of the most frequently used industry-standard web development framework to create scalable and extensible projects. MVCComponents Following are the components of MVC − Model The Modelcomponent corresponds to all the data-related logic that the user works with. This can represent either the data that is being transferred between theView and Controller components or any other business logic-related data. For example, a Customer object will retrieve the customer information from the database, manipulate it and updateit data back to the database or use it to render data.
  • 3. View The View component is used for all the UI logic of the application. For example, the Customer view will include all the UI components such as text boxes, dropdowns, etc. that the final user interacts with. Controller Controllers act as an interface between Model and View components to process all the business logic and incoming requests, manipulate data using the Model component and interact with the Views to render the final output. For example, the Customer controller will handle all theinteractions and inputs fromthe Customer View and updatethe database using theCustomer Model. The same controller will be used to view the Customer data. ASP.NETMVC ASP.NET supports three major development models: Web Pages, Web Forms and MVC (Model View Controller). ASP.NET MVC framework is a lightweight, highly testable presentation framework that is integrated with the existing ASP.NET features, such as master pages, authentication, etc. Within .NET, this framework is defined in the System.Web.Mvcassembly. The latest version of the MVC Framework is 5.0. We use Visual Studio to create ASP.NET MVC applications which can be added as a template in Visual Studio. ASP.NET MVC Features ASP.NET MVC provides the following features −  Ideal for developing complex but lightweight applications.  Provides an extensible and pluggable framework, which can be easily replaced and customized. For example, if you do not wish to use the in-built Razor or ASPX View Engine, then you can use any other third-party view engines or even customize the existing ones.  Utilizes the component-based design of the application by logically dividing it into Model, View, and Controller components. This enables the developers to manage the complexity of large-scale projects and work on individual components.  MVC structureenhances the test-driven development and testability of the application, since all the components can be designed interface-based and tested using mock objects. Hence, ASP.NET MVC Framework is ideal for projects with large team of web developers.  Supports all the existing vast ASP.NET functionalities, such as Authorization and Authentication, Master Pages, Data Binding, User Controls, Memberships, ASP.NET Routing, etc. ASP.NetFramework:MVC, Web Api , Entity Framework ,Web Forms ,Empty Forms etc.
  • 4. Example application using one of framework: In here we are using MVC and Entity Framework and build and run this sample as-is, you must have Visual Studio 2013 or Visual Studio 2013 Express for Web installed. If you have Visual Studio 2015, change theconnection string in theWeb.config file so that the SQL Server instance name is MSSQLLocalDB instead of v11.0. In most cases you can run the application by following these steps: 1. Download and extract the .zip file. 2. Open the solution file in Visual Studio. 3. Build thesolution, which automatically installs themissing NuGet packages. 4. Open the Package Manager Console, and run the update-databasecommand to create the database. 5. Run the application. If you have any problems with thoseinstructions, follow theselonger instructions. 1. Download the .zip file. 2. In File Explorer, right-click the.zip file and click Properties, then in the Properties window click Unblock. 3. Unzip thefile. 4. Double-click the.sln file to launch Visual Studio. 5. From the Tools menu, click Library Package Manager, then Package Manager Console. 6. In the Package Manager Console (PMC), click Restore. 7. Each migration will run, then the seed method will run. You can now run theapplication. Running the Sample To run the sample, hit F5 or choose the Debug | Start Debugging menu command. You will see the home page which includes a menu bar. (In a narrow browser window you'll have to click the symbol at the top right of the page in order to see the menu).From this page you can select any of the tabs to perform various actions such as display a list of students, add new students, display a list of instructors, and so forth. Screenshots: MVCsourceCode: Conroller:
  • 5. using System; using System.Collections.Generic; using System.Data.Entity; using System.Data.Entity.Migrations; using System.Linq; using System.Net; using System.Net.Http; using System.Web.Http; using practice_Much.Models; using Practice2.Models; namespace practice_Much.Controllers { public class RestauarantManagementController : ApiController { public ApplicationDbContext _Context; private object foodItem; public RestauarantManagementController() { _Context = new ApplicationDbContext(); } [HttpGet] [Route("api/Menu")] public SetMenuVIewModel SetMenuVIewModel() { ///var foodItem = _Context.FoodItems.GroupBy(p => p).ToDictionary(p => p. Key.Name, p => p.ToList()); var setMenu = _Context.SetMenus.Include(a => a.SetMenuItem).ToList(); var menu = new SetMenuVIewModel() { SetMenus = setMenu, FoodCategories = foodItem }; return menu; } } } Route Directory: Model: using System; using System.Collections.Generic;
  • 6. using System.Linq; using System.Web; namespace Practice2.Models { public class SetMenuItem { public int Id { get; set; } public SetMenu SetMenu{ get; set; } public int SetMenuId { get; set; } public FoodItem FoodItem { get; set; } public int FoodItemId { get; set; } public int Quantity { get; set; } } } Reference http://www.phpandstuff.com/articles/top-10-reasons-why-you-should-use-a-php-framework http://code.tutsplus.com/tutorials/10-compelling-reasons-to-use-zend-framework--net-12214 https://code.msdn.microsoft.com/ASPNET-MVC-Application-b01a9fe8