1

Just reading through the code it appears that this parameter will always appear in the link, I'm not entirely sure why though. I can understand why the value would get appended given hasStoreId returning true, but if no store is specified, the current store is used. Why force a link onto a store it's currently on? Is there a situation in which this actually does something useful?

For context, I was looking into the code because a site we've been asked to review, is using this widget. The existence of this specific query parameter seems to be making Phoenix_VarnishCache generate an EXTERNAL_NO_CACHE cookie which seems to force the client to avoid the cache. The expiration date on this cookie is 3 hours in the future, and the expiration appears to be renewed upon each request. I'm yet to look into why this cookie might function in this manner, it seems odd to say the least. I can't swear that the module hasn't been modified however, so it might not be default behaviour for the module.

3

Yes there is a situation. If you don't express the storeview in your url, the parameter forces the correct store.

Example:

All your store are on the same domain: example.org and if you change the storeview from english to french it is only saved in your session or cookie. If you now copy a link to a comment, IM, email, whatever, the site the user sees is english, no matter whether the page was french before.

The question might be, why always an not only, if it is needed - I have no idea, too much possibilities? too hard to check? lazy developer? :-)

  • Good point, that is a valid reason why it might be required. Just a bit inconvenient in this situation! – Peter O'Callaghan Aug 20 '13 at 16:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.