TTStyledTextLabel issue with URL's

I have added a TTStyledTextLabel inside my CustomCell for my UITableView, the code is:

  TTStyledTextLabel * tt_title = [[[TTStyledTextLabel alloc] initWithFrame:CGRectMake(50, cell.frame.origin.y, 640, 200)] autorelease];
    tt_title.text = [TTStyledText textWithURLs:[[self.posts objectAtIndex:indexPath.row] message]];
    tt_title.font = [UIFont systemFontOfSize:15];
    tt_title.contentInset = UIEdgeInsetsMake(10, 10, 10, 10);
    [tt_title sizeToFit];
    [cell addSubview:tt_title


The NSString passed in has a URL, however when I click on the URL it doesn't do anything.. not even opening it up in safari.. why is this?


Not sure exactly without seeing what is in the actual string you're passing in to TTStyledText, but as an alternative you could try using

[TTStyledText textFromXHTML:[[self.posts objectAtIndex:indexPath.row] message] lineBreaks:NO URLs:YES];

and add <a href=''></a> to your string

Need Your Help

zip file content type for http request

ios http nsurlrequest

I am sending a zip file to server via HTTPREQUEST what should the content-type be for this kind of file?

Can multiple WT application run on the same webpage?

c++ visual-studio-2010 embed webpage wt

so recently I asked a question to see if Can multiple WT applications run on same port? and the answer was a yes, (+1 to Jorge Núñez for that awesome answer). However, now I am trying to take his

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.