Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [autoloading]

The tag has no usage guidance.

0
votes
1answer
13 views

Autoloading Classes in Plugins

In a custom WordPress plugin I have a folder /classes with about 20 classes. Classes sometimes change, come and go. I want all those classes from the folder to be loaded automatically. No my idea was ...
0
votes
1answer
26 views

BuddyPress and namespacing

I'm using PSR-4 autoloading and namespacing for a new plugin. However, because my plugin is namespaced (and all it's classes are), I can't seem to extend a BuddyPress class (BP_Attachment) ...
0
votes
1answer
22 views

Problem with autoloader and namespaces

I'm writing a simple plugin with oop and using namespaces and autoloading. Here is my main file: add_action('plugins_loaded', array(My_Test_Plugin::get_instance(), 'plugin_setup')); class ...
0
votes
1answer
184 views

Autoloader not finding classes from my plugin

I am trying to work with autoloader in my plugin. In the main file of my plugin I have use My_Plugin\Includes; require_once( plugin_dir_path( __FILE__ ) . 'includes/class-autoloader.php' ); $...
1
vote
0answers
13 views

Widgets Scripts don't load - but load when I reload the page

I've recently made my website and added facebook web plugin script and instagram script on the widget bar. But when I go from the Homepage to another Page it's not loading. It's just loading when I ...
0
votes
1answer
39 views

Reorganization of namespaces

First of all thank You for Your time. I use autoload in my 2 plugins. They have to different namespaces but i want to build one main plugin with autoload for this two plugins. In future i am going to ...
5
votes
1answer
553 views

Autoloading in Child Theme

I'm trying to autoload the vendor/autoload.php from my parent theme into my child theme. heres what i have tried but to no avail: function beast_theme_setup() { $var1 = get_theme_root_uri() . '/...