We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi, im not having any issues, i am just curious on how i can select data from DB and show in a bootstrap dropdown menu?
something like this:
<div class="form-group"> <label for="equipment_used">Equipment used?:</label> <select class="form-control" id="equipment_used" name="equipment_used" placeholder="Equipment used" placeholder="Equipment used" class="form-control" id ="equipment_used"> <option value="one">One</option> <?php echo "<option value=" .$equipment['equipment_name']. ">" .$equipment['equipment_name']. "</option>"; ?> <?php echo htmlspecialchars($row['equipment_name']); ?> <option value="<?php echo htmlspecialchars($equipment['equipment_name'], ENT_QUOTES, 'UTF-8'); ?>" <option value="<?=htmlspecialchars($equipment['equipment_name'], ENT_QUOTES, 'UTF-8'); ?>"><?=htmlspecialchars($equipment['equipment_name'], ENT_QUOTES, 'UTF-8') ?></option> <option value="two">Two</option> </select> </div>
The text was updated successfully, but these errors were encountered:
Solved it!
I did this:
<div class="form-group"> <label for="the_equipment_used">Equipment used?:</label> <select class="form-control" id="the_equipment_used" name="the_equipment_used" placeholder="Equipment for this sensor" class="form-control" id ="the_equipment_used"> <?php $db = getDbInstance(); $get_all_equipment_IDs_and_names =($db->query("select equipment_ID, equipment_name FROM equipments ")); foreach ($get_all_equipment_IDs_and_names as $key => $value) { echo "<option value='".$value["equipment_ID"]."'>".ucfirst($value["equipment_name"])."</option>"; } ?>" </select> </div>
Sorry, something went wrong.
No branches or pull requests
Hi, im not having any issues, i am just curious on how i can select data from DB and show in a bootstrap dropdown menu?
something like this:
The text was updated successfully, but these errors were encountered: