• Hi,

    I have a problem with DS. I see this error PHP Warning: Constant DS already defined in /home4/root/website.com/wp-content/plugins/anspress-question-answer/anspress-question-answer.php on line 273

           private function setup_constants() {
    $plugin_dir = wp_normalize_path( plugin_dir_path( __FILE__ ) );

    define( 'DS', DIRECTORY_SEPARATOR );
    define( 'AP_VERSION', $this->_plugin_version );
    define( 'ANSPRESS_DIR', $plugin_dir );
    define( 'ANSPRESS_URL', plugin_dir_url( __FILE__ ) );
    define( 'ANSPRESS_WIDGET_DIR', $plugin_dir . 'widgets/' );
    define( 'ANSPRESS_THEME_DIR', $plugin_dir . 'templates' );
    define( 'ANSPRESS_THEME_URL', ANSPRESS_URL . 'templates' );
    define( 'ANSPRESS_CACHE_DIR', WP_CONTENT_DIR . '/cache/anspress' );
    define( 'ANSPRESS_CACHE_TIME', HOUR_IN_SECONDS );
    define( 'ANSPRESS_ADDONS_DIR', $plugin_dir . 'addons' );
    }

    On line 273 is this define( ‘DS’, DIRECTORY_SEPARATOR );

    How to fix this please?

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

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