1 esanchez Mar 08, 2006 03:21
3 esanchez Mar 09, 2006 04:51
Hi Nate,
Thanks for the suggestion. As you said, putting the code anywhere on that Clause, makes the icon appear on the Comments & Trackball.
Edgar
4 nate Mar 09, 2006 05:25
I think Personman is the guy for this job. He actually knows php.
Even though my suggestion didn't end up working out, I'm giving myself a pat on the back for being able to find the correct code and actually predict what would happen if it was changed. It was quite a hunt trying to figure out where those comment links come from, but it was a fun challenge.
I imagine that some php-smart people might be chuckling at me right now, but I don't mind! :D
5 topanga Mar 09, 2006 08:59
If I understand your question correct, this is the pace to be :
http://doc.b2evolution.net/v-0-9/evocore/Item.html#feedback_link
You can put into your_main.php this code. That means that you can change it for different skins.
void feedback_link( [ mixed $type = 'feedbacks' ] , [ mixed $before = '' ] , [ mixed $after = '' ] , [ mixed $zero = '#' ] , [ mixed $one = '#' ] , [ mixed $more = '#' ] , [ mixed $title = '#' ] , [ mixed $use_popup = '#' ] , [ mixed $hideifnone = '#' ] , [ mixed $mode = '' ] , [ mixed $blogurl = '' ] )
* Template function: Displays link to feedback page (under some conditions)
* {@internal Item::feedback_link(-)}}
*
* @param string Type of feedback to link to (feedbacks (all)/comments/trackbacks/pingbacks)
* @param string String to display before the link (if comments are to be displayed)
* @param string String to display after the link (if comments are to be displayed)
* @param string Link text to display when there are 0 comments
* @param string Link text to display when there is 1 comment
* @param string Link text to display when there are >1 comments (include %d for # of comments)
* @param string Link title
* @param boolean true to use a popup windows ('#' to use if comments_popup_windows() is there)
* @param boolean true to hide if no feedback ('#' for default)
* @param string 'pid' or 'title'
* @param string url to use
What does this actually means :
Every variable in this line can be changed.
Per default, you mention none.
But every change you want, you can put in here.
In your case, the variables to change are those for
Link text to display when there are x comments
Instead of a link text, you put the url for an image.
How those comment links get added is pretty cryptic to me, but I snooped around a bit anyway. The closest I could come to a possible solution was in the file _item.class.php in the evocore directory. I see the following block of code:
I'm imagining you could include a link to your image in the first "echo" line as part of the comment link. I am currently unable to test this, however, so you're on your own to see if I'm off my rocker.
I'm also guessing that this code handles links for trackbacks as well, which means it might insert the image in your trackback links....probably not a desirable result.
But again, I'm just completely guessing since I can't find anywhere else that is even remotely decipherable by my untrained eyes. Let me know if you try it....(By the way, I'm using version 1.6, so there's a chance code has changed if you're using an older version.)