1

I made an .apk which shows some web page (advert). Now URL of that web page is simply hard-coded.

I have several clients, who receive mine .apk. They want to set their own URL in their .apk. I don't know URLs beforehand. Client can change his URL on his own, without my knowledge nor help.

How to do it? It's important to make it user-friendly. The easier way for the client, the better. The clients have no idea about programming. They can't build and sign the .apk. Also, the easier to implement, the better.

Example:

I give .apk to a client. He sets his URL to www.clientA.com. He puts his .apk on Google Play. After some time, he changes his URL to www.anotherSiteOfClientA.com. If it is needed, he updates his .apk on Google Play.

My ideas:

  1. XML file for the URL. The problem is that it's not easy for the client to change this XML file when it's already packed into .apk.

  2. Another idea is a web service. But it's too much work on my side - internet connection in app, maintaining server, registering clients etc.

4

1 回答 1

0

只需在您的应用程序中使用提供数据库,然后让用户使用 SQLite 数据库资源管理器对其进行操作。他必须解压 .apk 文件并对其进行操作。请记住,客户必须自己构建和签署 apk。有一个用于此目的的工具:LINK TO XDA DEVELOPERS

看看这个链接

或者您可以将您的 URL 放在 strings.xml 中,客户就可以操作此文件。

编辑:更新评论原因如果这不是解决方案,客户最舒适的方法是为每个客户构建一个 Webfrontend 和一个数据库,并在启动时从该 Web 服务加载 URL,当有更新时。

于 2013-09-26T09:36:29.443 回答