As you see in the picture below, when I click on the bell icon, a drop-down menu appears in the lower right corner of the icon. I want this drop-down menu to be displayed at the bottom left and not at the bottom right. What should I do?

If you want to see my code, it is written using php :
function navigation(){ $output = ""; $icons = ["user","bell","envelope","commenting"]; $rows = [2,5,5,5]; for ($i=0; $i < count($icons) ; $i++) { $output .= '<div class="dropdown">'; $output .= '<a class="nav-item nav-link" data-toggle="dropdown">'; $output .= '<i class="fa fa-'.$icons[$i].'"></i></a>'; $output .= '<div class="dropdown-menu text-right">'; for ($j=0; $j < $rows[$i] ; $j++) { $output .= '<a href="#" class="dropdown-item">'.($j+1).'</a>'; } $output .= '</div>'; $output .= '</div>'; } return $output; }
And then this output will be displayed in the html file:
<nav class="navbar"> <div class="container"> <div class="navbar-nav d-flex flex-row"> <?= navigation() ?> </div> </div> </nav>
php drop-down-menu twitter-bootstrap-4 bootstrap-4
eylay May 09 '17 at 10:23 2017-05-09 10:23
source share