Resource icon

xF2 Add-on Browser Detection 2.3.0

No permission to download

DareSec

Inforc3r
Staff member
Administrator
Moderator
S.V.I.P Member
Collaborate
Registered
Joined
May 25, 2019
Messages
1,372
Points
523

Reputation:

DareDevil submitted a new resource:

Xon Browser Detection - A light-weight shim around Mobile_detect for XenForo 2

Usage (in templates)
The add-on injects the global variable $xf.mobileDetect, check that the variable is set before calling any methods to prevent errors during upgrades or if the add-on is disabled.

Code:
<xf:if is="$xf.mobileDetect && $xf.mobileDetect.isMobile()">
Is Mobile
<xf:else />

Not Mobile
Code:
</xf:if>
<xf:if is="$xf.mobileDetect && $xf.mobileDetect.is('Firefox')">
Is Firefox
<xf:else />
Not Firefox
Code:
</xf:if>
<xf:if is="$xf.mobileDetect...

Read more about this resource...
 

odin777

New member
Registered
Joined
Apr 23, 2019
Messages
1
Points
13

Reputation:

Some help please, how to force a style on mobile?

Code:
<xf:if is="$xf.mobileDetect && $xf.mobileDetect.isMobile()">
Is Mobile then force style
<xf:else />
 

Thanos Crax

Collaborate
Collaborate
Registered
Joined
Sep 25, 2020
Messages
315
Points
73

Reputation:

1627279249756.jpg


After adding the code to my template there is text at top of the screen
why is that so and did I do something wrong?
 

DareSec

Inforc3r
Staff member
Administrator
Moderator
S.V.I.P Member
Collaborate
Registered
Joined
May 25, 2019
Messages
1,372
Points
523

Reputation:

Top