[ticket/11271] Use class variable $db instead of global

PHPBB3-11271
[ticket/11271] Add the inline images html to content

PHPBB3-11271