MyBB Community Forums

Full Version: Maximum Images per Post is not working
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi Experts,

I am having a problem in the mybb forum, though i have given Maximum Images per Post 20, i am not able to post more than 5 images in thread here in my post i am not including smiles, is any other setting i need to do ...

My site URL is ..

http://makeadvise.com/

Thanks in advance....

Thanks & Regards,
Prince
Did you look at the attachment quota (in kB) for the usergroup of interest?
(2015-02-02, 04:00 PM)Ad Bakker Wrote: [ -> ]Did you look at the attachment quota (in kB) for the usergroup of interest?


Hi thanks for reply, yes i checked i have uploaded only 40 KB JPEG images in max type it's given 500 KB, please find the attached image for reference..

[attachment=33678]

Please reply ...Thanks...

Thanks & Regards,
Prince
OK, but these are the maximum sizes per document. Look at:

AdminCP->Users&Groups->Groups-> Edit usergroup of interest->Forums & Posts

and then nearly at the bottom of the page "Attachment Quota". This number in kB should be large enough to hold all your attachments.

In addation I see in my inc/settings.php file at line 230:

$settings['maxattachments'] = "10";

This means that there is a maximum of 10 attachments per post, check what this number is with you.
This also is in contradiction with AdminCP->Configuration->Posting where the maximum number of images is set (with me) at 20.

I will hear of your findings Smile .
(2015-02-02, 09:41 PM)Ad Bakker Wrote: [ -> ]OK, but these are the maximum sizes per document. Look at:

AdminCP->Users&Groups->Groups-> Edit usergroup of interest->Forums & Posts

and then nearly at the bottom of the page "Attachment Quota". This number in kB should be large enough to hold all your attachments.

In addation I see in my inc/settings.php file at line 230:



$settings['maxattachments'] = "10";

This means that there is a maximum of 10 attachments per post, check what this number is with you.
This also is in contradiction with AdminCP->Configuration->Posting where the maximum number of images is set (with me) at 20.

I will hear of your findings Smile .

Thanks for reply here in my settings i changed  Attachment Quota now it is 2000 KB, and i already made maximum number of images is set (with me) at 40, and
$settings['maxattachments'] = "10";
..

but after all of this i am not getting Add Attachment button on the post, it's getting hide after 5th image and only update button is coming (Please find below attached screen)..for  all user, admin, moderator ..every role .. 
[attachment=33681]

Thanks for your help ...please reply...

Thanks & Regards,
Prince
OK, this really is strange because I tried it and it went good until the 11th attachment.
The decision to show the button is made in newreply.php, newthread.php and editpost.php. Now let us try newreply.php and do some rudimentary debugging. Line 1200 is the line where the decision is made, this reads:

if($mybb->settings['maxattachments'] == 0 || ($mybb->settings['maxattachments'] != 0 && $attachcount < $mybb->settings['maxattachments']) && !$noshowattach)

Now add the following before this:

echo "maximum attachment setting = ".(string)$mybb->settings['maxattachments']."<br />";
echo "attachment count = ".(string)$attachcount."<br />";
echo "noshowattach = ".(string)strlen($noshowattach)."<br />";

Add attachements to a new reply to an existing thread and look at what is displayed at the top and show a screenshot here.
Hope to hear from you because I'm curious tooSmile
Hi,


Thanks you soooooo much Smile now it's working ....thanks for your help ...


Thanks & Regards,
Prince
Good to hear. What caused the problem, and what was the solution?
Hi,

I tried the last one code in newreply.php file and it's working now ...

Thanks & Regards,
Prince