Forum

Thread tagged as: Problem, Error, Third-party

Repeating region image upload fails beyond the 13th item

I've come across a strange error whereby in a repeating region with images, item 13 and up does not upload properly.

The repeating region in question is an image gallery with a thumbnail image and main image upload. The gallery uses a plugin called Royalslider, but i don't think this is a contributing factor. You can see a page from the website using this gallery here.

Each item has two image uploads, one for the thumbnail, and one for the full image. (It also has an optional youtube/vimeo url input). I have included the code for this template below.

I start uploading items, selecting a thumbnail image and a main image, and then hitting "Save & add another". I continue doing this for a while, creating more and more items.

It's when I reach item number 13 the trouble starts. As before I add a thumbnail image and a main image and click "Save & add another". The thumbnail uploads fine, and the next item is created, but the main image does not upload.

If i try to upload images for item number 14 or higher, no images are uploaded at all.

In case my explanation isn't making much sense i have created a pdf that visually explains this upload error, you can download it here.

I hope someone can help with this, i need to know why this is happening, and what i can do to fix it.

Thank you

Here is the template code for the image gallery item:

<img class="rsImg" src="<perch:content id="logo1" type="image" label="Gallery Item (Max: 928x650px)" width="928" height="650" crop="true" quality="100" order="2" />" data-rsTmb="<perch:content id="logo2" type="image" label="Gallery Item Thumb (54x54px)" width="54" height="54" crop="true" quality="100" order="1" />" data-rsVideo="<perch:content id="heading" type="text" label="Optional: Vimeo URL (NOT embed code)" required="false" order="3" />" />

And this is the Diagnostics report

Perch: 2.4.5
Production mode: Production (100)
Installed apps: content (2.4.5)
DB driver: PDO
DB tables: perch2_content_index, perch2_content_items, perch2_content_regions, perch2_content_resources, perch2_navigation, perch2_navigation_pages, perch2_page_templates, perch2_pages, perch2_resources, perch2_settings, perch2_user_privileges, perch2_user_role_privileges, perch2_user_roles, perch2_users
Users: 2
App runtimes:
<?php
    include(PERCH_PATH.'/core/apps/content/runtime.php');
?>
Editor plug-ins: markitup
H1: ad59c36f99a07ca5faa474b705995fa9
L1: 1a53a8f4e88b2617f17fff263ad84af4
headerColour: #ffffff
content_singlePageEdit: 1
helpURL:
siteURL: /
hideBranding: 0
content_collapseList: 1
lang: en-gb
update_2.4.5: done
latest_version: 2.8
on_sale_version: 2.8.7
PERCH_DEVELOPMENT: 10
PERCH_STAGING: 50
PERCH_PRODUCTION: 100
PERCH_DB_USERNAME: glory415_user
PERCH_DB_SERVER: localhost
PERCH_DB_DATABASE: glory415_perch
PERCH_DB_PREFIX: perch2_
PERCH_TZ: Europe/London
PERCH_EMAIL_FROM: (removed for privacy)
PERCH_EMAIL_FROM_NAME: (removed for privacy)
PERCH_LOGINPATH: /perch
PERCH_PATH: /home/glory415/public_html/perch
PERCH_CORE: /home/glory415/public_html/perch/core
PERCH_RESFILEPATH: /home/glory415/public_html/perch/resources
PERCH_RESPATH: /perch/resources
PERCH_HTML5: 1
PERCH_ERROR_MODE: DIE
PERCH_DATE_LONG: %d %B %Y
PERCH_DATE_SHORT: %d %b %Y
PERCH_TIME_SHORT: %H:%M
PERCH_TIME_LONG: %H:%M:%S
PERCH_DEBUG:
PERCH_PREVIEW_ARG: preview
PERCH_TEMPLATE_PATH: /home/glory415/public_html/perch/templates
PERCH_DEFAULT_DOC: index.php
PERCH_DEFAULT_EXT: .php
PERCH_PRODUCTION_MODE: 100
PERCH_RWD:
PERCH_HTML_ENTITIES:
PERCH_AUTH_PLUGIN:
PERCH_DB_CHARSET: utf8
PERCH_DB_PORT:
PERCH_DB_SOCKET:
Kai Nodland

Kai Nodland 0 points

  • 6 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

It sounds like you're hitting your server's configured limit for the number of fields in one form.

You can work around it by changing the "Edit all on one page" option in the Region Options.

Thanks Drew,

I'll give that a go and report back.

If this is the case is there a way to go beyond the servers limit? Where would be a good place to start looking?

Rachel Andrew

Rachel Andrew 394 points
Perch Support

You would need to increase the max_input_vars setting on your server

https://php.net/manual/en/info.configuration.php#ini.max-input-vars

Huzzah! it works, Thanks Drew. And thanks Rachel, I will probably have to contact my hosts support for that one.

Seeing as i now have to keep the "Edit all on one page" option unchecked for these regions, i need to add this to the Master pages. But it seems that master pages do not copy the region options from the referenced page, is there a way to do this?

Drew McLellan

Drew McLellan 2638 points
Perch Support

There's not, as each region has its own independent options which are (presumably) appropriate to its content.

Ok, thanks for the clarification Drew