Home › Forums › General Issues › Ajax error: Class acf_field not found. › Reply To: Ajax error: Class acf_field not found.
Thanks for your response, actually this does not solve the issue. Let me explain better.
This is a part of my php file for the field:
<?php
class acf_field_number_range extends acf_field
{
(..)
<script type="text/javascript">
$("#slider").bind("valuesChanged", function (e, data) {
$.ajax({
type: "POST",
dataType: "text",
url: "../wp-content/themes/twentytwelve/fields/test.php",
data: { minValue: data.values.min, maxValue: data.values.max },
async: false,
success: function(data){
alert(data);
},
error: function(xhr) {
alert('fail')
}
});
});
</script>
But the alert popup gives this error:
Fatal error: Class ‘acf_field’ not found in /home/…/…etc/../..etc/ test.php</b> on line 3
How can I get these values of the range slider? Thanks
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.