Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Detection is inefficient  #40

@selay

Description

@selay

I am using this module and there is an issue with detection. Bu I needed to optimize it for my own use because it each time when is_mobile is called, does the same checking to see if it is mobile or not. In reality, if something is not a mobile, it can not change itself during the user session to become a mobile. So, once the detection is done, it should be stored in a session to return the previous evaluation result if the session is set.
Doing so much string match, search, etc with headers to identify user agent etc, is not very efficient for php. So, can just keep in session once it is done. and this user will be marked as mobile during this session. I hope you consider this one in your next release or update.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions