Forum Replies Created

  • Thanks! This solved my marker problem in 5 minutes!

    Do you have any idea how to get the radius-circles to work?

    If I add the following code inside acf.add_filter('google_map_marker_args', function(args, $field) {}, the console tells me ‘google is not defined’.

    Here’s the code:

        var circle = new google.maps.Circle({
          map          : map,
          radius       : 1000,
          fillColor    : 'red',
          strokeColor  : 'red',
          strokeWeight : 1
        circle.bindTo('center', marker, 'position');
  • Is this method still working in the latest ACF version?

    I was working on a site locally until my database crashed last week. I used a customised version of your code for the last few weeks, but since I restored the site from a backup a few days ago I keep getting a 500 error when this function runs.

    Here’s my code:

    function my_upload_directory( $param ) {
      $mydir          = '/music';
      $param['path']  = $param['basedir'] . $mydir;
      $param['url']   = $param['baseurl'] . $mydir;
      return $param;
    function my_acf_upload_prefilter( $errors, $file, $field ) {
      // change the upload directory
      add_filter('upload_dir', 'my_upload_directory');
      return $errors;
    add_filter('acf/upload_prefilter/name=music-cover-art', 'my_acf_upload_prefilter');

    Any idea where the problem might lie? I’m using the exact same code that worked before, the only thing that has changed seems to be the ACF version (5.5.3 to 5.5.5)?

Viewing 2 posts - 1 through 2 (of 2 total)