Code Monkey home page Code Monkey logo

Comments (6)

Omicron7 avatar Omicron7 commented on September 22, 2024

I'm installing a windows VM with wordpress to try to get this figured out.
Information that would help solve this would be:

  • PHP Version.
  • WordPress version.
  • Values of:
    • ABSPATH
    • ACF_Address_Field::singleton()->base_dir
    • ACF_Address_Field::singleton()->base_uri_rel
    • if possible value of __FILE__ for address-field.php

from acf-address-field.

michapixel avatar michapixel commented on September 22, 2024

wp: 3.3.2
php: 5.3.9
ABSPATH: "D:\wamp\www\wordpress_test/"
base_dir: "D:\wamp\www\wordpress_test\wp-content\plugins\advanced-custom-fields-address-field-add-on"
base_uri_rel: "/D:/wamp/www/wordpress_test/wp-content/plugins/advanced-custom-fields-address-field-add-on"
FILE: "D:\wamp\www\wordpress_test\wp-content\plugins\advanced-custom-fields-address-field-add-on\address-field.php"

from acf-address-field.

Omicron7 avatar Omicron7 commented on September 22, 2024

Ahh, I see the issue. WordPress is adding a trailing slash to the ABSPATH that I'm not stripping off when doing string comparisons. Changing line 99 from
$root = array_pop( explode( DIRECTORY_SEPARATOR, rtrim( ABSPATH, DIRECTORY_SEPARATOR ) ) );
to
$root = array_pop( explode( DIRECTORY_SEPARATOR, rtrim( ABSPATH, '/' ) ) );
fixed it for my Windows VM.

from acf-address-field.

michapixel avatar michapixel commented on September 22, 2024

let me try it quickly ....

from acf-address-field.

michapixel avatar michapixel commented on September 22, 2024

yup much better now.

from acf-address-field.

Omicron7 avatar Omicron7 commented on September 22, 2024

ok, I'll get that merged into the development branch, it might be a bit before I can get a new version pushed to the WordPress plugin repo.

from acf-address-field.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.