Digital experiences for all disciplines
New Landing › How can we help? › Themeforest Theme Support › Flexform › Javascript Not Loading on Homepage
New Landing › How can we help? › Themeforest Theme Support › Flexform › Javascript Not Loading on Homepage
- This topic has 3 replies, 2 voices, and was last updated 10 years by Melanie – SUPPORT.
-
Posted in: Flexform
-
January 28, 2014 at 4:42 pm #45355
I am having an issue on my homepage with the animated graphs and the other javascript not loading.
I have moved the site to a development area and have traced the issue down to a plugin which I need to have activated. The plugin is a landing page builder called OpitimizePress which I installed so my client could quickly build landing pages for his google adwords.
I am hoping you could give me some sort of clue as to what is causing the conflict as my Javascript knowledge is not that strong. I have dealt with the OpitimizePress support before and they are less than helpful. I understand this could fall outside of your typical support but any proof you could arm me with that it is not your theme, but their plugin would be very helpful.
Thank you in advance for your time!
Working: http://dev.workingdoginc.com/testffa/
Not Working: http://familyfinancialadv.com/
Wordpress 3.8.1
Theme Version 1.6January 31, 2014 at 9:34 am #45967Hi, could you ask the plugin developers about that please?
Let us know what they say so we can check if we can do anything.Cheers
February 17, 2014 at 2:18 pm #49625Okay I spoke with the plugin developer and this was their response:
unfortunately the problem is with progress_bar short-code. Both OptimizePress and your theme are using the same short-code (progress_bar).
Anyway, is there any chance that you prefix progress_bar shortcode inside your child theme? That would be a fix for this issue.
How can I prefix the shortcode to correct the issue?
Nicki
February 20, 2014 at 10:24 am #50454Thank you for letting us know!
Copy this code to your child theme’s shortcodes.php
/* SERVICES PROGRESS BAR SHORTCODE ================================================= */ function progress_bar($atts) { extract(shortcode_atts(array( "percentage" => '', "name" => '', "type" => '', "value" => '', "colour" => '' ), $atts)); if ($type == "") { $type = "standard"; } $service_bar_output = ''; $service_bar_output .= '<div class="progress '.$type.'">'. "\n"; if ($colour != "") { $service_bar_output .= '<div class="bar" data-value="'.$percentage.'" style="background-color:'.$colour.'!important;">'. "\n"; } else { $service_bar_output .= '<div class="bar" data-value="'.$percentage.'">'. "\n"; } $service_bar_output .= '<div class="bar-text">'.$name.' <span>'.$value.'</span></div>'. "\n"; $service_bar_output .= '</div>'. "\n"; $service_bar_output .= '</div>'. "\n"; global $has_progress_bar; $has_progress_bar = true; return $service_bar_output; } add_shortcode('progress_bar', 'progress_bar');
and change it to
/* SERVICES PROGRESS BAR SHORTCODE ================================================= */ function swift_progress_bar($atts) { extract(shortcode_atts(array( "percentage" => '', "name" => '', "type" => '', "value" => '', "colour" => '' ), $atts)); if ($type == "") { $type = "standard"; } $service_bar_output = ''; $service_bar_output .= '<div class="progress '.$type.'">'. "\n"; if ($colour != "") { $service_bar_output .= '<div class="bar" data-value="'.$percentage.'" style="background-color:'.$colour.'!important;">'. "\n"; } else { $service_bar_output .= '<div class="bar" data-value="'.$percentage.'">'. "\n"; } $service_bar_output .= '<div class="bar-text">'.$name.' <span>'.$value.'</span></div>'. "\n"; $service_bar_output .= '</div>'. "\n"; $service_bar_output .= '</div>'. "\n"; global $has_progress_bar; $has_progress_bar = true; return $service_bar_output; } add_shortcode('swift_progress_bar', 'swift_progress_bar');
Then you can call the shortcode via [swift_progress_bar …
Let me know if that worked please!
-
Posted in: Flexform
You must be logged in and have valid license to reply to this topic.