Например,
Код: Выделить всё
Hello there
Some text here
Some text here
Код: Выделить всё
Hello there [table1]
Some text here
[table2]
Some text here
[table3]
Код: Выделить всё
preg_match_all("@\
Подробнее здесь: [url]https://stackoverflow.com/questions/24309366/change-all-table-tags-with-preg-match-all[/url]