• 项目中启动另外的一个app


        NSMutableString *webViewContent = [[NSMutableStringalloc] init];

        [webViewContent appendString:@"<html xmlns="http://www.w3.org/1999/xhtml">"];

        [webViewContent appendString:@"<head>"];

        [webViewContent appendString:@"<meta id="viewport" name="viewport" content="width=280; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;" />"];

        [webViewContent appendString:@" <style type="text/css">"];

        [webViewContent appendString:@" body"];

        [webViewContent appendString:@" {"];

        [webViewContent appendString:@" margin: 0px;"];

        [webViewContent appendString:@" padding: 0px;"];

        [webViewContent appendString:@" }"];

        [webViewContent appendString:@" </style>"];

        [webViewContent appendString:@" <title>title</title>"];

        [webViewContent appendString:@" </head>"];

        [webViewContent appendString:@" <body>"];

        [webViewContent appendString:@" <script>"];

        [webViewContent appendString:@" window.location = "vlife963656852:";"];

        [webViewContent appendString:@" setTimeout( function(){ window.location="https://itunes.apple.com/us/app/v-sheng-huo/id605292920?ls=1&mt=8"; } , 1500);"];

        [webViewContent appendString:@" </script>"];

        [webViewContent appendString:@" </body>"];

        [webViewContent appendString:@" </html>"];

        

        UIWebView *webView = [[UIWebViewalloc] initWithFrame:CGRectMake(0, 0, 1, 1)];

        webView.delegate = self;

        [webView loadHTMLString:webViewContent baseURL:[NSURLURLWithString:@""]];

        [self.view addSubview:webView];

        [webView release];

        

        [webViewContent release];

  • 相关阅读:
    vue 中 过滤filter 和 foreach的使用
    vuex 获取数据
    动态设置样式 calc计算
    vue-echarts-v3 使用 dataZoom属性 相关笔记
    访存加速-Speed-up of Memory Access Intensive Program
    台式机新添内存条无法开机?
    ADB的版本问题
    1184. Distance Between Bus Stops
    485. Max Consecutive Ones
    448. Find All Numbers Disappeared in an Array
  • 原文地址:https://www.cnblogs.com/iphone520/p/3352811.html
Copyright © 2020-2023  润新知