Skip to content
This repository has been archived by the owner on Jul 7, 2021. It is now read-only.

no working for me #1

Closed
urbels opened this issue Feb 18, 2014 · 3 comments
Closed

no working for me #1

urbels opened this issue Feb 18, 2014 · 3 comments

Comments

@urbels
Copy link

urbels commented Feb 18, 2014

Hi! I have multi site host and have a problem.
I used yours:
Sample use case: Normalize the user-agent string for the backend

It shows device correctly in logs, but serves same cache for both.

@willemk
Copy link
Owner

willemk commented Feb 18, 2014

If you want to serve different content and keep serving that content, you'll also need to add the vcl_hash function listed in the _Sample use case: Normalize the user-agent string for the backend_:

include "mobile_detect.vcl";

sub vcl_recv {

    call devicedetect;

    if (req.http.X-UA-Device) {
        set req.http.User-Agent = req.http.X-UA-Device;
        unset req.http.X-UA-Device;
    }
}

@willemk willemk closed this as completed Feb 18, 2014
@willemk
Copy link
Owner

willemk commented Feb 18, 2014

I've modified the readme to make it more clear.

@urbels
Copy link
Author

urbels commented Feb 18, 2014

Already used it as I mentioned in line 3. ;)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants