IOS: kCFErrorDomainCFNetwork error -1002. Error Domain=NSURLErrorDomain Code=-1002 "unsupported URL"
<p>hello all i know this kind of question asked previously but i didn't get any solution from them 
in my project i am working in login view when i am put code on login button i am getting an error </p>

<blockquote>
  <p>Error : Error Domain=NSURLErrorDomain Code=-1002 "unsupported URL"
  UserInfo=0x7fb37b62c9a0 {NSLocalizedDescription=unsupported URL,
  NSUnderlyingError=0x7fb37b715a20 "The operation couldn’t be completed.
  (kCFErrorDomainCFNetwork error -1002.)"}</p>
</blockquote>

<p>but i am using the same code for login which i used in my previous projects and it works fine there </p>

<p>here is my code:</p>

<pre><code>-(IBAction)login:(id)sender
{
    NSURLSessionConfiguration *configuration = [NSURLSessionConfiguration defaultSessionConfiguration];
    NSURLSession *session = [NSURLSession sessionWithConfiguration:configuration delegate:self delegateQueue:nil];
    NSURL *url = [NSURL URLWithString:@"http://eyeforweb.info.bh-in-15.webhostbox.net/myconnect/api.php?token={LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUc4d0RRWUpLb1pJaHZjTkFRRUJCUUFEWGdBd1d3SlVBeWo0WE9JNjI4cnJRTG9YeEpXNG1zUWI1YmtvYk1hVQpzMnY1WjFKeXJDRWdpOVhoRzZlZk4rYTR0eGlMTVdaRXdNaS9uS1cyL1NCS2pCUnBYUzVGYUdiV0VLRG1WOXkvCkYrWHhsUXVoeER0MEV3YkRBZ01CQUFFPQotLS0tLUVORCBQVUJMSUMgS0VZLS0tLS0K}&amp;method=user.getLogin"];
    NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url
                                                           cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                       timeoutInterval:60.0];

    [request addValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
    [request addValue:@"*/*" forHTTPHeaderField:@"Accept"];
    [request setHTTPMethod:@"POST"];
    NSString *mapData = [NSString stringWithFormat:@"login=abc@gmail.com&amp;password=123456"];//,username.text, password.text];
    NSData *postData = [mapData dataUsingEncoding:NSASCIIStringEncoding allowLossyConversion:YES];
    [request setHTTPBody:postData];
    NSLog(@"map data is = %@",mapData);
    NSURLSessionDataTask * postDataTask = [session dataTaskWithRequest:request completionHandler:^(NSData * data, NSURLResponse* response, NSError * error) {

        if(error == nil)
        {
            NSDictionary *json = [NSJSONSerialization JSONObjectWithData:data options:kNilOptions error:&amp;error];
            NSString *text = [[NSString alloc] initWithData: data encoding: NSUTF8StringEncoding];
            NSLog(@"Data = %@",text);
            NSDictionary *jsonDic = [NSJSONSerialization JSONObjectWithData:data options:kNilOptions error:&amp;error];
            NSLog(@"jsondic= %@",jsonDic);

            NSDictionary *userDataDic = [jsonDic objectForKey:@"data"];
            NSLog(@"Dict is %@",userDataDic);
</code></pre>

<p>Please help me to resolve it i already see the similar type of questions but didn't overcome from this issue
Any help is appreciated </p>