News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Ultimate Profile

Started by JovanT, March 12, 2009, 12:14:40 PM

Previous topic - Next topic

hcfwesker

Quote from: funkythemunky on January 26, 2012, 10:33:21 PM
Sorry I don´t know if it has been asked yet but why as admin can i not add users to my buddy-list?  ???

Does it not send them a request.  buddies wont be added until they accept your buddy request.

funkythemunky

#2821
No there is no button for adding a user a friend.

Some users can add users as buddies, some users can not, that is strange..
And so some still can view Karma, others don´t...

I checked all the permissions.

Perhaps I try to reinstall...

edit: Nah it´s even something else as well, some users can be added, some can´t. Something seems to be mashed up... o.O

I try reinstall first I think.

edit2: May it be it interferes with existing users that already were added as friend or sth like that?

edit3: You´re right sorry, deleted the other ones.

fullmoonya

funkythemunky, please do not post many times in a thread. you can modify your post and add something if needed.
do not mark my topic solve unless it is REALLY SOLVED.
my forum

Visit My Blog:
Google SEO Share

GSM-S

I have sercuity concerns with the mod when I saw that HTML and CSS codes are supported. What codes are supported?

hcfwesker

html and CSS lol, but just for profile pages.  kinda like customizing a profile on VB forums, or myspace

Quexinos

Okay so... I installed this and apparently my users who have added buddies prior to this mod don't have those added buddies in their buddy list and they can't remove or add them... any idea how to fix this?

fullmoonya

Quote from: Quexinos on February 27, 2012, 01:23:22 AM
Okay so... I installed this and apparently my users who have added buddies prior to this mod don't have those added buddies in their buddy list and they can't remove or add them... any idea how to fix this?
try this one posted by punja..

Quote from: punjabilokvirsa on January 17, 2012, 08:02:05 PM
I've discovered a bug in the code of Ultimate Profile 0.9.1 (don't know about previous versions). It was creating empty buddies in the buddy_list field of smf_members table when the person added their first buddy. This in turn meant that UP's code to check if guests should be allowed see the other person's UP or their pictures was always true. In other words, guests could see the locked pictures.

The problem is php's explode function:
explode(',', '')
creates
array(1) {
  [0]=>
  string(0) ""
}


But the developer's code (and normal human beings) expect it to be:
array(0) {
}


So to fix, change line 365 and 404 from:
$buddies = explode(',', $user_profile[$_GET['u']]['buddy_list']);
to:
$buddies = array_filter(explode(',', $user_profile[$_GET['u']]['buddy_list']));

In English, array_filter removes the bogus entry.

But that's not all folks, if you've used this mod for a while, you will also need to run a script to cleanup all the empty entries that have corrupted your users. To do this, run the following code in the root forum directory (comment out the updateMemberData line if you want to see what it does). Remove it when done, please.

<?php
require_once 
'SSI.php';
$space "<br />\n<br />\n";


