HTTP重定向过多

编程入门 行业动态 更新时间:2024-10-21 12:59:41
本文介绍了HTTP重定向过多的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

问题不会一直发生.我收到的错误如下,

The problem doesn't happen all the time. The error i'm getting is the following,

Error Domain=NSURLErrorDomain Code=-1007 "too many HTTP redirects" UserInfo=0x14d18d40{NSErrorFailingURLStringKey=URLHERE, NSErrorFailingURLKey=URLHERE,NSLocalizedDescription=too many HTTP redirects, NSUnderlyingError=0x14d18a10 "too many HTTP redirects"}

有人可以给我一个思路,向我指出正确的方向吗?

Could someone possibly give me an idea on what do here and point me in the right direction?

好的,基本上我想做的是在调用doPortal时,它使用URL加载Portal页面.但是,当我这样做时,它会显示有关太多HTTP重定向的错误.

Okay basically what i'm trying to do is when the doPortal is called, it loads up the Portal page with the URL. However when i do this, it shows the error about too many HTTP redirects.

代码:

-(void)doPortal { [ViewController SetRioSubjectName:[[ViewController getDictionaryOfKeys] objectForKey:[ViewController GetKeyName:k_SubjectName]] role:[ViewController getRoleID] ticket:[SpineMgr getTicket] TestURL:@"TestURL/login/testloginverifydetails.asp?database=LIVE&username=$spineuuid$&smartcardToken=$token$&role=$role$"]; NSURL *url = [NSURL URLWithString:PortalURL]; [self.webView loadRequest:request]; }

谢谢.

推荐答案

NSString *html = [NSString stringWithFormat:@"<html><body><a href=\"%@\">Link</body></html>", @"appian"]; [self.webView loadHTMLString:html baseURL:nil];

更多推荐

HTTP重定向过多

本文发布于:2023-10-31 16:19:46,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1546618.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:重定向   HTTP

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!