We are using the Centerrow theme. We have noticed that the search button, a magnifying glass icon, does not work when you view an item. It works fine on every other page, but on the page where the Dublin Core fields display, the search icon does not respond. When I mouse over the search icon the cursor turns into a pointing hand so it recognizes the icon as a link of some kind, but nothing happens when I click on the icon.
I’ve looked in Github for Centerrow and do not see anything about this. I also printed out the View page source for pages where the seacrh icon works and where it does not, and the only difference I see is a coupel of extra css pages on the item view page. I looked at those and don’t see anything that might affect the search icon function.
Has anyone see this kind of behavior before? I don’t know where else to look.
To be clear, the pages where you’re experiencing this error are item pages like this one - where the url includes item/#. Does it work for you when you view the page I linked?
Yes, an item page like the one at your link. I do get a search field when I click on the magnifying glass icon on that page. I notice this is a basic search (just one field). The search icon on our Omeka brings up a more complex search - choice of keyword, Boolean or exact; and choice of item, file or collection; plus a link for advanced search. Don’t know if that could be making a difference.
Ah, I see the problem. Because your site primarily displays PDFs, the lack of the normal image viewer breaks the theme’s javascript. That’s an oversight on our part. I’ll make a fix to the theme, but in the meantime, replace the contents of your /js/items-show.js with the following:
(function($) {
$(document).ready(function(){
var itemFilesNav = $("#itemfiles-nav");
if (itemFilesNav.length > 0) {
var inContainer = itemFilesNav.Chocolat({
imageSize: "default",
loop: true,
container: "#itemfiles",
}).data("chocolat");
inContainer.api().open()
inContainer.api().getElem("overlay").off("click.chocolat");
}
$(document).off("keydown.chocolat").on("keydown.chocolat", function(e) {
if (inContainer.api().get("initialized")) {
if (e.keyCode == 37) {
inContainer.api().prev()
}
else if (e.keyCode == 39) {
inContainer.api().next()
}
}
});
$(document).on("webkitfullscreenchange mozfullscreenchange fullscreenchange", function() {
if ((inContainer.api().get("fullscreenOpen")) && ($("#itemfiles").hasClass("chocolat-in-fullscreen") == false)) {
$("#itemfiles").addClass("chocolat-in-fullscreen");
} else {
$("#itemfiles").removeClass("chocolat-in-fullscreen");
}
});
});
})(jQuery)
It should be fine across the browsers… Make sure you’ve cleared cache or hard refreshed when testing on Firefox/Chrome.
Note: you’re also having a JS error coming from the Neatline Features plugin… it doesn’t seem to be affecting this specifically but if you’re not using it you might want to uninstall or deactivate it.