Search Results for 'theme'
-
AuthorSearch Results
-
March 6, 2009 at 9:27 pm #39396
In reply to: Is it possible to have custom themes for groups?
nicolagreco
Participantops stupid error
<?php
/*
Author: Nicola Greco
Author URI: http://nicolagreco.com
*/
require_once( ‘bp-core.php’ );
require_once( ‘bpdev-core.php’ );
function bpdev_search_css() {
global $group_obj;
bpdev_theme_register_style(
‘my-styles’, // your style slug name
‘XBOX Styles’, // your style name
‘xbox_styles_function’, // callback
‘on’, // status “on” on default
‘off’, // off will not display it in admin interface
( $groups_obj->id == 1 ) ? ( true ) : ( false ); // the group ID
);
}
function xbox_styles_function() { // example of css content
?>
#header {
background: #FFF;
}
<?php
}
add_action( ‘bpdev_theme_extra_setup_globals’, ‘bpdev_search_css’ ); // it will add the style
?>
March 6, 2009 at 9:01 pm #39394In reply to: Is it possible to have custom themes for groups?
Andy Peatling
KeymasterIf you look in the table wp_bp_groups_groupmeta you will see that every group has a theme and stylesheet applied to it. This corresponds with the member theme used to display the group.
I can’t remember if I use the table to load the theme at the moment, but it should make it easy to have multiple themes that you can then pick for each group.
March 6, 2009 at 8:56 pm #39393In reply to: Is it possible to have custom themes for groups?
nicolagreco
Participantif (the group is XBOX) add_action(‘wp_print_styles’, ‘your style hook’)
i made a good set of functions in bpdev theme to add stylesheet with condition, look here:
http://trac.bp-dev.org/plugins/browser/trunk/bpdev-theme/bpdev-theme-extra.php
look line 9:
function bpdev_theme_register_style( $slug, $name, $callback, $default = 'off', $admin_show = 'on', $condition = true, $priority = 1 ) {
it means that with this function you will be able to add styles in wordpress/buddypress integrating them in the bpdev admin interface to activate or deactivate them,
in your example you need a plugin like that called for example my-styles-bpdev.php
<?php
/*
Author: Nicola Greco
Author URI: http://nicolagreco.com
*/
require_once( 'bp-core.php' );
require_once( 'bpdev-core.php' );
function bpdev_search_css() {
global $group_obj;
bpdev_theme_register_style(
'my-styles', // your style slug name
'XBOX Styles', // your style name
'xbox_styles_function', // callback
'on', // status "on" on default
'off', // off will not display it in admin interface
$group_obj->id = 1; // the group ID
);
}
function xbox_styles_function() { // example of css content
?>
#header {
background: #FFF;
}
<?php
}
add_action( 'bpdev_theme_extra_setup_globals', 'bpdev_search_css' ); // it will add the style
?>March 6, 2009 at 8:49 pm #39391In reply to: Is it possible to have custom themes for groups?
gpo1
Participant@fishbowl81, Not bad attempt but don’t go for the myspace route..How did you get the amazon plugin or lastfm?
March 6, 2009 at 8:45 pm #39390In reply to: Is it possible to have custom themes for groups?
fishbowl81
ParticipantHere is a very very rough attempt,
http://gorgeousgamers.com/beta/groups/official-wii-group/home
as a note, you need to modify kses.php to allow style tags.
Brad
March 6, 2009 at 8:30 pm #39388In reply to: Is it possible to have custom themes for groups?
Burt Adsit
ParticipantI ran across something similar.
https://wordpress.org/extend/plugins/art-direction/
Allows ‘per blog post’ custom css. Cool.
In the case of bp the css gets queued up on a very selective basis. This is from bp-groups-cssjs.php in /mu-plugins/bp-groups:
function groups_add_structure_css() {
/* Enqueue the structure CSS file to give basic positional formatting for components */
wp_enqueue_style( ‘bp-groups-structure’, site_url( MUPLUGINDIR . ‘/bp-groups/css/structure.css’ ) );
}
add_action( ‘bp_styles’, ‘groups_add_structure_css’ );
We got actions too. Hook ‘bp_styles’ and define an override for the defaults. You might have a problem getting it in the sequence properly.
function my_custom_group_css(){
// check if the file exists and if it does queue it up
‘group-custom-‘ . $bp->groups->slug . ‘.css’
}
add_action(‘bp_styles’, ‘my_custom_group_css’, 99);
March 6, 2009 at 8:14 pm #39385In reply to: Is it possible to have custom themes for groups?
John James Jacoby
KeymasterI’d love to actually just have several themes with different .css files and that’s it. Selecting a different theme would keep the same structure, but allow for different styling.
March 6, 2009 at 8:02 pm #39382In reply to: Is it possible to have custom themes for groups?
fishbowl81
ParticipantI hate to take the myspace approach, but could add <style>CSS</style> into the group description.
March 6, 2009 at 7:20 pm #39376In reply to: Is it possible to have custom themes for groups?
John James Jacoby
KeymasterI think this is actually an AWESOME idea, and one I’ve been poking around at in my head for a while.
Not sure there is a super easy way to incorporate this, but I’d love to see it done!
March 6, 2009 at 5:15 pm #39370John James Jacoby
KeymasterYou will have to have a separate theme for your subdomain, and hard-code the links to go back to your root domain.
The way I did this, was to have a “buddypress-home” theme, and a “buddypress-sub” theme. The sub theme is basically a copy of all of the files from the “buddypress-home” theme, but without home.php, an edited style.css to change the name of the style, and a modified header.php which I will explain below.
The home theme is activated only for the root blog, the sub theme for all others.
In the header.php file for the sub blogs, I used
$bp->root_domain
as the destination for each link, plus whatever slug was appropriate (MEMBERS_SLUG, BP_GROUPS_SLUG, BP_BLOGS_SLUG).I also went ahead and made the BP_BLOGS_SLOG link
class="selected"
right away, that way when you’re in a sub blog, the appropriate tab is always shown as selected.March 6, 2009 at 10:25 am #39351In reply to: Can the BP Main theme be on blog #2?
Burt Adsit
ParticipantSure you can. It’s just a theme like any other theme.
March 5, 2009 at 10:29 pm #39329bigkill
Participantjohnjamesjacoby – you got it man.. it was in the wp-config
changed from
$base = ‘base’;
changed to
$base = ‘/’;
/** The Database Collate type. Don’t change this if in doubt. */
define(‘DB_COLLATE’, ”);
define(‘VHOST’, ‘no’);
$base = ‘/’;
define(‘DOMAIN_CURRENT_SITE’, ‘bigkill.com’ );
define(‘PATH_CURRENT_SITE’, ‘/’ );
define(‘BLOGID_CURRENT_SITE’, ‘1’ );
but now that I can see the blog it appears that the theme doesn’t get applied http://bigkill.com/foundonweb/
time to open a new post
March 5, 2009 at 10:23 pm #39328In reply to: Where to start theming
Andy Peatling
KeymasterIt’s okay to do anything you want with the theme files, just as you would do in WordPress.
You don’t need the loader.php stuff if you don’t want to, however, it does add some extra functionality, such as cross theme CSS and the ability to selectively load styles.
You should also read this:
https://codex.buddypress.org/getting-started/using-the-buddypress-themes/
March 5, 2009 at 5:01 pm #39314In reply to: Google Map Integration
Lsm_267
ParticipantHi bergsten
thanks for the plugin, essential for any network
I installed the 2.0b2 version on my BP, put the php code you gave above (add_action(‘bp_custom_profile_boxes’, ‘bp_google_maps_profile’, 6)
in the index.php from the directory /wp-content/member-themes/buddypress-member/profile, exactly here :
‘<?php if ( function_exists(‘bp_send_message_button’) ) : ?>
<?php bp_send_message_button() ?>
<?php endif; ?>
</div>
<?php add_action(‘bp_custom_profile_boxes’, ‘bp_google_maps_profile’, 6); ?>
<?php bp_custom_profile_sidebar_boxes() ?>
</div>
<div class=”main-column”>’
It’s working but a little buggy : the map shows two time as you can see here :
http://vivre-en-autarcie.com/members/admin/profile/public
something else is bugging.
the button update your position leads to a page that doesn’t exist with slug: update-position
the integration function works fine : I can edit a map where all markers my users are shown ; that’s great
thanks for any help
March 5, 2009 at 2:57 pm #39313In reply to: THEME ISSUE with LDAP Plugin – Simple Question!!!!
dpsweb
MemberSORRY!!! I did this and the error went away:
WPMU Admin Options > Allow New Registrations : Disabled.
WPMU Admin LDAP Options > Disable Public Signup : NO
What happens now is when a user clicks on the signup button it takes them to the WPMU login page. They login and it uses LDAP. There is no local user account signups as everything appears to be going through the LDAP plugin to authenticate.
March 5, 2009 at 12:01 am #39292In reply to: Using BP widgets with a non-BP WPMU theme
Per Søderlind
Participantfwiw: I’ve written a widget for ahp_recent_posts
March 4, 2009 at 11:42 pm #39290In reply to: one theme, one widget setup
filan
ParticipantThank you Trent, this works nicely!
March 4, 2009 at 11:36 pm #39287In reply to: one theme, one widget setup
Trent Adams
ParticipantTo get the theme that you want all users to have, just make the theme you want the default WPMU theme. This can be done by naming the folder of your theme “default” or looking at a plugin like this plugin.
To get all the widgets that you want in there, It would be best to actually hardcode the widgets you want into the theme itself. If you look at the code of certain themes that do this already, it shows you how to do that. Then, finally if you don’t want users to be able to change around widgets, there is a plugin that limits what menu’s users can see, but don’t have the link off hand. You will have to search for that one.
That is what I would do anyways!
Trent
March 4, 2009 at 11:18 pm #39283In reply to: Displaying RSS Feeds on Home Page?
Trent Adams
ParticipantThe buddypress home them you mean? Just treat it like any other theme and put in an RSS widget to display your feed. Since the member theme isn’t editable in the admin, it requires more, but the buddypress home theme doesn’t.
Trent
March 4, 2009 at 7:41 pm #39276In reply to: Making Member Theme Header Match Main Theme
Simon
ParticipantWordPress detects the currently enabled theme’s root and css directories via the bloginfo(‘template_directory’) and bloginfo(‘stylesheet_directory’) functions.
To call the css and images from the home theme in a member theme template you would have to hard code the path references as “/wp-content/themes/buddypress-home/styles.css”.
Personally, as hard coding is generally a bad idea, I would suggest simply copying the elements you wish to use from the home theme directory to the member theme directory and reference them the usual way.
March 4, 2009 at 7:27 pm #39274In reply to: BuddyPress Showoff: Post your links
Adam W. Warner
ParticipantMBP is a social community meant for those of us who wear artificial body parts, and those that love us. If you own a body part that’s made of acrylic, steel, plastic, or any other man-made material, you’ll probably want to have a look around. You can learn more about why MyBodyPart.org exists here. MBP is completely free. Why not sign up for a profile and start connecting with others who have had, or are having similar experiences?
(still needs branding and theme changes, oh, and also users, so why not sign up and help me create this community?
March 4, 2009 at 3:37 pm #39261In reply to: Making Member Theme Header Match Main Theme
mkgold
ParticipantBasically, I think I’m having problems with paths — the buddypress member page isn’t accessing the css/image files for the main theme. For some reason, I’m having trouble getting my head around this.
Here is the actual error that I’m seeing:
Warning: include(C:xampplitehtdocs/wp-content/member-themes/buddypress-member/options.php) [function.include]: failed to open stream: No such file or directory in C:xampplitehtdocswp-contentmember-themesbuddypress-memberheader.php on line 53
Warning: include() [function.include]: Failed opening 'C:xampplitehtdocs/wp-content/member-themes/buddypress-member/options.php' for inclusion (include_path='.;C:xampplitephppear') in C:xampplitehtdocswp-contentmember-themesbuddypress-memberheader.php on line 53I want the header to match the header on this
March 4, 2009 at 2:00 pm #39252In reply to: Google Analytics
Trent Adams
ParticipantIt is just a WPMU plugin that adds the code to every page, not theme specific so it works with BP as well.
Trent
March 4, 2009 at 1:14 pm #39249In reply to: Making Member Theme Header Match Main Theme
Burt Adsit
ParticipantWhat kind of problems are you running into?
Burt Adsit
ParticipantIt’s better to start a new topic for your kind of issue lorenzocoffee. I flipped the support red light on in this topic. We can do this here. When you start a new topic *you* have the ability to designate the topic as a support question and people will notice.
OK. You’re trying to upgrade from the beta version of bp to RC-1. After uploading and replacing all the files in /mu-plugins and then moving the new themes to the proper locations in /themes and /wp-content, things don’t work.
What does your apache error log say when you try to access your site. What is the url to your site?
-
AuthorSearch Results