Hi @jabbajabba,
create first a child-theme and add this snippet into functions.php or bp-custom.php
We are going to use one of the existing action hook in the group header template and add it a custom function.
function jabbajabba() {
echo '<a href="#">click here</a>';
}
//add_action( 'bp_before_group_header_meta', 'jabbajabba' );
//add_action( 'bp_group_header_actions', 'jabbajabba' );
add_action( 'bp_group_header_meta', 'jabbajabba' );
The snippet has 2 commented action, so you can choose the best place for your link button.
Reference file is
buddypress/bp-templates/bp-legacy/buddypress/groups/single/group-header.php
Thank you very much @danbp for you fast response.
I didn’t wrote my question clear enough :/
What i want to do is create a url just like above, but with the current group name in it.
Like this
http://somesite.com/current_group_name
Try this
function jabbajabba() {
?>
<a href="<?php bp_group_permalink(); ?>"><?php bp_current_group_name(); ?></a>
<?php
}
add_action( 'bp_group_header_meta', 'jabbajabba' );
thanks you very much!
it works now