Support

Account

Home Forums Search Search Results for 'save limit'

Search Results for 'save limit'

topic

  • Solved

    Stuck at 59 fields, not saving more

    Hi,

    I’m running into some kind of limitation issue where I can’t save any more additional fields for a specific group.

    The group currently has 59 fields and when I try to add one more field and update the group it only saves the field label but the field name keeps blank.

    I have no problem adding any new fields to other groups and I don’t get any errors after enabling wp_debug. Everything is fully updated and I also increased the php memory from 256mb to 512mb.

    I guess that it has something to do with the server/php configuration as stated in another similar topic. However increasing the php memory didn’t solve the issue. The current max_input_var is 1000 and the max_execution time is set to 60.

    I could split the fields and create an additional group but expanding the current group with more fields is more desirable.

    Is there anything that I could do server side to solve this? Or are there other things I should look for? Any help is much appreciated.

  • Solved

    Unknown column 'cwp_postmeta.meta_value'

    After Upgrade from 4 to 5.2.8 certain flexible-content-fields disappear from the frontend.

    The Field field_51dfa4b0fdc3e is such a flexible field that contains multiple post_object-references.

    They are saved to a custom post form the Plugin “Custom Post Widget” and attached via Widgets.

    In the previous version a get_field(‘fv_teaser’) returned the corresponding array. But with version 5 it only returns something like that:

    array (
      0 => 'foto_partner_teaser',
    )

    That’s the corresponding error-message:
    [29-Jul-2015 14:38:43 UTC] WordPress-Datenbank-Fehler Unknown column 'cwp_postmeta.meta_value' in 'order clause' für Abfrage SELECT cwp_posts.ID FROM cwp_posts WHERE 1=1 AND cwp_posts.post_type = 'acf-field' AND ((cwp_posts.post_status = 'publish')) AND cwp_posts.post_name = 'field_51dfa4b0fdc3e' ORDER BY cwp_postmeta.meta_value ASC LIMIT 0, 1 von require('wp-blog-header.php'), require_once('wp-includes/template-loader.php'), include('/themes/XXXXX/page-templates/XXXXXX.php'), get_sidebar, locate_template, load_template, require_once('/themes/XXXXX/sidebar.php'), dynamic_sidebar, call_user_func_array, WP_Widget->display_callback, apply_filters('widget_display_callback'), call_user_func_array, xxxxxWidgetsAVTeaser, get_field, get_field_object, acf_get_field, _acf_get_field_by_key, acf_get_field_id, get_posts, WP_Query->query, WP_Query->get_posts

  • Solving

    Standard Crop doesn't work on ACF Images

    I tried using the image crop plugin, for ACF, and found that it had some serious limitations (you have no way to know the dimensions of your cropped area while cropping, and you can’t retain the ratio of the set image size – good suggestions for future revisions).

    So, I’ve been forced to use WordPress’ original cropping tool (when you EDIT an image in the MEDIA LIBRARY), with the base Advanced Custom Fields plugin. So, if I crop an image from my media library (and choose “All image sizes” when I save the crop and save the revised image), and then add that image to a custom field … it doesn’t use the cropped version of the image.

    Any ideas why this happens?

  • Solved

    my_acf_save_post and conditional issues

    So I have a my_acf_save_post function that does a couple of things before it saves the post but it appears to be handling things strangely.

    <?php
    function my_acf_save_post( $post_id ) {
    
        
      // bail early if no ACF data
      if( empty($_POST['acf']) ) {
            
          return;
            
      }
    
      // bail early if editing in admin
      if( is_admin() ) {
        
        return;
        
      }
    
       //obtain the current page's post ID
      $project_id = get_the_ID();
            
      // array of field values
        $fields = $_POST['acf'];
    
      // specific field value
       $field = $_POST['acf']['assigned_project'];
       $field2 = $_POST['acf']['volunteer_role'];
    
      //check if person is wanting to be a teamleader, check if spot is filled
       if($field2 == 'Teamleader') {
        if (leaderCheck() == true) {
          header("Location: http://www.myurlpage.com");
          die();
        }
       }
    
      //check if project is full and bail/kick if true
      if(limitCheck() == true) {
    
        header("Location: http://www.myurlpage.com");
        die();
    
      }
      
       //update assigned field
       update_field('assigned_project', $project_id, $post_id);
    
        
    }
    
    // run before ACF saves the $_POST['acf'] data
    add_action('acf/save_post', 'my_acf_save_post', 1);
    ?>

    It works fine without the teamleader and limit check. But if I add them, when the user submits the form the page goes blank (rather than just reloading the page) and the post is still saved but just partially filled out.

    The functions leaderCheck and limitCheck both return true after checking a few things based on the get_posts array and are also saved in the plugins functions. Should I call these functions on the single.php page that I’m using the form on as well? Calling them in the function above doesn’t seem to do what I need them to.

    For more references here are the two other functions that are called in the above one:

    <?php
    function leaderCheck() {
      $teamLeaders = get_posts(array(
                    'post_type' => 'volunteer',
                    'role' => 'teamleader',
                    'meta_query' => array(
                      array(
                        'key' => 'assigned_project', // name of custom field
                        'value' => '"' . get_the_ID() . '"', // matches exaclty
                        'compare' => 'LIKE'
                      )
                    )
                  ));
    
      //store count
      $count = count($teamleaders);
    
       if ($count >= 1) {
    
        $filled = true;
      }
    
      return $filled;
    }
    ?>
    <?php
    function limitCheck() {
    
      //get the volunteers
      $volunteers = get_posts(array(
                    'post_type' => 'volunteer',
                    'meta_query' => array(
                      array(
                        'key' => 'assigned_project', // name of custom field
                        'value' => '"' . get_the_ID() . '"', // matches exaclty
                        'compare' => 'LIKE'
                      )
                    )
                  ));
    
      //store count
      $count = count($volunteers);
    
      //get project limit
      $projectLimit = get_custom_field('project_limit');
    
      if ($projectLimit >= $count) {
    
        $full = true;
      }
    
      return $full;
    }
    ?>
  • Solved

    ACF5 hangs with Flexible Content or Repeaters

    Hi,

    I think this is a strato.de specific problem but posting here anyway.

    If I am editing a page in wp-admin with multiple repeating fields or working with flexible content, after a certain number of fields or sections, when I click Update it just spins without saving.

    At the moment, I have a flexible content field with 6 sections (of 8 possible) being used, one of which is a repeater with 3 fields, so I don’t think this is excessive. It works fine and quickly on my local server with many more sections, on strato it hangs.

    If I add a 7th field it hangs, if I remove it, it saves. So it’s being limited somewhere.

    Any ideas how I can work out what’s going on?

  • Solving

    Flexible Content Field Limit Subfield Limit?

    I seem to have a limit to the amount of subfield that I can add to a layout for Flexible Content

    I know this because after I add a subfield and hit save, nothing is added.
    If I duplicate a layout of 5 and hit save, then 5 subfields after that duplicated layout will be deleted.
    If I clear 2 spots at the beginning. Then I can add 2 subfields at the end.

    This all points that there is an issue with subfield limits. I have purchased the the Flexible Content, Gallery, and Repeater

    Attached is the exported PHP file

    Please help my whole theme is based off your amazing plugin

    Thank You

  • Solving

    Fields only save as long as edit page is open

    Here’s a weird one.

    I’ve got a cpt with a number of fields. As of a couple days ago, if I edit a field on an existing post, and save it, it shows up on the front end, but as soon as i leave the edit page, it reverts back to the older version of the content of that field.

    Any idea what would cause this? i’ve never seen this before, especially the fact that the edits show on the live site until you leave the backend page.

    To my knowledge, no plugins were updated anytime last week before this happened, so i’m not sure why it just started. AND, the normal wordpress content area saves fine. So its only an ACF issue.

    Thoughts??

    My only idea is that it was a php limit, like max vars or something, but we’ve had no problems with this before.

    Hosted on wpengine.

    Thanks!!

  • Solving

    ACF not saving fields – tried everything

    Hey Guys,

    I am having the same problem that a few people discussed about in the forum however we couldn’t find a solution.

    We got to a point that the fields doesn’t save anymore.

    We have a couple of Repeaters and Flexible Content all together in one of our Custom Post Types.

    max_input_vars is on 500000 (Very large number) but still not working.

    If i move the field up and down it gets saved however the last one it wont get saved at all and we need to include a couple of new ones.

    Do we have any limits for repeater or flexible content being saved?

    Anything else to make it work? Any magic? Please HELP!!!!!!

    Details.
    – WordPress – Version 3.8.4
    – Advanced Custom Fields: Repeater Field – Version 1.1.1
    – Advanced Custom Fields: Flexible Content Field – Version 1.1.1 |

    Kind Regards,
    Andre.

  • Helping

    Conditional Logic limitation

    is there a limitation Conditional Logic rules? after around 11 rows i cant save anymore rules..
    can i enlarge this somehow?

  • Helping

    Flexible content type not saving last items in admin view

    I am using flexible content type with repeaters nested within it.

    I have a live site and a dev site. Dev is local and live is at HostGator. Both were working earlier and the client notified me that some items of content fell off on the live site. When I went in to troubleshoot I realized that the custom fields for the 9th item within the repeater is missing on the live site.

    So I tried to add it back in and it saves but the new custom field won’t show. I feel like everything after 8 items is just falling off. The reason for that is I can edit something in the first item but anything below the 8th won’t stick.

    I feel like the issue is something to do with config settings on live (although everything was working ok on the same servers) Here is what I have done to troubleshoot so far…I have access to the php.ini file and am verifying that my config changes are sticking by checking a phpinfo() file. I have ramped up all these settings: max_input_vars, post_max_size, max_execution_time, max_input_time, max_input_nesting_level, memory_limit

  • Solved

    Repeater field doesn't work with taxonomy term fields

    I’m trying to add a repeater field to “forms->taxonomy term” and it looks like repeater fields don’t save. Is this a limitation due to how taxonomy terms work?

  • Solved

    Unable to change/save values on pages

    I know there are a few posts on saving ACF values on pages. Unfortunately, I just spent several hours debugging this issue, and the PHP settings suggested here didn’t work:

    http://www.advancedcustomfields.com/faq/limit-number-fields/

    After trying about a billion things, I realized it was my theme. Apparently WordPress can get a bit picky with requirements regarding your theme. In my case, I didn’t have an index.php file in my theme (because I wasn’t using it), but that was causing the pages to (I guess) not register correctly with the correct page type.

    Once I added an index.php file to my active theme, all of my fields started updating again.

    If you’re debugging an issue with fields not saving, try the php.ini fixes, but also be sure your theme is following the recommended guidelines from WordPress.

  • Solved

    Limit Taxonomy Multi Select Dropdown

    How i can limit Taxonomy Multi Select input?

    I create Field with this setting :
    Field Type* = Taxonomy
    Field Type = Multiple Values – Multi Select
    Load & Save Terms to Post = checked

    I display the form in the front end. i already success to limit multiple values – checkbox, but i have a problem to limit Multi Select Dropdown.

    Can you help me?

  • Helping

    Repeater add-on bug!

    Hi there,

    I’ve been using your ACF plugin and add-ons for quite some time, thanks for your great work!

    One bug I discovered recently is related to the Repeater add-on. Apparently, I can only enter a limited number of values using the Repeater, around 243. If I add custom field values beyond that number it starts behaving weird, either values aren’t saved or some of them get lost. Are you aware of this bug, and is there a way to have it looked into?

    Awaiting your response,
    Alex

  • Solved

    Saving Data with Repeater Field / ACF API

    Hello,

    Thanks for the great plugin. I am trying to use the Repeater Field Addon with one of my custom plugins. Pretty much, when installing my plugin, I would like to register a predefined repeater field and have an admin user modify the data. I very easily was bale to register and display the repeater field in the admin but none of the data is being saved after submitting the post. I assume there must be some type of save function I need to call as well? Could you please point me in the right direction on how to accomplish this? Here is my register code:

    public function create_acf_field_repeater(){
    if(function_exists(“register_field_group”))
    {
    register_field_group(array (
    ‘id’ => ‘acf_pages’,
    ‘title’ => ‘pages’,
    ‘fields’ => array (
    array (
    ‘key’ => ‘field_53bafa11cf1de’,
    ‘label’ => ‘tweets’,
    ‘name’ => ‘tweets’,
    ‘type’ => ‘repeater’,
    ‘sub_fields’ => array (
    array (
    ‘key’ => ‘field_53bafa19cf1df’,
    ‘label’ => ‘tweet’,
    ‘name’ => ‘tweet’,
    ‘type’ => ‘text’,
    ‘column_width’ => ”,
    ‘default_value’ => ”,
    ‘placeholder’ => ”,
    ‘prepend’ => ”,
    ‘append’ => ”,
    ‘formatting’ => ‘html’,
    ‘maxlength’ => ”,
    ),
    array (
    ‘key’ => ‘field_53bafa41cf1e0’,
    ‘label’ => ‘json’,
    ‘name’ => ‘json’,
    ‘type’ => ‘text’,
    ‘column_width’ => ”,
    ‘default_value’ => ”,
    ‘placeholder’ => ”,
    ‘prepend’ => ”,
    ‘append’ => ”,
    ‘formatting’ => ‘html’,
    ‘maxlength’ => ”,
    ),
    array (
    ‘key’ => ‘field_53bb06882fce4’,
    ‘label’ => ‘approved’,
    ‘name’ => ‘approved’,
    ‘type’ => ‘checkbox’,
    ‘column_width’ => ”,
    ‘choices’ => array (
    1 => ‘approved’
    ),
    ‘default_value’ => 1,
    ‘layout’ => ‘vertical’,
    ),
    ),
    ‘row_min’ => ”,
    ‘row_limit’ => ”,
    ‘layout’ => ‘table’,
    ‘button_label’ => ‘Add Row’,
    ),
    ),
    ‘location’ => array (
    array (
    array (
    ‘param’ => ‘post_type’,
    ‘operator’ => ‘==’,
    ‘value’ => ‘page’,
    ‘order_no’ => 0,
    ‘group_no’ => 0,
    ),
    ),
    ),
    ‘options’ => array (
    ‘position’ => ‘normal’,
    ‘layout’ => ‘no_box’,
    ‘hide_on_screen’ => array (
    ),
    ),
    ‘menu_order’ => 0,
    ));
    }
    }

    Thanks!

    – Eric K

  • Solving

    Is there a cap on # of repeater rows displaying in admin?

    I used a repeater and update_field to populate entries to a draw (custom post) with name, userID, etc.

    Anyway, this works great but we got way more entries than every thought possible (1431)…

    Now when in the admin only 999 records (repeater rows) show.

    I guess there is a hard cap on this? Not sure if it’s WP or ACF thing?

    Either way all records are saved correctly and can be pulled to front-end.

    Just wondering of anyone knows if there is a way to change this limit.

    Thx!

  • Unread

    Front End Form: Possible to have a Publish and Save Draft?

    I’m building a front end submission form for my client (using ACF 4).

    They want registered users to be able to ‘save and return’ as well as ‘publish’.

    Each registered user is limited to publishing only one post.

    The solution I’ve come up with is to have two form-post buttons. One that publishes as ‘draft’ and another that publishes as ‘pending’.

    Is it possible to have two form-post buttons that have different publish behaviors?

  • Helping

    Using get_post_meta to get Flexible Fields?

    I’ll try and keep this as short, sweet, and concise as I can. So I’m letting users create JSON files for an API by filling out a Flexible Field. I need to build and save these JSON files anytime they updated the post so I don’t reach the limit of the number of times we can hit the API.

    Anyway, I need to use get_post_meta to pass the fields so I can build the JSON file. So here is what I have and these 3 work.

    $bc_id = get_post_meta( $post_id, 'page_biblio_2', true );
    $bc_uri = get_post_meta( $bc_id[0], 'request_uri', true );
    $bc_type = get_post_meta( $bc_id[0], 'type_of_request', true );

    But the next 4 are wrapped in a Flexible Field and do not work. What am I doing wrong?

    $bc_media = get_post_meta( $bc_id[0], 'media_type', true );
    $bc_audience = get_post_meta( $bc_id[0], 'audience', true );
    $bc_content = get_post_meta( $bc_id[0], 'content_class', true );
    $bc_custom = get_post_meta( $bc_id[0], 'custom_query', true );
  • Unread

    Problem with generated "Repeater" field

    I have a “Repeater” field which is generated like this:

    if(function_exists("register_field_group"))
    {
      register_field_group(array (
        'id' => 'acf_custom_object',
        'title' => 'Custom Object',
        'fields' => array (
          array (
            'key' => 'custom_images',
            'label' => 'Images',
            'name' => 'image_urls',
            'type' => 'repeater',
            'sub_fields' => array (
              array (
                'key' => 'custom_image',
                'label' => 'Image',
                'name' => 'image_url',
                'type' => 'text',
                'column_width' => '',
                'default_value' => '',
                'placeholder' => '',
                'prepend' => '',
                'append' => '',
                'formatting' => 'html',
                'maxlength' => '',
              ),
            ),
            'row_min' => '',
            'row_limit' => '',
            'layout' => 'row',
            'button_label' => 'Add Row',
          ),
        ),
        'location' => array (
          array (
            array (
              'param' => 'post_type',
              'operator' => '==',
              'value' => 'my_custom_post_type',
              'order_no' => 0,
              'group_no' => 0,
            ),
          ),
        ),
        'options' => array (
          'position' => 'normal',
          'layout' => 'default',
          'hide_on_screen' => array (
          ),
        ),
        'menu_order' => 0,
      ));
    }
    

    The field is NOT generated by Admin GUI, it gets generated in my functions.php together with the custom post type it belongs to.

    No I have the problem, that I could not add repeating values by a hook. It seems like in my hooked function the fields generated by code and not by GUI are not known/fillable?!

    Hooked function:

    function post_saved($post_id)
    {
      $images = array('test1.jpg', 'test2.jpg', 'test3.jpg');
      $values = array();
      foreach ($images as $n => $image) {
        $values[]['image_url'] = $image;
      }
      update_field('field_53562b25c883a', $values, $post_id);
    }
    add_action('pmxi_saved_post', 'post_saved', 10, 1);
    

    UPDATE:

    Ok, I’ve found the reason why the field (generated in functions.php) is not recognized in other hooks. It seems like the fields have to start with “field_”!!!

  • Unread

    Warning when hitting max_input_vars limit

    Hey Elliot,
    Not sure if this is really practical, but would it be possible to do a check that we’re not submitting an ACF Form that will exceed the max_input_vars, and if so throw a warning and stop the form from submitting?

    It could be a simple count of the number of fields (bonus points if you could get other fields on the page as well outside of ACF) to see if we’d be hitting that limit. I know it might not be possible to get an exact count (I think cookies are counted in the total for example), but close would be nice.

    I just hit the limit in the ACF Field editor, which caused me to lose the last field, which happened to be a repeater. It’s not the end of the world when you lose a normal field since get_field should still be able to retrieve the value, but I think with a Repeater it checks back to the original field, which was gone. Oddly enough once I finally managed to increase the limit and recreate the field, the content didn’t reappear on the front page. I had to go into the post and hit save for it to show up, even though when editing the post I could see the content.

    I think the number of fields was 47 if that helps.

    Cheers!
    Phill

  • Helping

    Flexible Content Displaying Zero's & Limited Fields

    Hello, love this plugin! I purchased the “Flexible Content” Add-On and I’ve got 2 problems that I’m hoping someone out there can help me solve.

    1) Display Zero’s
    My clients site needs to display zero’s if entered into the field, but if we enter “0” it doesn’t display on the front end. I know it’s because of the get_sub_field if statement that it’s not showing, and I also know that I can get it to work if I add !== false to the code, however, that makes it so empty items show up when there is no content. I need it to work like this…if the field is empty, don’t show it, if the field has content (any content including zero’s) show it. That’s it. Here’s the basic function I”m using:

    // Sand Equivalent
    if( get_row_layout() == 'sand_equivalent' ):
    if( get_sub_field('sand_equivalent-data') !== false):
    echo '<tr class="row row-section">';
    echo '<td class="column-1">D2419</td>';
    echo '<td class="column-2">T176</td>';
    echo '<td class="column-3"><strong>Sand Equivalent</strong></td>';
    echo '<td class="column-4">Sand Equivalent</td>';
    echo '<td class="column-5">' . get_sub_field('sand_equivalent-data') . ' </td>';
    echo '</tr>';
    endif;
    endif;
    

    2) Limited Fields with Flexible Content
    In my flexible content field, I have about 15 layout rows each having about 3-4 sub-fields. I need to have 19 layout rows, however the flexible fields won’t allow me to add more. I’ve read on these forums these helpful posts:

    I’ve tried the php.ini and the .htaccess solutions, as well as bumping the memory_limit and non of those fixed the issue. So my questions are:

    1. Are there any other solutions to get just a few more fields?
    2. Is this a limit of the Flexible Content Add-On? or would this same thing happen if I just used regular fields?
    3. It sounds like ACF5 will probably fix this, how soon until this is released?

    Thanks for your time and help today!

  • Unread

    Repeater, inside flex, inside repeater issue

    Hi

    I’ve run into an issue with nesting that I wanted to check out before I refactor everything. I’m basically facing the same problem as @LetterAfterZ in this thread:

    http://support.advancedcustomfields.com/forums/topic/nested-repeater-inside-a-flex-content-inside-a-repeater/

    I have a repeater that contains a flex content field and one of the layouts in the flex content field contains a repeater. Everything works as expected and I get no errors. The exception to this is that the sub fields in the final repeater are not being rendered – regardless of the type of field used – the result is always false.

    I did as @elliot suggested and debugged the first repeater (results here : https://gist.github.com/FourStacks/9806486)

    As you can see the final repeaters sub fields are blank (starts line 77). Bit weird this as the database shows the results as being saved (see same gist – line 205 onwards). The values post ids from a post object field.

    This is my code : https://gist.github.com/FourStacks/9806658

    Don’t think I’ve done anything daft there (tried using both have_rows and has_sub_field to no avail).

    I’m developing locally at the moment and my MAMP install has a reasonable memory limit so at a bit of a loss.

    Any help/advice would be much appreciated!

  • Solving

    Cannot save more than 64 fields in field group

    I have a problem when creating more than 64 fields in the fields group using plugin “Advanced custom fields”. I’ve already found out that problem is in saving of new fields not in loading from database, because when I put new field directly to database it is loaded and shown in plugin (in the list of fields).

    I was trying to find source of the problem and found out that fields are send in $_POST[“fields”] array. But when they are processed by plugin method the $_POST[“fields”] variable has only 64 fields in it (I tried count($_POST[“fields”])) even if there is more fields in the form.

    So I think that this array is cut to size of 64 somewhere in wordpress probably.

    I tried this

        
        add_filter( 'postmeta_form_limit' , 'customfield_limit_increase' );
        function customfield_limit_increase( $limit ) {
            $limit = 100;
            return $limit;
        }
    

    but it didn’t work. Any suggestions please?

  • Helping

    Complex taxonomy query

    Hi all!!

    May be you can help me on this.
    I have a custom post type ‘promotional_products’ with the title, content and thumbnail enabled.

    I created new repeatable acf and location is set to the multiple Taxonomy terms. These are custom taxonomies like – Ingredients, Food type, Events, Diets etc.

    The purpose to this is to link Promotional posts like drinks or juice, for example, to to certain reciepe ingredients.

    Lets imagine, I want to add the wine to all italian food type and food with pasta as ingredient. So I open the Taxonomy term Pasta from taxonomy edit page, add the relational posts of wine (repeater for unlimitness), Save and….

    …. I cannot figure out, how to display them on single post.

    Get the terms for this posts and find out, which terms has attached promotional posts.

    What do you think?

  • Helping

    Unable to save Table/Row preference in Repeater options

    I have quite a few repeater fields, and in them I have a few post object fields and an additional repeater field. Overall, a pretty nested situation.

    The primary repeater field has always been set on on Row view with no issues. Only recently did I receive a memory_limit error which has so far been fixed by increasing my PHP memory_limit. But since then, the view of the repeater field has switched to Table view. When I select to change that view to Row, I receive the “Updated successfully” alert, but the option doesn’t stick.

    What might be causing this?

Viewing 25 results - 51 through 75 (of 222 total)