Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1186058
    thecashbag
    Participant

    I’m trying to build a custom post type template. I know you don’t support these as it’s custom development but I want to learn some details about your code so that I can implement it myself.

    I’m trying to create a custom post template that has everything included in one file, not spread out over multiple views. It makes for easier development.

    I have managed to do this by following the path of each of the x_get_view() function and coping the corresponding code back into my new template.

    Your help documents show that their are two arguments used each time. For example x_get_view( 'global', '_header' ) will grab code from the Global folder and the file named _header. The first argument is global and the second argument is _header.

    But I have just come across x_get_view( 'global', '_content', 'the-content' ) inside the x\framework\views\global\_content.php file that has three arguments. What is the third argument the-content doing? And where is it pointing exactly? I could not find any file named “the-content” inside x\framework\views\global…

    #1186079
    Paul R
    Moderator

    Hi,

    The third argument is an extension.

    This x_get_view( ‘global’, ‘_content’, ‘the-content’ ) means to get the file

    x/framework/views/global/_content-the-content.php

    Hope that helps.

  • <script> jQuery(function($){ $("#no-reply-1186058 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>