Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Nam Gi VU 26 posts 47 karma points
    Apr 06, 2010 @ 13:19
    Nam Gi VU
    0

    Why do we need both of Name and Alias?

    Almost every object defined in Umbraco has a name and an alias. I'm wondering why do we need these two properties? Why not just use the name to identify the object?

    Hope to hear from all of you!

    Nam.

  • Jamie Howarth 306 posts 773 karma points c-trib
    Apr 06, 2010 @ 13:27
    Jamie Howarth
    2

    Hi Nam,

    "Name" is for the human-friendly display names of objects, "Alias" is for programmer-friendly names, where spaces and symbols are not recommended etc.

    Hope this helps.

    Benjamin

  • Laurence Gillian 600 posts 1219 karma points
    Apr 06, 2010 @ 13:28
    Laurence Gillian
    3

    Name - for the editor.

    Alias - for the programmer.

    -

    When building large sites it means you can define a naming architecture which the editor does not have to see. We use a system where we prefix the type of stored data which its relation. This means across the site we can reuse properties, which makes writing/reusing macro's easier.

    Generic objects which would get reused across the site;

    1. contentBody
    2. contentTeaser
    3. contentHeader
    4. mediaRelation (used for relating content to media)
    5. contentRelation (vice versa)
    Area specific types;
    1. albumName 
    2. albumRelease
    3. eventDate
    Working like this allows a programmer to list out the objects quickly in a nicely ordered list of relations! Which saves having to search through all the properties just to find if you called the object HeaderSub or SubHeader.
    Hope thats useful! Umbraco is just really a framework, use it as you wish!
    Lau

Please Sign in or register to post replies

Write your reply to:

Draft