January 22, 2017

To know about Swagger API framework

You can find all details regarding Swagger API framework here

January 21, 2017

Update Package Visual Studio framework

Update framework dependencies in project.
Update-Package -Reinstall -ProjectName <Project Name>

January 20, 2017

Install Nuget Package for specific project only

Install-Package Newtonsoft.Json -Project <Your Project Name>

January 19, 2017

How to Create Chrome Extension

How to create Chrome extension 

Step 1:
Create one file named Manifest.json with below content


"manifest_version": 2,

"name": "Post",

"description": "Post",

"version": "1.0",

"content_scripts": [{

"js": ["Popup.js"],

"matches": ["http://*/*", "https://*/*"]


"icons": {

"48": "icon.png"


"content_security_policy": "script-src 'self' <Specify all external urls with spaces>; object-src 'self'",

"permissions": [

"tabs", "<all_urls>","activeTab"


"browser_action": {

"default_icon": "icon.png",

"default_popup": "popup.html"



Step 2:
Create popup.html with below content

<!DOCTYPE html>
<body style="width: 500px;height:500px;background-color:lightgray;font-family:Arial; ">
<h1>My Chrome Extension</h1>
<td style="vertical-align:top;width:2%;"></td>
<textarea id="postcontent" name="content" rows="15" cols="50" style="width:410px;"></textarea>


<script type="text/javascript" src="Popup.js"></script>



Step 3:

Create Popup.js file with below content


code: "window.getSelection().toString();"

}, function (selection) {

if (selection[0] != "")

document.getElementsByTagName('textarea')[0].innerHTML = selection[0];


chrome.tabs.query({currentWindow: true, active: true}, function(tabs){

document.getElementById('hdnUrl').value = tabs[0].url;



active: true,

currentWindow: true

}, function (tabs) {

chrome.tabs.executeScript(tabs[0].id, {

code: 'Array.prototype.map.call(document.images, function (i) { return i.src; });'

}, callback);


Now place all these files in One folder and load this folder Chrome "Load Unpacked .."

January 18, 2017

Sitecore Helix documentation and Habitat project

You can find all Sitecore Helix related information on below Url.


Sitecore Habitat project on Github



January 17, 2017

Call Custom API in Sitecore using JavaScript

Controller Logic here 
using Sitecore.Configuration;
using Sitecore.Data.Items;
using Sitecore.Mvc.Controllers;
using Sitecore.Resources.Media;
using Sitecore.SecurityModel;
using System.Web.Mvc;
public class ArticleDetailsController : SitecoreController
        public virtual ActionResult ArticleDetails()
        //Read Query String values here
            // To Do Sitecore related activities here

In JavaScript we will access

function ArticleDetails() {
   var HostUrl = "Your Host Url";  
   var xmlHttp = new XMLHttpRequest();
   var url = HostUrl + '/api/Sitecore/QuickPost/ArticlePost?QueryString
   xmlHttp.open("GET", url, false);
   return xmlHttp.responseText;