Tuesday, 5 September 2017

How to install Sitecore Experience accelerator SXA Learning Site "ShowCase"

What is ShowCase for Sitecore Experience Accelerator.?

What Habitat is for Helix; Showcase is for Sitecore Experience Accelerator.

The showcase was originally created by Cognifide for Zen Garden - a product that later evolved into Sitecore Experience Accelerator. And is currently passionately maintained by Adam Najmanowicz

Here are the Steps in order to do Set up for Showcase.


The Latest cut of Showcase can clone or downloaded from Sitecore Showcase





In my case, I have downloaded the same @ C:\projects\Showcase\Sitecore.XA.Showcase




Launch the Visual Studio with Administrative privileges and open the Solution.

Update the showcase folder in Sitecore.XA.Project.Showcase.User.Config depending upon the location you have cloned the Git Solution as shown below.



Rebuild the Solution and Publish the solution to Root of  Sitecore Instance.In my case it was

C:\inetpub\wwwroot\sitecoresxa\Website as shown below



If all goes fine then go to your Sitecore Instance and Login as Admin.

Now goto http://<yourSitecoreinstancename>/unicorn.aspx


Sync in order to install all the Sitecore item.


If all went fine you can see a tenant called showcase and a site called int as shown below


I found some cosmetic issue while accessing in preview mode.




When connnect Sitecore SXA community over Sitecore SXA Slack  Adam replied that the current Git version is not compatible with version 4 and have provided compatible package as given below

https://1drv.ms/u/s!AmgGEEfpMIP2hqBVhOmhFoFGbVzsCg

Voila all fine as shown below




                                                  
Happy Sitecore Experience Acceleration.                        

Saturday, 2 September 2017

How to Use Login and Logout in Sitecore Experience Accelerator SXA


Open the Sitecore in experience Editor Mode and add login in the Main section while log out rendering in Header section as shown below.





Add the Associated items(Login and Logout)  under given item path as shown below.


/sitecore/content/PradeepNewtenant/myllandingpage/Data/Security




These data source items are useful in order to customise the label, Error Message and Redirection Url post successful login as shown below.

MyLogin                                                                                                                          



MyLogout                                                                                                                




Alright look like all set; let's see how its works in preview mode.  Voila, it works perfectly fine as shown below.

                                 

Isn't it too easy?                                                                                                                                  

Yes, It is very straight forward  However I am pretty much sure you must be having the similar question How to get this working with custom login provider or with federated authentications, etc.

Alright time to do deep dive to find the clue the crux is here.                                                                  


My deep love with latest crush Sitecore SXA continues  :)                                                                   

Happy Sitecore Experience Acceleration.                                                                                           

Thursday, 31 August 2017

How to use Twitter in Sitecore Experience Accelerator SXA 200th Blog

Almost 4 years back I wanted to maintain online diary where I can augment all my Sitecore learning and think of writing blogs so it helps me along with the world wide Sitecore community.

Here comes my first welcome blog  Learning Sitecore CMS Welcome Blog.

Time went like a rocket and did not realize me this current blog post is special and it's 200th blog post for Learning Sitecore CMS.

In today Session I will be covering how to use Twitter in Sitecore Experience Accelerator.

To start with first create one twitter application in Twitter Application Management 




Go to Keys and Access Token and You should be ready with below.

  • Consumer Key (API Key)
  • Consumer Secret (API Secret)
  • Access Token
  • Access Token Secret
Oh, Enough we can't wait for any further without launching Sitecore Launch Pad.



Alright lets Launch Sitecore                                                                                                                  




Open the Experience Editor Mode and add the Twitter Component.



Use existing or New associated content; In my case, I am choosing an existing component as shown below.


The item path for the existing item for me   was as below.                                                                                                                                                       /sitecore/content/PradeepNewtenant/myllandingpage/Data/Twitters/MyTwitter

The actual setting of items is as shown below.




The twitter app credentials need to be augmented @

 /sitecore/content/PradeepNewtenant/myllandingpage/Settings/Twitter Apps/Pradeep Twitter App


 
All done time to see the results.




It works as shown below.




My deep love with my latest crush is Sitecore SXA continues  :)

