b2evolution b2evolution

  • Sign in
  • Sign up
  • About
  • Downloads
  • Hosting
  • Docs
  • Support
  • Sign in
  • Sign up
  • Manuals Home
  • Latest Updates
 
  1. b2evolution CMS User Manual
  2. Back-office Reference
  3. Collections
  4. Contents
  5. Short Tags Reference
  6. Custom Fields Short Tags
  7. [parent:] Short Tag

[parent:] Short Tag

Built-in Feature

The [parent:] short tag is used to reference the parent of an Item. This works similarly to the [item:] Short Tag.

Note: An Item can be linked to a parent Item in the Item Properties Panel.

Note: [parent:...] generates:…


a block element when it is used as prefix for short tags subscribe, emailcapture, compare, fields and cannot appear inside a paragraph in such a case. (b2evolution will automatically move it out of the paragraph)
  • inline text when it is used as prefix for short tags like field, url, titlelink, etc. and can appear anywhere in such a case (inside a paragraph, table, etc.)


  • Syntax Breakdown

    [parent: ( "titlelink" | "url" | <fields short tag> ) ]

    • titlelink: specify this to render parent title with link
    • url: specify this to render parent URL
    • <fields short tag>: see [fields:] short tag

    Samples

    Linking to the Parent Item

    [parent:titlelink]
    [parent:url]

    Displaying All Fields of the Parent Item

    [parent:fields]

    Displaying Specific Fields of the Parent Item

    [parent:fields:first_numeric_field,first_string_field,second_numeric_field]

    Displaying the Value of a Specific Field of the Parent Item

    [parent:field:first_string_field]

    Recursion

    If you are using fields in a Content Block, you can control the level at which they are resolved by using [-parent:fields:...], [--parent:fields:...] etc. Each - pushes the resolution up one level to the caller.

    Tags: 7.0.2
    Created by fplanque • Last edit by fplanque on 2019-12-27 23:33 • •

    No feedback yet

    On this page

    • Built-in Feature
    • Syntax Breakdown
    • Samples
    • Linking to the Parent Item
    • Displaying All Fields of the Parent Item
    • Displaying Specific Fields of the Parent Item
    • Displaying the Value of a Specific Field of the Parent Item
    • Recursion

    Search the Manual

    Content Hierarchy

    • b2evolution CMS User Manual
    • User's Guide
    • Installation / Upgrade
    • Front-office Reference
    • Back-office Reference
      • Site
      • Collections
        • Collection Dashboard
        • Contents
          • Post Browsing Screens
          • Post Edit Screen
          • Short Tags Reference
            • Helper CSS Classes
            • Custom Fields Short Tags
              • [compare:]
              • [field:]
              • [fields:]
              • [item:]
              • [link:]
              • [parent:]
            • [audio:]
            • [cblock:]
            • [div:]
            • [emailcapture:]
            • [file:]
            • [image:]
            • [include:]
            • [inline:]
            • [pagebreak]
            • [poll:]
            • [subscribe:]
            • [switcher:]
            • [teaserbreak]
            • [thumbnail:]
            • [video:]
          • Post Concepts
          • Mass Edit
          • Mass Post Contents
          • Other post actions
          • Renderers Reference
        • Comments
        • Categories
        • Features
        • Skins
        • Widgets
        • Settings
        • Creating a new collection
      • Files
      • Analytics
      • Users
      • Messages
      • Emails
      • System
      • Working with Results Tables
    • Developer Reference
    • Operations Reference
    • Advanced Topics
    • Glossary
    • Archives
    Free blog engine

    This online manual is powered by b2evolution CMS – A complete engine for your website.

    About b2evolution

    • What is it?
    • Features
    • Getting Started
    • Screenshots
    • Online demo
    • Testimonials
    • Design philosophy
    • Free & open source
    • Terms of service

    Downloads

    • Latest releases
    • Skins
    • Plugins
    • Language packs

    About us

    • About us
    • Contact

    Webhosting Guide

    • Web hosting blog
    • Best web hosting
    • Cheap web hosting
    • Green web hosting
    • Hosting with SSH
    • VPS hosting
    • Dedicated servers
    • Reseller hosting
    • Int'l: UK / France

    Docs & Support

    • Online manual
    • Forums
    • Hire a pro !

    Other

    • Adsense
    • Press room
    • Privacy policy

    Stay in touch

    • GitHub
    • Twitter
    • Facebook
    • LinkedIn
    • News blog
    • RSS feed
    • Atom feed

    Founded & Maintained by François Planque