Skip to:
Content

BuddyPress.org

Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#944 closed enhancement (wontfix)

bp_pagetitles

Reported by: junsuijin's profile junsuijin Owned by: junsuijin's profile junsuijin
Milestone: 1.1 Priority: minor
Severity: Version:
Component: Keywords: has-patch
Cc:

Description

I've created a concept patch that allows for simple modification of bp-sn-framework pagetitles like 'Blog,' so as not to need a child template file override for such modifications. This patch also cleans up the model 'archive.php' file. The method proposed is arguably the cleanest means of accomplishing this task.

Attachments (1)

bp_pagetitles.patch (3.2 KB) - added by junsuijin 15 years ago.

Download all attachments as: .zip

Change History (7)

#1 @junsuijin
15 years ago

I'm planning to run through the entire bp-sn-framework making these cleanups and adding the bp_pagetitle function if people think it'd be useful.

I'd also like to hear some opinions on whether people think the following would be useful, or just overdoing it:

-change-

<div class="entry">
<?php the_content( __( 'Read the rest of this entry &raquo;', 'buddypress' ) ); ?>
</div>

-to-

<?php do_action( 'bp_before_blog_post_content' ) ?>

<div class="entry">
<?php the_content( __( 'Read the rest of this entry &raquo;', 'buddypress' ) ); ?>
</div>

<?php do_action( 'bp_after_blog_post_content' ) ?>

These two spots seem like the most common locations to want to add html like custom dates, author info, etc, and can also be used in conjunction with the 'bp_before_blog_post' and 'bp_after_blog_post' actions, to more easily alter anything in between the befores or afters, without having to mess with the content.

I think making simple changes to these areas should not require making a new template file in the child; thusly, the child theme creator can focus on the 'minor' aspects of presentation without worrying about merging changes from the framework.

#2 @DJPaul
15 years ago

My personal opinion with regards to adding more actions or filters around parts of the base theme is that there would be a lot of these action calls and convenience functions everywhere, making the file hard to read and overcomplicated. As individual files in this framework can be easily overriden with custom files, I don't think it is out of the question to expect people to do that.

#3 @djpaul
15 years ago

I had a wordy post but lost it when my browser crashed, so: should this theme system be for a theme designer or for a plugin developer? Both approaches have merit (whether to add loads of actions in)

#4 @nicolagreco
15 years ago

I think replacing a file with your own, for non-developers, is better and simpler than adding and removing actions and filters.

Even if i'm a Thematic lover, so i like the everywhere-actions-&-filters idea.

Any way i think this patch can be applied, it's just for the page title.

#5 @junsuijin
15 years ago

  • Resolution set to wontfix
  • Status changed from new to closed

a similar approach to http://codex.buddypress.org/how-to-guides/customizing-labels-messages-and-urls/ does indeed seem the appropriate solution for this, especially since this change can be handled entirely from the theme, rather than bp-custom.php

#6 @junsuijin
15 years ago

My previous ignorance surrounding bp-custom.php has been lifted, but I still recommend putting the custom .po and .mo into the theme or somewhere else they won't be destroyed by an auto-upgrade.

Note: See TracTickets for help on using tickets.