Code Monkey home page Code Monkey logo

Comments (4)

stefangabos avatar stefangabos commented on June 8, 2024

It's probably that the element the date picker is attached to changes position after the page is loaded. You could call the "update" method once the page is loaded to fix that

from zebra_dialog.

brailateo avatar brailateo commented on June 8, 2024

No, it's not the changing positions, I put the $('#data_pif').Zebra_DatePicker(); in a setTimeout after 1 second, I load the HTML template before and on success I define the calendars. So ... it's something else. BTW, what update() method?
in console

$('#data_pif').Zebra_DatePicker().update()
TypeError: $(...).Zebra_DatePicker(...).update is not a function

but despite the error, it fixed the position!
So ... it's no problem issuing more $('#data_pif').Zebra_DatePicker() than one?
P.S. îmi place însă că ne conversăm în engleză ... ;-)
Teo

from zebra_dialog.

brailateo avatar brailateo commented on June 8, 2024

Sorry, I was on the wrong project :-D
I found now:

var datepicker = $('element').data('Zebra_DatePicker');
datepicker.update();

Thanks,
Teo

from zebra_dialog.

stefangabos avatar stefangabos commented on June 8, 2024

You should really look into the configuration options ;)

The "update" method is used like this:

var dp = $('selector').Zebra_DatePicker();

then, somewhere else in your code, you might call

dp.update();

P.S. ne conversam in engleza ca sa pot da link-uri catre aceste discutii cand mai au si altii problema asta :)

from zebra_dialog.

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.