Recent Topics

1 Aug 29, 2008 00:21    

My b2evolution Version: 2.x

First off I have to say I've been out of the loop for a while - and there are a lot of cool changes since 0.93 8|

Can anyone help me with getting comments to display inline right below the post?

I'm not talking anything fancy like nested - just simple display....

I did look for a plugin that would do this - and I looked around the forums a plenty so if there is a post out there on this I must have missed it.

Rob

2 Aug 29, 2008 12:17

Try adding $c = 1; before the skin_include() bit for _feedback.php

¥

3 Aug 29, 2008 22:21

Oh hey - thats nice! - does exactly what I want - Thanks ever so much!
Is it possible though to have the comments form itself not displayed - I tried setting 'disp_comment_form' => false, in _item_feedback.inc

and it did the trick -but
it also made it so the leave a comment links didn't work

4 Aug 29, 2008 23:32

urm, probably ... buggered if I can think of what it is off the top of my head though :p

¥

5 Aug 30, 2008 01:59

I am such a boob - either that or the last search for this info was influenced by too many Millers .... the answer is over in Skins - at least for nifty corners -

ok, nitfy corners, index.main.php around line 255, use this:

<?php
// ------------------ FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE ------------------
if( $disp == 'posts' )
{
$c = 1; // force display of comments
skin_include( '_item_feedback.inc.php', array(
'before_section_title' => '<h4>',
'after_section_title' => '</h4>',
'disp_comment_form' => false, // prevent display of comment form
) );
}
else
{
skin_include( '_item_feedback.inc.php', array(
'before_section_title' => '<h4>',
'after_section_title' => '</h4>',
) );
}
// Note: You can customize the default item feedback by copying the generic
// /skins/_item_feedback.inc.php file into the current skin folder.
// ---------------------- END OF FEEDBACK (COMMENTS/TRACKBACKS) ---------------------
?>

Just so happens I'm using nifty corners - tho I don't see why it wouldn't work elsewhere.....

Yaaaay!

Um, once again its Miller time! :D

6 Sep 12, 2008 22:02

Hi,
I also try this trick to show comments on first page. It works for asevo skin but not for evocamp.
Does someone know why?
Mel

Edit: Forget it, I find why. I add in posts_main.php and it's fine.

7 Sep 19, 2008 21:11

Hi,

I tried this with asevo and it made my hole page go blank.
Would love to have this option on my blog. Any Advice?

8 Sep 20, 2008 04:08

What you add?
For Asevo, I just have to add this line

				$c = 1; // force display of comments 


It's around line 236 in index.main.php (I'm not sure, I think I modify also something else)

It give this

	// ------------------ FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE ------------------
				$c = 1; // force display of comments 
				skin_include( '_item_feedback.inc.php', array(
						'before_section_title' => '<h4>',
						'after_section_title'  => '</h4>',
					) );

Good luck!

9 Sep 22, 2008 23:38

Thanks mel_t

While THIS does indeed work, would love to take that extra step and hide the comment form, rather than having it show under each post. Tried CapnRob's code, but for some reason it is just not working...

10 Sep 23, 2008 02:01

You create a new file with an another name (copy from _item_feedback.inc.php to _item_feedback_noform.inc.php) and you remove this part. Don't forget to change name of your file in your index.main.php. It should work...

// ------------------ COMMENT FORM INCLUDED HERE ------------------
skin_include( '_item_comment_form.inc.php', array(
		'disp_comment_form'	 =>	$params['disp_comment_form'],
		'form_title_start'   => $params['form_title_start'],
		'form_title_end'     => $params['form_title_end'],
    'preview_start'      => $params['preview_start'],
    'preview_end'        => $params['preview_end'],
    'comment_template'   => $params['comment_template'],	// The template used for displaying individual comments (including preview)
	) );
// Note: You can customize the default item feedback by copying the generic
// /skins/_item_comment_form.inc.php file into the current skin folder.
// ---------------------- END OF COMMENT FORM ---------------------

11 Sep 23, 2008 02:29

Hi mel_t,

Thanks for your assistance on this.... the only problem is now if someone wants to leave a comment there is no form available for them to fill out....

12 Sep 23, 2008 03:32

It doesn't have a link "let a comment"?? (scuse I don't know exact formulation, I have my b2evo in french ;-) )
Normally, if you keep your original _item_comment_form.inc.php intact, it should display the post+comment+form.
At least, I think so...

