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

Floating Sidebar moves not correct

    • 10 years ago Bikul
      Participant

      Expired

      Hello,

      I created a single portfolio item with a floating sidebar on the left.

      I also activated the sticky header.

      When I scroll down the single portfolio page the floating sidebar is now too much at the top, covered by the sticky menu.

      Where can I change this moving position of the floating sidebar?

      As the page is not visible to the public yet, I could give you login credentials?

      Thanks for Help
      Bernd

       

    • 10 years ago Mirela
      Participant

      Hello,

      Please go to file: js\main.js and find these lines:

      function codeless_single_portfolio_floating(){
      	"use strict";
      	var $sidebar   = $(".fixed_sidebar"), 
              $window    = $(window),
              offset     = $sidebar.offset(),
              topPadding = 15;
      

      Edit the topPadding = 15; value to 200 or more. Save and refresh.

      Best regards!

    • 10 years ago Bikul
      Participant

      Expired

      Hi Mihaila,

      that works great!

      Is there a chance to integrate this into the child theme somehow, so that I dont have to do this modification again, when you update the theme?

      Thank you
      Bernd

    • 10 years ago Mirela
      Participant

      Hello,

      Sorry for the late reply.
      You should add this code:

      <?php
      // Register Script
      function custom_main_js() {
       
      	wp_deregister_script( 'specular' ); // This is the handle used by the main theme's functions.php for main.js
      	wp_register_script( 'specular-child', '/wp-content/themes/specular-child/js/main_custom.js', array( 'specular' ), false, false ); // This is the URL to your child theme's custom js file and a handle we've given it
      	wp_enqueue_script( 'specular-child' );
       
      }
       
      // Hook into the 'wp_enqueue_scripts' action
      add_action( 'wp_enqueue_scripts', 'custom_main_js' );

      into your child’s theme function.php file. Please read here, for more information.

      Best regards!

    • 10 years ago Bikul
      Participant

      Expired

      Hi Mihaila,

      seems complicated. I see that there is “Custom JS Code” in WordPress/Specular/General Options

      Could I not put the changed code simply in here and it will not be affected from a theme update?

      Thanks
      Bernd

       

    • 10 years ago Mirela
      Participant

      Hello,

      Sorry but in this case it will not work from the Custom js code.

      Best regards!

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