Title: problem with minification
Last modified: December 19, 2018

---

# problem with minification

 *  Resolved [capitalismclown](https://wordpress.org/support/users/capitalismclown/)
 * (@capitalismclown)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/problem-with-minification/)
 * hi there
 * I use minification via fast velocity minify. it seems that this causes an error
   in chrome, says cannot read text property of undefined. here is the code block(
   minified) that throws the error. causes the plugin to crash and the page does
   not load at all.
 * lp.options.text*=1;lp.options.loadingScreen*=1;if(lp.options.loadingScreen&&lp.
   validateScreenSize()){if(lp.options.closeBtn){var close_btn=jQuery(‘<span class
   =”lp-close-screen”>X</span>’);close_btn.click(lp.destroyLoader);jQuery(‘html’).
   append(close_btn)}
    if(lp.options.codeblock&&lp.options.codeblock.length)jQuery(‘
   html’).append(lp.options.codeblock);if((typeof lp.graphics!=’undefined’)&&(typeof
   lp.graphics[lp.options.graphic]!=’undefined’)){lp.graphics[lp.options.graphic].
   create(lp.options);var lpCodeBlock=document.getElementById(‘loading_page_codeBlock’);
   if(lpCodeBlock)lpCodeBlock.style.display=’block’}}else lp.options.loadingScreen
   =0})();jQuery(function(){if(cp_loadingpage.options.loadingScreen)cp_loadingpage.
   loadingPage()});jQuery(window).on(‘load’,function(){cp_loadingpage.loadOriginalImg();
   cp_loadingpage.destroyLoader()});
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fproblem-with-minification%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [codepeople](https://wordpress.org/support/users/codepeople/)
 * (@codepeople)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/problem-with-minification/#post-11007821)
 * Hello [@capitalismclown](https://wordpress.org/support/users/capitalismclown/),
 * That seems there is an issue with the minifying plugin and the javascript code
   included with the WordPress function: `wp_add_inline_script`
 * Please, follow the steps below:
 * 1. Open the “/wp-content/plugins/loading-page/loading-page.php” file with the
   text editor of your choice.
 * 2. Go to the piece of code:
 *     ```
       if(function_exists('wp_add_inline_script'))
       ```
   
 * 3. And edit it as follows:
 *     ```
       if(false && function_exists('wp_add_inline_script'))
       ```
   
 * and that’s all.
    Best regards.
 *  Plugin Author [codepeople](https://wordpress.org/support/users/codepeople/)
 * (@codepeople)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/problem-with-minification/#post-11009888)
 * Hello [@capitalismclown](https://wordpress.org/support/users/capitalismclown/),
 * I’ve published an update of the plugin that solves the conflict.
 * Best regards.
 *  Thread Starter [capitalismclown](https://wordpress.org/support/users/capitalismclown/)
 * (@capitalismclown)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/problem-with-minification/#post-11010082)
 * thanks that worked great. all sorted.
 * on a different note, I have hit a bit of a wall with a plugin im building. I 
   could use some help.
 * it is working as integrated into wordpress, however it is the javascript that
   is causing a problem, the core of the thing needs to be re written, but I didnt
   write it. been released as a freebie stand alone and I want to convert to a plugin
   in full and it would be of interest to people im certain.
 * can you help me out with this? can i contact you directly somehow?
 * you seem to have a proper handle on plugin development and deployment so i thought
   id ask
 * thanks
 * J
 *  Plugin Author [codepeople](https://wordpress.org/support/users/codepeople/)
 * (@codepeople)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/problem-with-minification/#post-11010092)
 * Hello [@capitalismclown](https://wordpress.org/support/users/capitalismclown/),
 * If you are needing a custom coding service, do not hesitate in describe your 
   project through my private website:
 * [https://wordpress.dwbooster.com/support](https://wordpress.dwbooster.com/support)
 * Best regards.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘problem with minification’ is closed to new replies.

 * ![](https://ps.w.org/loading-page/assets/icon-256x256.gif?rev=2316939)
 * [Loading Page with Loading Screen](https://wordpress.org/plugins/loading-page/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/loading-page/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/loading-page/)
 * [Active Topics](https://wordpress.org/support/plugin/loading-page/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/loading-page/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/loading-page/reviews/)

## Tags

 * [Crash](https://wordpress.org/support/topic-tag/crash/)
 * [minification](https://wordpress.org/support/topic-tag/minification/)
 * [problem](https://wordpress.org/support/topic-tag/problem/)

 * 4 replies
 * 2 participants
 * Last reply from: [codepeople](https://wordpress.org/support/users/codepeople/)
 * Last activity: [7 years, 5 months ago](https://wordpress.org/support/topic/problem-with-minification/#post-11010092)
 * Status: resolved