Currently, I am working on a language translation system that involves using the Google Translator API. To make this process smoother, I need to create a dropdown list of languages and pass their corresponding codes to the API. Initially, I attempted this using Bootstrap, but encountered some challenges. While I am comfortable implementing this feature in HTML, I am interested in incorporating it into Bootstrap for a more polished look. Below is my current attempt:
<div class="btn-group"> <a class="btn btn-default dropdown-toggle btn-select2" data-toggle="dropdown" href="#">Select a Region <span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#" >Spanish</a></li>
<li><a href="#">Sinhala</a></li>
<li><a href="#">Portuguese</a></li>
<li class="divider">Arabic</li>
<li><a href="#">Quebec</a>
</li><li><a href="#">Ontario</a>
</li><li><a href="#">British </a>
</li>
</ul>
</div>
I would appreciate any suggestions or guidance on how to proceed with this task. Thank you in advance for your help.