Closed robsonlopes closed 8 years ago
yes, this also happened on my Magento v1.9.0.1 site (with Varnish 4.0)
I also tried Varnish_Cache-4.2.2, it looks like nothing help.
I tried all tips mentioned in README_VARNISH_CACHE.txt, but the issue is still over-there.
@johnjyin I see that now you fixed this issue. Looks like you added "-p esi_syntax=0x03" to startup parameters.
But after that I got next issue - when I go to some product page which contain formkey - it try replace
<esi:include .../>
to current page content (see screenshot below).
Could anyone help me fix it? PS:Varnish cache 3.0.5
Same problem here :(
@hugodiasneto you have same issue like me or like guy from first post? If same like guy from first post - try add "-p esi_syntax=0x03" to startup parameters
@ihor-sviziev i got the same problem. do you have solved this issue?
@matthiaskomarek no, now we using older version of this module and implemented hack for skipping form key validation, but it can be unsecure.
I have the same issue with the ESI include tag displaying on the frontend. I ended up doing the same as @ihor-sviziev by using the older version which does not use ESI, then added a 'hack' to remove form key validation.
This is due to bad quoting.
change lines 24 and 25 of app/code/community/Phoenix/VarnishCache/Helper/Esi.php
from
const ESI_INCLUDE_OPEN = '<esi:include src="';
const ESI_INCLUDE_CLOSE = '" />';
to
const ESI_INCLUDE_OPEN = "<esi:include src='";
const ESI_INCLUDE_CLOSE = "' />";
I fixed this by adding "-p esi_syntax=0x03" to my startup parameters (as said in the README) then, editing the given .vcl file as accordingly :
Search for “sub vcl_fetch {“ And add just below : set beresp.do_esi = true;
Then I restarted varnish service, flushed varnish cache in Magento settings, cleaned the cookies.
@Cranke or @chougron could you create pull request which will fix those issue?
done
@PHOENIX-MEDIA could you merge those changes?
@Cranke I've confirmed that this was the issue with my install @ http://residualdrivers.com Thanks for that fix!
@Cranke Hello friends! I was very pleased to see everyone's efforts to solve this annoying problem.
The solution mentioned above was excellent, but not fully resolved the issue. As you can see from the images below, an error occurred in the javascript code that creates the cockie PAGECACHE_FORMKEY. Does this error has to do with the other?
I auditioned on a clean installation of Magento 1.9.1.1
ok we can change that, too. in app/design/frontend/base/default/template/varnishcache/cookie/formkey.phtml change line 36 from
'<?php echo $_formKeyValue; ?>',
to
"<?php echo $_formKeyValue; ?>",
clear caches and the code will work.
@Cranke Thank you!
I have strange problem at checkout and in the client area, see the screenshot http://screencast.com/t/pgbth6ez4jF
<input name="form_key" type="hidden" value="<esi:include src=" http:="" virtualfashion.com.br="" varnishcache="" getformkey="" "="">