Skip Navigation

[Closed] Im trying to integrate loader.php to functions. I am using a child theme

This support ticket is created 8 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Our next available supporter will start replying to tickets in about 1.65 hours from now. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 -
- - - - - - -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 5 replies, has 2 voices.

Last updated by Waqas 8 years, 5 months ago.

Assisted by: Waqas.

Author
Posts
#342284

I am trying to setup installer loader files and toolset_import folder into child-theme. Are they supposed to go into the parent folder or child folder. Also, i dont understand where in the functions.php folder(parent/child) the loader.php code needs to go.

The code on https://toolset.com/documentation/embedded-toolset/building-and-distributing-toolset-based-themes/ shows the code for affiliate, i do not see that code anywhere in my loader.php file

#342345

Do i put the code from the loader.php file into the functions.php or do i just use the following provided on the https://toolset.com/documentation/embedded-toolset/building-and-distributing-toolset-based-themes/ page?

//include the Toolset installer in the theme
include get_template_directory() . '/installer/loader.php';
WP_Installer_Setup($wp_installer_instance,
array(
'plugins_install_tab' => 1, // optional, default value: 0
'affiliate_id:toolset' => '99999', // optional, default value: empty
'affiliate_key:toolset' => 'NNNNNNNNNN', // optional, default value: empty
'src_name' => NAME OF THEME, // optional, default value: empty, needed for coupons
'src_author' => '',// optional, default value: empty, needed for coupons
'repositories_include' => array('toolset') // optional, default to empty (show all)
)
);
#342348

The theme that i am using is unite and it is a Bootstrap theme. I have completed all page layouts and urgently need to bundle and add to clients WordPress install.

#342361

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Yes, you need to add the code mentioned at https://toolset.com/documentation/embedded-toolset/building-and-distributing-toolset-based-themes/ to your theme's functions.php file. Add this code before 'init' event in your functions.php file.

Further, please provide some debug information about your site. See https://toolset.com/faq/provide-debug-information-faster-support/ for more information.

I have enabled debug information area for your next reply.

#342447

So just to confirm, i dont copy and paste the code from the loader.php file, i just paste the code from the https://toolset.com/documentation/embedded-toolset/building-and-distributing-toolset-based-themes/ page. Should these go into the parent or child theme folder? where should the toolset_import folder go (child or parent).

#342452

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Yes, you need to copy the code from that page (as you mentioned the URL).

Secondly, it is supposed to go into the active theme. In case of a Parent/Child themes, child theme is activated theme, but, a child theme is supposed to have changes or updated while deriving core features from the parent.

Logically, it should go under parent theme. So when the child theme has updates, your core changes are not lost.

The topic ‘[Closed] Im trying to integrate loader.php to functions. I am using a child theme’ is closed to new replies.