Skip to main content

Forums

Forum Replies Created

Viewing 15 posts - 16 through 30 (of 66 total)
  • Author
    Posts
  • in reply to: [Solved] Nivo Lightbox Problem #179974

    Chromawoods
    Participant

    It is the gallery overlay (nivo-lightbox-overlay) that is blocking everything else on the page. You can find it just before the body tag closes. If you inspect its CSS after closing the lightbox, you will see that its z-index is very high.. and it does not matter that the opacity is 0, it will still obstruct your other stuff as long as it’s not display: none; or z-index: -1; or whatever suitable.

    in reply to: Chain Unexpectedly BREAKS! :( #179155

    Chromawoods
    Participant

    So when examining this in the console, we can see that it is the css method that returns undefined. Why? Well if you check the code, you will see that it actually doesn’t return the object in every case. Look at the very first if-statement; it pushes a function into the queue but it doesn’t return this.

    Instead of returning this in every if-block, you could just stick it into the end of the css method, that way you know that it will return properly.

    I’m making a nice DOM manipulation library with pure JavaScript

    Are you doing this as a learning experience or is it a serious project? Just considering your health and well-being here.. ;)

    in reply to: Sidebar display at the bottom of content #178485

    Chromawoods
    Participant

    You should provide some code that shows what you have right now.

    Perhaps the two columns are taking up more than 100% width, which would cause your sidebar to wrap down beneath the content? You might need to adjust some padding or margin or box-sizing, but hard to say without knowing what your HTML and CSS looks like. :/

    in reply to: Set global time on JAVA PLAY FRAMEWORK #177459

    Chromawoods
    Participant

    You should perhaps ask that question on Stack Overflow or something. This forum is about JavaScript.

    Play is a Java framework so I guess you just want to get the server time using Java?
    http://stackoverflow.com/questions/12584992/how-to-get-current-server-time-in-java

    in reply to: Update price onchange via jQuery #176737

    Chromawoods
    Participant

    updatePrice does not know what $(this) is. If you log it to the console, you will see that it in the context of that function, this refers to the window object. You have named the param e, which is misleading because it’s not an event, it’s the actual select element. So to make it work, you could do:

    function updatePrice(select) {
        $(select).parent().siblings('.price').html(select.value);
    }
    

    So you are turning a list into a table using JS. I assume you can’t just have the table being served in the markup to begin with? If you really really need to create it like that, I think I would build the table using jQuery objects from the start and then register event handlers on them using jQuery, not the onchange attribute, that’s weird IMO. replaceWith can take jQuery as a parameter, so it should be fine.

    in reply to: Super simple jQuery accordion, help needed #176640

    Chromawoods
    Participant

    @paulie_d it does not quite work as expected? If you expand one item and then click another one, that item does not expand. I made a fork of your fork and made a few modifications:

    When we click an item, we must reference it with jQuery’s $(this). Also cached some selectors and utilized chaining for performance.

    in reply to: Slideshow, setTimeout and ClearTimeout #173448

    Chromawoods
    Participant

    In chgSlide, you clear the timeout, but you never start it again, so that’s why it does not start again. Try invoking rotate in the end of chgSlide.

    Regarding setTimeout: Instead of passing a string that invokes the rotate function, you can simply pass a reference to it, like this:

    timer = setTimeout(rotate, pause);
    
    in reply to: JS button transitions #172574

    Chromawoods
    Participant

    Just updated the pen. Now there’s also a CSS solution in there. But I think IE 9 and lower will not like it.

    in reply to: JS button transitions #172571

    Chromawoods
    Participant

    That being said… yeah it could be done with CSS transitions I guess. :)

    in reply to: JS button transitions #172519

    Chromawoods
    Participant

    This site in particular that you are mentioning are using a very simple technique, in which the panels are absolutely positioned with bottom:0. Then, they use jQuery’s slideDown/slideUp, which actually pushes the content upwards when using slideDown because of the bottom:0 positioning.

    Made a pen if you’re interested

    in reply to: Date And Time Picker. #171757

    Chromawoods
    Participant

    Did you check unheap?

    in reply to: Add and remove elements repeatedly #170848

    Chromawoods
    Participant

    Not sure if it answers your question, but I made something similar as an experiment:

    Demo: http://chromawoods.com/bricklr/demo/
    Source: https://github.com/chromawoods/bricklr

    It has a few options to play around with and you might just achieve something like what you are trying to do. If not, maybe make a feature-request and I’ll update it. :)

    in reply to: .clone problem #169423

    Chromawoods
    Participant

    Although I don’t know for sure what’s wrong, there is a problem in your code, namely the ID attributes on the elements that you clone. You will end up with duplicates, which is invalid. Use classes or data-attributes instead.

    Is there perhaps a live example of the problem? A CodePen?

    in reply to: AJAX page transition effect #169222

    Chromawoods
    Participant

    The load() function does exactly what you want; you don’t need the $.ajax() function at all. You basically just need to exchange the selectors in my code with the ones you want to use.

    in reply to: Media Queries for JS? #169221

    Chromawoods
    Participant

    I’ve used jRespond on several projects and it is working very well. Might be overkill if you only have one single function to trigger, but once your project grows and more JS needs to trigger on breakpoints, it’s a nice lib to have.

    Plus, it also does some nice things for performance, like window resize event throttling.

    https://github.com/ten1seven/jRespond

Viewing 15 posts - 16 through 30 (of 66 total)
icon-link icon-logo-star icon-search icon-star