All Products
Search
Document Center

Mobile Platform as a Service:Settings

Last Updated:Jan 27, 2026

my.setOptionMenu

Note

This API is supported in mPaaS 10.1.32 and later versions.

Sets an additional icon for the option menu in the navigation bar. Clicking the icon triggers onOptionMenuClick.

Input parameters

Name

Type

Required

Description

icon

String

Yes

The URL (starting with https or http) or Base64 string for the optionMenu icon. The recommended size is 30 × 30 pixels. (Base64-encoded images are not currently supported.)

Notes on the icon property

  • Because of App Transport Security (ATS) restrictions in iOS, the icon URL must be an HTTPS link or a base64 string. HTTP links are ignored.

  • When the icon is in base64 format, only vector image formats are supported. Do not use the "data:image/png;base64" prefix.

Code example

my.setOptionMenu({
  icon: 'https://img.alicdn.com/tps/i3/T1OjaVFl4dXXa.JOZB-114-114.png',
});