View previous topic :: View next topic |
Author |
Message |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Tue Oct 05, 2004 9:52 pm Post subject: Image Links In Comments |
|
|
I would like to change the "email - url" links to images in the comment script. How can I achieve this?
IE : I know she's using Greymatter but I've seen someone use it in b2 before. Just misplaced the link : http://cgi.aztecdreamz.net/gm/archives/00000019.php#comments |
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Tue Oct 05, 2004 9:55 pm Post subject: |
|
|
I know it's this line of coding i need to edit but what's the proper script?
<?php comment_author_email_link("e-mail","[","] ") ?><?php comment_author_url_link("url", "[", "] ") ?> |
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Tue Oct 05, 2004 10:51 pm Post subject: |
|
|
Nevermind I got it by playing around with the commands. If anyone's interested here's the code:
<a href="mailto:<?php comment_author_email() ?>"><img src="images/yourimage.jpg" border="0" alt="e-mail" title="e-mail"></a>
<a href="<?php comment_author_url() ?>"><img src="images/yourimage.jpg" border="0" alt="website" title="website"></a>
You can see it in function here http://kisschanel.com |
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Tue Oct 05, 2004 11:03 pm Post subject: |
|
|
well i guess i didnt do it quite right. how to i fix it so the image WONT show if they didnt put an email or url? someone commented without entering an url and its linked as about:blank |
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Thu Oct 07, 2004 3:58 am Post subject: |
|
|
???  |
|
Back to top |
|
 |
Sigg3
Joined: 03 Jul 2003 Posts: 626 Location: Oslo, Norway
|
Posted: Thu Oct 07, 2004 9:23 am Post subject: |
|
|
It's a difficult question!
If you could somehow implement code into where it says email, it would save you alot of work. Don't think it works, though.
<?php comment_author_email_link("email", " - ", "") ?>
Or, you need to have a look at b2functions.php, I assume. It's a tough one. _________________ Sigg3 dot net - because you're worth it! | b2 Cafelog Resource Center |
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Thu Oct 07, 2004 12:44 pm Post subject: |
|
|
Sigg3 wrote: | It's a difficult question!
If you could somehow implement code into where it says email, it would save you alot of work. Don't think it works, though.
<?php comment_author_email_link("email", " - ", "") ?>
Or, you need to have a look at b2functions.php, I assume. It's a tough one. |
I'm not sure if you quite understand what I'm looking for. Or maybe I didn't quite understand your response LOL. But what I needed was an image instead of a text link for "email and "url". I accomplished that already. My NEW problem is when a comment poster has no URL, the image that I use still shows up and it links it to "about:blank". What I want to achieve is basically nothing showing up if they put nothing in that URL field. |
|
Back to top |
|
 |
Sigg3
Joined: 03 Jul 2003 Posts: 626 Location: Oslo, Norway
|
Posted: Thu Oct 07, 2004 3:30 pm Post subject: |
|
|
Yes, and that's what I replied to:)
That would need some change in the coding, since you already have placed a picture on the page with your <img src=""> SO you need it to be a variable (somehow included into the tag mentioned above). I don't know how you'd be able to do that except for changing the script code itself (which I believe would be @ b2functions.php)....
 _________________ Sigg3 dot net - because you're worth it! | b2 Cafelog Resource Center |
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Thu Oct 07, 2004 6:40 pm Post subject: |
|
|
oh i see. Well I'm not comfortable with php (matter fact I am VERY amatuer at it) and I don't think I want to tamper with my b2functions.php lol. You're very smart by the way. |
|
Back to top |
|
 |
Sigg3
Joined: 03 Jul 2003 Posts: 626 Location: Oslo, Norway
|
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Thu Oct 07, 2004 7:16 pm Post subject: |
|
|
Sigg3 wrote: | Far from it. I'm an amateur as well:)
ok... I don't like the sound of that. "amateur", like.
I'm a newbie. |
Well Ive had b2 for almost a year and i still dont have the FULL comfortable hang of it. If it was regulat html I'd be a GURU but php weakens me. At least I try to do it on my own feel me? I know a lot of people that just let someone login and do it for them. |
|
Back to top |
|
 |
Sigg3
Joined: 03 Jul 2003 Posts: 626 Location: Oslo, Norway
|
Posted: Thu Oct 07, 2004 9:44 pm Post subject: |
|
|
Well, HTML helped me this far. I've only dabbled with php.
And, as anything else in life, dabbling doesn't get you very far.
I've done the login thing, people have even tried to pay me, but I hang out at this board mostly when I'm at work, and when I've got nothing better to do I might as well try to do something constructive.
I think php is very logical, though. But my mind is tied up in CSS2 at the moment. Trying to improve and evolve:)
Good luck! _________________ Sigg3 dot net - because you're worth it! | b2 Cafelog Resource Center |
|
Back to top |
|
 |
kiss
Joined: 09 Sep 2004 Posts: 27 Location: Brooklyn
|
Posted: Thu Oct 07, 2004 9:50 pm Post subject: |
|
|
Thanks for the good luck! Same to you.
PS - CSS2? I never heard of it. Do you have a link that can further enlighten me about it? |
|
Back to top |
|
 |
Sigg3
Joined: 03 Jul 2003 Posts: 626 Location: Oslo, Norway
|
|
Back to top |
|
 |
|