<![CDATA[ (Resolved) Just upgraded Evolution to 1.0.12 and broke my site - My Forums]]> https://forums.modx.com/thread/?thread=88818 <![CDATA[Re: (Resolved) Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488574 Quote from: Jako at Jan 28, 2014, 10:26 AM
This problem should be fixed with 1.0.13-RC2.

I think your snippet sendCacheControlHeader does not work properly. Maybe DateTime() class is not available.

Try it with:
header('Cache-Control: public'); 
header('Expires ' . strftime('%a, %1 %b %Y %H:%M:%S', strtotime('+1 year')) . ' GMT');


Yes, that worked and stopped the error caused by the previous code.

Thanks again for your help.

Mike]]>
thingstodo Jan 29, 2014, 02:51 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488574
<![CDATA[Re: HEEELP!!! Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488524
There are one or two other less serious issues but I'll start another thread about those.

And will try your suggested code when I iron everything else out.

Thanks]]>
thingstodo Jan 28, 2014, 05:06 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488524
<![CDATA[Re: HEEELP!!! Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488522
I think your snippet sendCacheControlHeader does not work properly. Maybe DateTime() class is not available.

Try it with:
header('Cache-Control: public'); 
header('Expires ' . strftime('%a, %1 %b %Y %H:%M:%S', strtotime('+1 year')) . ' GMT');

]]>
Jako Jan 28, 2014, 04:26 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488522
<![CDATA[Re: HEEELP!!! Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488521 thingstodo Jan 28, 2014, 04:11 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488521 <![CDATA[Re: HEEELP!!! Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488519
This is what sendCacheControlHeader does


header("Cache-Control: public");


$date = new DateTime();
$date->modify("+1 year");
$expires = 'Expires '.$date->format("D, j M Y H:i:s").' GMT';
header($expires); //]]>
thingstodo Jan 28, 2014, 04:07 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488519
<![CDATA[Re: HEEELP!!! Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488517 Jako Jan 28, 2014, 03:56 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488517 <![CDATA[Re: HEEELP!!! Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488516
This is the full System Event error message:

« MODX Parse Error »
MODX encountered the following error while attempting to parse the requested resource:
« PHP Parse Error »
PHP error debug
Error : extract() [function.extract]: First argument should be an array
ErrorType[num] : WARNING[2]
File : /home/webuyany/public_html/manager/includes/document.parser.class.inc.php
Line : 1015
Source : extract($error_info);
Basic info
REQUEST_URI : /blog
Resource : [61]Blog
Current Snippet : sendCacheControlHeader
Referer : http://webuyanybike.com/
User Agent : Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/31.0.1650.63 Chrome/31.0.1650.63 Safari/537.36
IP : 87.194.146.45
Benchmarks
MySQL : 0.0033 s (6 Requests)
PHP : 0.0328 s
Total : 0.0360 s
Memory : 3.88734436035 mb

Backtrace

1 DocumentParser->executeParser()
index.php on line 140
2 DocumentParser->prepareResponse()
manager/includes/document.parser.class.inc.php on line 1568
3 DocumentParser->parseDocumentSource()
manager/includes/document.parser.class.inc.php on line 1658
4 DocumentParser->evalSnippets()
manager/includes/document.parser.class.inc.php on line 1450
5 DocumentParser->_get_snip_result()
manager/includes/document.parser.class.inc.php on line 1061
6 DocumentParser->evalSnippet()
manager/includes/document.parser.class.inc.php on line 1147
7 extract()
manager/includes/document.parser.class.inc.php on line 1015]]>
thingstodo Jan 28, 2014, 03:52 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488516
<![CDATA[Re: HEEELP!!! Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488515
BTW: If you are logged into the backend the frontend should show the full error message.]]>
Jako Jan 28, 2014, 03:45 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488515
<![CDATA[(Resolved) Just upgraded Evolution to 1.0.12 and broke my site]]> https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488514
I've just upgraded a site from Evolution 1.0.8 to Evolution 1.0.12 and it's broke.

Initially the home page worked but all the other pages just returned "Error"

So I thought it must be a Furl issue but then the home page also just comes up with "Error"

In system events i get a message about Snippet - sendCacheControlHeader:

Error : extract() [function.extract]: First argument should be an array

This is really serious, has anyone any ideas what I can do?

Cheers
Mike]]>
thingstodo Jan 28, 2014, 03:28 AM https://forums.modx.com/thread/88818/heeelp-just-upgraded-to-1-0-12-and-broke-my-site#dis-post-488514