Content Management System and E-commerce for ASP.NET
MY ACCOUNT SHOPPING CART
  phone U.S. TOLL-FREE NUMBER:
1-888-225-2767
 
 
   

Web Parts


All content displayed by Kentico CMS is based on web parts. Web parts are basic building blocks of page. The web part may display a text, menu, search dialog or it can display some dialog.

You can easily create your own web parts, which is very easy. The web parts are standard ASCX user controls that can be created in Visual Studio 2005 or Visual Web Developer 2005 Express Edition. You can even create them using Notepad, without any compilation.

The following code represents a web part that displays text specified in its DisplayText property:

statictext.ascx:

<%@ Control Language="C#" AutoEventWireup="true"
CodeFile="~/CMSWebParts/Text/statictext.ascx.cs"
Inherits="CMSWebParts_Text_statictext" %>
<asp:Literal ID="ltlText" runat="server"></asp:Literal>

statictext.ascx.cs:

public partial class CMSWebParts_Text_statictext : CMSAbstractWebPart
{
    protected void Page_Load(object sender, EventArgs e)
    {
            ltlText.Text = this.GetValue("DisplayText");
    }
}

As you can see the web part uses standard ASP.NET syntax. It can be written either in C# or Visual Basic.NET.

Web part may have any number of custom properties. Once you create the web part in Visual Studio 2005, you need to register it Kentico CMS Site Manager and define its available properties.

Then, you can use the web part on your web site and configure their property values. In this way, you can quickly build powerful web sites.

Kentico CMS is delivered with a rich set of web parts:

  • Full-text search
    • Search box
    • Search dialog
    • Search dialog with results
    • Search results
  • General
    • Language selection
    • Page placeholder
    • User control 
    • Java Script
  • Listings and viewers
    • Attachments
    • Calendar
    • Datalist
    • Datalist with custom query
    • Document pager
    • Grid
    • Grid with custom query
    • Image gallery
    • Random document
    • Related documents
    • Repeater
    • Repeater with custom query
    • XSLT viewer
  • Membership
    • Current user
    • Logon form
    • My profile
    • Registration form
    • Sign out button
  • Navigation
    • Breadcrumbs
    • CSS list menu
    • Drop-down menu
    • Site map
    • Tab menu
    • Tree menu
  • Newsletters
    • Newsletter subscription
    • Newsletter unsubscription
  • Text
    • Editable text
    • Static HTML
    • Static text
  • BizForms
    • BizForm form
  • E-commerce
    • My Account
    • Product datalist
    • Shopping cart
    • Shopping preview
  • Forums
    • Forum
    • Forum group
    • Forum search box
    • Forum search results
  • Web services
    • Datalist for web service
    • Grid for web service
    • Repeater for web service

and the number grows with every new version.