Returns the number of the slice displayed in a page in Responsive Web Design mode.
// If the "Tablet" slice is displayed
IF BrowserSlice() = 2 THEN
...
END
Syntax
<Result> = BrowserSlice()
<Result>: Integer
Number of current slice.Remark: If the page is not using the Responsive Web Design mode, <Result> is set to 1.
Remarks
- The number of default slice is 1.
- Then, the slice number increases for each following slice:
- If "Desktop" is the default slice, the numbers increase from the largest slice ("Desktop") to the smallest slice ("Mobile").
- If "Mobile" is the default slice, the numbers increase from the smallest slice ("Mobile") to the largest slice ("Desktop").