Glossary Item Box

Modules: Modules

Controls: Anti robot image

See Also CmsDeveloperGuide Send comments on this topic.

Simple shop

This module allows you to organize quickly and show a categorized list of items (goods) with an opportunity of selecting them and sending an order form by e-mail. Items list, order form, minimal order sum and confirmation messages are tuned through the CMS administrative interface.

 

The control has some templates that helps to configurate it as you need: 

Template's name Description
TopPart Template to display top part of the simple shop.
BottomPart Template to display bottom part of the simple shop.
ItemTemplate Template to display a goods
ItemSeparator Template to display a separator between goods
CategoryHeader Template to display the category header
CategoryFooter Template to display the category footer
CategorySeparator Template to display the separator between goods' categories
OrderFormSeparator Template to display separator between last category and order form
OrderForm Template to display order form
ConfirmationTemplate Template to display order confirmation message
 

In the TopPart, BottomPart and OrderFormSeparator tags of the SimpleShop tag you can use the following parameters:

Template's part Description
<%# Container.SumLabel %> Label that showes the order sum.
 

In the ItemTemplate tag of the SimpleShop tag you can use the following parameters:

Template's part Description
<%# Container.Name %> Name of the good
<%# Container.Desc %> Description of the good
<%# Container.Price %> Price of the good
<%# Container.IconUrl %> Path to the icon
<%# Container.ImageAttributes %> Additional image attributes (image's description and link to display large image)
<%# Container.HasLargeImage %> Whether there is large image or not
<input type="text" id="NumberTextBox" runat="server" /> TextBox to input number of ordered goods
 
In the OrderForm and ConfirmationTemplate tags of the SimpleShop tag you can use the following parameters: 
Template's part Description
<%# Container.Html %> HTML code of the content. This HTML is set through the CMS administrative interface.
 

The OrderForm and ComfirmationTemplate tags are usually not added. Then it is just displayed the HTML set through the CMS administrative interface.

 
 

In the CategoryHeader and CategoryFooter tags of the SimpleShop tag you can use the following parameters:

Template's part Description
<%# Container.CategoryName %> Category name
 
 
A template file for this module lies in a modules/simpleshop folder and can look as follows:

<%@ Register TagPrefix="cmss" Namespace="CMSLib.Modules.SimpleShop" Assembly="CMSLib" %>
<%@ Control Language="c#" Inherits="CMSLib.Pages.SiteControl" %>


<h3>Books</h3>

<cmss:SimpleShop id=SimpleShop1 runat="server">
<ItemTemplate>
    <p><img src="<%# Container.IconUrl %>" align="left" <%# Container.ImageAttributes %> border="1">
    <b><%# Container.Name %></b><br /><%# Container.Desc %></p>
    <p>Price: <%# Container.Price %><br />
    Number: <input type="text" id="NumberTextBox" runat="server" value="0" /></p>
</ItemTemplate>
<CategoryHeader>New category: <%# Container.CategoryName %></CategoryHeader>
<CategoryFooter>End category: <%# Container.CategoryName %></CategoryFooter>
<OrderFormSeparator>Order sum: <b>$<%# Container.SumLabel %></b></OrderFormSeparator>
</cmss:SimpleShop>

 

Modules: Modules

Controls: Anti robot image

 

 


© 2005-2007 Astron Digital Ltd. All Rights Reserved.