Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

189
Views
want to get multiple values from dropdown after adding script tag in html page it stop working or using select and script tag togetherit stop working

This is my load clients function from where I pass value to clients.html page views.py

def load_clients(request):
    CPA_id = request.GET.get('CPA_id')
    clients = CPA_Client.objects.filter(CPA_id=CPA_id)
    return render(request, 'crm/clients_dropdown_list_options.html', {"clients": clients})
        # return JsonResponse(list(cities.values('id', 'name')), safe=False
client.html
<select id="ddselect" name="framework[]" multiple class="form-control">
  <option value="----">------</option>
  {% for Client_of_CPA in clients %}
  <option value="{{ Client_of_CPA.pk }}">{{ Client_of_CPA.name }}</option>
{% endfor %}
</select>

In this code i am getting my output but need to select multiple values from a dropdown thats why i want to add some functionality of bootstrap jquery due to which i need script tag. After adding script tag page stop working

This is my whole code in html page

<!DOCTYPE html>
<html>
  <head>
    <script>
      $(document).ready(function(){
      $('#ddselect').multiselect(
          {
           nonSelectedText: 'Select Framework',
          enableFiltering: true,
          enableCaseInsensitiveFiltering: true,
          closeOnSelect:false,
          });
      
        
      });
  </script>
  </head>
  <body>
 
    <select id="ddselect" name="framework[]" multiple class="form-control">
  <option value="----">------</option>
  {% for Client_of_CPA in clients %}
  <option value="{{ Client_of_CPA.pk }}">{{ Client_of_CPA.name }}</option>
{% endfor %}
</select>
  </body>
</html>
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!