title: How to display image on UIImageView using URL and NSString in ios?
body: <p>I want to display image on <code>UIImageView</code>  using URL and <code>NSString</code>. I am unable to show image.</p>
  
  <p>My code is:</p>
  
  <pre><code>UIImageView *view_Image = [[UIImageView alloc]initWithFrame:CGRectMake(view_Image_Pos_X, view_Image_Pos_Y, 179, 245)];
  
  view_Image.backgroundColor = [UIColor greenColor];
  view_Image.tag = img;
  view_Image.userInteractionEnabled=YES;
  view_Image.autoresizesSubviews = YES;
  view_Image.alpha = 0.93;  
  [self.view addSubview:view_Image];               
  </code></pre>
  
  <p>Here what i am trying:</p>
  
  <pre><code> if (img == 0) {
  
  
   NSString *url_Img1 = @"http://opensum.in/app_test_f1/;";
   NSString *url_Img2 = @"45djx96.jpg";
  
   NSString *url_Img_FULL = [NSString stringWithFormat:@"%@%@", url_Img1,url_Img2];
  
   NSLog(@"Show url_Img_FULL: %@",url_Img_FULL);
  
  
  
   NSURL *url_img = [NSURL URLWithString:url_Img_FULL];
   NSLog(@"Show: url_img %@",url_img);
  
  // Here below line working perfectly and image is showing             
  
  view_Image.image = [UIImage imageWithData:[NSData dataWithContentsOfURL:[NSURL URLWithString:@"http://opensum.in/app_test_f1/45djx96.jpg"]]];   // working code
  </code></pre>
  
  <p>but i dont want this i want to concatanate two url make one url(ie;url_Img_FULL) and then pass to an image like below:</p>
  
  <p><code>UIImage *image = [UIImage imageWithData:[NSData dataWithContentsOfURL:[NSURL URLWithString:url_Img_FULL]]];  // Not Working</code>   </p>
  
  <p>I Want from "url_Img_FULL" (ie: combination of two url) The image will show.
  You can check also the url is working properly.
  Any idea?</p>