Monday, November 26, 2018

Setup Visual Studio Project For Sitecore


Visual Studio solution for Sitecore 9

 

1.      Create a new a new web project,

 

 

 

 

Enter the Name

Location

Solution name

 

 

2.      Select ‘Empty’ ASP.NET Template

Click on ‘MVC’ Check box

Click on OK

 

 

3.      Delete the Global.asax file

Delete the Web.Config file

 

4.      Go to your Sitecore IIS Project. Follow this link https://sitecore4u.blogspot.com/2018/09/sitecore-9-update-2-installation.html, if you are not having Sitecore project in IIS.

 

 

 

Copy Global.asax, Web.Config files and paste in your Visual Studio Project.

 

 

 

5.      Add Nuget package solution for sitecore

 

 

 

 

NuGet V3 feed URL (Visual Studio 2015+)

https://sitecore.myget.org/F/sc-packages/api/v3/index.js

 

6.      Tools -> NuGet Package Manager -> Manage NuGet Packages for Solutions

 

Sitecore.Kernel

Sitecore.Mvc

Sitecore.Mvc.Analytics

 

Click Install

 

7.      Now your project is ready.

 

To set up the publishing deployment, in the Create Publish Settings dropdown in the Visual Studio toolbar, select <New Custom Profile>

In the Publish Web dialog, in the Publish method field, click File System, and in the Target location field, browse to the Website folder of your Sitecore instance, and then click Publish.

 

 


Installing Sitecore eCommerce

                             Installing Sitecore eCommerce

PREREQUISITES:

1.      Download and Install .NET Core 2.1.4 from the below link.

2.      Download and Install .NET Core Windows Server Hosting 2.0.0 from the below link.

3.      Download(Just Download Don’t Install) Sitecore PowerShell Extensions 4.7.2 from the below link




4.      Download(Just Download Don’t Install) Sitecore Experience Accelerator 1.7.1 from the below link

5.      Download(Just Download Don’t Install) the Sitecore XC Update 2 release package from the below link

6.      Create Folders
c:\Sitecore\Deploy
c:\Sitecore\Deploy\assets

7.      Copy
Sitecore PowerShell Extensions 4.7.2
Sitecore Experience Accelerator 1.7.1
To
c:\Sitecore\Deploy\assets

8.       
8.1   Copy
Sitecore XC Update 2 ZIP file
To
c:\Sitecore\Deploy

8.2   Extract
Sitecore XC Update 2 ZIP file
To
c:\Sitecore\Deploy

8.3   Delete
“Sitecore XC Update 2” ZIP file

9.       
9.1    
Extract Below ZIP files
From c:\Sitecore\Deploy

SIF.Sitecore.Commerce.1.2.14.zip
Sitecore.Commerce.Engine.SDK.2.2.72.zip
Sitecore.BizFX.1.2.19.zip

To Same folder (c:\Sitecore\Deploy)

9.2    
      Delete Below ZIP files
From c:\Sitecore\Deploy

SIF.Sitecore.Commerce.1.2.14.zip
Sitecore.Commerce.Engine.SDK.2.2.72.zip
     Sitecore.BizFX.1.2.19.zip

10.  Download MS Build Microsoft Visual Studio Web targets from the below link

10.1             
a)      Change extension of downloaded file from “nupkg” to “zip”
b)     extract zip file
c)      open extracted folder and navigate to
msbuild.microsoft.visualstudio.web.targets.14.0.0.3 -> tools -> VSToolsPath -> Web
d)     Copy “Microsoft.Web.XmlTransform.dll” file into “c:\sitecore\deploy\assets”.

11.   
Copy file “Sitecore.Commerce.Engine.DB.dacpac” from “C:\Sitecore\deploy\Sitecore.Commerce.Engine.SDK.2.2.72” into “C:\sitecore\deploy\assets”
Unzip “C:\sitecore\deploy\Sitecore.Commerce.Engine.2.2.126.zip” into “C:\sitecore\deploy\Sitecore.Commerce.Engine.2.2.126” folder and open “C:\sitecore\deploy\Sitecore.Commerce.Engine.2.2.126\wwwroot\bootstrap\Global.json” file.
a)      Set the “Database” value under “SourceStoreSqlPolicy” to “SitecoreCommerce9_Global”
b)      Set the “Server” value under “SourceStoreSqlPolicy” to “.”
c)      Zip the folder “C:\deploy\Sitecore.Commerce.Engine.2.2.126” as “C:\deploy\Sitecore.Commerce.Engine.2.2.126.zip” file overwriting the existing file “C:\deploy\Sitecore.Commerce.Engine.2.2.126.zip”.
d)      Remove “C:\deploy\Sitecore.Commerce.Engine.2.2.126” folder afterwards

