Merge pull request #1901 from phl0/fixSearch

Prevent passing null to htmlspecialchars
这个提交包含在:
Peter Goodhall 2023-01-03 17:16:56 +00:00 提交者 GitHub
当前提交 72891bb6ca
找不到此签名对应的密钥
GPG 密钥 ID: 4AEE18F83AFDEB23

查看文件

@ -27,7 +27,7 @@
<div class="form-group row">
<label for="callsign" class="col-sm-2 col-form-label">Callsign / Gridsquare</label>
<div class="col-sm-8">
<input type="text" class="form-control" id="callsign" value="<?php echo htmlspecialchars($this->input->post('callsign')); ?>">
<input type="text" class="form-control" id="callsign" value="<?php if ($this->input->post('callsign') !== null) { echo htmlspecialchars($this->input->post('callsign')); }; ?>">
</div>
<div class="col-sm-2">
<button onclick="searchButtonPress()" class="btn btn-outline-success my-2 my-sm-0" type="submit"><i class="fas fa-search"></i> Search</button>