ACC (Advanced Custom Code) is a versatile WordPress plugin designed to help developers and site administrators easily add custom HTML, CSS, JavaScript, or PHP to their website. It works like a powerful code manager, allowing users to insert code snippets that enhance the functionality and design of their WordPress site. ACC is perfect for developers who want to make quick modifications, integrate third-party libraries, or customize elements without having to alter the core theme files.
Table Of Contents
The plugin comes with features like support for multiple page builders (Gutenberg, Elementor, WPBakery, etc.), theme compatibility (Astra, Divi, Neve, and more), and the ability to add code to function.php, header.php, and footer.php. With a simple, user-friendly interface built on the native WordPress UI, ACC provides the ability to make your website adaptable and add personalized code solutions without hassle. Whether you're adding Google Analytics, Facebook Pixels, or any other type of custom code, ACC is an essential tool for simplifying these processes.
function.php
, header.php
, and footer.php
effortlessly. This feature is particularly useful for integrating tracking codes like Google Analytics, Facebook Pixel, and more.Step 01: First we have to go to the WordPress dashboard.
Step 02: Then we have to click the Plugins option from the dashboard. Then we have to click “Add New Plugin” button , from there we have to click “Upload Plugin”. Then we have to choose the plugin from our device. Then we have to click install button. Here we can Active The Plugin or we may active it later from Plugins options
3. After activation we will see ACC options on dashboard like below
4. Then we can make shortcode snippet like below
5. Now we can use this short code where we want
6. The styles has changed for the shortcode
Use our recommended page builder plugin, FancyPost to unlock a number of powerful blocks to help you to design amazing websites!
Ready to take control of your website’s custom code needs? Click the button below to download the ACC - Advanced Custom Code plugin. With ACC, you can easily add and manage custom code, integrate third-party libraries, and make powerful customizations to your WordPress website—all from an intuitive, user-friendly interface.
The ACC - Advanced Custom Code plugin offers various ways for developers to customize and extend its features. Whether you want to add custom functionality, modify the existing behavior, or integrate with other tools, the Developer Area provides the flexibility you need.
The ACC plugin includes multiple action hooks and filters that can be used to extend or modify its behavior without changing core plugin files.
acc_before_custom_code_execution
This action hook can be used to execute custom functionality before any custom code (HTML, CSS, JavaScript, or PHP) is executed.
add_action('acc_before_custom_code_execution', 'my_custom_pre_execution_code');
function my_custom_pre_execution_code() {
// Custom code to execute before any ACC custom code
error_log('Executing code before ACC custom scripts run.');
}
acc_modify_custom_html
This filter allows you to modify the HTML code that is added using ACC before it gets rendered.
add_filter('acc_modify_custom_html', 'modify_custom_html_code', 10, 1);
function modify_custom_html_code($html_code) {
// Add a custom wrapper to all HTML snippets added via ACC
return '<div class="my-custom-wrapper">' . $html_code . '</div>';
}
If you need to extend the ACC functionality using JavaScript or CSS, you can enqueue custom scripts or styles that interact with the elements created by ACC.
add_action('wp_enqueue_scripts', 'enqueue_acc_custom_scripts');
function enqueue_acc_custom_scripts() {
wp_enqueue_script('my-acc-custom-script', get_stylesheet_directory_uri() . '/js/custom-acc.js', array('jquery'), '1.0', true);
wp_enqueue_style('my-acc-custom-style', get_stylesheet_directory_uri() . '/css/custom-acc.css', array(), '1.0');
}
Developers can choose where to place their custom code within WordPress using dedicated hooks. Here are some examples:
wp_head
to insert custom JavaScript or CSS directly into the <head>
section of the site.add_action('wp_head', 'insert_custom_header_code');
function insert_custom_header_code() {
// Your custom code for the header
echo '<script>console.log("Custom JavaScript code from ACC.");</script>';
}
wp_footer
to add scripts or elements that should be loaded at the bottom of the page.add_action('wp_footer', 'insert_custom_footer_code');
function insert_custom_footer_code() {
// Custom JavaScript for tracking
echo '<script>console.log("Custom footer code executed!");</script>';
}
With ACC, developers can add custom PHP code to create hooks, filters, or any other backend functionality they require. Here's an example of adding a new WooCommerce filter:
add_action('init', 'customize_product_price');
function customize_product_price() {
if (class_exists('WooCommerce')) {
add_filter('woocommerce_get_price_html', 'modify_price_display', 10, 2);
}
}
function modify_price_display($price, $product) {
// Adding a discount label to the price display
return $price . ' <span class="discount-label">Limited Time Offer!</span>';
}
ACC also allows you to add third-party libraries like Bootstrap, Font Awesome, etc. Here’s an example of how to enqueue Bootstrap via ACC:
add_action('wp_enqueue_scripts', 'enqueue_bootstrap_via_acc');
function enqueue_bootstrap_via_acc() {
wp_enqueue_style('bootstrap-css', 'https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css');
wp_enqueue_script('bootstrap-js', 'https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js', array('jquery'), '5.3.0', true);
}
The ACC - Advanced Custom Code plugin offers a wide range of opportunities for developers to extend its features and customize its behavior. With support for hooks, filters, JavaScript, CSS, and even backend PHP customization, developers can take full advantage of its flexibility to meet specific project needs
We are always looking to improve! If you have any suggestions for new features or improvements to the plugin, feel free to reach out to us. Your feedback helps us make Easy Job Listing even better.(Contact form , Telegram, WhatsApp, Messenger)
If you enjoy using ACC-Advanced Custom Code and would like to support its continued development, please consider making a donation. Your contributions will help us add more features, provide regular updates, and continue offering support to all users.
Why these kinds of plugins are not accepted in WP?
Script insertion plugins are powerful yet risky, needing strict security. WordPress limits JavaScript handling to prevent unsafe code and offers options to lock theme/plugin edits. Without strong security measures, plugins may be rejected.