ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Linking pages and entries in Expression Engine by IDs

November 29, 2011 12:27am

Subscribe [4]
  • #1 / Nov 29, 2011 12:27am

    dgink

    60 posts

    Hi,

    I would like to know if there is a way to link pages and entries across the site that does not involve path variables. I need my authrs and publishers to be able to link to other related entries and pages across the website. But I cant see how they can do this in the default text area.

    Specifically I am looking for a way to link entries by their ID so my website is more portable.

    Is this possible?

  • #2 / Nov 29, 2011 8:05am

    Boyink!

    5011 posts

    The challenge you are bumping into is that EE isn’t a “page-based” CMS.  One entry may be used in ways that cause it to appear on the site at several different URLs.

    At times you can get around this by looking at add-ons like Playa which allow use of relationships which you as the developer can then turn into links.

    Otherwise if you use the Pages Module and look through the related add-ons out there (possibly Structure) that push EE to more of a Page Based model I think there are offerings that allow link-building like you mention.

  • #3 / Nov 29, 2011 8:32am

    dgink

    60 posts

    Hey Mike,
    Thanks for looking in.

    I do own the playa module and use it in my current project.
    But how do I use it to generate links out of relationships? Can you give me a hint?
    Also I need this in a way that content authors can easily link the text they are publishing to related entries on the fly (I mean snippets of content in the body of their text like natural organic links, not a stack of links below the article).

    How do I do this?

  • #4 / Nov 29, 2011 8:36am

    Boyink!

    5011 posts

    The P&T docs have examples of link generation - it’s just native EE code:

    http://pixelandtonic.com/playa/docs/templates#primary

    But it’s not an approach that is going to create ad-hoc links within blocks of content.  To get there you either have to go down the path I suggested earlier or use the normal Link buttons in a tool like Wygwam and treat in-site URLs the same as off-site URLs.

  • #5 / Nov 30, 2011 2:47am

    John Henry Donovan

    12339 posts

    Hi Amit,

    Has Mike’s helpful advice been enough for you to make headway?
    I’m going to move this thread to the Community Help forum so you can continue to post to it

  • #6 / Nov 30, 2011 3:03am

    dgink

    60 posts

    Certainly improved my understanding of EE but unfortunately didn’t solve my problem. You can move this post.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases