Important Notice from AspDotNetStorefront
It is with dismay that we report that we have been forced, through the action of hackers, to shut off write-access to this forum. We are keen to leave the wealth of material available to you for research. We have opened a new forum from which our community of users can seek help, support and advice from us and from each other. To post a new question to our community, please visit: http://forums.vortx.com
Results 1 to 5 of 5

Thread: Different Templates based on Content

  1. #1
    philipb is offline Junior Member
    Join Date
    Jul 2010
    Location
    Ft. Lauderdale, Florida
    Posts
    22

    Default Different Templates based on Content

    I am looking for a way to have different templates (for the same skin) based on where a customer is on the site. Specifically, the following areas each need to have their own slightly different look & feel:

    1) Home, Category & Topic pages: 2-column layout w/ top & left navigation, home topic info in the middle-right & contact info across the bottom.

    2) Product Pages: 3-column layout, with nav on the left, reviews on the right & product info in the center.

    What is the best / easiest way to achieve this?

  2. #2
    ZachJ85 is offline Senior Member
    Join Date
    Apr 2010
    Location
    Philadelphia, PA
    Posts
    99

    Default

    TemplateSwitching.Enabled = true
    If you want to enable template file switching by entity, set this flag to true. You can then assign a template.ascx file to each entity (category, section, etc) that you want. The template.ascx file you assign to each entity must exist in the active skin folder (e.g. skins/skin_1).
    ------------------------------------------------------------------

    Under the extensions data and put the name of the skin file that you want to use
    SQL 2008, Visual Studio 2010
    Source: C#
    Version: AspDotNetStorefront ML 8.0.1.1/8.0.1.1
    Framework: .Net 4.0 (Running)

  3. #3
    GoodFella is offline Member
    Join Date
    Mar 2009
    Posts
    99

    Default

    How exactly do you "assign a template.ascx file to each entity (category, section, etc)?"

    Thanks you.

  4. #4
    hunter0781 is offline Member
    Join Date
    Apr 2010
    Posts
    34

    Thumbs up

    Once you enable the template switching appconfig look under the extension data tab on the entity and there will be a field to enter the template name.

  5. #5
    GoodFella is offline Member
    Join Date
    Mar 2009
    Posts
    99

    Default

    Thank you.