Soldato
Can anyone give me some pointers on the best way to do this.
I have a table with people in with the usual details, including an email address, their name and a unique key.
At the moment I'm setting up a form, iterating through the table displaying their name and a tick box, the id being the unique key.
When it then posts, how am I best to go through getting the people's details? Can I iterate through $_POST?
Does that all make sense?
I'm sure there's a better way to do this though, I just don't know how?
I have a table with people in with the usual details, including an email address, their name and a unique key.
At the moment I'm setting up a form, iterating through the table displaying their name and a tick box, the id being the unique key.
Code:
while($row = mysqli_fetch_array($result)) {
$team=strtolower($row['team']);
if($row['email'] == "") {
$team = 'white';
}
?>
<div class="col-sm-30 <?php echo $team.'Background'; ?>">
<input class="form-group-input" type="checkbox" value="<?php echo $row['uniqueid']; ?>" name="<?php echo $row['uniqueid']; ?>" id="<?php echo $row['uniqueid']; ?>" <?php if($team == 'white') { echo 'disabled'; } ?>>
<label class="form-checkbox form-label-inlin" for="<?php echo $row['uniqueid']; ?>">
<?php echo checkPartnerName($row['uniqueid']); ?>
</label>
</div>
<?php
}
When it then posts, how am I best to go through getting the people's details? Can I iterate through $_POST?
Does that all make sense?
I'm sure there's a better way to do this though, I just don't know how?