PHP extract string in between [ and ]
<p>How to extract string between [ and ]</p>

<p>I tried using trim() but I believe trim() only works in removing spaces.</p>

<p>ex. [abc123-ab:ab123] 
output should be -> abc123-ab:ab123</p>
