title: How do I add a UITextView to this UITableViewCell?
body: <p>I have a <code>UITableViewCell</code> that is dynamically sized based on the content in it.  I do this in <code>heightForRowAtIndexPath</code> as follows:  </p>
  
  <pre><code>- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
  {
    if (indexPath.section == 1 &amp;&amp; indexPath.row == 1) {
      NSDictionary *fields = self.messageDetailsDictionary[@"fields"];
      NSString *cellText = fields[@"message_detail"];
      UIFont *cellFont = [UIFont systemFontOfSize:14.0];
      CGSize constraintSize = CGSizeMake(self.tableView.frame.size.width - 50.0f, MAXFLOAT);
      CGSize labelSize = [cellText sizeWithFont:cellFont constrainedToSize:constraintSize lineBreakMode:NSLineBreakByWordWrapping];
      return labelSize.height + 20.0f;
    } else {
      return tableView.rowHeight;
    }
  }
  </code></pre>
  
  <p>In <code>cellForRowAtIndexPath</code> I customise the cell as follows:  </p>
  
  <pre><code>case 1:{
    UITableViewCell *cell = [[UITableViewCell new] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"DetailCell"];
    if (cell == nil) {
      cell = [[UITableViewCell new] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"DetailCell"];
    }
    NSDictionary *fields = self.messageDetailsDictionary[@"fields"];
    cell.selectionStyle = UITableViewCellSelectionStyleNone;
    cell.textLabel.lineBreakMode = NSLineBreakByWordWrapping;
    cell.textLabel.font = [UIFont systemFontOfSize:14.0];
    cell.textLabel.numberOfLines = 0; // This means multiline
    cell.textLabel.text = fields[@"message_detail"];
    return cell;
  }
  </code></pre>
  
  <p>This all works fine, however I want the content of the cell to detect phone numbers, dates/times etc.  So I think I need to have the content in a <code>UITextView</code> within the <code>UITableViewCell</code> to make this possible.</p>
  
  <p>How can I dynamically size the <code>UITextView</code> and add it to the cell with the content by modifying my code above?  Sample code please with answers because I've already tried adding the UITextView as a subview of the cells contentView but it's not working as I'd expect.</p>