Test Mraid on Device

纵然是瞬间 提交于 2021-01-20 09:22:27

问题


I want to test Mraid (http://www.iab.net/mraid) on mobile application, but I can't find a good solution.

in this link : https://github.com/mikerowehl/mraid-testing

He describes about device testing but it is for 3 years ago and doesn't work now. i want to use my own server to push mraid ad to my application for testing like this now.

How can I have a testing application?

How should I do in server?


回答1:


As you already know Mraid compatible Ads contain HTML+ Javascript(And javascript uses Mraid API). Since you don't have any server that delivers Mraid Ads to you.What I would do is simply create some index.html resource file inside your APP and load this resource within the webview where you want to load the Ad.

E.g. In IOS check this stackoverflow link for:how to load javascript into webview from local resources

Just create some basic Mraid Ad (there are lots of examples on this site https://wiki.operamediaworks.com/display/AMS/MRAID+Sample+Ads and I usually use this mraid diagnostics Ad to test all the mraid related functionality http://admarvel.s3.amazonaws.com/demo/mraid/MRAID_v2_diagnostics.txt).

Hope it helps!




回答2:


MRAID - Mobile Rich Media Ad Interface Definitions - allows to use device(native) functionality from HTML/JS code.

[Android principle implementation]

IAB describes a common API but a technical part is provided by Ad SDK and consists of:

  1. mraid.js
  2. custom WebView

For testing your implementation you can use next resources:

  • IAB webtester tool
  • IAB SDK tester
  • IAB tags, admarvel tag


来源:https://stackoverflow.com/questions/34647055/test-mraid-on-device

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