dir/view/profile_selectors.php

15 lines
485 B
PHP
Raw Normal View History

2012-05-16 07:31:36 +02:00
<?php
function sexpref_selector($current="",$suffix="") {
$select = array('', t('Males'), t('Females'), t('Bisexual'), t('Autosexual'), t('Abstinent'), t('Virgin'), t('Nonsexual'));
$o .= "<select name=\"sexual$suffix\" id=\"sexual-select$suffix\" size=\"1\" >";
foreach($select as $selection) {
$selected = (($selection == $current) ? ' selected="selected" ' : '');
$o .= "<option value=\"$selection\" $selected >$selection</option>";
}
$o .= '</select>';
return $o;
}