nerdexam
IBM

LOT-404 · Question #24

John has added WebViewOverlay to his IBM Worklight application to display content from external websites based on URLs provided by users. John wants to disable the execution of JavaScript on the…

The correct answer is D. webViewOverlay.getSettings().setJavaScriptEnabled(false). See the full explanation below for the reasoning.

Question

John has added WebViewOverlay to his IBM Worklight application to display content from external websites based on URLs provided by users. John wants to disable the execution of JavaScript on the external websites so as to make make the application more secure. Which code will allow John to do this?

Options

  • AwebViewOverlay.setJavaScript(false)
  • BwebViewOverlay.setJavaScriptEnabled(false)
  • CwebViewOverlay.setParams("JavaScript", false);
  • DwebViewOverlay.getSettings().setJavaScriptEnabled(false)

How the community answered

(35 responses)
  • A
    3% (1)
  • B
    14% (5)
  • C
    6% (2)
  • D
    77% (27)

Community Discussion

No community discussion yet for this question.

Full LOT-404 Practice