Search Results for 'code'
-
AuthorSearch Results
-
January 27, 2010 at 2:50 pm #84367
In reply to: @ links (mentions)
Gautam
MemberReplying to kevinjohngallagher’s post (maybe its in spam, but I got an email notification as I am subscribed to topic):
1) Making “@” links is cool, and very “twitter generation”, even if its not something that’s totally globalised yet. But the “@” link is not pointing at what you’re replying to. We’re faking the functionality without the reasoning, which in the end will just confuse users.
On Twitter, you post on your profile page. People read it on their feed, and reply on their own Profile page. So a link to “@kev” goes to the page where “kev” has written his post. That’s the point of it, to link to someone’s post.
Here, we’re making the link “@kev” go to “/profiles/kev/” for the user to not see the post. That’s exactly the opposite of the purpose of the “‘@” linking system

–> That’s basically the work of a reply plugin, not of a mentioning plugin. I also have future plans with the plugin like linking
#tag, etc. Even if I do something like that which you have mentioned, then a single user can make multiple posts, then which post will the plugin link to?2) The other issue is that Twitter names don’t have spaces, while BBpress / wordpress names can. So if i write “@Michael R Thanks for your reply”, how does the plugin know where the username ends? What if it finds a “michael” in the usertable, it will then link “@Michael” to “/profiles/michael/” and the message will read “R Thanks for your reply”. In Twitter, it parses at the first space; but we can’t do that here.
Oh that will also involve looping through queries until you find a match, so first for Michael, then for Michael R, then for Michael R Thanks etc. Ofcourse there could/should be a word/search limit – either way there is huge potential for database issues there. Imagine adding up to 5 sql searches, per “@” per post, per page load.
The initial solution, and i suppose this is for Gautam, is to make a search of the user table for all users who have posted on the topic being replied to, which should narrow it down considerably, though it should be noted that if you have “Michael” and “Michael R”, or any similar naming issues, the plugin will not know that…
–> That can’t be helped. The plugin first checks if that username exists, if not, then checks if that nicename exists. This will be also mentioned on the plugin page.
3) You are effectively allowing a user to search your database for anything you put after your “@” symbol. Now this one is a little bit of scaremongering, but we’ve all seen bad coding before. What if I write “@drop table wp_usermeta hi bob, how much fun would this be
“. There is a reason that we try to make sure we don’t take database queries from the user.–> 1) This is what is used to match the username – /[@]+([A-Za-z0-9-_]+)/, so there is no point of mysql commands going in there.
If you want to test the plugin (how it works), you are free to use this as sandbox – http://forum.gaut.am/
I have made some posts to test the plugin here.
January 27, 2010 at 2:05 pm #84364In reply to: @ links (mentions)
Michael
ParticipantNice
January 27, 2010 at 2:03 pm #78849In reply to: Loading bbpress after codeigniter
tobefound
MemberDid you get things working? Me too interested in getting a simple and clean forum working with an existing login system on codeigniter.
/T
January 27, 2010 at 1:53 pm #84362In reply to: @ links (mentions)
Michael
ParticipantGreat – thanks Gautam. Looking forward to it.
(Are you maybe calling it bbMentions?
)
January 27, 2010 at 11:58 am #84358In reply to: @ links (mentions)
kevinjohngallagher
MemberBBprogress had two versions of this one mate, they should still be kicking around somewhere. The first one used Ajax to convert the links (it pinged a search page for @username).
That said… My issue with it at the time is my issue with what you’re trying to achieve as well. 9/10 when someone is typing “@Michael R” they are replying to a post above. To that end, the “@Michael R” should link to that post, not to the person’s profile page. What you effectively need is a “reply to” button as well as a “quote” button that pre populates the “@Michael R” information.
Writing that functionality isn’t a problem (check out the quote plugin), but rather that there is no hook in BBpress that doesn’t hardcode output from the core to the bottom of each post. Not only would you need a plugin, but you’d also need a theme with additional hooks/function calls.
Its definitely doable though, once yu have defined exactly what it is you’re after/the need is for it
January 27, 2010 at 7:04 am #84357In reply to: @ links (mentions)
Michael
ParticipantRight, I have looked at the Easy Twitter Links plugin, but I’m not sure how to alter it to run through the post. I’d probably have some idea if I managed to find the code BuddyPress uses. I wish I could grep the folder, but I don’t have Linux…
January 27, 2010 at 6:31 am #84356In reply to: @ links (mentions)
Michael
Participant@OKTeaRoom – I will have a look at that – though I’d also need to find out how to check for member existance.
@etiviti – Thanks, I’ll download it and run through the code. I’m sure it’ll be easy to make the plugin.
January 27, 2010 at 5:31 am #83770In reply to: no WP backend interface
rohanduggan
MemberSounds cool, thanks for the info. Sorry for the redundant post in that case… I thought somebody had just not updated the message assuming (and we know what they say about assumptions:)) that if the plug in was searchable via WP backend with an install button that it might be installable. My enthusiasm (desperation) for a decent BB for WP got the better of me
January 26, 2010 at 11:16 pm #84355In reply to: @ links (mentions)
rich! @ etiviti
Memberif you look at the buddypress code for activity-notifications (can’t remember the filename) but they have a simple function that filters the content, checks for @<username> string, then validates against the usertable and rewrites the content with a link.
January 26, 2010 at 7:51 pm #32936Topic: @ links (mentions)
in forum ShowcaseMichael
ParticipantHave been working on my forum recently, and I have though tof something I’d like to add to it.
Now, I’m no plugin developer, or PHP junkie, but I’d like to know what steps would be needed to turn @ links (mentions, like those found on Twitter) into links that take the user to a members profile page/or maybe even the member’s website (if any).
Example:
‘@matt’ would become ‘@matt‘
It would obviously have to scan through the post, check for any mentions, check if the user exists, and if it does, then apply the link. Now, I have no idea how this would be implemented – I hope to learn more soon.

