Links not showing on single listings

http://links.mrboobird.com/listing/mrboobird-com/ is an example on the site I'm playing with... and the links aren't showing (using that page as an example). I entered the site under the custom form, and it's not showing up as a clickable link.

Also, is it possible to just comment out the "reviews are closed" since that doesn't appear to be functional, and also the "comments off" (unless I can re-enable comments somehow?). It so, how and where would I do this?

Thanks!

  • DavidM
    • DEV MAN’s Mascot

    Hi kmurraycreative and welcome to WPMU DEV!

    Those items aren't customizable within the plugins interface, but with a bit of work you can get that done relatively easily. Probably the best starting point for such alterations would be to get a child theme of the included Directory theme setup.

    Fortunately 'eyecool' (feel free to thank him with rep points!), one of our awesome community members here on the site created a tutorial for that at the following:
    https://premium.wpmudev.org/forums/topic/directory-plugin-child-themes-a-tutorial

    And with that, you'll have yourself a copy of the Directory theme that should be able to handle any minor updates to the Directory plugin without messing up your edits.

    Given that, you could take a look at line 61 of /directory/themes/default/comments.php:
    <p class="nocomments"><?php _e( 'Reviews are closed.', THEME_TEXT_DOMAIN ); ?></p>

    You can change that string or even remove it if you like.

    And you can do similarly with line 53 of /directory/themes/default/includes/functions/loop-functions.php, for the 'reviews off' string.

    And as for the url link, I believe you'll find that on line 34 of /directory/themes/default/single.php, where you could perhaps just wrap the php code with an href tag.

    And I believe that would cover your edits there. Let me know if you have any questions on that! :slight_smile:

    Cheers!
    David

  • kmurraycreative
    • WPMU DEV Initiate

    Thanks for promptly answering my question.
    I just commented out on the comments.php, as that was the main modification I wanted to make.

    On the issue of links not linking...
    I changed line 34 to

    <a href=<?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?>
    
    						<?php echo get_post_meta( $post->ID, '_ct_textarea_4d41cdafe95c6', true ); ?></a>

    ... but now it's just a blank area that goes to the link without showing a clickable link... I am probably missing something pretty obvious here, but just recently decided to learn more about this coding stuff.

    Thanks,
    Jessica

  • DavidM
    • DEV MAN’s Mascot

    Hi Jessica,

    I believe you're simply missing the quotes. Could you try the following?

    <a href="<?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?>"
    	<?php echo get_post_meta( $post->ID, '_ct_textarea_4d41cdafe95c6', true ); ?>
    </a>
  • DavidM
    • DEV MAN’s Mascot

    Hiya Jessica,

    Could you give the following a try?

    <a href="<?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?>"
    	<?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?>
    </a>

    And with that you'll want to be sure to keep the following line intact, which is:
    <?php echo get_post_meta( $post->ID, '_ct_textarea_4d41cdafe95c6', true ); ?>

    In your original post of the code, you had that line mixed in with the other line (they're two different lines in the file). I should have caught that! :slight_smile:

    Thanks,
    David

  • kmurraycreative
    • WPMU DEV Initiate

    Rrr!!! It's still doing that.
    The whole code looks like this -- and I've uploaded a screenshot as well http://mrboobird.com/wp-content/uploads/2011/05/mrboobirdlinks.jpg

    <div class="entry-post">
                        <h1 class="entry-title"><?php the_title(); ?></h1>
                        <div class="entry-content">
                            <?php the_post_thumbnail( array( 275, 100 ), array( 'class' => 'alignleft' ) ); ?>
                            <?php the_content(); ?>
                            <a href="<?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?>"
    	                <?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?></a>
                            <?php echo get_post_meta( $post->ID, '_ct_textarea_4d41cdafe95c6', true ); ?>
    
                            <?php wp_link_pages( array( 'before' => '<div class="page-link">' . __( 'Pages:', THEME_TEXT_DOMAIN ), 'after' => '</div>' ) ); ?>
                        </div><!-- .entry-content -->
  • DavidM
    • DEV MAN’s Mascot

    Hi Jessica,

    I believe you're only missing a single closing tag '>'. Could you try copying the following in place of your code from above?

    <div class="entry-post">
                        <h1 class="entry-title"><?php the_title(); ?></h1>
                        <div class="entry-content">
                            <?php the_post_thumbnail( array( 275, 100 ), array( 'class' => 'alignleft' ) ); ?>
                            <?php the_content(); ?>
                            <a href="<?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?>">
    	                <?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?></a>
                            <?php echo get_post_meta( $post->ID, '_ct_textarea_4d41cdafe95c6', true ); ?>
    
                            <?php wp_link_pages( array( 'before' => '<div class="page-link">' . __( 'Pages:', THEME_TEXT_DOMAIN ), 'after' => '</div>' ) ); ?>
                        </div><!-- .entry-content -->

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.