Forum Replies Created
-
In reply to: Group Blog + P2 or Posthaste
Thanks for the suggestion + info Erich73. I sent him an email.
EDIT: He already answered:
Unfortunately I don’t have a good answer for you. Buddypress already works like P2 in so many ways – have you had a look at BuddyPress 1.2?
My best suggestion is just to dig through the source, especially the javascript and php -> javascript files. They’d leave you with the best clue.
Although, I think BuddyPress probably has all of your needs covered.
Dead end…
In reply to: Normal WordPress Themes?Would this plugin also help in upgrading a custom Buddypress 1.1.3 theme to 1.2?
I’ll try that later this week…
In reply to: STOP feature-polls for BP 1.3Privacy, advanced xprofile fields and front-end posting have to do with cleaning up loose ends in existing core functionality; access, member management, usability, etc. They are not in the same category as requesting a gallery or event management feature.
The polls are silly window dressing. The last one was largely ignored. Probably rightly so. We don’t pay Andy’s rent, Automattic does. Don’t pretend like we’re some hippy commune ruled by consensus.
In reply to: STOP feature-polls for BP 1.3@Xevo, I’m pretty sure Erich73 was not asking for a poll plugin. I think his comment was about the relative pointlessness of open polls for new features, when there are still many core issues that should be fixed first.
I remember we’ve gone through this over six months ago, also with a poll and promises that certain features, like privacy, would become core in version 1.2 and 1.3. Very little of that has materialized.
… I can see that users of wordpress/buddypress wanting the wp-admin to be only for admins as the name suggests and keep the users off the creepy admin panel.
Absolutely. That’s why I’m trying to sort out front-end posting with P2 and/or Posthaste. Raoulduke is working on it as well.
In reply to: STOP feature-polls for BP 1.3Totally agree, Erich73.
I’d also add privacy (making parts members-only etc.), another core feature that was promised a year ago and again after polling last Fall, but disappeared from the priority list for 1.2 and 1.3. Poor Jeff Sayre has been struggling with that without any support from Automattic.
‘User-Blogs-Posts from Front-end’ can be done in most places by integrating the P2 theme or using the Posthaste plugin. Both work fine on regular blog index/home pages.
I’m trying to get it to work on the group blog homepage. No luck so far. Will post for download today or tomorrow two versions of the excellent bp-groupblog with P2 and Posthaste code integrated, as far as I can figure them out. I will need some help fixing them.
In reply to: BuddyPress MapsGrosbouff, are you aware of the Geo Mashup plugin. Couldn’t you leverage that?
I installed and activated Geo Mashup site-wide, but then it asks all the member blogs for their own Google API code in the wp-admin, which is annoying and will confuse many users.
Haven’t had time to test your plugin yet, but if it does the same as Geo Mashup, I’d rather have a cleaned up BP-ready version of Geo Mashup.
In reply to: buddypress + p2 theme@raoulduke, I did get Posthaste working. I had the tag in the wrong place. It really needs to be right before the loop.
P2, Posthaste, the TDO Mini Forms plugin all work fine on regular blog index pages, but I can’t get any of them to work on the Group Blog. There is a referral check problem or the form can’t find the right blog ID.
In reply to: notifications not being sentWhat does Peterverkooijen mean when he says “copying an earlier version of an entire template folder solved the problem”
That the problem was probably caused by mistakes in a custom theme and had nothing to do with the IntenseDebate plugin. I always save older versions, so I can put old template files back when I screw up.
In reply to: Group BlogTried Posthaste again. Got it to work this time – I had the tag in the wrong place…
But it basically has the same problem as P2; it doesn’t work on the group home page (with Group Blog), only on a regular blog index page.
I suspect the problem is mismatching referrers or something like that. If anyone has any clue how to fix that or what to look for, please let me know.
In reply to: Privacy+4
In reply to: Group BlogJust noticed that the author links produced by P2’s entry.php look something like this:
http://mywebsite.com/testgroup/blog/author/admin/The ‘/blog’ is not supposed to be there! It’s apparently generated by $wp_rewrite WP_Rewrite in /wp-includes.
P2 apparently uses standard single WP tags that produce links that in some cases end in /blog. That would explain why posts end up on the default blog when I turn on the javascript.
What would these tags be? Are there WP tags or functions that produce links with ‘/blog’?
Is there good catch-all way to replace these links with WPMU/BP equivalents?
In reply to: Front End Blog Posting+1
I’m working on integrating P2 into the Group Blog plugin here.
I got it working without Ajax, but as soon as I add the javascript, posts from the P2 post-form end up on the main blog. Can’t figure it out. Any pointers very much appreciated…
BTW, couldn’t get Posthaste to work. P2 looks like the way to go, with Automattic behind it.
In reply to: Group BlogI’ve now integrated P2 by adding the theme to the /bp-groupblog/groupblog folder, editing these lines in P2’s functions.php and copying P2’s index.php main code to Group Blog’s blog-latest.php – with some cleanups…:
define( 'P2_INC_PATH', WP_PLUGIN_DIR . '/bp-groupblog/groupblog/inc' );
define( 'P2_INC_URL', get_bloginfo('url').'/wp-content/plugins/bp-groupblog/groupblog/inc' );
define( 'P2_JS_PATH', WP_PLUGIN_DIR . '/bp-groupblog/groupblog/js' );
define( 'P2_JS_URL', get_bloginfo('url').'/wp-content/plugins/bp-groupblog/groupblog/js' );It works very nice without Ajax, by disabling js in that last line. The P2’s post-form then posts to the correct blog. That is already a huge user interface improvement; group members don’t have to go into wp-admin to post on the group blog.
Unfortunately when you fire up the .js Ajax magic, posts still end up on the main blog. So the problem is somewhere in the Javascript;
– the blog ID (?) does not make it into the javascript?
– or the javascript has a default blog ID somewhere?
– or the javascript identifies the blog based on the URL where it comes from, which is a group page, so it adds the post to the default URL instead?
Which hypothesis is right? Or something else entirely? Where should I look to fix it? Probably somewhere in P2’s javascript files.
Any help very much appreciated!
EDIT:
Without Ajax only content from the first tab in P2’s post-form, Status Update, is posted. If you use the Blog Post tab it forwards to the blog home page, but the post isn’t there.
Posts also end up in Uncategorized, instead of the Status category. Comments on all posts are closed, can’t figure out why or how to turn them back on.
In reply to: Group BlogThere may be some clues here how to make P2 work outside the regular blog index.php.
@dlittle800, the welcome email text in under Site Admin -> Options -> Welcome User Email
In reply to: buddypress + p2 themeNow trying Posthaste again. Removing that line removed the post form from all the loops, but putting this line in the template files does nothing:
<?php if(function_exists(posthasteForm)) { posthasteForm(); } ?>I tried in several files, including regular blog index.php files. Also tried this:
<? posthasteForm(); ?>Still nothing… And if I leave the add_action(‘loop_start’… and just use the form, nothing gets posted, not even on the main/default blog.
I think I’m closer to a solution with P2, if somebody can help me figure out how to use the P2 post-form from a page that is not the regular index.php of the blog.
Is there an example of that in Buddypress version 1.2?
In reply to: Group BlogIs this the function (from p2/inc/ajax.php) that handles data from the P2 post form?:
function save_post() {
check_ajax_referer( 'ajaxnonce', '_inline_edit' );
if ( !is_user_logged_in() ) {
die('<p>'.__('Error: not logged in.', 'p2').'</p>');
}
$post_id = $_POST['post_ID'];
$post_id = substr( $post_id, strpos( $post_id, '-' ) + 1 );
if ( !current_user_can( 'edit_post', $post_id )) {
die('<p>'.__('Error: not allowed to edit post.', 'p2').'</p>');
}
$new_post_content = $_POST['content'];
// preserve custom "big" titles
$post = get_post( $post_id );
if ( !$post ) die('-1');
$clean_title = str_replace( '…', '', $post->post_title );
if( strpos($post->post_content, $clean_title ) !== 0 ) {
$post_title = $post->post_title;
} else {
$post_title = prologue_title_from_content( $new_post_content );
}
$post = wp_update_post( array(
'post_title' => $post_title,
'post_content' => $new_post_content,
'post_modified' => current_time('mysql'),
'post_modified_gmt' => current_time('mysql', 1),
'ID' => $post_id
));
$post = get_post( $post );
echo apply_filters( 'the_content', $post->post_content );
}How does this function know which blog to store the data in?!
I guess my problem has to do this:
check_ajax_referer( 'ajaxnonce', '_inline_edit' );What does that do?
There is also a function new_post() that has this:
if( 'POST' != $_SERVER['REQUEST_METHOD'] || empty( $_POST['action'] ) || $_POST['action'] != 'new_post' ) {
die('-1');
}That has to do with matching referrers etc, right?
Any pointers and ideas appreciated…
In reply to: buddypress + p2 themeOK, thanks Scotm!
I guess my problem is not so much getting P2 to work within Buddypress and customizing it, but how to use on the Group Blog homepage.
I may need to test install version 1.2 to see how it uses the post-form. And Posthaste may be a simpler starting point for my problem. Thanks Symm2112!
In reply to: Group BlogI’m trying to integrate the P2 theme. If you use P2 as the group blog theme it works fine, although you may want to customize the layout etc. to bring it into the BP environment.
But I’d like to use the ajaxified microblogging interface on the group homepage (template /groups/single/home.php). I’ve figured out how to get P2 post form there, but Ajax is broken and all posts end up on the main blog.
I guess the problem is the URL of the page where it’s send from doesn’t match the blog. For example, the group blog home is here:
http
/mysite.com/groups/testgroupand the associated group blog is here:
http
/mysite.com/testblogIs there a way to tell the script to treat data from the post form on …/groups/testgroup as if it is coming from …/testblog? And …/testblog should of course be some kind of tag, like bp_the_site_blog_link() (?) that enters the correct associated blog_url into the process.
Or is there another approach?
In reply to: What are you doing for Spam@Bbrian017, you have to add that line to wp-config.php yourself + a few other things. It’s explained here.
It’s a bit of a hack, so I think it would be good if it became part of the basic setup, maybe at installation (wpmu).
In reply to: buddypress + p2 themeScotm, where can I find Andy’s how-to and that Buddypress theme extension pack? Will it work for version 1.1.3?
Either way I’d like to learn more. I’m halfway integrating P2 into my custom theme, but can’t get the Ajax editing to work and all posts end up on the main blog instead of on the group or member blog.
Yes Symm2112, also definitely interested in your code. I’ll give Posthaste another try with your info. Perhaps I can put a new hybrid with Andy’s P2 solution together, that I will post here.
Thanks!
EDIT: Is P2 integrated in the version 1.2 custom theme? Anyway, I want to use that ajaxified microblogging interface on the group blog main page in a heavily customized version 1.1.3 theme and keep the blogs looking like blogs.
In reply to: buddypress + p2 themeJust tried Posthaste. It adds a P2-derived post form at the top of every loop – and I mean literally every loop in the site, including member loops and group loops. And it doesn’t seem to work either.
Has anyone else tried P2 within Buddypress by now, in particular on member blogs and group blogs? I’m working on it, but got stuck…
I always use the confirmation emails in my inbox as a way to keep track of passwords I used on sites I signed up with. Sending the login credentials in a confirmation email, including the password, serves a real purpose. That’s why most websites still do it that way.
I understand there are security objections to sending out passwords, but I am not running a banking site. Making it easier for members to access my site is a higher priority. Not being able to send them the password in a confirmation email is very annoying.
Also, if you run a community that actually does stuff, like organize events, you want to send new members a friendly welcome mail with some practical info. Why the hell disable the welcome email as a “core feature”?!
Add this to the main plugin file bp-groupblog.php:
/*** Make sure BuddyPress is loaded ********************************/
if ( !function_exists( 'bp_core_install' ) ) {
require_once( ABSPATH . '/wp-admin/includes/plugin.php' );
if ( is_plugin_active( 'buddypress/bp-loader.php' ) )
require_once ( WP_PLUGIN_DIR . '/buddypress/bp-loader.php' );
else {
return;
}
}
/*******************************************************************/Working on Group Blog here…