This may not be a very great idea to have for a bbPress forum, but I think it would be nice. Could anyone help me with this?
Peace, Michael
January 26, 2010 at 6:05 pm #84176In reply to: Thanks plugin
January 26, 2010 at 4:40 pm #82537In reply to: wp integration cookie does not work
gerikg
Member1. Shut off your caching plugin first.
2. You didn’t follow #8 correctly. “define(‘COOKIEPATH’, ‘/’ );” should be after
?phpif it doesn’t work email me (on my profile)
January 26, 2010 at 7:23 am #84174In reply to: Thanks plugin
Michael
ParticipantSounds great Paul – love the way you go beyond with plugins. Thank you for that.

That wouldn’t be a problem; I’m always tweaking my theme files to make it all just look better.
January 26, 2010 at 1:07 am #84312Sabuntu
Memberactually he was cooperative and tried to explain as simple as he could but i’m not that clever to catch him up
January 26, 2010 at 12:06 am #76706Damien
MemberInstantly knocked 3 queries from my mainpage, thanks
January 25, 2010 at 9:12 pm #84322In reply to: Parse error on install
Ipstenu (Mika Epstein)
ModeratorTextWrangler for Mac.
January 25, 2010 at 8:37 pm #84269Dailytalker
MemberDid you follow the steps decribed in this topic?
Did you install the plugin?
Did you change the permalinks to “name” before activating the plugin?
Did you change the codes in your htaccess?
Did you write as rewrite base /?
Thats what I have in the htaccess of my wp-frontpage:
RewriteBase /
So it really must work. I am pretty sure.
January 25, 2010 at 8:10 pm #84263Dailytalker
MemberWhat you can do is what I have….
1st step
Download the plugin, you find on the link bellow and follow the instructions on that site:
2nd step
If the name of your forum is “forums” you need to name the RewriteBase /forums/
RewriteBase /forums/
If the name of your forum is “community” your RewriteBase is /community/
RewriteBase /community/
etc.
3rd step
After you have followed the steps of that site you will find some bugs. To solve them do the following:
To solve the major bugs you need to do this:
I found a solution for the admin-backend link!
Just ad the following code
RewriteRule ^bb-admin/$ – [L]
before this code
RewriteRule ^([^.]+)/([^.]+)/page/([0-9]+)/?$ topic.php?id=$2&page=$3 [L,QSA]
and it works!!! Cool.
I found another mistake. The “topics-RSS” where missing because you deleted one rewrite mod too much. To repair this you need to put the following code just after the mod rewrites for “view”
RewriteRule ^rss/topics/?$ rss.php?topics=1 [L,QSA]
original code:
RewriteRule ^rss/topics/?$ /forum/rss.php?topics=1 [L,QSA]
Than also the rss-feed for the topics should work.
January 25, 2010 at 6:42 pm #84171In reply to: Thanks plugin
pengerik
MemberPlease share if/when available! Been looking for this some time…
January 25, 2010 at 6:02 pm #84170In reply to: Thanks plugin
Gautam
MemberI had actually created this sort of plugin once for a forum, but didn’t release it publicly. When I get time, I might extract out that part and release it.
Edit – If Paul doesn’t do it first
January 25, 2010 at 5:44 pm #84169In reply to: Thanks plugin
Michael
Participant@paulhawke – sounds great, can’t wait to see it.
Now, are you going to be making it a “like” this post, or a “thank you” for this post plugin?
January 25, 2010 at 5:40 pm #76941In reply to: Display a list of recent topics
chandersbs
MemberThanks Chris and everyone, I will test Kevin’s code tonight and see how it works.
Keep you guys posted
January 25, 2010 at 5:02 pm #84283paulhawke
MemberI think there are a number of big architectural hurdles to get over. In WP I bind a given slug to a page on a 1-to-1 basis, and that’s what is used to resolve a given URL. If I have a forum I would want “virtual page slugs” where anything starting with (say) “/forum” is passed to my plugin for resolution of the rest. The URL processing in WP is messy (to say the least) and is a perfect example of the opposite of the “Open/Closed” OO design principle – “Closed to modification but Open for extension” – I imagine that a rewrite of that code would go a long way to improving WP itself.
If bbPress were hosted on a single page using a WP shortcode, then the entire GUI needs to be re-coded to run fully AJAX as the user will need to remain on that particular page.
January 25, 2010 at 4:50 pm #84295In reply to: I have decided to write my own WordPress Plugin
paulhawke
MemberOr, like me, you can grep the bbPress source for “do_action” and “apply_filter” to see what the code does. In any case, the code itself is the best documentation.
January 25, 2010 at 4:50 pm #84327In reply to: Administration of bbPress in Buddypress
Ipstenu (Mika Epstein)
ModeratorOriginal topic on BuddyPress: https://buddypress.org/forums/topic/how-to-create-forums-in-bbpress-within-buddypress
Windhamdavid’s awesome solution link: https://buddypress.org/forums/topic/how-to-access-to-bbpress-admin-from-buddypress
-
AuthorSearch Results