Posts

How your site appears in google search results

Image
Search engines now look deep into site contents and try to understand more about your site e.g. Google uses structure data to understand more about the content on your page. By providing structured data we not only can get the benefit of special features like rich snippets but also our site will be eligible to appear in graphic search results. By providing structured data you can outstand your site presence in the google search results and in result increase in clickthrough. While searching keyword 'eCommerce' (from the UK, 5th of May 2020) I get the following results. These are the highlights of the page Featured snippet Related Images Article Books People also searched for FAQ and the rest of the search results. Google supports structured data in the following formats  JSON-LD  (recommended, use this format whenever possible),  Microdata , and  RDFa . Google also uses  schema.org vocabulary, but for definitive, google search behaviors, r...

Add Angular component in your EPiServer site

Image
Angular is a platform and framework for building client applications in HTML and TypeScript. Angular is written in TypeScript. It implements core and optional functionality as a set of TypeScript libraries that you import into your apps. It is easy to add Angular Components in our EpiServer MVC website with the following steps. Installations Prerequisite: Install the latest version of Node JS   before proceeding. Install Angular CLI - ( npm install -g @angular/cli ) The Angular CLI is a command-line interface tool that you use to initialize, develop, scaffold, and maintain Angular applications. You can use the tool directly in a command shell, or indirectly through an interactive UI such as Angular Console. Create New Angular Component Once prerequisites are installed, open the node js command prompt and browse to your alloy/quicksilver/EPiServer site root location. Create a new Angular application by running this command  ng new firstEPiApp –...

EPiServer CMS 11 Useful SQL Queries - 2

Here is a set of few queries that we have been using in different investigations Get usages of EPiServer contents including pages and blocks Check Table size No contents have been added for following content types Looking into Activity Logs Unmapped Property List Get usages of EPiServer contents including pages and blocks SELECT   tct.Name,    tct.ModelType,    COUNT(tc.pkID) AS PageCount FROM   tblContent AS tc RIGHT OUTER JOIN   tblContentType AS tct ON tc.fkContentTypeID = tct.pkID Where tct.ModelType is not null and tct.ModelType not like 'EPiServer.%' GROUP BY   tct.Name, tct.ModelType ORDER BY  PageCount desc Check table size EXEC sp_spaceused 'tblBigTable' No contents have been added for following content types SELECT   tct.Name,    tct.ModelType FROM   tblContent AS tc RIGHT OUTER JOIN   tblContentType AS tct ON tc.fkContentTypeID = tct.pkID Where tct.ModelType is not null a...

EPiServer CMS 11 Useful SQL Queries - 1

Here is a set of few queries that we have been using in different investigations Check How Big is your Database Get Data for Each Property and from Each Content Type Complete Tree Structure of your web site Check EPiServer DB Version Check How Big is Database SELECT      t.NAME AS TableName,     s.Name AS SchemaName,     p.rows AS RowCounts,     SUM(a.total_pages) * 8 AS TotalSpaceKB,      CAST(ROUND(((SUM(a.total_pages) * 8) / 1024.00), 2) AS NUMERIC(36, 2)) AS TotalSpaceMB,     SUM(a.used_pages) * 8 AS UsedSpaceKB,      CAST(ROUND(((SUM(a.used_pages) * 8) / 1024.00), 2) AS NUMERIC(36, 2)) AS UsedSpaceMB,      (SUM(a.total_pages) - SUM(a.used_pages)) * 8 AS UnusedSpaceKB,     CAST(ROUND(((SUM(a.total_pages) - SUM(a.used_pages)) * 8) / 1024.00, 2) AS NUMERIC(36, 2)) AS UnusedSpaceMB FROM      sys.tables t INNER JOIN       ...

Get Specific Elements Blocks from EPiServer Forms

A small extension to get the specific form elements block with all properties rather relying on   FriendlyNameInfo  with the limited set of properties. EPi Form Extensions Gist Example: Custom form element block: public   class   HiddenExternalValueElementBlock  :  HiddenElementBlockBase {     [ Display (Name =  "Enable if its a special campaign" )]      public   virtual   bool  MySpecialCampaign {  get ;  set ; }     [ Display (Name =  "Propperty 1" )]      public   virtual   bool  Property1 {  get ;  set ; }     [ Display (Name =  "Property 2" )]      public   virtual   bool  Property2 {  get ;  set ; } } Extension Methods: using  EPiServer.Core; using  EPiServer.F...

Azure based architecture for serving EPiServer CMS As Content Hub

Image
This architecture uses the Azure API Management to provide access to content from EPiServer for different channels. Contents are exposed via headless API and other Custom written APIs. Editors and admins will have secure access to EPIServer CMS. API Management is used to publish APIs to external, partner and channels, securely and at scale. Application Insights is used to detect issues, diagnose crashes and track usages. AAD - Azure Active Directory is used for secure, enterprise-grade authentication. Traffic Manager is used to determining which web app is geographically best placed to handle each request, and will be used to obtain zero downtime.  A CDN - content delivery network serves static content, such as images, script, and CSS for different channels. Azure SQL DB/Redis Cache/Azure Blob Storage to server data about the site in a high performance and highly scalable way References: Episerver headless white paper Cont...

Serialize IContent to use in Angular like front technologies

(A self note) A generic service to convert IContent into an Expando Object , ExpandoObject  can be converted into JSON to use in Angular/React components. Find the code gist  https://gist.github.com/khurramkhang/e8d4b9ef093fe30610be986efa352744 Limitations: not supporting multilingual not preparing friendly urls