UPDATE #2: I have released a minor update that adresses the missing "" in the comments link. So those of you out there that care about validation can breathe easy again. Get it at the usual place.
UPDATE: I had left out one crucial piece of information from the setup directions, so the zip file has been updated. The only change is that I have now stated as a last step that you must open your index.php and find this line: <?php comments_popup_link(__('Comments (0)'), __('Comments (1)'), __('Comments (%)')); ?>
and replace it with <?php cjd_comment(); ?>
once that is done everything should be peachy.
That's right I am back with a new plugin. And the plugin is now ready to go.
Per Post Comment Text. You can see it in action on this site right now. You will notice that some of the links to view comments look normal, Comments (0), while others are a little different. This plugin allows you to set the text of you comments links on a post per post basis. Pretty snazzy.
Right now it handles everything you can throw at it, except post that have comments closed. At this time the plugin still just displays whatever you have set as your text. Right now the plugin has a default value, in this case Comments, so that if you don't want to add a custom link to an article you still have a default to fall back on.
Stroll on over and visit Keely Weston
March 1, 2007
I am impressed with this plugin. Only tried on a test post so far, but looks great! Thanks for sharing this.
One question, is there a way to style the cjd_comment in index.php, for example, to include a raquo? Or maybe easier to put that in the custom text, now that I think about it.
Stroll on over and visit Minna
March 1, 2007
Hmm... do you know any plugin or hack to exclude the custom fields needed by this plugin from the ones that show before the post? I have other kinds of custom fields that are supposed to show in the post and so this one does too :D
Stroll on over and visit Chris J. Davis
March 1, 2007
Do you mean translations? If you do mean translation then my answer would be sorta. You can enter any language you like into the custom field, and you can edit the plugin code to make the default and the closed comments message match whatever language you would like.
Other than that I am not sure what you are asking.
Stroll on over and visit Chris J. Davis
March 1, 2007
I also just Dled the newest nightly from teh WordPress site, 10-25-2004 and installed it and everything is still working fine.
Stroll on over and visit Manuls
March 1, 2007
And.. it works with traductions?
Stroll on over and visit Tin
March 1, 2007
hi chris,
the plugin is excellent! i have two questions though:
1. when i use cjd_comment to replace the previous tag in index.php, it shows up a link to the permalink comments page. how can i make it so that the popup comments work instead? my site uses popup comments.
2. lets suppose if i dont put anything in the value field. is there any way i can change the default 'comments (0)' 'comments (1)' and 'comments (#)'? i'd like it to say something else by default. i used to have my own customized text, but it was part of the tag that cjd_comment replaced.
thanks!
Stroll on over and visit Chris J. Davis
March 1, 2007
Let's see here:
if (0 == $texts) {echo "<a href=" . get_permalink() . '#comments' . ">Comments ($number)";
Just replace the word Comments with what ever you are wanting the text to be.
I plan on giving you an easy way to change the default text in the next version of the plugin, as well as some other goodies.
Stroll on over and visit Tin
March 1, 2007
thanks for the response, chris. i hope you do decide to include the popup comments feature though. my site is a photoblog and the comments are actually critique. popup comments are easier because you can view the image while typing the critique, instead of having to scroll up and down over and over again while analyzing the images. ;)
Stroll on over and visit Blair
March 1, 2007
Hey Chris
This site I'm mucking with is back in happy valid land.
All I can say is "You da man!"
Big thanks for that and keep up the great work :)
ps: not sure what happened in the last post with the google url? edit this and that out if you like
Stroll on over and visit Chris J. Davis
March 1, 2007
Unfortunately no, Alex's hack replaces the comment link, so it would replace mine also. Only one of them can be used at any time, not both.
Stroll on over and visit Anonymous
March 1, 2007
Fair enough - yours stays :)
Stroll on over and visit Chris J. Davis
March 1, 2007
One thing I can do is try to hack up an alternate version of Alex's hack that can run along side mine.
Hopefully in teh next few days I can get around to exploring that for you.
Stroll on over and visit Podz
March 1, 2007
Thanks for this plugin!
One question if that's okay.
I've been using Alex's Last Visit plugin, and would get a 'New' appear next to comments when appropriate.
His tag was this:
<?php ak_comments_popup_link(__('Comments (0)'), __('Comments (1)'), __('Comments (%)')); ?>
I can't seem to get the image to appear.
How would I do that ? Or is it not possible ?
Stroll on over and visit Chris J. Davis
March 1, 2007
Good catch, I think I might just add that to the install instructions.
Stroll on over and visit Andr√
March 1, 2007
Hi Chris,
concerning projektguerilla.de I found the error. I changed the index.php in the root of the wordpress directory, but not in the directory of the kubrick-theme, which I'm using. Maybe helpfull to add a hint in the installation instructions.
Your plugin works fine. :-)
Stroll on over and visit William
March 1, 2007
For some reason, I can only set one per post comment text, and then whenever I try to edit another post or add a custom field in a new post, it doesn't add the field. It says "custom field added," but it doesn't actually add it.
Any ideas?
Stroll on over and visit Chris J. Davis
March 1, 2007
Not without some more information. What version of WordPress are you currently running, and did the plugin ever work as advertised?
Stroll on over and visit William
March 1, 2007
Sorry, I forgot about this post =P
I use the latest mingus build of WP. But I've gotten it to work somewhat. it adds the custom field the first time you click either "Add custom field," "Publish," or "Save." You just can't add or edit a custom field after doing one of those things already.
Works, though. Nice plugin.
Stroll on over and visit Shawn Grimes
March 1, 2007
Hey Chris, just wanted to let you know that this plug-in is works great with the new WP 1.5 release. I have installed on my site right now. Thanks for the time you put into these plug-ins. Cheers!
Stroll on over and visit Chris J. Davis
March 1, 2007
Very cool Shawn, welcome back!
And I appreciate your kind words.
Stroll on over and visit Shawn Grimes
March 1, 2007
Oh, btw, I meant to ask in my previous (bad grammar filled) post. Will you be updating this plug-in in the near future? I read some of your comments that there will be an update with a few goodies? What are these said goodies? Inquiring minds want to know. ;)
Stroll on over and visit Chris J. Davis
March 1, 2007
Hmmmm... yeah I need to update the plugin so setting the default text will be easier. I don't remember what the other goodies were...
Stroll on over and visit Chris J. Davis
March 1, 2007
Shawn,
You mean as it does in WordPress by default? At this time, no. But I might be persuaded into trying to hack it in...
Stroll on over and visit Shawn Grimes
March 1, 2007
Hey Chris, I was wondering if there was a way to remove the link to the comments once you actually click on link to get to the comments. It works fine and the link disappears when I'm not using the plugin, but once I activate it, the link stays regardless. I hope you understand what I mean.
Stroll on over and visit Shawn Grimes
March 1, 2007
Well I noticed it works that way here on your site, so that is why I asked if I might be missing something somewhere. While on the issue of persuasion, maybe a way for the link text to show up as intended when digging through the archives? Hmm, what could a lowly blogger such as myself possibly do to persuade a code foo master........
Stroll on over and visit Chris J. Davis
March 1, 2007
It appears that way for me, because I am using a custom template for single post views. So yeah you can do that with my plugin easily, just create a single.php template and leave out my plugin.
There problem solved. heh.
Stroll on over and visit Jenna
March 1, 2007
I think the link to the download is broken. :)
Stroll on over and visit Chris J. Davis
March 1, 2007
Jenna,
Sorry about that I have moved my hosting and development to wp-plugins.org and had forgotten to update this link to reflect that, all better now.
Stroll on over and visit Chris J. Davis
March 1, 2007
Hey Jenna, try one more time!
Stroll on over and visit Jenna
March 1, 2007
I must be doing something wrong, because it's still not working for me...! :)
Stroll on over and visit Conor ONeill
March 1, 2007
I'm interested in trying this out.
Does it work on WP2.0?
I've tried downloading it from the link at the top of the page but the zip file appears to be corrupted. Also I cannot find it at wp-plugins.org.
Thanks.