154 posts CoralixThemes
  • Elite Author: Sold more than $75,000 on Envato Market
  • Has sold $125,000+ on Envato Market
  • Sells items exclusively on Envato Market
  • Helped protect Envato Market against copyright violations
+5 more
CoralixThemes
says

Hi guys,
I need some help! My last work has a problem with Themeforest top bar. For some reason the demo is working fine but when I try to see the preview (which includes Themeforest top bar some scripts stop working). Any idea?
Themeforest item: http://themeforest.net/item/candidate-political-donation-landing/7143739
Demo here: http://candidate.coralixthemes.com/

1859 posts The Last Man Standing
  • Elite Author: Sold more than $75,000 on Envato Market
  • Has sold $125,000+ on Envato Market
  • Has been a beta tester for an Envato feature
  • Helped several times protecting Envato Market against copyright violations
+9 more
ImanGM
Moderator
says

Hi,

I guess it’s because some JS codes are not permitted to load when your site is loaded in an iframe from another domain name than your site.

This is why I’ve removed the default ThemeForest top bar on my latest item with one on my own host.

Hope this helps.

Cheers,
Iman

1353 posts
  • Has been part of the Envato Community for over 4 years
  • Has sold $40,000+ on Envato Market
  • Has been a beta tester for an Envato feature
  • Has collected 50+ items on Envato Market
+4 more
Smartik
says
Remove the iframe. Add this in the header of your template.
<script>if ( top !== self ) top.location.replace( self.location.href );</script>
154 posts CoralixThemes
  • Elite Author: Sold more than $75,000 on Envato Market
  • Has sold $125,000+ on Envato Market
  • Sells items exclusively on Envato Market
  • Helped protect Envato Market against copyright violations
+5 more
CoralixThemes
says

Hi, Thank for your help. I try this with my custom top bar but it didn’t work. :(


Hi,

I guess it’s because some JS codes are not permitted to load when your site is loaded in an iframe from another domain name than your site.

This is why I’ve removed the default ThemeForest top bar on my latest item with one on my own host.

Hope this helps.

Cheers,
Iman
154 posts CoralixThemes
  • Elite Author: Sold more than $75,000 on Envato Market
  • Has sold $125,000+ on Envato Market
  • Sells items exclusively on Envato Market
  • Helped protect Envato Market against copyright violations
+5 more
CoralixThemes
says

Thank you so much. It works! You save my day :)


Remove the iframe. Add this in the header of your template.
<script>if ( top !== self ) top.location.replace( self.location.href );</script>
by
by
by
by
by
by