CERTIFICATE FOR SITECORE COMMERCE ENGINE CONNECT:

We create this certificate for Commerce Engine to authenticate with Sitecore XC Engine.
1.      Open PowerShell as Admin
2.      Run the following command

New-SelfSignedCertificate -certstorelocation cert:\localmachine\my -dnsname “sc902.engineconnect”

Copy and Save the Thumbprint in notepad.
3.      Export certificate by running the following command

Export-Certificate -Cert cert:\localMachine\my\{Thumbprint} -FilePath ‘C:\sitecore\deploy\assets\sc902.engineconnect.cer’

Replace {Thumbprint} with your generated Thumbprint value from above step.

INSTALLATION:

1.      Check whether you have all your necessary files placed in your deploy(c:\sitecore\deploy) folder
And assets(c:\sitecore\deploy\assets) folder

Pic 1.
Pic 2.





2.      Check your Sitecore Instance

2.1             Rebuild link databases(core, master)


2.2             Rebuild search index




2.3             Sitecore PowerShell Extensions 4.7.2


2.4             Install “Sitecore Experience Accelerator 1.7.1 rev. 180604 for 9.0” package



After Successful installation.

Go to
Sitecore Control Panel -> Indexing Manager -> Select the Below 2 Indexes and Click Rebuild





3.      Running Deploy Script

Copy the Script from this https://gitlab.com/viet.hoang/workshop/blob/master/Scripts%20for%20Sitecore%20Commerce%20902/sc9_com_install.ps1 link, Create a Powel Shell Script “Deploy-Sitecore-Commerce.ps1” file, Save it into c:\sitecore\deploy\SIF.Sitecore.Commerce.1.2.14

               Open PowerShell in Administration mode, run the script.
    

              

Thursday, October 18, 2018

Sitecore Advantages and Disadvantages


Advantages of Sitecore:
  • Web framework. Sitecore is much more than just a web content management tool, but is actually an entire web framework which allows you to create reusable site components in one repository, all of which can be selected and assembled across multiple sites
  • Cutting-edge technology. Sitecore is built upon Microsoft Net 2.0 technology, which enables it to be run cleanly in any modern browser.
    Ease of integration. Sitecore CMS has an entire layer (Sitecore Data Providers) devoted to integration with external systems for the delivery of content, and for connection with any kind of database.
  • Highly customizable - able to override most Sitecore events such as saving content, publishing content, etc
  • Highly scalable – Sitecore can run on a single server or one hundred servers. Both the CMS and the backend databases can be scaled to multiple servers as demand increases with little effort
  • Flexible – Create any type of content and relate content in various ways
  • Easy internationalization – Languages can be added at any time and are each versioned separately
  • Ease of customization. Sitecore has a highly customizable workflow engine which allows integration with third parties, and is so flexible that right out of the box, you can setup versioning, approval control, notifications, publishing, and archiving.
  • Schedule publishing of content or automatically publish content live
  • Quickly compare versions, view version history, and roll back versions
  • Create simple or complex workflows with email integration or other custom actions
  • Create content once and display it for any device
  • Intuitive end user interface. Sitecore has invested great time and effort to make its user interface easy to use and intuitive, understanding that no matter how good software is, no one will use it if it isn't understandable to users. Sitecore CMS is designed so as to have the look and feel of Microsoft Word, which virtually everyone is familiar and comfortable with.
  • Package content, templates, and layouts
  • Modular Design – Sitecore modules are available to add functionality to an existing Sitecore CMS. Sitecore offers many paid and free community modules that install seamlessly
  • Manage multiple sites or sub-sites easily within Sitecore, even providing different domain names as desired
  • Recover deleted content from the recycle bin
  • Set dates to retire old content automatically
  • Site Tools – Broken links report, HTML validation, custom validation, Spell Check
  • SEO friendly URLs and support for Vanity URLs
  • Ability to store physical assets such as images and flash in the database or on the file system
  • Wizard driven interface
  • SEO module. Included in the Sitecore Service is an SEO module that allows you to see your website as search engines will see it, so that you can adapt and optimize your search rankings to achieve your desired goals.
