monim67 / django-bootstrap-datepicker-plus

Bootstrap3/Bootstrap4/Bootstrap5 DatePickerInput, TimePickerInput, DateTimePickerInput, MonthPickerInput, YearPickerInput with date-range-picker functionality for django >= 2.0
https://pypi.python.org/pypi/django-bootstrap-datepicker-plus
MIT License
223 stars 61 forks source link

You have to load jQuery before form.media. This message is only visible when DEBUG=True #101

Open sasikumar1978k opened 1 year ago

sasikumar1978k commented 1 year ago

You have to load jQuery before form.media. This message is only visible when DEBUG=True Screenshot from 2023-07-11 12-35-00

Steveo00 commented 1 year ago

I am having the same problem. I am running bootstrap v5.2.3 and I think the issue is because bootstrap v5 no longer includes jQuery but I am not sure if this is true and, if true, is causing the problem

ashsmith88 commented 1 year ago

Came across the same issue.

Solved it by loading jQuery before the form.media in the html template:

<!-- Load jQuery -->
        <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>

        {{ form.media }}
Marco0201 commented 11 months ago

You need to be sure to load jQuery before form.media like the comment above. Otherwise you could use and install django-bootstrap4 and follow the steps in the documentation, django-bootstrap4 includes jQuery. Also keep in mind, django-bootstrap5 does not include jQuery so you would need to include it separately.