when i change the data inside the input field.
when using load_value do i change the properties of the input field?
im using add_filter('acf/load_value/name=my_select', 'my_acf_load_value', 10, 3);
to fill out some input fields on certain posts.
this all works well to fill out the input fields with what i get from the api.
The problem is when i change them and hit update they don’t seem to get saved in the wp db.
it also doesnt seem to be sent to
add_action('save_post', 'function');
add_action('update_post', 'function');
Thanks yeah i solved it that way….
function my_head_input()
{
?>
<style type="text/css">
.field {width:50%; display:inline-block; vertical-align: top; -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box; padding:10px !important;}
.field_type-repeater,.field_type-true_false {width:100%; padding: 10px 0!important;}
</style>
<script type="text/javascript">
jQuery(document).ready(function(){
"use strict";
var isbn = jQuery('#acf-field-isbn').val();
if (isbn) {
jQuery('#acf-isbn p').append('<br><a href="http://www.bokrondellen.se/'+isbn+'.aspx" target="_blank"> Boklänk till Bokrondellen '+isbn+'</a>');
}
});
</script>
<?php
}
add_action('acf/input/admin_head', 'my_head_input');
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.