Search This Blog

Thursday, April 7, 2016

Working With SharePoint 2013 APP - Three SharePoint 2013 App Deployment Models

What are the Three SharePoint 2013 App Deployment Models?

  • SharePoint-hosted
  • Self-Hosted
  • Automatically Provisioned Azure Web Application


SharePoint Hosted Apps:

When the app is hosted in SharePoint itself, the code is only in HTML and JavaScript and is hosted by SharePoint.A SharePoint-hosted app may provision basic resources into its app web such as HTML/CSS/JS files, site column/content type/list definitions, etc. 
Under no circumstances can server-side code run within a SharePoint-hosted app.

In the SharePoint-hosted deployment type model, a new isolated subweb known as app web is created under the parent site called the host web,for hosting app. The app web keeps all the app content such as lists, workflows, pages, out-of-webparts and so on. 
The app code runs in the client browser which can use only HTML and JavaScript with CSOM / REST API and not any server side code.

Provider Host Apps:

In a provider-hosted app, you are responsible for the infrastructure (again, external to SharePoint) where your app runs. You have lots of flexibility in the sense that you can run full-blown server side code and even take advantage of frameworks like ASP.NET MVC 
(or even use Java, PHP, or other non-Microsoft technologies as well), but you are also responsible for things like tenant isolation.



You or your app purchaser’s IT department must host a provider-hosted app on a dedicated server or third-party hosting service. Depending on your choice, these apps run either on your server or in the cloud. A provider-hosted app can also include SharePoint components that run in SharePoint, so it can be mixed in its hosting

The Provider-hosted deployment model is almost same as Auto-hosted model, the only difference is that the app code resides in an external domain or server i.e. your own hosting environment which may not be necessarily be windows-based. The app code can be written in any programming language and technology like PHP, .NET or Java. 
In this scenario, SharePoint acts only as launching pad for the external app. 

Auto-Hosted App:

In this cloud model, though the app is developed for SharePoint but the app code resides outside of the SharePoint on Microsoft Windows Azure in the background, 
which can also have access to Microsoft SQL Azure database for managing data. The app is automatically deployed to Windows Azure and SharePoint creates a cloud-hosted app on your behalf. Auto-hosted model is supported on SharePoint Online only unlike the other deployment models.



Working With SharePoint 2013 APP - Introduction

Apps for SharePoint or SharePoint Add-ins:

First, a quick background: 

SharePoint 2010 introduced the sandboxed concept, the predecessor to SharePoint Apps, but it offered limited access for developers at the site-collection level. It had many issues and had to work under several code access security (CAS) policies. What grew out of that was the need for a new concept that would allow developers to become more productive, 
efficient and have more freedom and, thus, SharePoint Apps.

One of the important things to note is that a SharePoint App creates a sub-site of the site where the app is installed and supports creating lists, defining properties and so on.

Microsoft set out to create an extensibility point in SharePoint 2013 that would allow customers to build their own solutions for SharePoint without hurting the hosted model whenever a customer’s code was found to be ‘executionally challenged’. They came up with a model called a SharePoint App, which is simply a solution with no SharePoint server side code.

Here are some important notes to be made on SharePoint Apps when compared with farm solutions:

1. App code never runs within the SharePoint host environment.
2. Apps have two scopes: They can work within the scope of a SharePoint site, as well as with a special SharePoint site        called the App Catalog.
3. No down time is required for the whole environment when an app is being upgraded.





Default Sharepoint URL

(Remember for SharePoint 2013, 2016 you might want to add “15”, “16” respectively after “/_layouts/” but if you don’t SharePoint will take care of that for you) .. Also some of these are turned off on Office 365 SharePoint online.


Site collection level recycle bin:
      /_layouts/15/AdminRecycleBin.aspx

Site level recycle bin (Added by Steve Stewart):
      /_layouts/RecycleBin.aspx

Recreate default site sp groups (Added by Neal Bongers):
      _layouts/15/permsetup.aspx

Load document tab initial (Added by Dominik Gempeler)
      ?InitialTabId=Ribbon.Document

Delete user from Site collection (on-premises) (Added by SamDavid):
       /_layouts/15/people.aspx?MembershipGroupId=0

Display list in grid view. ‘True’ is case sensitive (Added by Antoine L.):
      ?ShowInGrid=True

Quick Launch settings page (Added by Ishani M.):
       /_layouts/quiklnch.aspx

Navigation Settings page (Added by Abdur Raheem):
        /_layouts/15/AreaNavigationSettings.aspx

Sandboxed Solution Gallery:
        /_catalogs/solutions/Forms/AllItems.aspx

Workflow history hidden list:
        /lists/Workflow History

Filter toolbar for Lists and libraries (Added by Asimaili):
?Filter=1
Site usage page (Added by @Dnyag):
       /_layouts/usage.aspx

Site content and structure  page (Added by @Dnyag):
      /_layouts/sitemanager.aspx

Site settings page (Added by Aowworld):
      /_layouts/settings.aspx

View all site content page (Site content) (Added by Aowworld):
      /_layouts/viewlsts.aspx

Manage site collection features – CASE SENSITIVE –  (Added by Vardhaman):
      /_layouts/ManageFeatures.aspx?Scope=Site

Manage site features (Added by Vardhaman):
      /_layouts/ManageFeatures.aspx

 Get the version of the SharePoint server (Patch level) (Added by: John Liu):
      /_vti_pvt/Service.cnf

Web Part Maintenance Page (Added by: Ricky):
?Contents=1

Show Page in Dialog View (Added by:Ricky):
?isdlg=1

Application page for registering SharePoint apps
     /_layouts/15/appregnew.aspx

Save Site as a template
     /_layouts/savetmpl.aspx

Sign in as a different user
     /_layouts/closeConnection.aspx?loginasanotheruser=true

Enable SharePoint designer
      /_layouts/SharePointDesignerSettings.aspx

Welcome Page (Default page settings)
      /_layouts/AreaWelcomePage.aspx

Change Site Master Page
      /_layouts/ChangeSiteMasterPage.aspx

Page Layouts and Site Templates
      /_Layouts/AreaTemplateSettings.aspx

Master Pages library
      /_catalogs/masterpage/Forms/AllItems.aspx

Quick Deploy List
Quick%20Deploy%20Items/AllItems.aspx

Open Page in Edit Mode
?ToolPaneView=2

Taxonomy Hidden List (MMS)
      Lists/TaxonomyHiddenList/AllItems.aspx

User Information List:
 _catalogs/users
_catalogs/users/simple.aspx

Force displaying the user profile in the site
collection:
      /_layouts/userdisp.aspx?id={UserID}&Force=True

Site hierarchy page (lists of sub sites) – (Added by community contributions)
     /_layouts/vsubwebs.aspx
     /_layouts/1033/vsubwebs.aspx

Restricting Custom People Picker to only one Sharepoint group programatically

Refer the following script files in your page,     <!-- For People Picker -->     <script type="text/javascript" src...