Debug javascript in opera mini

China☆狼群 提交于 2021-02-06 09:26:27

问题


How do i debug javascript in opera mini?

I have already installed opera mini emulator.

can someone help me how do i debug javascript remotely with dragonfly (firebug equivalent of opera)?

My script does in work in all other browser but not in opera mini


回答1:


Opera Mini supports console API like this:

server:console?post=http://url/to/your/script

OR

You can dump your log data to source and get source using this command(this fill display source code of current/last page for your device):

server:source

OR

Use remote console services like jsconsole.com. You add script tag with jsconsole script and key. After this use this key on jsconsole site to get the log.

NB: jsconsole script rewrites console.log calling via ajax request




回答2:


There is, at least for now, no support for debugging a javascript directly in Opera Mini.

You can use document.write to output progress/debug messanges, that is about the extent of debugging posibilities.

Could you point to the script, or at least describe what it is trying to do?

Opera Mini is fairly different from a normal browser, scripts are run on the transcoding servers, and the result of the run is then passed to the client, which can not in fact run scripts.

The client can then pass on clicks and some other events to the script when the user interact with the page, which might change the state/look of the page on the server, which is then sent to the client.



来源:https://stackoverflow.com/questions/19098018/debug-javascript-in-opera-mini

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!