$request $smcFunc['db_query']('''
SELECT id_member, buddy_list
FROM {db_prefix}members
ORDER BY id_member ASC'
,
array()
);

while ($row $smcFunc['db_fetch_assoc']($request)) {
if ($row['buddy_list']) {
$exp explode(','$row['buddy_list']);
$fil array_filter($exp);
if (count($exp) != count($fil)) {
echo "$space {$row['id_member']}: ";
var_dump($row['buddy_list']);/*
echo "$space exp:";
var_dump($exp);
echo "$space fil: ";
var_dump($fil);*/
echo "$space fixed: ";
$fixed implode(',',$fil);
var_dump($fixed);
echo "$space";
if (function_exists('updateMemberData')) updateMemberData($row['id_member'], array('buddy_list' => $fixed));

}
}
}

$smcFunc['db_free_result']($request);

do not mark my topic solve unless it is REALLY SOLVED.
my forum

Visit My Blog:
Google SEO Share

Blah blah

What would cause overhang like this on my forum?

http://imageshack.us/f/444/profile2j.png/

any guesses?

fullmoonya

Quote from: Blah blah on March 01, 2012, 10:03:09 PM
What would cause overhang like this on my forum?

http://imageshack.us/f/444/profile2j.png/

any guesses?
maybe the file is too big and the server was having hard time to load those content.
do not mark my topic solve unless it is REALLY SOLVED.
my forum

Visit My Blog:
Google SEO Share

hcfwesker

yeah, the super duper sized image in your signature is definitely causing it.

visualuser

Quote from: punjabilokvirsa on January 17, 2012, 08:02:05 PM
I've discovered a bug in the code of Ultimate Profile 0.9.1 (don't know about previous versions). It was creating empty buddies in the buddy_list field of smf_members table when the person added their first buddy. This in turn meant that UP's code to check if guests should be allowed see the other person's UP or their pictures was always true. In other words, guests could see the locked pictures.

The problem is php's explode function:
explode(',', '')
creates
array(1) {
  [0]=>
  string(0) ""
}


But the developer's code (and normal human beings) expect it to be:
array(0) {
}


So to fix, change line 365 and 404 from:
$buddies = explode(',', $user_profile[$_GET['u']]['buddy_list']);
to:
$buddies = array_filter(explode(',', $user_profile[$_GET['u']]['buddy_list']));




try to find which file i should change the code, but i did not find anything....
i have problems with buddy functions....
old members cannot add new ones...
i assume that i must make all this changes that describe above,
is this correct?

LVBadman

Hello world.

Very great mod. But I have one problem.

in the user profile is a media box, as I have installed aeva gallery 1.4w and it shows tags like: [smg id = 102 type = av],
how to make a box appear in the media player and not just text. Now shows like this:



But I want to be like this:



Is it real?

SMF - 2.0.2
Aeva - 1.4w
UP -   ultimate_profile-0-9-1_20

visualuser

Quote from: LVBadman on March 02, 2012, 03:30:46 PM
Hello world.

Very great mod. But I have one problem.

in the user profile is a media box, as I have installed aeva gallery 1.4w and it shows tags like: [smg id = 102 type = av],
how to make a box appear in the media player and not just text. Now shows like this:



But I want to be like this:



Is it real?

SMF - 2.0.2
Aeva - 1.4w
UP -   ultimate_profile-0-9-1_20


you must find the right code of what you like to put,
try this code to see what you get

<object width="480" height="385"><param name="movie" value="http://www.youtube.com/v/XmSdTa9kaiQ?fs=1&amp;hl=el_GR" /><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><embed src="http://www.youtube.com/v/XmSdTa9kaiQ?fs=1&amp;hl=el_GR" type="application/x-shockwave-flash" width="480" height="385" /></object>

LVBadman

In that way working. But I want to add media files from aeva library.

fullmoonya

#2834
Quote from: visualuser on March 02, 2012, 01:42:52 PM
Quote from: punjabilokvirsa on January 17, 2012, 08:02:05 PM
I've discovered a bug in the code of Ultimate Profile 0.9.1 (don't know about previous versions). It was creating empty buddies in the buddy_list field of smf_members table when the person added their first buddy. This in turn meant that UP's code to check if guests should be allowed see the other person's UP or their pictures was always true. In other words, guests could see the locked pictures.

The problem is php's explode function:
explode(',', '')
creates
array(1) {
  [0]=>
  string(0) ""
}


But the developer's code (and normal human beings) expect it to be:
array(0) {
}


So to fix, change line 365 and 404 from:
$buddies = explode(',', $user_profile[$_GET['u']]['buddy_list']);
to:
$buddies = array_filter(explode(',', $user_profile[$_GET['u']]['buddy_list']));




try to find which file i should change the code, but i did not find anything....
i have problems with buddy functions....
old members cannot add new ones...
i assume that i must make all this changes that describe above,
is this correct?

try to find the codes in buddies.php in source directory and look for the codes there.

EDIT:

look only for this codes, it is in line 365 and 404:
$buddies = explode(',', $user_profile[$_GET['u']]['buddy_list']);

and change those to:
$buddies = array_filter(explode(',', $user_profile[$_GET['u']]['buddy_list']));

do not mark my topic solve unless it is REALLY SOLVED.
my forum

Visit My Blog:
Google SEO Share

visualuser

[quote author=fullmoonya link=topic=298641.msg3286153#msg3286153
try to find the codes in buddies.php in source directory and look for the codes there.

EDIT:

look only for this codes, it is in line 365 and 404:
$buddies = explode(',', $user_profile[$_GET['u']]['buddy_list']);

and change those to:
$buddies = array_filter(explode(',', $user_profile[$_GET['u']]['buddy_list']));
[/quote]


many thanks, it was very easy.... :)

but i must run a script as described?
How can i do this?
should i make a php file and run from my browser?
i am a bit confused.....

Quexinos

#2836
Quote from: fullmoonya on February 28, 2012, 11:08:27 PM
Quote from: Quexinos on February 27, 2012, 01:23:22 AM
Okay so... I installed this and apparently my users who have added buddies prior to this mod don't have those added buddies in their buddy list and they can't remove or add them... any idea how to fix this?
try this one posted by punja..

I would if I knew what file to edit

EDIT
oh it was buddies.php okay... I ran the script too, I just uploaded it as test.php ... that should do it right?

visualuser

Quote from: Quexinos link=topic=298641.msg3286808#msg3286808I ran the script too, I just uploaded it as test.php ... that should do it right?


i also run the script.... and here is my result:

139: string(3) ",42"

fixed: string(2) "42"



164: string(2) ",4"

fixed: string(1) "4"



180: string(2) ",2"

fixed: string(1) "2"



323: string(17) ",14,160,160,301,4"

fixed: string(16) "14,160,160,301,4"


is that mean that works ok?
i am wondering if i finish with this or not...

Quexinos

Okay it didn't work, some users still can't add buddies...

any other ideas on how to fix this?

pixeleyes

RECENT PROFILE VIEW

How to add Recent Profile View block in ultimate profile?

Advertisement: