iphone - 如何在 Info.plist 中设置多个 url schemes

标签 iphone ios url url-scheme info-plist

我想在 Info.plist 中设置多个 url schemes。但我不知道如何在 Info.plist 中设置许多 url 方案。谁能帮帮我,我是一条鱼

最佳答案

Project Navigator->YourInfo.plist 点击它; 而不是单击图片示例中选定行下的“+”,您将获得其他 url 方案的新项目。

new url scheme

这里我们有两种方案:

一个://

两个://

EDIT1:作为文本:

<key>CFBundleURLTypes</key>
<array>
    <dict>
        <key>CFBundleTypeRole</key>
        <string>Editor</string>
        <key>CFBundleURLSchemes</key>
        <array>
            <string>one</string>
            <string>two</string>
        </array>
    </dict>
</array>

CFBundleURL 类型 CFBundleTypeRole CFBundleURL方案 第三 CFBundleTypeRole 编辑 CFBundleURL方案 一 二

EDIT2:与第三个选项不同的文本:

<key>CFBundleURLTypes</key>
<array>
    <dict>
        <key>CFBundleTypeRole</key>
        <string>Viewer</string>
        <key>CFBundleURLSchemes</key>
        <array>
            <string>three</string>
        </array>
    </dict>
    <dict>
        <key>CFBundleTypeRole</key>
        <string>Editor</string>
        <key>CFBundleURLSchemes</key>
        <array>
            <string>one</string>
            <string>two</string>
        </array>
    </dict>
</array>

关于iphone - 如何在 Info.plist 中设置多个 url schemes,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18695764/

相关文章:

javascript - 使用 Phonegap 为 iPhone 生成 PDF

java - 打开 URL 的 Intent 不适用于一个应用程序,但适用于另一个应用程序

iphone - 如何从 StoryBoard 设计的 UITableView 中删除静态单元格

ios - dateFormatter 根据设备返回不同的日期

ios - 如何让 tableFooterView 始终位于 UITableView 的底部

.htaccess - mod 重写以删除文件扩展名,添加尾部斜杠,删除 www 并在没有文件/目录可用时重定向到 404

url - 哪个页面 url 扩展的 SEO 更好

iphone - 使用 ARC 进行内存管理,奇怪的行为

ios - 如何使用 AFNetwork 的 AFHTTPRequestOperationManager 设置 HTTP 请求体?

jquery - Touchstart 点击事件不适用于 iPhone/iPade