Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7433325
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T09:39:05+00:00 2026-05-29T09:39:05+00:00

I’m parsing a json object and populating it in table view. When the table

  • 0

I’m parsing a json object and populating it in table view.

When the table view row is selected it navigates to a detailed view controller named as “ThirdDetailView” and was able to assign the parsed data in my ThirdDetailView (using web view).

Problem arises when my ThirdDetailView is one of the view in my four tab bars .I have placed those four tabbar in a view called firstView, So that clicking on the tableview navigates to firstView containing four tabbars showing the ThirdDetailView as highlighted as the first tab.if this is the case data is not getting loaded in the web view.

below is the code:

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
     title=[story objectAtIndex:indexPath.row];
 NSDictionary *detaildesc1=[media1 objectAtIndex:indexPath.row];
  ThirdDetailView *detailViewController1= [[ThirdDetailView alloc]init];
    [detailViewController1 initWithItem:detaildesc1 Title:title];

     FirstView *dvController4 = [[FirstView alloc] initWithNibName:@"FirstView" bundle:[NSBundle mainBundle]];
    [self.navigationController pushViewController:dvController4 animated:YES];

    [dvController4 release];

    [detailViewController1 release];
    }
    }

ThirdDetailView

@synthesize theItem1,theTitle,img,body,message,facebook,webview,id1;

     - (id)initWithItem:(NSDictionary *)detaildesc1 Title:(NSString *)title 
    {
if (self = [super initWithNibName:@"ThirdDetailView" bundle:nil]) {
    self.id1=detaildesc1;
    self.theTitle=title;
      urlAddress = [NSString stringWithFormat:@"http://dev-parkguiden.knutpunkten.se/Api/GetPark?parkid=%@",self.id1];
        baseURL =[[NSURL URLWithString:urlAddress]retain];
        jsonData=[NSData dataWithContentsOfURL:baseURL];

        // self.title=title;

        NSDictionary *items=[NSJSONSerialization JSONObjectWithData:jsonData options:NSJSONReadingMutableLeaves error:nil];

         boom=[items objectForKey:@"description"];
         NSLog(@"what is the text:%@",[items objectForKey:@"description"]);

         [self.webview loadHTMLString:boom baseURL:nil];
    }

return self;
    }

enter image description here

FirstView Tabbar
enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T09:39:06+00:00Added an answer on May 29, 2026 at 9:39 am

    Try Out this

    - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
     [[NSUserDefaults standardUserDefaults] setValue:[media1 objectAtIndex:indexPath.row] forKey:@"id1"];
        [[NSUserDefaults standardUserDefaults] setValue:[story objectAtIndex:indexPath.row] forKey:@"theTitle"];
    
         FirstView *dvController4 = [[FirstView alloc] initWithNibName:@"FirstView" bundle:[NSBundle mainBundle]];
        [self.navigationController pushViewController:dvController4 animated:YES];
    
        [dvController4 release];
    
        [detailViewController1 release];
        }
        }
    
    
     - (void)viewDidLoad {
    
    
        [super viewDidLoad];
        id1 =    [[NSUserDefaults standardUserDefaults] valueForKey:@"id1"];
        theTitle = [[NSUserDefaults standardUserDefaults] valueForKey:@"theTitle"];
        NSLog(@"hi %@", id1);
        hello=@"hello";
        NSLog(@"ahhhha sdfgs :%@",theTitle);
    
        urlAddress = [NSString stringWithFormat:@"http://dev-parkguiden.knutpunkten.se/Api/GetPark?parkid=%@",self.id1];
        baseURL =[[NSURL URLWithString:urlAddress]retain];
    
        jsonData=[NSData dataWithContentsOfURL:baseURL];
    
        NSDictionary *items=[NSJSONSerialization JSONObjectWithData:jsonData options:NSJSONReadingMutableLeaves error:nil];
    
        self.boom=[items objectForKey:@"description"];
        NSLog(@"retard:%@",self.boom);
        NSString *html = [NSString stringWithFormat:@"<html><body><p>%@</p></body></html>", self.boom];  
        [self.webview loadHTMLString:html baseURL:nil]; 
    
    
    }
    

    I have tested in my app in perfectly show your text in webview

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
i got an object with contents of html markup in it, for example: string
I have an MVC Razor view @{ ViewBag.Title = Index; var c = (char)146;
I'm parsing an XML file, the creators of it stuck in a bunch social
I used javascript for loading a picture on my website depending on which small
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.