0

私はいくつかのテキストを持っています

some text [http://abc.com/a.jpg] here will be long text 

can be multiple line breaks again [http://a.com/a.jpg] here will be other text

blah blah

私が変身する必要があるのは

<div>some text</div><img src="http://abc.com/a.jpg"/><div>here will be long text 

can be multiple line breaks again</div><img src="http://a.com/a.jpg"/><div>here will be other text

blah blah</div>

<img>タグを取得するために、 に置き換え\[(.*?)\]<img src="$1"/>結果、

some text<img src="http://abc.com/a.jpg"/>here will be long text 

can be multiple enters again<img src="http://a.com/a.jpg"/>here will be other text

blah blah

ただし、テキストを でラップする方法がわかりません<div>

RegexKitLiteを使用してiPhoneですべてを行っています

4

1 に答える 1