Disadvantages of Sitecore:
Companies that decide on the system’s unmatched personalization capabilities should be ready for the following limitations:
·       EXPENSIVE. Per user license agreement. Needs heavy customizations.
·       Less of user guides for the newly workers who haven't any idea about that.
·       High cost. As it usually happens in software development, the cost depends greatly on the company’s business specifics and requirements. However, irrespective of the case, a Sitecore-based CMS comes at a high price.
·       EXPENSIVE. Per user license agreement. Needs heavy customizations.
·       Less of user guides for the newly workers who haven't any idea about that
·       A “per user” licensing. Companies with a broad reach may consider this pricing model unsuitable as it significantly increases the overall cost.
·       CMS development requires IT expertise. Non-pro users cannot develop a full-fledged CMS out of the basic framework that Sitecore delivers, as it requires programming skills. The framework is “empty,” it does not come laden with a template that allows creating a system on its basis. That is why, to build the core that will enable further system management, companies turn to an outsourced help.
·       Cloud-related issues. Sitecore has not been as quick as its competitors in shifting to the cloud, which causes various issues. Recently, however, this vendor has begun utilizing the cloud in a fast-paced manner, which brings hope for the elimination of this issue.


Monday, September 10, 2018

sitecore 9 update 2 installation


Prerequisites
• Windows 10
• Sitecore License with xDB
• MS SQL Server 2016
• MS SQL Management Studio
• .Net Framework 4.6
• Web Deploy  - https://www.microsoft.com/en-us/download/details.aspx?id=43717
• SOLR 6.6.2 - http://archive.apache.org/dist/lucene/solr/6.6.1/solr-6.6.2.zip
• Java 8
• Non-Sucking Service Manager NSSM - https://nssm.cc/download
• Packages for XP Single (On Premises deployment) - https://dev.sitecore.net/Downloads/Sitecore_Experience_Platform/90/Sitecore_Experience_Platform_90_Update2.aspxStep by step guide

1. install the ones below if not yet
• Web Deploy
• Java 8.0
• Set the Java_Home Variable
2. create a new folder C:\Sitecore\Install
3. install SOLR 6.6.2
• copy the solr-6.6.2.zip to C:\Sitecore
• Extract the Zip
• Run Command Prompt as administrator

• Check solr working or not by using http://localhost:8983/


4. Now SOLR 6.6.2 run as a window service
• download NSSM and install it
• Extract to C:\Sitecore
• Run Command Prompt as administrator


• Check whether Solr_6.6.2 window service is running


5. set up HTTPS for SOLR 6.6.2
• download this PowerShell file solrssl.ps1 and put it into C:\Sitecore\Install\
• update the key tool path to your local path in solrssl.ps1 file



• Run Windows PowerShell as administrator


• in case if you got the error, open Windows PowerShell (run as administrator)
• Set-ExecutionPolicy -Scope CurrentUser Unrestricted

• Remove Comment from these 4 lines in solr.in.cmd file(C:\sitecore\solr-6.6.2\bin).

• Restart Solr_6.6.2 service
• open a browser, navigate to https://localhost:8983/




6. Install  Sitecore Install Framework
• Run Windows PowerShell as administrator
• use the following commands to install the latest version of SIF
1. Register-PSRepository -Name SitecoreGallery -SourceLocation https://sitecore.myget.org/F/sc-powershell/api/v2
2. Install-Module SitecoreInstallFramework
3. Install-Module SitecoreFundamentals
4. Install-Module SitecoreInstallFramework
5. Install-Module SitecoreFundamentals

7. enable Database Authentication


8. download and unzip Package for XP Single
• copy / paste Sitecore 9.0.2 rev. 180604 (OnPrem)_single.scwdp to C:\Sitecore\Install
• copy / paste Sitecore 9.0.2 rev. 180604 (OnPrem)_xp0xconnect.scwdpto C:\Sitecore\Install
• unzip XP0 Configuration files 9.0.2 rev. 180604.zip and copy / paste all files to C:\Sitecore\Install

9. copy / paste Sitecore licence file (license.xml) to C:\Sitecore\Install
10. download sc9_install.ps1 and copy / paste it to C:\Sitecore\Install, open it update below:


11. open Windows PowerShell (run as administrator)


• When the installation process completed.
navigate to http://sc9.sc/ and http://sc9.sc/sitecore/