Forum Replies Created
-
In reply to: bbpress plugin: register_activation_hook
By the looks of it, it’s an action that’s called as
bb_deactivate_plugin_$plugin
, so the action hook’s name is specific to the plugin. The$plugin
value is shown in the URL for activating a specific plugin.In reply to: Making `from` a link in Topic ViewI find looking at a bbPress install database pretty unnerving with all the relational IDs around the place
In reply to: Making `from` a link in Topic ViewOh, that’s
get_user_profile_link( $topic->topic_last_poster )
then it seems that usernames don’t contain spaces (only the display name does), the username is converted to using a – instead of any invalid charactersIn reply to: Making `from` a link in Topic Viewget_user_profile_link( $topic->topic_poster )
, rather than all that sanitize/echo stuff. Can’t check it 100% since my test server is dead, but that should be right I think.In reply to: Adding a Navigation Bar to the Kakumei theme.It’d be too broad a subject to cover really, but menus are generally done from using
<li>
/<ul>
and using CSS to style those to appear how you want. There should be some examples on CSS styling tutorials and the like though.In reply to: Showing more tags on Heatmap.Yep, pretty much. Don’t be afraid to just give it a try and see what happens, it’s how you learn with these things
In reply to: Adding a Navigation Bar to the Kakumei theme.Yes it’s possible, just learn to edit HTML/CSS and modify the header.php in the kakumei template folder (or a copy of it). Mess around a bit and you’ll be able to find exactly where it’ll go if you put it in a given place in the template.
In reply to: Showing more tags on Heatmap.You changed the defaults, instead of just using different parameters when you call the function? Editing core files is really bad practice…
In reply to: Showing more tags on Heatmap.In the first line of function
bb_tag_heat_map
:$defaults = array( ‘smallest’ => 8, ‘largest’ => 22, ‘unit’ => ‘pt’, ‘limit’ => 40, ‘format’ => ‘flat’ );`
Line 3158 of
functions.bb-template.php
in my slightly outdated SVN of 1.0.2In reply to: Showing more tags on Heatmap.bbPress functions have a set of default values that are overwritten by the arguments passed when it’s called, so if a value isn’t specified for something, it stays with the default.
In reply to: Modifying header.phpWe can’t see your header’s source code by just looking at the PHP file, you’d need to use a .phps extension or .txt, or similar…
In reply to: Profile LinksUse something like
<?php echo '<a href="' . esc_attr( get_user_profile_link( $topic->topic_poster ) ) . '">' . $topic->topic_poster_name . '</a>'?>
In reply to: Showing more tags on Heatmap.bbPress functions don’t take arguments the same way as normal PHP functions. You pass arguments as an array.
i.e.
bb_tag_heat_map( array( 'smallest' => 9, 'largest' => 38, 'limit' => 80 ) );
In reply to: bbPress inside a WP Sidebar WidgetTry the other way round, skinning bbPress with your WordPress widgets. Under deep integration, the sidebar functions might work fine. Maybe. bbPress isn’t light enough to just be invoked by a small piece of code in a widget though. That said, there is a WordPress plugin for displaying the latest posts and such from bbPress.
In reply to: What code is generating thisSomething like:
function no_login_notice( $a, $b ) {
if( $b !== 'You must <a href="%s">log in</a> to post.' )
return $a;
}
add_filter( 'gettext', 'no_login_notice', null, 2 );should work I think
In reply to: Page Conditional CheckingThere’s
bb_get_location()
in functions.bb-template.php which returns the page you’re on and is above all the page conditional functions (which are based onbb_get_location()
anyway)In reply to: Convert YetAnotherForum to bbPress, or any platform…Argh, ASP.NET is an evil possessed devil of a language… anyone got a database dump I can test with?
In reply to: Convert YetAnotherForum to bbPress, or any platform…At first I was like “open”, then I was all “ASP.NET”
So yeah, uhh, anyone got a dump of a database for one of these? I don’t even have a test install I can run ASP.NET that I know of…
Edit: Nevermind, Apache can do it. Will look into a conversion script, but it’ll be written in PHP.
In reply to: list of plugins used at wordpress.org forums??The WordPress.org support forums will almost certainly just be using custom-written code. What functionality are you trying to get? Someone here might know of an equivalent plugin.
Nope, but the same data should be available from either profile iirc
<?php if ( $wp_profile_user = bb_get_user( get_post_author_id( $post_id ) ) ) : $wp_profile_link = esc_attr( "/members/{$wp_profile_user->user_nicename}/" )?><a href="<?php echo $wp_profile_link?>">View profile</a><?php endif?>
Your profile pages from bbPress and WordPress should be in sync anyway if you’ve integrated properly…
In reply to: How do I create user records?Read through
register.php
in bbPress’ base directory and functionbb_new_user
underfunctions.bb-pluggable.php
in bb-includes to get an understanding of how normal registration works.Normally the user is given an auto-generated password, but the function used in the registration function will hash anything anyway.
Ah…. add a sidebar capability
In reply to: How do I create user records?Why not just use bbPress native functions and adapt code?
Any chance of a user/password login for the demo?