Happy Sitecore Experience Acceleration.

Tuesday, 29 August 2017

Fixing the Error While Installing Sitecore 8.2 Complete Set Up : The type 'System.Object' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Runtime, Version=4.0.0.0

I face one unexpected issue while installing Sitecore 8.2 using Sitecore 8.2 rev. 160729.exe

I will say unexpected because I have used the same installer in order to install the Sitecore Complete Instance at least 10 times.

The Error is as below

Compilation Error

Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS0012: The type 'System.Object' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.

Source Error:


Line 10: @model Sitecore.Mvc.Presentation.RenderingModel
Line 11: @{
Line 12:   var rendering = Html.Sitecore().Controls().
GetUserControl(Model.Rendering);
Line 13:   rendering.Class = "sc-launchpad";
Line 14:   

Source File: c:\inetpub\wwwroot\Habitat\Website\sitecore\shell\client\Applications\LaunchPad\Layouts\Renderings\LaunchBar.cshtml    Line: 12 



As the Error is clearly saying  You must add the Reference to 'System.Runtime

I copied the System.Runtime.dll from below location

C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.1\Facades

to Bin folder of Sitecore Instance; In my case it was

C:\Inetpub\wwwroot\Habitat\Website\bin






It was relaxed feeling when I saw launchpad screen back



Happy Sitecore




How to use Google Map in Sitecore Experience Accelerator









 Add a Google Map Rendering as shown below





Try to use existing or new content as per need


When we preview you get the below OOPS message.



In order to fix this issue, we need to provide Map Provider setting as shown below.



Voila, finally we got something rendered.



But life always needs more and is always demanding I want to display Dubai as location.We can update map item in order to get the desired results as shown below.


 Hurray all set I am all set now.


I am in deep love with my latest crush is Sitecore SXA. :)

Monday, 28 August 2017

How to use Image in Sitecore Experience Accelerator

Open the experience editor mode as shown below






Click in the header section of the grid as shown below.




Add an image rendering as shown below.



Select the associated content from existing content or create a new one



Click on choose an image





You can upload a new image.
From Existing media library.



Now open the site in preview mode as shown below




Voila all done




I am in deep love with my latest crush is Sitecore SXA. :)

How to get list of Users by Roles in Sitecore

Select T.RoleName ,UserName From (
SELECT RoleName,USERID
  FROM [Core].[dbo].[aspnet_UsersInRoles]
  inner join aspnet_Roles on [Core].[dbo].[aspnet_UsersInRoles].Roleid = aspnet_Roles.RoleId

 ) AS T

 inner join   [Core].[dbo].[aspnet_Users] on T.USERID  = [Core].[dbo].[aspnet_Users].USERID

  order by RoleName


Friday, 14 July 2017

How to fix the “Failed to compare two elements in the array” error while installing Sitecore Package.

This fine morning I was installing a given Sitecore Package from one environment to other. During installation, I encountered the Error “The installation failed.”.

"Failed to compare two elements in the array" As shown



























Someone has truly said life is not always easy as it was a straight forward Sitecore package installation and I was not anticipating any error.

Thanks to Sitecore logging mechanism to capture and provide detailed log information.




















Upon checking log we found error “Failed to compare two elements in the array. ---> System.ArgumentException: Could not parse the language XX. Note that a custom language name must be on the form: isoLanguageCode-isoRegionCode-customName”
As shown below.











On further investigation, I observed that a custom language has been used in provided Sitecore package. In order to fix this issue further, we need to register the custom language tool.
The Language Registration tool allows to register a language in Sitecore that doesn’t have the corresponding language in MS Windows, for example, “Eastern Scottish”, by registering a custom culture in .NET framework.


A marketplace module by Dhruva Can be used in order to register the custom language. 















Post registering custom language the Error got resolved.

Enjoy Sitecore package installation.

Pradeep Shukla
Sitecore Architect:: Digital Marketing Expert 

Wednesday, 26 April 2017

What is domain Sharding

​Domain sharding is a technique for splitting resources across multiple domains to improve page load time.


Featured post

Getting Started With SOLR

Getting Started with Solr ·           Features o    Hit highlighting o    Auto correction o    Faceted Search o    Multi lan...