Skip to:
Content
Pages
Categories
Search
Top
Bottom

Adding template_notices to theme files

  • Profile photo of Travel-Junkie
    Boris
    Participant

    @travel-junkie

    How about we add “ calls to normal theme files?
    Most of the time they won’t be used, but I’ve written a few plugins now that deal with posts and it’d be useful to output any error/success messages. They won’t do any harm there neither if they’re not used.
    Just a thought…

Viewing 19 replies - 1 through 19 (of 19 total)
  • Profile photo of Tammie Lister
    Tammie Lister
    Moderator

    @karmatosed

    You mean just add in the page.php / index / single and so on?

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    It’s a good point, where would it go ? Directly after do_action(‘bp_before_blog_home’) ?

    It would need to be in a minimum of ‘index’, ‘page’, and possibly ‘archive’

    Profile photo of Travel-Junkie
    Boris
    Participant

    @travel-junkie

    Just below div class=”padder” works good. I’d say in archive.php, index.php, page.php, single.php.

    Profile photo of Paul Gibbs
    Paul Gibbs
    Keymaster

    @djpaul

    Make a patch and I’ll look at it after work

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    :( forgot about Billy Nomates single.php

    yep after .padder makes sense, ensures it claims static position rather than following after whatever might be hooked into those various bp_before_blog_… actions

    Profile photo of Tammie Lister
    Tammie Lister
    Moderator

    @karmatosed

    Lol to Billy Nomates single.php :)

    So this would be for messages / alerts that type of thing?

    Profile photo of Travel-Junkie
    Boris
    Participant

    @travel-junkie

    https://trac.buddypress.org/ticket/2739

    @karmatosed
    yup, just your regular old error/success messages you get on all the BP files

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    Just added ticket and patch so may have duplicated your efforts there @travel-junkie – sorry but wanted to verify for myself how multiple file patching worked .

    https://trac.buddypress.org/ticket/2740

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    @djpaul Paul is it my imagination or do a lot of files seem to be missing add_action(template_notices) or be using an older implementation?

    Profile photo of Paul Gibbs
    Paul Gibbs
    Keymaster

    @djpaul

    Not all the files need them. Quite often the notices are in the components’ -header.php files.

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    Understood.

    Profile photo of Travel-Junkie
    Boris
    Participant

    @travel-junkie

    Hmm, how do you actually add patches to trac. Maybe I’m just being thick, but all I could find was just normal attachments..

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    it is attachments you just upload a .patch file of course if one had commit accessor were working on ones own svn repository you would simply add / merge the changes to a branch or trunk

    Profile photo of Paul Gibbs
    Paul Gibbs
    Keymaster

    @djpaul

    I can find you some instructions on how to make patch files from a svn repo if you let me know what OS you use, Travel-Junkie?

    Profile photo of Travel-Junkie
    Boris
    Participant

    @travel-junkie

    @djpaul
    Cheers, mate! I’m on Windows 7, but I found out in the meantime myself.

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    Tortoise! One of those times where it beats trying to wrestle with the command line /shell :)

    Profile photo of Paul Gibbs
    Paul Gibbs
    Keymaster

    @djpaul

    @hnla Following on from what you said earlier, I’m checking all theme files in branch and trunk just in case trunk has missed any changes.

    Profile photo of Paul Gibbs
    Paul Gibbs
    Keymaster

    @djpaul

    Everything’s in-sync.

    Profile photo of Hugo Ashmore
    Hugo Ashmore
    Moderator

    @hnla

    Edit// too slow sorry I should have run comparisons earlier.

    @djpaul it might be worth a check, might also be me worrying , but wasn’t sure where this add_action should occur. I note 7 files in bp-default with 8 occurrences in 1.2.6 and the same for trunk in my local checkouts so think all is ok a wild goose chase? sorry!

Viewing 19 replies - 1 through 19 (of 19 total)
  • The topic ‘Adding template_notices to theme files’ is closed to new replies.
Skip to toolbar