beautypg.com

Grandstream GXV3140 GMI Guide User Manual

Page 17

background image

Grandstream Networks, Inc.

GMI HTML SDK and API Guide

Page 17 of 43

www.grandstream.com

Last Updated: 09/2010

Also,no modification in the menu.xml file is necessary for the GMI Applet. By default, the user

can locate the GMI applet under the phone menu->Personalize->Screen Layout and configure the

URL for the phone to obtain the page.

For more details and examples, please refer to the two source files in the applet folder (ajax.html

and timer.html)

Fileapplet/ajax.html

function

softkey_process

(

keyCode

)

{

document

.title =

"Applet-Ajax: in softkey_process, keyCode = "

+ keyCode;

switch

(

keyCode

)

{

case

8

:

//Process F3 event in Backspace keyevent

//Backspace

GMIEngine.refresh

()

;

break

;

case

16

:

//Process F4 event in Shift keyevent

//Shift

var

orig =

document

.

location

;

var

dst = orig.href.replace

(

/ajax/i

,

"timer"

)

;

GMIEngine.gotourl

(

dst

)

;

break

;

case

112

:

//F1 process here;

break

;

case

13

:

//Enter process here

break

;

case

113

:

//F2 process here;

break

;

case

114

:

//F3 process here;

break

;

case

115

: