Hi there!
I wanted to know if there´s a way to shou only my friend´s statuses history. (friend or other relationship type).
I post this as a suppor request, because I just don´t know if that´s actually possible or not. (maybe should be a feature request...?).
Thanks!
Rosamunda

Comments

icecreamyou’s picture

Status: Active » Closed (fixed)

That's already a feature. Use the "Facebook Status UR Recent Updates" block. See documentation if you need help.

Rosamunda’s picture

Thanks!!!!

Rosamunda’s picture

Category: support » bug
Status: Closed (fixed) » Active

I´ve verified the documentation (I´ve readed before asking, but I swear I didn´t red about that block! :)

Anyway, I´ve even rebuilded the module but still doesn´t appear that block. I must say that I´ve activated all "User Relationships" submodules...

Maybe an incompatibility with other module? I´ve "user activity" installed aswell, but I´ve deactivated, and the problem remains...

I´ve firstly installed this module and seconly installed User Relationships... but I dont think that could be a cause for this problem...

icecreamyou’s picture

Component: User interface » Miscellaneous
Status: Active » Postponed (maintainer needs more info)

First refresh your cache. I think in 6.x that's under ?q=admin/settings/performance, but I'm not sure whether it clears the entire cache or not.

If that doesn't work try updating the weight of the facebook_status module in the system table in your database to -1. That probably won't fix anything, and in fact might break something, but if it works that's an easy fix.

There shouldn't be any conflict with other modules. Are you looking under ?q=admin/build/block or just expecting the block to show up on it's own?

Also, whenever you report a problem like this, you should state the type and version of PHP and SQL you're running. Otherwise it will usually be assumed you're on PHP 5.1 or later and MySQL 5.0 or later.

Anyway, the code for the block is pretty short, so if worst comes to worst you should be able to just stick this somewhere on your own.

  //You MUST set $ur_rtid to the RTID of the relationship type you want to use before executing this code.
  $content = facebook_status_get_rel_status($ur_rtid);
  $content = facebook_status_list_render($content);
  if ($content) {
    $content = '<div class="facebook_status_block_rel">'. $content .'</div>';
    echo $content;
  }
Rosamunda’s picture

THANK YOU VERY MUCH for your kind answer and your help, Ice.
I´ve cleared the cache using devel´s link, and I went to the block´s list and didn´t found it there. The only block that appears with the "recent updates" phrase is "Facebook Status Recent Updates", that shows me all new activity.
I´ve tried what you told me, but didn´t work, so, I´ll go for the PHP code snippet and put it inside a nice little block ;) That should do the trick, I hope.
Yes, I have both PHP and MySQL 5.x versions, sorry for not mentioning it.
Anyway, I´ll try reinstalling the User Relationship module also, and see if that can help...
THANKS!!

Rosamunda

PS. erm... how do I set up the $ur_rtid ? My relationship ID is "1", it doesn´t work with this:
$content = facebook_status_get_rel_status($ur_rtid , 1);
nor this:
$ur_rtid = 1;

icecreamyou’s picture

Anything that starts with a dollar sign ($) is a variable. That means it represents something, in this case a number. You have to store the number in the variable before you use it in the rest of the code; for example this code will pass '3' to the function:

$variable = 3;
this_is_a_function($variable);
//You can't assign a value to a variable while it's being passed as an argument, so this won't work:
this_is_another_function($variable = 3);
//Variables automatically have a value of FALSE if you haven't assigned them a value before.

You don't really need to do that though, since you already know what RTID you want to use. Just do it like this instead.

  //RTID = 1.
  $content = facebook_status_get_rel_status(1);
  $content = facebook_status_list_render($content);
  if ($content) {
    $content = '<div class="facebook_status_block_rel">'. $content .'</div>';
    echo $content;
  }
Rosamunda’s picture

THANK YOU VERY MUCH ICE!
And thank you very, very much for the variable´s explanation. I´m studying php, but it´s pretty hard to understand how variables work :)

Again, many thanks! I´m changing it right away!!

Rosamunda

icecreamyou’s picture

Status: Postponed (maintainer needs more info) » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.