Jump to content

Dropdown menu format


Suchy

Recommended Posts

<select name="id">
   <?php foreach($results as $x) { ?>
          <option value="<?= $x['id'] ?>">
	       <? printf ("%.40s", $x['name']) // limit name to 40 letters ?>   ***    id: 
	      <?= $x['id'] ?>    ***    added: 
	      <?  printf ("%.16s", $x['date']) ?>					 
         </option>
   <?php } ?>
</select>

 

here is how it looks:

screenshot001ve3.jpg

 

 

Is it possible to line up the results so the dropdown will look like this:

 

screenshot002rt0.jpg

 

???

Link to comment
https://forums.phpfreaks.com/topic/88665-dropdown-menu-format/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.