Support

Account

Home Forums Search Search Results for 'max_input_vars = 3000'

Search Results for 'max_input_vars = 3000'

topic

  • Solving

    ACF new repeater fields won't save value

    Dear all,

    I asked the support for help like two weeks ago. That didn’t work (yet). So to speed up to process I’m posting this issue on here.

    I have searched for a solution on the internet and I can’t seem to find the solution to my problem. Before I start, the plugin worked before great without any issues.
    But I found out after making some new repeater fields (got a lot of them) that they won’t save. The field that I didn’t touch in the ACF Custom Fields Group editor is still working. But the newly created fields won’t save.

    What I did to try and fix this problem is the following:
    I already tried to increase the max_input_vars in the PHP settings a few days ago.

    his is how the php.ini file looks like:
    upload_max_filesize = 128M
    max_execution_time = 120
    post_max_size = 228M
    max_input_vars = 6000
    date.timezone = “Europe/Amsterdam”
    memory_limit = 768M
    max_input_time = 120
    zend_extension=/usr/local/php56/lib/php/extensions/ioncube.so
    zend_extension=/usr/local/php56/lib/php/extensions/ZendOptimizer.so
    suhosin.get.max_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000

    Also, we have contacted our server hosting team (Siteground) and they have ensured us this way: “In this case, I would personally recommend to reach the devs of this plugin and ask them to further troubleshoot for you. As right now, I’ve increased all of the values to the maximum possible on a server level and for 99% of the plugins is plenty of “power”. That’s why please reach them back and ask for further instructions as currently on a server level everything is set correctly.”

    The next step for me was to disable all plugins and narrow down the possible cause of this problem. Again nothing helped even with disabling all plugins except for ACF (what I need to work and where the issue is).

    Also, I got the newest version of ACF so that cannot be the problem also?

    I am hoping for a solution, here is a snippet of the code:

    <!-- gerwin uitprobeersel !-->
    <?php if( have_rows('product') ): ?>
    <?php while( have_rows('product') ): the_row(); ?>
    <div class="betonelementholder" id="<?php the_sub_field ('product_titel'); ?>">
      <div class="betonelementboxen">
        <a href="<?php the_sub_field ('product_link'); ?>">
          <div class="betonelemtenboxleft">
            <img src="<?php the_sub_field ('product_afbeelding'); ?>" title="<?php the_sub_field ('product_afbeelding_titel'); ?>" alt="<?php the_sub_field ('product_afbeelding_alternatieve_tekst'); ?>">
          </div>
        </a>
        <div class="betonelementenboxright">
          <figure>
            <figcaption>
              <h2>
                <?php the_sub_field ('product_titel'); ?>
              </h2>
              <span class="sport_main_title_green">
                <?php the_sub_field ('product_subtitel'); ?>
              </span>
            </figcaption>
          </figure>
          <div class="description">
            <p>
              <?php the_sub_field ('product_omschrijving'); ?>
            </p>
          </div>
          <a href="<?php the_sub_field ('product_link'); ?>">
            <div class="elementbutton">
              <?php the_sub_field ('btn_text');?>
              meer informatie
            </div>
          </a>
        </div>
      </div>
    </div>
    <?php endwhile; ?>
    <?php endif; ?>
    <!-- end gerwin uitprobeersel !-->
    
  • Solving

    Repeater field with multiple flexible content fields having problems

    Hi-

    Giant Images: Before and After

    I have a Repeater field which contains a dropdown and three Flexible Content fields. The Flexible Content fields (are supposed to) each contain the same 5 layouts: title, blurb, image, video, button.

    An example of the field layout I am going for “Field Name (Field Type)”:

    Sections (Repeater)
        Columns (Dropdown)
        Column 1 (Flexible Content)
            Title
                Title (Text)
            Blurb
                Blurb (Textarea)
            Image
                Image (Image)
                Link (URL)
            Video
                Video (oEmbed)
            Button
                Button Text (Text)
                Button Link (URL)
        Column 2 (Flexible Content)
            Title
                Title (Text)
            Blurb
                Blurb (Textarea)
            Image
                Image (Image)
                Link (URL)
            Video
                Video (oEmbed)
            Button
                Button Text (Text)
                Button Link (URL)
        Column 3 (Flexible Content)
            Title
                Title (Text)
            Blurb
                Blurb (Textarea)
            Image
                Image (Image)
                Link (URL)
            Video
                Video (oEmbed)
            Button
                Button Text (Text)
                Button Link (URL)

    After saving this, I end up with something like this:

    Sections (Repeater)
        Columns (Dropdown)
        Column 1 (Flexible Content)
            Title
                Title (Text)
            Blurb
                Blurb (Textarea)
            Image
                Image (Image)
                Link (URL)
            Video
                Video (oEmbed)
            Button
                Button Text (Text)
                Button Link (URL)
        Column 2 (Flexible Content)
            Title
                Title (Text)
                Blurb (Textarea)
                Image (Image)
                Link (URL)
                Video (oEmbed)
                Button Text (Text)
                Button Link (URL)
            Blurb
            Image
            Video
            Button
        Column 3 (Flexible Content)

    Notice how in Column 2, all fields have moved to be underneath Title and Column 3 is just empty.

    I did some Googling around and saw mentions of max_input_vars and upped that from 1000 to 3000, but that seems to have made it even worse. The column fields will move to be inline with the column # dropdown field.

  • Solved

    5th field is not shown in frontend

    Hi,

    I created the fieldgroup “Rahmenbedingungen” including five costum fields. All the same type etc.

    But the 5th field “hallengroesse” is not shown in the frontend. For example:

    http://handball-pro.de/passkontinuum-stossen/

    I already added the code the .htaccess and created a php.ini:

    php_value max_input_vars 3000
    php_value suhosin.get.max_vars 3000
    php_value suhosin.post.max_vars 3000
    php_value suhosin.request.max_vars 3000

    Thanks for your help.

  • Solved

    Option Fields not saving within Flexible Content

    Hi @elliot,

    Just encountered a bug when saving values within a 2x repeaters and flexible content field. It says it saves fine, and appears to have saved. But then I left the options page (after saving), and then re-entered, and it didn’t actually save it.

    Using Options, Flexible Content and Repeater plugins. Have tried disabling other plugins, just having ACF by itself – but didn’t change anything.

    I’ve also tried flushing out post revisions, still no luck.

    I’ve tried changing the PHP settings, including all of the below:

    max_input_vars = 3000;
    max_input_nesting_level = 128;
    max_input_time = 300;
    max_execution_time = 300;
    post_max_size = 32M;
    memory_limit = 300M;

    But didn’t fix it unfortunately.

    I will attach a private login example, so you can check it out.

    Does anybody know a fix for this?

    Kind Regards,
    Matt

