Skip to Content Skip to Menu

CBAuthorBot Hack - Show CB Avatar in articles

  • Brat
  • Brat
  • OFFLINE
  • Posts: 5
  • Thanks: 0
  • Karma: 6
18 years 1 week ago #24570 by Brat
Replied by Brat on topic Installation
Hello all. I found this wonderful thread, and couldn't find mention of the proper way to install this outstanding mambot.

Simply put, create an associated XML file, and take this file along with the version of the CB Author bot that you want, and create a ZIP file with these two. Then, all you simply need to do is install this bot normnally just as you would any other mambots.

For your reference, I've uploaded a sample ZIP bundle that you can use. Of course, open it, make sure that the enclosed XML and CBAuthorbot.php files are suitable for your specific installation. Edit these however you see fit. Hope this helps someone!

Regards,
Brat.

Attachment CBAuthorbot.zip not found



Post edited by: Brat, at: 2006/11/13 22:15
Attachments:

Please Log in or Create an account to join the conversation.

  • Brat
  • Brat
  • OFFLINE
  • Posts: 5
  • Thanks: 0
  • Karma: 6
18 years 1 week ago #24571 by Brat
Replied by Brat on topic Mamblog and CB Author bot
Someone earlier asked a question regarding implementation of this hack with Mamblog. Currently, Mamblog does not support mambots. However, it is fairly easy to hack Mamblog to include this code. I did something similar on my test installation (completely separate, as I did this before discovering this hack), and it works just fine. In fact, I'm going to borrow some code from the bot to flesh out my code (LOVE the avatar link to the profile!).

There may be a lot of complaints about Mamblog, but, to its credit, it works, it is stable, and it is fairly easy to customize the code (sorry, couldn't tolerate Joomblog).

I do believe that Mamblog may process bots in the future. In the meantime, I simply hack in the code I want.

Again, huge thanks to the original author of this bot!

Regards,
Brat.

Please Log in or Create an account to join the conversation.

  • Flipsider
  • Flipsider
  • OFFLINE
  • Posts: 137
  • Thanks: 0
  • Karma: -82
18 years 1 week ago #24804 by Flipsider
Replied by Flipsider on topic Re:CBAuthorBot Hack - Avatar popup on mouseover
ericfoster3 wrote:

Here's a new twist to the same idea. I hacked CBAuthorBot to display the avatar in a popup when you mouseover it.

This also works in my Newest Users module, and Who Is Online module.

Check it out at my site to see what I am talking about.

Arundel Class of 1983

Hey what code do I have to implent in modules to make it work there too?

De-Karma me... if you dare...
CB Xbox Gamercard Plugin (Gone] - CB Xbox Gamercard Module (Gone)

Please Log in or Create an account to join the conversation.

  • giapet
  • giapet
  • OFFLINE
  • Posts: 1
  • Thanks: 0
  • Karma: 0
17 years 11 months ago #26480 by giapet
Hi guys,

I'm trying to implement this on my website. I've got it working, but I can't seem to be able to tweak the formatting o_o I'm 99% PHP-stupid, for the record.

I'd like for the icon to show up next to the "written by" message, so that it'll look like:

[IMAGE] Written by [AUTHOR]

I tried the various code fussing that was mentioned in this thread as much as I dared, but I couldn't get it to work out that way.

Most of my posts on the site open with an image, so it always winds up being the icon and then the first image, which looks funny ^^; I'd like to find a way to get this to work out (...without having to just throw a couple of line breaks up at the top of every article).

Thanks very much for any help! :)

Please Log in or Create an account to join the conversation.

  • houbahop
  • houbahop
  • OFFLINE
  • Posts: 50
  • Thanks: 0
  • Karma: 9
17 years 11 months ago #26700 by houbahop
Hello,

I have ported this avatar hack to mamblog for my purpose and I have seen that some users here were interested.

in mamblog.html.php find : <td valign="top" colspan="4">

then add before echo $blog->text; ?>

[code:1] // modif pour inclure l'avatar CB
global $database, $mosConfig_live_site;
$query = "SELECT avatar FROM #__comprofiler WHERE user_id = $blog->created_by AND avatarapproved = '1'";
$database->setQuery( $query );
$avatar = $database->loadResult();
$avatarlink = "";
$txt = "";
if ( $avatar ) {
$avatarlink = $mosConfig_live_site.'/images/comprofiler/tn'.$avatar;
$txt = "<a href=\"".sefRelToAbs('index.php?option=com_comprofiler&task=userProfile&user='.$blog->created_by)."\"><img src=\"$avatarlink\" HSPACE=\"5\" border=\"0\" align=\"left\" class=\"authorimg\" /></a>";
echo $txt;
}
// fin modif avatar CB[/code:1]


To activate this to work, you need to make a link like that :

vith SEO activated:
www.yoursite.com/component/option,com_mamblog/task,show/action ,all/


I would be happy if someone that know well the CB API to use the function to create the page navigation could help me with that.

I ask that because currently if the total number of blogs is more than the number of blog that must be show (variable setup in the backend), only the firsts blogs are shown, then there is for each other ones a text link that points to them.

My aim is to change this and put a link to have the next X blogs that reloads the page wich new ones.

Well, I hope that will be no issues with that. It works well on my computer with the last joomla and akocomment 2.0 installed. Please make a backup of the file before to update it in case of..


Houbahop.


EDIT :

After a few hours of work I have added the call to mosPageNav class to have some links to browse ALL the blogs.
It seem to work fine, however some areas of the code are dark for me and I wouldn't be surprised if I had broken some features. However until now I have no problem. Contact me to have the file if you want to test it.

the next feature I will add will probable be the number of hits of each blog.

[IMG


Post edited by: houbahop, at: 2006/12/11 03:06

Please Log in or Create an account to join the conversation.

17 years 11 months ago #27566 by KurtSteiner
Replied by KurtSteiner on topic Re:Installation
Brat wrote:

Regards,
Brat.

Attachment CBAuthorbot.zip not found



Post e



Hello Brat,
many thanks for putting most of the hacks together :)


To all,

through this Bot i got the avatar in the content, but it seems that some avatars are to big, so i would prefear only to show the Thrumpnail version.

Have anybody implemented this?:huh:

sunny regards from Germany

BERND (Kurt Steiner)

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum