Module

Developer
Supported

Sitemap Module

ExpressionEngine 3, ExpressionEngine 4, ExpressionEngine 5

Back to this add-on's main page
View Other Add-ons From PutYourLightsOn

     

You must be logged in to post.

PHP Errors - strpos() expects to be string, array given

Support (Resolved)

John Bacon
John Bacon

Hey Ben,

I’ve been trying to get this to work and have a feeling it’s got something to do with a custom config setting or the Focus Lab Master Config.

Any time I attempt to load Sitemap, I receive the following PHP error:

A PHP Error was encountered

Severity: Warning

Message: strpos() expects parameter 1 to be string, array given

Filename: libraries/Template.php

Line Number: 2703

There are many similar errors, all “array given”. The only actual output I can see (visible via source) is the single word “Array”.

Do you have any suggestions or have you run across this before?

PutYourLightsOn
# 1
Developer
PutYourLightsOn

hi John, when exactly do you see this error. in the module settings or on the front-end? if on the front-end then what exactly is in your template? and can you please try synchronising your templates and trying again?

John Bacon
# 2
John Bacon

Hi Ben,
I see the error on the front-end - {exp:sitemap:get} is the only thing in my template, no extra spaces or characters. Synchronizing returned the same errors.

I have previously tried with a saved template file, without a saved file, unsynced, synced, etc. I’ve also made sure to clear my cache and regenerate Sitemap module settings any time I attempted a troubleshoot (per many of the issues in this forum).

If temporary admin rights might help, I’m open to that option as well.

PutYourLightsOn
# 3
Developer
PutYourLightsOn

yeah that might be easiest, please email to info@putyourlightson.net

PutYourLightsOn
# 4
Developer
PutYourLightsOn

the error turned out to be unrelated to the Sitemap module

John D Wells
# 5
John D Wells

Hi Ben,

Would you mind revealing what the issue ended up being?  I’m seeing a similar issue for a fellow community member, trying to figure out what’s at fault.

Thanks!
John

PutYourLightsOn
# 6
Developer
PutYourLightsOn

i was not involved in the fix so don’t know what the issue was

John D Wells
# 7
John D Wells

Bummer - thanks for replying!

Cheers,
John

John Bacon
# 8
John Bacon

Hey John,

Funny I ran across this post again, because I just tracked it down to Minimee. The output of var_dump, at least, is as follows:

array(19{ ["base_path"]=> string(37"/var/www/vhosts/site.com/httpdocs" ["base_url"]=> string(0"" ["cachebust"]=> string(0"" ["cache_path"]=> string(50"/var/www/vhosts/site.com/httpdocs/assets/cache" ["cache_url"]=> string(13"/assets/cache" ["cleanup"]=> string(2"no" ["combine"]=> string(3"yes" ["combine_css"]=> string(3"yes" ["combine_js"]=> string(3"yes" ["css_library"]=> string(6"minify" ["css_prepend_mode"]=> string(3"yes" ["css_prepend_url"]=> string(0"" ["disable"]=> string(2"no" ["js_library"]=> string(5"jsmin" ["minify"]=> string(3"yes" ["minify_css"]=> string(3"yes" ["minify_html"]=> string(2"no" ["minify_js"]=> string(3"yes" ["remote_mode"]=> string(4"auto" 

I think the issue may lie in my use of Focus Lab’s EE Master Config. At least that’s my amateur guess.

John D Wells
# 9
John D Wells

Hi John,

Very interesting - would you mind posting this to Minimee’s forum so that we don’t bother Ben any further? :)

Also when you write the post, let me know if this is an MSM site, and if so if you have MSMinimee installed as well…

Cheers!
John