Вопрос

I am building an app with a lot of urls being called from a MySQL server.

What I need to do for my app is take the textfield text and send it (which i already know how to do) BUT i need to replace the spaces with + (pluses)

Это было полезно?

Решение

Try with the string method - (NSString *)stringByReplacingOccurrencesOfString:(NSString *)target withString:(NSString *)replacement;

str=[str stringByReplacingOccurrencesOfString:@" " withString:@"+"];
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top