1 bit Jul 21, 2009 19:54
3 bit Jul 21, 2009 20:14
Uhmmm... maybe that bit about the special class gave the impression that I am more proficient than I really am.
Where do I put that code?
Before you say anything, remember I'm blonde too. ;)
4 yabba Jul 21, 2009 20:24
heh, bugger, lemme go find the file .......
ok, based on, urm, 3.x.rc1, /skins/(optional)skin_name/_item_comment_inc.php, you'd change this bit :
// Default params:
$params = array_merge( array(
'comment_start' => '<div class="bComment'.( $Comment->author_user_ID == $Item->author_ID ? ' bCommentAuthor' : ' SomeRiffRaff' ).'">',
'comment_end' => '</div>',
'Comment' => NULL, // This object MUST be passed as a param!
), $params );
¥
5 bit Jul 21, 2009 21:00
Er... so I would have to also create bComment.bCommentAutor and bComment.SomeRiffRaff subclasses in blog_base.css?
6 bit Jul 21, 2009 21:04
I get <del>this</del>these errors:
Notice: Undefined variable: Comment in /home/bit/public_html/blog/skins/_item_comment.inc.php on line 20
Notice: Trying to get property of non-object in /home/bit/public_html/blog/skins/_item_comment.inc.php on line 20
Notice: Undefined property: Item::$author_ID in /home/bit/public_html/blog/skins/_item_comment.inc.php on line 20
7 yabba Jul 24, 2009 21:22
Find a bit that looks like this and then modify it to look a tad more like this :
/**
* @var Comment
*/
$Comment = & $params['Comment'];
?>
<!-- ========== START of a COMMENT/TB/PB ========== -->
<?php
$Comment->anchor();
// change this line
// echo $params['comment_start'];
// to be this
echo '<div class="bComment'.( $Comment->author_user_ID == $Item->creator_user_ID ? ' bCommentAuthor' : ' SomeRiffRaff' ).'">';
?>
<div class="bCommentTitle">
¥
8 bit Jul 26, 2009 17:26
Well, the error is gone.
So what do I do now? Do I define those subclasses in the skin? And what would be the syntax? (I tried defining .bCommentAuthor and bComment.bCommentAuthor, but it didn't work.)
EDIT: Never mind, I made it. Am I the only one to think this change would be a nice addition to b2evo?
9 bit Jul 26, 2009 17:35
Aaaand... thanxalot again, Yabba!
10 yabba Jul 27, 2009 00:53
Yer welcome ;)
¥
It would
ish
¥