更新记录
1.0.4(2025-07-11) 下载此版本
1、修改了描述
1.0.3(2025-07-11) 下载此版本
1、新增readme 文档
1.0.2(2025-07-11) 下载此版本
修改了文案
查看更多平台兼容性
uni-app
Vue2 | Vue3 | Chrome | Safari | app-vue | app-nvue | Android | iOS | 鸿蒙 |
---|---|---|---|---|---|---|---|---|
√ | √ | - | √ | - | - | - | - | - |
微信小程序 | 支付宝小程序 | 抖音小程序 | 百度小程序 | 快手小程序 | 京东小程序 | 鸿蒙元服务 | QQ小程序 | 飞书小程序 | 快应用-华为 | 快应用-联盟 |
---|---|---|---|---|---|---|---|---|---|---|
- | - | - | - | - | - | - | - | - | - | - |
其他
多语言 | 暗黑模式 | 宽屏模式 |
---|---|---|
× | × | √ |
说明:
在当今的移动应用开发中,广告标识符(IDFA)对于精准营销、用户分析等至关重要。然而,如何高效且合规地获取这些标识符却是一个挑战。我们网页获取IDFA插件正是为此而生,可以在浏览器获取IDFA,并且无需任何特殊权限。
1.0 主要特点:
-
专业支持 由 多米科技 提供专业的技术支持和服务,确保您的问题得到及时解决。
-
免费试用 所有收费插件均支持免费试用,您可以先体验再决定是否购买。
2、官网下载插件
2.1 获取OAID
window.dy_refer.getIdfa(".button", (idfa)=>{
console.info("idfa获取成功 = ", idfa)
})
2.2 完整示例代码,如下图
<template>
<!-- #ifdef APP -->
<scroll-view class="content">
<!-- #endif -->
<image class="logo" src="/static/logo.png"></image>
<view class="text-area">
<text class="title">{{title}}</text>
</view>
<!-- <view class="buttons">
<button class="button" @tap="openTest" type="primary">打开列表</button>
</view> -->
<view>
<button class="button" @tap="getIDFATest" type="primary">获取IDFA</button>
</view>
<view class="text-area">
<text class="title">获取成功</text>
</view>
<view class="text-area">
<text class="title">{{idfa}}</text>
</view>
<!-- #ifdef APP -->
</scroll-view>
<!-- #endif -->
</template>
<script>
import '@/uni_modules/duomi-idfa-h5/js_sdk/dm_idfa_h5.js'
export default {
data() {
return {
title: 'Hello',
idfa:"",
}
},
mounted() {
},
methods: {
getIDFATest() {
window.dy_refer.getIdfa(".button", (idfa)=>{
console.info("idfa获取成功 = ", idfa)
alert(idfa)
this.idfa = idfa
})
}
}
}
</script>
<style>
.content {
display: flex;
flex: 1;
align-items: center;
}
.logo {
height: 200rpx;
width: 200rpx;
margin-top: 200rpx;
margin-bottom: 50rpx;
}
.title {
font-size: 36rpx;
color: #8f8f94;
}
.buttons {
margin-top: 50px;
margin-bottom: 50px;
}
.button {
width: 640rpx;
margin: 10px;
}
</style>