if ($_POST) {
    if ($_POST['country_id'] == '') {
        echo 'selected="selected"';
    }
} else {
    if (isset($billing) && $billing->country_id == '') {
        echo 'selected="selected"';
    }
}
?>
><?php 
echo lang('Please select');
?>
</option>
                                    <?php 
echo country_options($_POST ? $_POST['country_id'] : (isset($billing) ? $billing->country_id : ''));
?>
                                </select>
                        </div>
                            
                    </div>
                    <div class="control-group <?php 
highlightclass(form_error("email"));
?>
">
                        <label for="email" class="control-label"><?php 
echo lang('Email');
?>
<span class="mandatory">*</span></label>
                        <div class="controls">
                            <input type="text" name="email" id="email" value="<?php 
Beispiel #2
0
$document->addScript("/media/custom_js/jobseeker/profile_edit.js");
/* Jobseeker Class */
jimport("recruitment.jobseeker.jobseeker");
$jobseeker = new Jobseeker($user->id);
$juser_result = $jobseeker->current_user();
$data = $juser_result->fetch_object();
/* IndustryList Class */
jimport("recruitment.jobseeker.industrylist");
$industrylist = new IndustryList();
$industrylist_result = $industrylist->all();
$industrylist_options = industry_options($industrylist_result, $data->industry);
/* CoutnryList Class */
jimport("recruitment.jobseeker.countrylist");
$countrylist = new CountryList();
$countrylist_result = $countrylist->all();
$countrylist_options = country_options($countrylist_result, $data->country);
function country_options($result, $current)
{
    $html = "";
    $selected = "";
    while ($row = $result->fetch_object()) {
        if ($current == $row->name) {
            $selected = "selected='selected'";
        } else {
            $selected = "";
        }
        $html .= "<option value='{$row->id}' code1='{$row->code1}' code2='{$row->code2}' {$selected}>{$row->name}</option>";
    }
    return $html;
}
function industry_options($result, $current)
Beispiel #3
0
echo province_options(isset($_POST) ? $_POST['province'] : '');
?>
				</select>
			    <?php 
echo form_error("province");
?>
			    </div>
			</div>
		       <div class="control-group">
			    <label for="country_id" class="control-label"><?php 
echo lang('Country');
?>
<span class="mandatory">*</span></label>
			    <div class="controls"><select name="country_id" id="country_id" style="width: 150px;">
				<?php 
echo country_options(isset($_POST) ? $_POST['country_id'] : '');
?>
				</select>
				<?php 
echo form_error("country_id");
?>
			    </div>
			</div>
		       <div class="control-group">
			    <label for="dayphone" class="control-label"><?php 
echo lang('Day Phone');
?>
<span class="mandatory">*</span></label>
			    <div class="controls">
				<input type="text" name="dayphone" id="dayphone" value="<?php 
echo $_POST ? $p->dayphone : (isset($user) ? $user->phone1 : '');
?>
                            </select>
                            <?php 
echo form_error("province");
?>
                        </div>
                    </div>
                    <div class="form-control">
                        <label for="country_id" class="form-label"><?php 
echo 'Country';
?>
</label>
                        <div class="form-field">
                            <select name="country_id" id="country_id" class="countryselect">
                                <?php 
echo country_options($_POST ? $_POST['country_id'] : (isset($user) ? $user->user_country_id : ''));
?>
                            </select>
                            <?php 
echo form_error("country_id");
?>
                        </div>
                    </div>
                    <div class="form-control">
                        <label for="email" class="form-label"><?php 
echo 'Email';
?>
</label>
                        <div class="form-field">
                            <input type="text" name="email" id="email" value="<?php 
echo $_POST ? $p->email : (isset($user) ? $user->user_email : '');