13 Sep 23, 2008 05:31

It does have a link to leave a comment but when you click on it it opens up a new page with the post and where the form should be is blank...

14 Sep 23, 2008 05:38

mel_t,

you said you got CapnRob's code to work in asevo... could you post your version of that same code so I can try it as I am also using asevo....

15 Sep 23, 2008 05:40

Oh.. I see, asevo skins does'nt have the same files than my evocamp skin since it have a file "single_main" where I leave the form.
I'm quite sorry, my actual knowledge is not enough to solve your problem. Maybe someone else could help?
Good luck,
Mélanie

16 Sep 23, 2008 21:04

Is there a way to allow comments to be displayed on one blog versus all?

17 Nov 20, 2008 14:43

I have tried everything from this site regarding enabling my comments to be seen on the main blog page at the bottom of the blog post..

... yet, it eludes me!

If someone is bored, or incredibly kind-hearted, if you wouldn't mind taking a look at my site?

http://www.nixiepixel.com

p.s - I have no feedback.php, apparently, not sure if I need it or what I am supposed to put in it.

Thanks so much for all you guys do! :oops:

18 Nov 22, 2008 14:44

skins/[skin name]/index.main.php ( or posts.main.php ... whichever ), find a section of code that looks like this :

					<?php
						// ------------------ FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE ------------------
						skin_include( '_item_feedback.inc.php', array(
								'before_section_title' => '<h4>',
								'after_section_title'  => '</h4>',
							) );
						// Note: You can customize the default item feedback by copying the generic
						// /skins/_item_feedback.inc.php file into the current skin folder.
						// ---------------------- END OF FEEDBACK (COMMENTS/TRACKBACKS) ---------------------
					?>

and change it to look something like this :

					<?php
					$foo = array(
								'before_section_title' => '<h4>',
								'after_section_title'  => '</h4>',
								'disp_comment_form' => $c,
							);
					$c = 1;
						// ------------------ FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE ------------------
						skin_include( '_item_feedback.inc.php', $foo );
						// Note: You can customize the default item feedback by copying the generic
						// /skins/_item_feedback.inc.php file into the current skin folder.
						// ---------------------- END OF FEEDBACK (COMMENTS/TRACKBACKS) ---------------------
					?>

¥

19 Nov 22, 2008 19:49

my skin avoecamp doesnt have this,,,,

FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE :'(

20 Nov 23, 2008 10:45

In that case, copy and paste the above code into your skins posts.main.php just after this section of code :

			<?php
				// List all tags attached to this post:
				$Item->tags( array(
						'before' =>         '<div class="posttags">'.T_('Tags').': ',
						'after' =>          '</div>',
						'separator' =>      ', ',
					) );
			?>


		</div>

<!-- Paste the code from the previous post here -->

¥

21 Nov 23, 2008 14:36

I tried your suggestions for inserting the code into my .index and/or .posts and it still isn't working. It doesn't give me errors or anything, it just doesn't change.

I may just change my skin to rectify the issue..

Thank you Yabba for trying to help you angel! =D

http://www.nixiepixel.com

22 Nov 23, 2008 18:06

What skin are you using?

¥

23 Nov 24, 2008 00:58

¥åßßå wrote:

What skin are you using?

¥

