1.

Which is the method used to process on the input post data before it is saved to the database?(a) prep()(b) settings()(c) defineSettings()(d) prepSettings()I had been asked this question by my college director while I was bunking the class.My query is from Crafting the Public API in chapter Parsing, Benchmarking and Logging of JavaScript

Answer» RIGHT answer is (d) prepSettings()

Easiest EXPLANATION: defineSettings() METHOD returns an array whose keys define the setting names, and values define the parameters (the type of value, etc). If you need to do any PROCESSING on your SETTINGS’ post data before they’re saved to the database’s content table, you can do it with the prepSettings() method.


Discussion

No Comment Found

Related InterviewSolutions