MyBB Community Forums

Full Version: Set maximum size limit for MyCode Image insert??
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
(2012-04-29, 06:22 PM)anori Wrote: [ -> ]
(2012-04-29, 06:15 PM)GunnerAIO Wrote: [ -> ]That's what I'd want but in either existing stock MyCode that I can't edit via configuration>MyCode... or global css. So where could I edit the stock MyCode buttons because they aren't listed in the config section??


Simply create a new MyCode (will overwrite the default and when you delete the default becomes active again):

then insert
regular expression:
\[img\](.*?)\[/img\]

And the replacement:
<a href="javascript:void(0)" onclick="window.open('$1', '', 'toolbar=no');myWindow.focus();"><img src="$1" style="max-width: 640px;" alt="Image" title="Full sized Picture" /></a>

Determine the width of your site first though, which can be found in the css templates.

working perfectly on my forum : http://www.camotesislandforum.com/showth...d=17#pid17
(2012-04-29, 02:09 PM)Euan T Wrote: [ -> ]The plugin does add a MyCode, but it's simply so you can post pictures larger than the limit. You can easily remove the MyCode IIRC.

What I'd do is something like this:

.post_body img {
    max-width: 80%;
}

That would make images have a maximum width of 80% of the post container.

Sorry for the bump but I tried this with no luck. It only works in Google Chrome but not with firefox.
Anyone? Please?
Can you take a screenshot or provide a URL where it does not work? It should work just fine on Firefox.
Thanks.
Tried Fit on Page with no luck.
Pages: 1 2