Add Friend – not adding
Just installed BP RC1 on WPMU 2.7.
Seems to work great but am experiencing a problem with the “Friends” module.
When I log in I go to “My Account”->”Friends”. It shows a list of people I could add as friends. Next to each person is the “add friend” button. When I click it, it the icon changes to the “working” icon, but it never stops. So graphically, it looks like it is doing something but never stops, and the friend doesn’t get added (nor does the recipient get a Friend request).
I’d provide logs – just not sure what you would need – I’m running it on a cpanel server.
Thanks in advance,
Oh. So that is your site. Wasn’t really reading it properly. Sorry. No, no way to just flip a switch in the backend that I’m aware of. Lemme go try this on your site and see what firebug says. Gotta look at it and all the other environmental things going on.
@awarner20 working on your problem now. Got an idea now that I have a reproducible problem. Hang in there.
http://jurnl.com/wp-content/mu-plugins/bp-core/bp-core-ajax-handler.php is a 404 on mine and modemlooper’s
I tried the same URL but for testbp.org:
And it certainly finds it. I can’t imagine why it doesnt like accessing the files in that directory under our servers. Incidentally, I can access the images directly under the bp-core/images directory. Just not the PHP file.
heres another thing…when the group wire gets paginated the links are this. Is that right?
so what I did was move the file to the root and rewrote the code butadsit said to reflect the new location and bingo! worked
ok so when moving the file it allows the ajax to finish but does not change the result. when you click popular or another link it just refreshes but does not up date the content.
group wire pagination threw this back
Warning: require_once(/home/content/t/w/i/twitterfic/html/bp-core-ajax-handler.php/wp-load.php) [function.require-once]: failed to open stream: Not a directory in /home/content/t/w/i/twitterfic/html/bp-core-ajax-handler.php on line 3
Fatal error: require_once() [function.require]: Failed opening required ‘/home/content/t/w/i/twitterfic/html/bp-core-ajax-handler.php/wp-load.php’ (include_path=’.:/usr/local/php5/lib/php’) in /home/content/t/w/i/twitterfic/html/bp-core-ajax-handler.php on line 3
@awarner20 your problem with the email friendship requests is a bug. Can’t be solved with a one liner. Sorry. I did submit a workaround patch in trac though:
It eliminates the problem by eliminating the problem. Lemme explain. When a user requests friendship an email is sent out to the destination user. The destination user is supposed to click the link and it automatically approves or rejects the request. Doesn’t work due to the fact that a security mechanism is being used to validate the process. The ‘nonce’ security scheme uses the originating user’s identity and some other stuff to come up with this ‘nonce’ key. The key is only valid when used by the originating user.
When the destination user clicks on the link the key is used but they are not the originating user. So the security check fails. Andy is aware of the problem. I just removed the automatic accept/reject links and used a link to the destination user’s friendship notifications page where it will have to be manually accepted or rejected.
Just a thought: I notice the other settings in bp-core-cssjs use the wp_enqueue function whereas the ajax one just echo’s a var definition. Not sure if that could be a cause or not?
modemlooper, the wire pagination link is not the one you mentioned above. It should be:
I’m on my way to look at your site now. I looked at Chris’s already. Can’t determine the problem just by looking at it though. At least not yet.
Gimme a few.
modemlooper, can you put things back to the way they were on your site please. Gotta check it the way it’s supposed to be. bp-core-ajax-handler.php
Thinks are kinda funcky there now.
Chris, looking at your site again. Why is it coming up 404? I have to work through the sequence from the member theme to bp trying to load that file. Working on it..
Got it back to normal was just trying to see if it was the location….weird that it could find file when moved but not when in that folder.
Thanks so much for helping.
Burtadsit and others: Good news is it’s working! – and I owe you a big apology if I’ve sent you spinning of in random directions.
I know you asked for 755 a hundered times. Given the 404 I triple checked this. As a long shot, I downloaded a different FTP client and set it to chmod 755 from mu-plugins all the way down, recursively and to files and subirectories. Even though I did with my previous FTP client, apparently it didn’t do a good job.
so, I download Filezilaa and it seemed to do something the other FTP client didn’t. Modemlooper – I explicitly previously granted that directory and that file 755 access but that didn’t work until I did this recursive chmod on all of it.
Burtadsit – thanks so much for your time and please accept my apologies since this was effectively user error (though I can blame it on the crappy FTP tool!)
I’m a happy camper now!
modemlooper, try what I did since we have the *exact* same problem.
err…following from my previous post, the whole ajax thing is definitely working. I get the notification email etc. The other person can accept the friendship request etc.
One thing and I can open a seperate thread so not as to derail this one until modemlooper has his problem resovled, but, when I click the link inside the email:
To accept the friend request, The browser spawns and redirects the URL to:
But that causes a 404. (just going to wp-login works but with the ?redirect part I get a 404).
ok downloading that client…I chmoded recursively too.
Ya had to say that didn’t you modemlooper? Glad it was fixed Chris. Sometimes that’s the way things go. I got to learn more about firebug and the friends component that I’ve successfully ignored until now.
OK. Back to modemlooper now.
modemlooper, I just realized that you are running a modified members directory page. In the members directory the pagination action is being triggered and it’s getting back the correct response for that action. For instance going to page #2 of the member list. But it’s not getting displayed. More than likely it’s due to the structure of the page being different. The js that handles the response that comes back from the server doesn’t seem to know what to do with things now.
Can you replace the current directory with the standard directory? We can try to narrow things down then.
not sure what you mean? do you want me to put the letters back?
Put letters back but the problem is that this file for some reason can’t be found in its current location. I moved the file and relinked the code to it. Then the ajax worked fine but it caused some other errors as i’m sure other files relied on its original location.
Ya. Thanks. The letter search for members is the easiest to test. Saves on all the join/leave for groups or friendship requests. Thanks.
modemlooper, can you disable all other js and plugins temporarily? Google analytics and that sharethis widget. Everything seems to be working, you are getting the correct results back to the browser from the ajax calls but the js in bp is not functioning after the call.
You are getting results but not displaying them.
ok disabled the pugins…but not sure if there is any other js to disable.
Ok. Thanks. Didn’t make any difference at all. Put everything back.
I’m at a loss here guy. The only other suggestion I have to solve the 404 is to go into root and check the ownership and permissions of that directory and file. Can’t see ownership in an ftp client.
I’ll ask some others to stop by this thread and take a look also.
The topic ‘Add Friend – not adding’ is closed to new replies.