• Resolved dimers

    (@dimers)


    Hi, I have much table data in my posts I and would like the <table> rendering to persist in the posts listed on the front page. How can this be enabled? Is there an theme option to enable this? Currently the <table> rendering in posts on the home page is removed and the text in the <table> is displayed as a single unstructured string. <table> data in a post is rendered as such when a single post is displayed.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Theme Author bassjobsen

    (@bassjobsen)

    Thanks for your interesting question. to be honest, i have never test this before. I will do coming days to give you a solution.

    By default on the homepage the expert of the post will be shown. See also https://codex.www.ads-software.com/Excerpt (this filters HTML).

    I think the best solution will be to create a new template front-page.php and show posts with the_content() and use the more tag.

    Globally this template should look like that shown below:

    <?php
    get_header();
    do_action( 'jbst_before_content_'.get_post_format());
    jbst_content_nav_top();
    if ( have_posts() ) :
    	while ( have_posts() ) : the_post();
    	the_content();
    	endwhile;
    endif;
    do_action( 'jbst_after_content_'.get_post_format() );
    get_footer();
    ?>
    Thread Starter dimers

    (@dimers)

    Hi,
    I tried creating a ‘front-page.php’ with the code as you noted but this did not work as expected.

    I edited your content.php file in “themes/jbst” and swapped out ‘the_excerpt()’ for ‘the_content()’ on lines 49 and 69. This appears to work OK and preserves the HTML tags (the <table> displays).

    I prefer not to alter your theme files, can this be a new theme option to expose ‘the_content()’ or to ‘the_excerpt()’ on the main page and search result pages?

    Theme Author bassjobsen

    (@bassjobsen)

    I will add that theme option before uploading the next version to www.ads-software.com. Thanks! See also: https://github.com/bassjobsen/jbst/issues/118

    Theme Author bassjobsen

    (@bassjobsen)

    This issue is fixed, please see: https://github.com/bassjobsen/jbst/issues/118

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Persist rendering for posts on the front page?’ is closed to new replies.