Copied to clipboard

Flag this post as spam?

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


  • kaivalya 16 posts 96 karma points
    Nov 25, 2015 @ 20:48
    kaivalya
    0

    how do I use page names instead of Id in Umbraco

    how do I use page names instead of Id in Umbraco 7

  • Dennis Aaen 4500 posts 18255 karma points admin hq c-trib
    Nov 25, 2015 @ 20:52
    Dennis Aaen
    0

    Hi kaivalya,

    Can you give a bit more information where you are trying to use page names instead of id. And it would be great if you could share that code you have, if you have any.

    This will make it easier for people to help you.

    /Dennis

  • kaivalya 16 posts 96 karma points
    Dec 01, 2015 @ 15:10
    kaivalya
    0

    Hi Dennis,

    Thanks for your reply,

    here is my link http://velocity.staging.synergynetworx.com/ I have just started to build this, but when I preview the page I see the page-id, how do I get the page name instead of ID

  • Phill 115 posts 288 karma points
    Dec 01, 2015 @ 16:27
    Phill
    0

    Hi Kaivalya,

    I'm guessing a bit here since I can't see any of your code but it looks like you're possibly using a Content Picker and then doing something like:

    <a href="@Model.Content.GetPropertyValue("itemLink")">learn more</a>

    That will link you to the ID, where what you want to do it get the content Node and it's url like the following:

    <a href="@Umbraco.TypedContent(Model.Content.GetPropertyValue("itemLink")).Url">learn more</a>

    That's a bit simplified but my guess is that should help you out.

  • kaivalya 16 posts 96 karma points
    Dec 01, 2015 @ 16:59
    kaivalya
    0

    Hi Phill

    thanks for sending this out it works but then I am seeing errors on this page

    http://velocity.staging.synergynetworx.com when you click on learn more of the first slide it will take you to the http://velocity.staging.synergynetworx.com/products/

  • Nik 1599 posts 7179 karma points MVP 6x c-trib
    Dec 01, 2015 @ 17:23
    Nik
    0

    Hi Kaivalya,

    At a quick looks at your errors I would say that you are referencing your CSS incorrectly.

    If you change your CSS in your layouts to start with a / instead of just CSS then see how it behaves. Making these changes via Chrome Dev Tools when visiting your site caused it to start rendering correctly.

    Also check image links and script links as well for the same issue.

    Nik

  • kaivalya 16 posts 96 karma points
    Dec 01, 2015 @ 17:29
    kaivalya
    0

    Hi Nik,

    It works, Thank you very much for your Support and Help

Please Sign in or register to post replies

Write your reply to:

Draft