I am facing an issue with adding an icon to a text value in HTML. The problem arises when the icon is added to a Bootstrap button. Upon selecting a value from an external source, the button label changes accordingly. However, this change in text causes the icon to be excluded. I attempted to resolve this by applying the icon via a class to the div, but this resulted in permanently changing the text type, which is not desired. Any suggestions on how to approach this situation?
<div class="col-2" style="padding: 20px;">
<div class="btn btn-primary dropdown-toggle dropdown-toggle-split" id="acctFilter" data-toggle="dropdown" acctid="placeholder">
<i class="fa fa-building"></i> SELECT ACCOUNT
<span class="sr-only">Toggle Dropdown</span>
</div>
<div class="dropdown-menu" id="acctList" role="menu" aria-labelledby="dropdownMenu">
</div>
</div>
When attempting to add it like this, the entire button text changes...
<div class="col-2" style="padding: 20px;">
<div class="btn btn-primary dropdown-toggle dropdown-toggle-split fa fa-globe" id="acctFilter" data-toggle="dropdown" acctid="placeholder">
SELECT ACCOUNT
<span class="sr-only">Toggle Dropdown</span>
</div>
<div class="dropdown-menu" id="acctList" role="menu" aria-labelledby="dropdownMenu">
</div>
</div>