Code Monkey home page Code Monkey logo

Comments (9)

KevinBatdorf avatar KevinBatdorf commented on September 17, 2024

Do you have a link? There are a few reasons that error would occur.

Checking it would just simply not throw the error and the slider would still not work. Otherwise a good idea though.

from liquidslider.

creativereason avatar creativereason commented on September 17, 2024

No link yet, just playing around locally still trying to see if it fits my needs.

My JS call (in document.ready) is this:
$('#slider-id').liquidSlider({
dynamicTabs: false,
keyboardNavigation: true,
hashNames: true,
autoHeight: false,
});

Tried autoHeight to see if made a difference. I had an existing image loader I'm going to disable to see if it makes a difference.

Do I need to explicitly set a height & width for the liquid-slider class in CSS?

from liquidslider.

KevinBatdorf avatar KevinBatdorf commented on September 17, 2024

Are you using a custom build?

from liquidslider.

creativereason avatar creativereason commented on September 17, 2024

No pulled the latest from Github.

from liquidslider.

KevinBatdorf avatar KevinBatdorf commented on September 17, 2024

What does your markup look like? It could be a typo in the markup or a missing closing tag somewhere that the browser hasn't caught.

from liquidslider.

creativereason avatar creativereason commented on September 17, 2024

It's really crazy, messy because of the site it's on (magazine with a lot of image of image overlays) so there are extra divs inside the panel container. Maybe that's causing the problem?

The code is generated from PHP so this is pulled from firebug:

                        <div id="mks" class="click draped1" style="top: 63.7096774194%; left: 75.4782608696%; width:6.4347826087%; height: 2.5537634409%;"><a href="http://bit.ly/13kKqkq" target="_blank">&nbsp;</a></div>                                     
              <img class="slide active" src="img/issue-1/draped-in-nostalgia-01-small.jpg" id="draped1">
        </div></div><div id="image-2" class="img-wrapper slider-id-panel panel"><div class="panel-wrapper">
                    <img class="slide" src="img/issue-1/draped-in-nostalgia-02-small.jpg" style="display: none;" id="draped2">
        </div></div><div id="image-3" class="img-wrapper slider-id-panel panel"><div class="panel-wrapper">
                    <div id="mks-2" class="click draped3" style="top: 88.4408602151%; left: 14.0869565217%; width:5.7391304348%; height: 2.8225806452%;display: none;"><a href="http://bit.ly/13kKqkq" target="_blank">&nbsp;</a></div>                                 
                        <div id="lulu-belle" class="click draped3" style="top: 91.1290322581%; left: 36.3478260870%; width:7.8260869565%; height: 2.1505376344%;display: none;"><a href="http://bit.ly/15468fD" target="_blank">&nbsp;</a></div>    
                        <div id="stray-dog" class="click draped3" style="top: 93.8172043011%; left: 9.3913043478%; width:7.6521739130%; height: 2.1505376344%;display: none;"><a href="http://bit.ly/YqfL5G" target="_blank">&nbsp;</a></div>                       <div id="shadow-catchers" class="click draped3" style="top: 93.9516129032%; left: 37.7391304348%; width:7.3043478261%; height: 1.8817204301%;display: none;"><a href="http://www.shadowcatchers.net" target="_blank">&nbsp;</a></div>                       
                        <div id="mks-3" class="click draped3" style="top: 0.0000000000%; left: 50.0000000000%; width:50.0000000000%; height: 100.0000000000%;display: none;"><a href="http://bit.ly/13kKqkq" target="_blank">&nbsp;</a></div>                                                           
                    <img class="slide" src="img/issue-1/draped-in-nostalgia-03-small.jpg" style="display: none;" id="draped3">
                </div></div></div>


  </div></div>

Sorry for poor formatting...

from liquidslider.

KevinBatdorf avatar KevinBatdorf commented on September 17, 2024

I see a few things not working properly.

The element id="mks" isnt being added as it's own slide. Is this within the Liquid Slider container?
Also, the top and left positioning might be throwing it off, but you can position the slider wrapper with these instead. I'm assuming another plugin is manipulating that though.

Can you post the markup in your html?

It should be something like:

<div class="liquid-slider"  id="slider-id">
        // One slide is within these divs
        <div>
            <?php # content goes in here ?>
        </div>
</div>

from liquidslider.

creativereason avatar creativereason commented on September 17, 2024

Yes, the mks is inside the it just looks like it from that paste above... here's my code (with calls to PHP functions:

<div class="liquid-slider"  id="slider-id">
  <div id="image-1" class="img-wrapper">          
      <?php addLink('http://mylink/10jSvRc', 712, 354, 25, 89, 'draped1', 'michael-jacob', false);?>            
      <?php addLink('http://mylink/13kKqkq', 474, 868, 19, 74, 'draped1', 'mks', false);?>                                      
      <img class="slide active" src="img/issue-1/draped-in-nostalgia-01-small.jpg" id="draped1" />
  </div>
  <div id="image-2" class="img-wrapper">
      <img class="slide" src="img/issue-1/draped-in-nostalgia-02-small.jpg" style="display: none;" id="draped2" />
  </div>
  <div id="image-3" class="img-wrapper">
      <?php addLink('http://mylink/13kKqkq', 658, 162, 21, 66, 'draped3', 'mks-2');?>                                   
      <?php addLink('http://mylink/15468fD', 678, 418, 16, 90, 'draped3', 'lulu-belle');?>  
      <?php addLink('http://mylink/YqfL5G', 698, 108, 16, 88, 'draped3', 'stray-dog');?>
      <?php addLink('http://mylink/Blah', 699, 434, 14, 84, 'draped3', 'shadow-catchers');?>                        
      <?php addLink('http://mylink/13kKqkq', 0, 575, 744, 575, 'draped3', 'mks-3');?>                                                           
      <img class="slide" src="img/issue-1/draped-in-nostalgia-03-small.jpg" style="display: none;" id="draped3" />
  </div>

So each addLink does another DIV (that is opened and closed with some details about it for tracking and popups at relevant locations).

Are you thinking my image-1... image-3 needs to have another empty div around them?

Starting to think I'll refactor or move onto another rotator option (perhaps fixing issues with my existing one). I appreciate your responses, but unfortunately the existing site is pretty deep with this existing functionality.

from liquidslider.

KevinBatdorf avatar KevinBatdorf commented on September 17, 2024

Hey, I updated your code so that GitHub will use syntax highlighting.

Do you close out the slider at the end? In your code it seems you left off the closing div at the end. Was this just a mistake when copying it over?

I dont think you will need another div wrapped around, but it wouldnt hurt to try that.

from liquidslider.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.