How I can save a Page in a Page Template in Kentico Xperience13 - kentico

In Kentico Xperience13, when I go in the Page Template application they said we need to use the Page Application to create a page and save it as a Page Template. But when I create a Page I don't see the place where I can save as a Page Template. So when I came back in the Page Template application the list is always empty.

To use Page Templates in Kentico Xperience 13, you either need to create default templates through code - see Developing page templates, or you can save widgets that have been added to a page as a custom page template - see Saving pages as custom page templates

As someone currently working on a site in Xperience 13, you may want to consider taking a class or two on Pluralsight to give you the basics of MVC and .net core. I am new to those but have been using Kentico for over 10 years. This change to MVC has been a bear to learn. But the Pluralsight courses have helped me get a better understanding of the structure.
Kentico does use content based routing as an option (and I think it is default in 13) you can learn more about it here https://docs.xperience.io/developing-websites/implementing-routing#Implementingrouting-Contenttree-basedrouting
when you build page types you don't have to worry about the model and the controller portion, kentico handles it, you just need to build the view.
this tutorial covers the basics https://docs.xperience.io/13tutorial/asp-net-core-development-tutorial

Related

Integrating html templates in Kentico 10

I am using Kentico portal to make an E-commerce site.If I wish to change the design of available sample E-commerce site.Would it be a tidious task ?
Example : If I download e-commerce design templates (i.e html and css files) and I wish to change design of each page of sample kentico site (home page,product detail page etc.)then, what is the most suitable and quick way to achieve this ?
How should I update the html/css of each page of available site with downloaded templates? OR Should I create entirely a new e-commerce site in the portal ?
The out of the box sites are meant to be used as examples and references not to build a production site off of. The markup used on the Ecommerce site will also be different, considerably different than your purchased template. I've found it much easier and faster to start from scratch with a blank site and implement all of the design that way. Make sure you take advantage of shared layouts and templates, this will help make development and re-skins in the future easier.

Display standard Kentico CMS document page using MVC controller

Is there an easy way to use an MVC controller in Kentico; and, return a specific page that has been developed in Kentico, as opposed to referencing something like ~/Views/ControllerName/SomeView.cshtml?
I'm trying to use the MVC controller to provide some needed routing functionality, and already had a working page prior to using the controller. I would like the display to be pulled from the working page I had before using the controller.
I'm using Kentico 7.
Especially in Kentico 7, MVC support was more or less "you can use it, but it won't be usable with portal functionality."
You can have MVC pages, and have Portal pages, but there really isn't a way to pull in a portal style page into it. You're best bet is to try to either use some custom logic to render the elements you need and pull in that content dynamically into the page.
I could be wrong, my MVC isn't as strong as my kentico.
Trevor is right - there is an ASP.NET MVC support in Kentico v7 you can use but there is nothing like MVC Portal Engine or something like that. There are two possible ways how to achieve your scenario:
You can use Kentico as a 'model' and read (manipulate) data via API in your controller and view (typically in Razor). Then you need to:
a) register route to your controller in CMS Desk > Node > Properties > URls and choose proper Path type (route or MVC) - this is prefered way
b) create MVC page template in Site manager > Page templates
You can find example on Corporate Site (part of default installation) in CMS Desk > Corporate Site > Examples > Development Models > MVC
You can learn more in Kentico CMS 7 documentation (MVC development overview section).
Please note there is whole new MVC approach in latest version (Kentico 9).
Portal engine is based on web forms and components such as web parts, page templates or widgets are not supported by MVC itself so you wont be able to display your page using MVC.
Kentico 10 will contain many new features regarding MVC, but mixing portal engine with it will not be the case.

Importing a static website on to Kentico CMS

I've been developing an static website (just html, css and js files) for a client who now wants to load the site on to Kentico CMS.
I don't know anything about this CMS. Is this a practical way to import the completed code into this system?
Thanks.
I would do things the way Kentico expects.
Take your header/footer and put them into the master page (template).
Take individual template HTML and create Layouts and Templates from them.
Use Kentico Web Part where possible
For dynamic content areas, use the Editable Content Web Part.
For the menu use the CSS Menu Web Part.
Use the Portal Engine technique. Don't use ASPX pages unless you really have to.
Here is some documentation from version 8: https://docs.kentico.com/display/K8/Creating+portal+engine+master+pages.

Which is the Liferay equivalent of a IBM WebSphere Portal / WCM Menu?

I've developed with WPS and WCM for several years and now I am also learning Liferay. I can't help but compare the features and I understand that in Liferay some things are done differently.
I would like to know the best practices to manage the following simple example:
A simple page with a carrousel with several images and links
Google analytics inserted in the page (Reusable in most pages)
The following is how I'd solve it in IBM WPS:
A HTML component with the Google Analytics code that is called in every page (I can't find how to do this in Liferay)
A content definition of an image and a link.
Create several contents for each image and link.
Create a menu that shows the list of content in the form of a carrousel (I can't find how to do this either in Liferay)
I am aware that Liferay has a list portlet and content that has repeatable items. I know I could use these, however its much more usable if I can have on content for each image/link and one reusable HTML snippet of code.
How should I solve this in liferay in the most efficient way?
Thanks!
You have to use Liferay Web Content portlet for creating the carousel. This is available in Control Panel. For your particular requirememnt you have to create a dynamic web content, which involves using of Velocity language and javascript to iterate over a set of images. Infact if you see Liferay's website, the home page has this kind of stuff.
For Google Analytics there are two ways. Liferay is not just meant for creating one site, it caters creation of multiple sites. Each site has a group of pages. You can create site from Control panel again. In the site settings you have this option to add google analytics id. So with each site can have different google analytics id.
If you want to do it at a global level, we add the google analytics script snippet in the Theme of liferay.
To get a better understanding of all the jargons used in Liferay, you have to atleast go through Liferay's documentation. And while going through it you have unlearn what you have previously learned. Liferay has hell lot of features than Websphere portal.
http://www.liferay.com/documentation/liferay-portal/6.1/user-guide

How to provision a custom page without using the _layouts directory?

I need to provision a custom aspx page which does some work and then redirects to another page. Using a _layouts page, AKA an application page won't work since I only want this page accessible to one site collection.
I looked at using pattern #4 from blog post Application Development on MOSS 2007 and WSS V3. It feels pretty hacky, and it asks you to drop the DLL. Drop it into the bin of the site collection, and upload the file through SP Designer.
I'd rather have this page be a feature that gets included in my site definition or stapled to an existing site definition. I imagine I could use a feature receiver to deploy the files to the pages SP list. One of the comments on the blog post says as much:
Pardon my ignorance on this maybe I am
missing the point completely but
wouldnt it be easier to deploy your
custom pages by programmatically
adding them to the pages splist?
I basically, had a simple .aspx page
with a user control. I deployed it via
this method.
How can a custom page be provisioned without using a _layouts page?
I guess another option is to keep using a _layouts page, but make sure the referrer is correct.
Besides application pages, you also have the possibility to create site pages.
Site pages are in nature related to application pages, but they reside in a site not in _LAYOUTS.
The welcome page (default.aspx) is an example of such a page.
In the same way as with application pages, it is possible to do codebehind in these pages (check out AC's article on this subject, Using ASP.NET 2.0 Code Behind Files in SharePoint v3 Sites)
You can read this article regarding the subtle differences between application pages and site pages: SharePoint Application and Site Pages - Part 1 of 2
You deploy this custom page using a feature, where you specify the file as ghostable (look at the example in ACs article).

Resources