Error - Warning: strrpos() [function.strrpos]:

Hi guys...

Recently i tried your library system and really like it.

The first week was fine with no problem and i had uploaded some pdf files.

Recently I found some files having error of "Warning: strrpos() [function.strrpos]: Offset is greater than the length of haystack string in /home/mysite/public_html/main/application/helpers/Functions.php on line 600"

Not all files have this error... only some but still viewable.

Any helps would be appreciated very much...


Please someone answere my request as I have no idea how to fix this error "Warning: strrpos() [function.strrpos]: Offset is greater than the length of haystack string in /home/mysite/public_html/main/application/helpers/Functions.php on line 600" occurring randomly to some files I had uploded to my site.

Thanking you.

Hi, what version are you using?

I am getting the same error on our homepage.
we are using version 0.10



I installed the two versions on different sub-folder and tested if it was caused by the version.
It happened with the two versions as I tried on both already.

Does this happen on the admin theme, or the public theme, or both? Are you using a theme as installed, or did you make changes to it? Where on the page does the problem occur with each?

It looks like there is a problem with the code that makes text snippets, so if you see a 'snippet' argument being passed to the item() function in your theme, try changing the value to something smaller, or removing that 'snippet' option altogether. Let me know whether or not that fixes the problem.

Thanks for responding to my question.
It happened on both sides.
We are using the theme as installed. The error occurred randomly after some item records.
Please see some examples -


We've made a note of this on Trac to be fixed in the next release of Omeka. Meanwhile, you can make sure the value for display_errors in your .htaccess is set to 0 instead of 1. That should suppress minor errors like that. It's better to have those errors display during debugging and development, but better to have it turned off after your site goes live. Hope that helps.

Dear Admin and members,

Thanks for the ideas and advices.
The problem for me is now fixed by putting "Off" in the "php.ini".

display_errors = Off
display_startup_errors = Off
log_errors = Off;
log_errors = Off;
ignore_repeated_errors = Off
report_memleaks = Off
track_errors = Off
;html_errors = Off

Now my site has no error anymore. Sweet... Thanks all.