Changing "Browse Collections" and "Browse Exhibits" in Berlin Theme

Hi,

Could you point me to the lines in the code for the Berlin theme where I could rephrase the "Browse Collections" and "Browse Exhibits" headers that appear at the top of those pages?

with thanks,
Karen

In Omeka 2.0, you can do that from the admin side under Appearance->Navigation.

In previous versions, you can configure the navigation under the theme's configuration, in Custom Header Navigation

Thanks for the speedy response Patrick!

I just realized my question wasn't very clear. I actually mean the line that is popping up underneath the main navigation "Browse Items (29)" or "Browse Collections (4)". Here is an example of my main navigation no longer matching what I've renamed collections:

http://www.nineteenthcenturydisability.org/collections

I've changed the main navigation and am just looking to get that line beneath to match it.

Thanks so much and sorry my question was so unclear!

Ah! I should have understood what you were getting at.

Those pages are produced by some default theme files that all themes draw from. So, you'll want to copy those files into your Berlin theme, then make the changes there.

The default files are in /application/views/scripts/ in your Omeka installation. The two that you'll need are /collections/browse.php and /items/browse.php within that folder. Copy those, including the folder, into Berlin, so you end up with the Berlin theme having:

items/show.php (already there)
items/browse.php
collections/browse.php

Then the text you are looking for is right at the top of the two browse.php files.

I've added some documentation about modifying themes

Thanks so much! I will test this all out when I get home tonight!

I have a related question. On my site, I refer to items as "articles" and to collections as "issues" (it's a newspaper archive site). I revised the headers accordingly, by modifying the PHP files you referenced here.
However, in the default theme on the Browse Items page, there is a secondary nav with tabs. One of the tabs says "Search Items" and I'd like to change it to "Search Articles." I've looked all over and can't find where this is being pulled from.
I'm using Omeka 2.1. Here's the page I'm talking about: http://monadnockdigitalarchives.com/items/browse.

I'm running an older version of Omeka so I don't know if this will work.

On the theme's items/browse.php (https://github.com/omeka/theme-berlin/blob/master/items/browse.php) there's a line called <?php echo public_nav_items(); ?>. Based on http://omeka.org/codex/Functions/public_nav_items, you might be able to change that to something like this:

<?php
echo public_nav_items(
    array(
        'Browse All' => uri('items'),
        'Browse by Tag' => uri('items/tags'),
        'Search Articles' =>uri('items/search')
    )
);
?>

I looked in the Omeka 2.0 documentation http://omeka.readthedocs.org/en/stable-2.0/Reference/libraries/globals/public_nav_items.html, but it didn't have any examples, so like I said before, I don't know if this will work.

That looks like the simplest solution -- or at least pretty darn close. Depending on which theme you are modifying, you might need to follow this guide to overriding the default items/browse.php file.

The array structure is just a little bit off. It should have another layer of arrays for each navigation link:

array(
    array('label' => __('Browse All'),
          'uri' => uri('items')
         ),
    array('label' => __('Browse by Tag'),
          'uri' => uri('items/tags')
         ),
    array('label' => __('Search Articles'),
          'uri' => uri('items/search')
         )
)

That looks like the simplest solution -- or at least pretty darn close. Depending on which theme you are modifying, you might need to follow this guide to overriding the default items/browse.php file.

The array structure is just a little bit off. It should have another layer of arrays for each navigation link:

array(
    array('label' => __('Browse All'),
          'uri' => uri('items')
         ),
    array('label' => __('Browse by Tag'),
          'uri' => uri('items/tags')
         ),
    array('label' => __('Search Articles'),
          'uri' => uri('items/search')
         )
)

Thank you both for the help! I tried applying the code patrickmj posted in the default theme's items/browse.php file, and (because I'm a PHP novice) I'm getting the following error:
Fatal error: Call to undefined function uri() in /home3/daravern/public_html/themes/default/items/browse.php on line 12
Line 12 contains the following:
'uri' => uri('items')
I tried replacing 'items' with 'items/browse' and 'items browse' and 'browse'--and I still get the same error. I basically can't figure out the uri for the page where this nav appears.

Maybe instead of 'uri' => uri('items') try 'uri' => url('items')

It looks like uri() has been deprecated as a function and you can use url() instead.

array(
    array('label' => __('Browse All'),
          'uri' => url('items')
         ),
    array('label' => __('Browse by Tag'),
          'uri' => url('items/tags')
         ),
    array('label' => __('Search Articles'),
          'uri' => url('items/search')
         )
)

But like I said before I'm running an older version of Omeka, so I'm not sure. When I ran a search in the 2.0 documentation for uri, I came across https://omeka.readthedocs.org/en/latest/Reference/filters/admin_navigation_main.html?highlight=uri, and it uses this structure.

This worked--thank you so much!!
I ended up using 'items/browse' for the first url. Here's the full code, in case anyone else wants to change the text of these secondary nav tabs:

<nav class="items-nav navigation secondary-nav">
<?php echo public_nav_items(
array(
array('label' => __('Browse All'),
'uri' => url('items/browse')
),
array('label' => __('Browse by Tag'),
'uri' => url('items/tags')
),
array('label' => __('Search Articles'),
'uri' => url('items/search')
)
)
); ?>
</nav>