Here is my code:
NSString *trimfeedback = [FeedbackTxtString stringByReplacingOccurrencesOfString:@"<br><u>Your
answer</u>:<ca>#ya#</ca><br><u>Correct answer</u>:<br>" withString:@"<p>"];
the string which is to be replace will be static and ‘FeedbackTxtString’ can contain text either ‘Correct answer’ or ‘Correct answers’ . I need to implement the OR case as i dont know what will be in ‘FeedbackTxtString’. If FeedbackTxtString contain ‘Correct answers’ then string to be replace should be <br><u>Your answer</u>:<ca>#ya#</ca><br><u>Correct answers</u>:<br>" withString:@"<p>, or if it contains ‘Correct answer’ then string to be replace should be <br><u>Your answer</u>:<ca>#ya#</ca><br><u>Correct answer</u>:<br>" withString:@"<p>
how could i do that ?
Do this: