Difference between revisions of "PHONEGAPDEVICE()"

From Lianjapedia
Jump to: navigation, search
(Created page with "==Purpose== Function which can be used in .rsp pages and/or server-side procedures to determine the device if the current client is a mobile device ==Syntax== PHONEGAPDEVICE(...")
 
 
(5 intermediate revisions by the same user not shown)
Line 6: Line 6:
  
 
==See Also==
 
==See Also==
[[ISPHONEGAP()]], [[ISSERVER()]], [[PHONEGAPVERSION()]], [[PHONEGAPPLATFORM]]
+
[[ISPHONEGAP()]], [[ISSERVER()]], [[PHONEGAPVERSION()]], [[PHONEGAPPLATFORM()]]
  
 
==Description==
 
==Description==
 
The PHONEGAPDEVICE() function returns the device - 'phone' or 'tablet' - if the current client is a mobile device, otherwise an empty string.
 
The PHONEGAPDEVICE() function returns the device - 'phone' or 'tablet' - if the current client is a mobile device, otherwise an empty string.
 +
 +
Note: PhoneGap Build of Lianja Apps was deprecated in Lianja v5.4.  Instead, the Build Workspace provides the ability to configure Apps as [[#Progressive Web Apps|Progressive Web Apps (PWA)]].
  
 
==Example==
 
==Example==
Line 28: Line 30:
 
[[Category:Lianja VFP Extensions]]
 
[[Category:Lianja VFP Extensions]]
 
[[Category:VFP Function Extensions]]
 
[[Category:VFP Function Extensions]]
[[Category:Mobile Apps]]
+
[[Category:Lianja v2.0]]
 +
[[Category:PhoneGap Apps]]

Latest revision as of 11:13, 9 December 2020

Purpose

Function which can be used in .rsp pages and/or server-side procedures to determine the device if the current client is a mobile device

Syntax

PHONEGAPDEVICE()

See Also

ISPHONEGAP(), ISSERVER(), PHONEGAPVERSION(), PHONEGAPPLATFORM()

Description

The PHONEGAPDEVICE() function returns the device - 'phone' or 'tablet' - if the current client is a mobile device, otherwise an empty string.

Note: PhoneGap Build of Lianja Apps was deprecated in Lianja v5.4. Instead, the Build Workspace provides the ability to configure Apps as Progressive Web Apps (PWA).

Example

do case
case phoneGapDevice() = 'phone'
   // called from phone mobile client
case phoneGapDevice() = 'tablet'
   // called from tablet mobile client
otherwise
   // not called from mobile client
endcase