It is the MiamiBeachtheme skin, which I have modified (appearance-wise, the code hasn't changed much).

Thanks!

24 Nov 24, 2008 08:59

Well, it works for me :P ( [url=http://innervisions.org.uk/?tempskin=MiamiBeachBlogTheme]demo[/url] )

The only changes I made were in posts.main.php ( approx line 146 )

	<?php
	$c = 1;
	// ------------------ FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE ------------------
	skin_include( '_item_feedback.inc.php', array(
	'before_section_title' => '<h4>',
	'after_section_title'  => '</h4>',
	'disp_comment_form'  => false,
	) );
	// Note: You can customize the default item feedback by copying the generic
	// /skins/_item_feedback.inc.php file into the current skin folder.
	// ---------------------- END OF FEEDBACK (COMMENTS/TRACKBACKS) ---------------------
	?>

¥

25 Nov 25, 2008 09:55

Yaaay! Many stars from me to you! :D really, Thanks so much!!!

I don't suppose I could be even more picky and find a way to hide the mass of comments, so that only the number of comments show up initially, (ex: "3 comments" ) and the "3 comments" can be clicked on for an expanded view?

Then my nerdy process will be complete, and I will not bother anyone anymore. 8|

26 Nov 25, 2008 10:46

give an inch take a mile :|

Ok, all this goes in posts.main.php.

Change the top of the file to look a tad like this :

if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );

// newly added bit
require_js( '#jquery#' );
add_headline( '<script type="text/javascript">
//<![CDATA[
jQuery(document).ready(function(){
	jQuery( ".feedbackText" ).click( function(){
		var id = "feedback_"+jQuery( this ).attr( "id" );
		jQuery( "#"+id).toggle( "slow" );
	}).trigger("click");
});
//]]>
</script>');
// end of new bit


// This is the main template; it may be used to display very different things.
// Do inits depending on current $disp:
skin_init( $disp );

Then meander down to the bit you added last time and change that section to look like this :

	<?php
	if( $total = generic_ctp_number( $Item->ID, 'feedbacks', 'published' ) )
	{
		echo '<div><span class="feedbackText" id="for_item_'.$Item->ID.'">'.$total.' comments</span>'."\n";
		echo '<div id="feedback_for_item_'.$Item->ID.'">'."\n";
		$c = 1;
		// ------------------ FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE ------------------
		skin_include( '_item_feedback.inc.php', array(
		'before_section_title' => '<h4>',
		'after_section_title'  => '</h4>',
		'disp_comment_form'  => false,
		) );
		// Note: You can customize the default item feedback by copying the generic
		// /skins/_item_feedback.inc.php file into the current skin folder.
		// ---------------------- END OF FEEDBACK (COMMENTS/TRACKBACKS) ---------------------
		echo '</div>'."\n";
		echo '</div>'."\n";
	}
	?>

¥

27 Nov 25, 2008 13:58

Yabba, really and truly-- thank you for teaching me that little ditty.

For some reason, after the changes.. now when I just casually go to the blog, it pops up the admin window that will access my hosting and all my root files. 8|

Since I can't have that happen, I'm changing the skin for now, until I can figure out what's going on, but I will be switching back as I do quite like what you've shown me with the comments!

28 Nov 25, 2008 14:12

Nevermind! I linked to a photo that required admin access in my blog, so it popped it up. Oh the amazing things we do when we're not technologically aware.

Anyhoo.. thanks again for everything. :lol:

30 Dec 17, 2008 20:36

This is quite confusing for someone who doesn't really know coding. Any chance to make it a widget or plugin or something? :)

31 Dec 18, 2008 18:01

It's a smidge hard to hack a skin from inside a plugin ;)

¥

32 Jan 27, 2009 18:52

I have been trying to figure out how to get comments to display on ASEVO but only when a comment has been posted. The only thing I have been able to do is get the "Post a Comment" form to display under every post. This is not what I am looking for. I am just trying to get comments to display when and if there are any.

Any assistance would be much appreciated!!

33 Jan 27, 2009 19:50

In that case, this is certainly the right thread to read ;)

¥

34 Feb 27, 2009 15:08

I have tried reading this, hacking the code, etc, but to no avail. Could you guide me in the right direction. Just want the comments inline as stated, but am using glossyblue skin. Tried adding the section of code:

<?php
$c = 1;
// ------------------ FEEDBACK (COMMENTS/TRACKBACKS) INCLUDED HERE ------------------
skin_include( '_item_feedback.inc.php', array(
'before_section_title' => '<h4>',
'after_section_title' => '</h4>',
'disp_comment_form' => false,
) );
// Note: You can customize the default item feedback by copying the generic
// /skins/_item_feedback.inc.php file into the current skin folder.
// ---------------------- END OF FEEDBACK (COMMENTS/TRACKBACKS) ---------------------
?>

in the posts.main.php but got a fatal error. Added it right before the post lists mode section and got this error:

Fatal error: Call to a member function can_see_comments() on a non-object in /home/xxx/public_html/xxx/xxx/skins/glossyblue/_item_feedback.inc.php on line 47

Thanks for any help.
Doc

35 Feb 27, 2009 16:13

It needs to go inside your post loop, not before it ;)

¥

36 Feb 27, 2009 18:18

Thank you. Worked perfect :p


Form is loading...