Support » Plugin: Advanced Custom Fields » ACF Choices Not Updating on Frontend

  • solarinnovations

    (@solarinnovations)


    I cannot for the life of me figure out why changing the ‘choices’ for any of my ACF that were previously set up will not reflect my changes on the frontend.

    
    		$applications = search_meta_key('field_559551c77d1c6');
    		$allapplications = array();
    		foreach ($applications['choices'] as $application)
    		{
    			if ($application != 'Select an Application') //if using checkbox, comment 'else' out
    				$allapplications[$application] = $application;
    //			else 
    //				$allapplications[] = $application;
    		}
    		$args['fields'][] = array(  'type' => 'meta_key',
    									'label' => 'application',
    									'format' => 'checkbox',
    									'relation' => 'OR',
    									'data_type' => 'ARRAY<CHAR>',
    									'compare' => 'LIKE',
    									'meta_key' => 'application',
    									'values' => $allapplications 
    								);
    

    ACF Field Settings: https://imgur.com/O7EtNES
    Frontend where no changes are reflected: https://imgur.com/la3RL8p

    I have a custom post type, ‘projects’ where these fields are utilized.

    I’ve provided the link to the production site, since none of you will have access to the staging branch I’m working on. It should still provide a good example. Please do keep in mind though, I am working on a staging branch and have taken the necessary precautions against caching being the issue.

    I have disabled all caching plugins on the staging branch where I am working and confirmed there are no higher external caching services operating on my staging branch. I also have eliminated browser cache. This is an issue I have been hitting my head against the wall over for a few days now.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • solarinnovations

    (@solarinnovations)

    $applications = search_meta_key(‘field_559551c77d1c6’);

    If I change the field_XXXXXXXXX, the entire field breaks. But no matter where I specify this particular field, it brings up the list seen here https://imgur.com/la3RL8p instead of whatever I have input for my choices on the field.

    P.S. – Sorry for the poor code formatting in my original post. I see no option to edit so that I can fix it.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.