Open theme. css
Add:
The max-width (image width) must be adjusted according to your needs
Open functions. php
Search:
Replace with:
Add:
.img {
height: auto;
max-width: 600px;
}The max-width (image width) must be adjusted according to your needs
Open functions. php
Search:
// 
$s = preg_replace("/\[img\]((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\[\/img\]/i", "<img border='0' src=\"\1\" alt='' />", $s);
// [img=http://www/image.gif]
$s = preg_replace("/\[img=((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\]/i", "<img border='0' src=\"\1\" alt='' />", $s);Replace with:
// 
$s = preg_replace("/\[img\]((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\[\/img\]/i", "<img border=\"0\" src=\"\1\" alt=\"\" class=\"img\">", $s);
// [img=http://www/image.gif]
$s = preg_replace("/\[img=((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\]/i", "<img border=\"0\" src=\"\1\" alt=\"\" class=\"img\">", $s);