Codeless
  • Support Home
  • Themes
  • Support
  • WordPress Tutorials
    • How to Start a Blog
    • Best Website Builders
    • Best Small Business Hosting
    • Email Marketing Services
    • Cheap WordPress Hosting
  • Video Tutorials

Community Forums

Button Opens Page in New Window

Button open in New Window _new _self
    • 6 years, 9 months ago vitalife
      Participant

      Expired

      Using Handel theme, how can I set the buttons to open in a new window.  I tried adding

      target=”_new” in the cl_button markup but this did not work, and I can’t see an easy way to add it to the target.   Is this something easy to do. I have lots of buttons for viewing Catalog on my site which is a PDF on a Google drive and I’d prefer these open in a new window / tab..

      Thanks

    • 6 years, 9 months ago Mirela
      Participant

      Hello,

      Please go to file \includes\codeless_builder\shortcodes\cl_button.php and find this line:

      <a href="<?php echo esc_url( $link ) ?>" class="<?php echo esc_attr( $this->generateClasses('.cl-btn') ); ?> 
      	<?php echo esc_attr( $extra_classes ); ?>" <?php $this->generateStyle('.cl-btn', '', true) ?> > <span><?php echo cl_remove_empty_p( cl_remove_wpautop($btn_title, true) ) ?></span></a>
      

      Replace with this:

      <a href="<?php echo esc_url( $link ) ?>" target="_blank" class="<?php echo esc_attr( $this->generateClasses('.cl-btn') ); ?> 
      	<?php echo esc_attr( $extra_classes ); ?>" <?php $this->generateStyle('.cl-btn', '', true) ?> > <span><?php echo cl_remove_empty_p( cl_remove_wpautop($btn_title, true) ) ?></span></a>

      Let me know.
      Best regards!

    • 6 years, 9 months ago vitalife
      Participant

      Expired

      Thanks!

    • 6 years, 6 months ago imme
      Participant

      Hello!

      How do i add the target _blank to specific buttons? I dont want all of my buttons to open in a new window just a few.

      Regards,

      Kim

    • 6 years, 6 months ago Ruco
      Keymaster

      Hello,

      You can’t do that at the moment. We are going to add this feature to the next update of handel that will come shortly.

      Regards!

    • 6 years, 6 months ago Ruco
      Keymaster

      UPDATE IS ONLINE with the UPDATES REQUIRED!

Viewing 5 reply threads

You must be logged in to reply to this topic.

Login

Log In
Register

Renew Support

  • Renew Specular Support
  • Renew Tower Support
  • Renew Folie Support
  • Renew Handel Support
  • Renew June Support
  • Renew Picante Support
  • Renew Thype Support
  • Renew Regn Support

Search Forums

Forums

  • Bygge – Construction Theme
  • Converta – Software Theme
  • Folie – The WordPress Website Builder
  • Handel – Responsive Multi-Purpose Business Theme
  • June WooCommerce WordPress Theme
  • Livecast – Podcast Theme
  • Picante – Restaurant & Food WordPress Theme
  • Regn | Agency & Business WordPress Theme
  • Remake – Minimal Portfolio & Agency Theme
  • Specular – Multi-Purpose WordPress Theme
  • Suggest us Features
  • Tower – Business-Driven Multipurpose WP Theme
  • Vibrance – Photography Theme

Site Links

  • Support Policy
  • Specular Support Forum
  • Video Tutorials
  • Knowledge Base
  • Guides and Reviews

Useful Articles

  • Build a Website
  • Web Design & Development
  • Hosting
  • WordPress

Login

Log In
Register Lost Password