reply

  • ACF has advised that this might be due to “hitting a limit on the number of variables that can be used on a single page load on your server”.

    We followed their instructions to edit the php.ini file on the server and add max_input_vars=3000 and it seems to have fixed the issue.

  • Hi @johnstew

    It is possible that you are hitting the max_vars limit on your server and you can fix this by making the following changes to your php.ini file:

    max_input_vars = 3000
    suhosin.get.max_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000

    Let me know if this helps.

  • Hi @saadsohailk

    This is possibly due to PHP limiting the number of variables.

    Try to increase this by adding
    max_input_vars = 3000

    In you php configuration.

    Let me know if it helps.

  • Hi @thestart,

    Thanks for the post.

    It is possible that your server is terminating the save process before ACF can finish the field’s save process.

    Please increase your max_vars setting by making the following changes to your php.ini file:

    max_input_vars = 3000
    suhosin.get.max_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000
  • Hi @gwenzez

    Thanks for the question.

    There is no limit to the number of custom fields that can be added to a field group or in your case the repeater. Your server might be terminating the save process before ACF completes its job, you will need to increase the max_vars PHP setting. You can make the following changes to your php.ini file:

    max_input_vars = 3000
    suhosin.get.max_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000

    The WSOD might also be as a result of a plugin conflict, please deactivate all other installed plugins and switch to one of the stock WP themes to check if the issue will still pop up.

    To update the plugin you will need to log in as an admin.

  • Thanks for the responses. I’m actually on a dedicated server, so increasing the memory really does increase the memory. And yes, I’m sure that my max_input_vars and memory limit are correct by verifying in the php info.

    I added these:
    max_input_vars = 3000
    suhosin.get.max_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000
    Per the FAQ, although I bumped those all up to like 16000 with still no results. And memory is at 800MB currently.

    I was in the process of adding new fields when this started happening. I had to add 7 and I made it to 5 before it stopped working for the final 2. So I’m sure that no other plugins were updated or installed and I’m certain nothing else on the site was being changed either during the additions. It just decided to stop at 60 and making these changes hasn’t worked. I’ve also checked the database manually to be sure that it wasn’t some display issue, but the new entries I created (that ACF said were created successfully) are not in the database either. Thanks again.

  • Hi @bruno-martins

    I am not sure what you mean by “It does not work” is the Repeater field not saving values? If this is the case, it may be related to the field_name length.

    ACF uses the field’s name to save a value into the database. When saving sub fields, the ‘save name’ is generated by the ancestors names + the row index and can become quite long. It is possible that the length of this ‘save name’ can become too long for the wp_options table, and WP will not be able to save the value at all.

    You can solve this by reducing the field name length.

    If the issue is to do with the field not saving, you can make the following changes to the php.ini file:

    max_input_vars = 3000
    suhosin.get.max_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000
  • Thanks Hube2. I have been developing locally in MAMP Pro. Here is what I did after some research into the solution you recommended.

    I increased this ‘max_input_vars = 3000’.

    In MAMP that is under File > Edit Template > PHP

  • ok … looks like this is caused by the new default max_input_vars=1000 in php.ini. Changing that limit to 3000 solved the issue for me.

    Maybe it is possible to add a check into ACF to issue some kind of information or error if this happens?

  • There’s some similiar types of issues on the forum here:

    http://support.advancedcustomfields.com/forums/search/?bbp_search=max_input_vars+%3D+3000

    What solved my issue was dropping the following into the top of my WP site’s .htaccess file:

    php_value max_input_vars 7000

  • After much research and much reading… I found the answer via another post on this website. I had to increase my php settings to allow more variables to be inputed.

    max_input_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000

    The post with the answer:

    http://support.advancedcustomfields.com/forums/search/?bbp_search=max_input_vars+%3D+3000

    Eliot, I know this issue is not related to your plugin, but just a php setting. However since it seems like a few people have already experienced the same issue, maybe you could have common solutions as this one placed somewhere easy to find in your support forum.

  • Silly me, of course the answer was not number of fields, but number of post vars…

    72 fields just happened to push the post vars count over PHP 5’s default limit of 1000. This issue also crops up with really large menus in WP.

    The fix:

    Add a php.ini file to /wp-admin/ and put these settings in there (assuming your host allows php.ini overrides):

    
    max_input_vars = 3000
    suhosin.post.max_vars = 3000
    suhosin.request.max_vars = 3000
    

    From: http://anothersysadmin.wordpress.com/2012/02/16/php-5-3-max_input_vars-and-big-forms/

Viewing 16 results - 1 through 16 (of 16 total)