I have to put 2 id-s together from $_POST
then I want to explode them, example:
My id-s are 38 and 310. I made the id-s to this id = "38.310" in my html file.
After $_POST
I want to explode the id-s:
$id=$_POST['id'];
echo($id); // Gives 38.31
$new_id = explode(".", $id);
echo($new_id[0]); // Gives 38
echo($new_id[1]); // Gives 31
Is the a way to get these id-s not rounded?
I need the 38
and the 310
! The id 310
can be also 1003000
...
EDIT:
function dostuff(document, message, id, action) {
var eingabe;
eingabe = confirm(message);
if (eingabe === true) {
document.msgform.action.value = action;
document.msgform.id.value = id;
document.msgform.submit();
} else {
return true;
}
return false;
}
LINK
<a href="#" onclick="dostuff(document, 'MESSAGE',<?php echo($row['vID']);?>.<?php echo($row['id']);?>,'FITTER_fitter_repaired');" class="button small red" >ACTION</a>
$row['vID'] = 38
$row['ID'] = 310
and my submit looks like this
<form enctype="multipart/form-data" name="msgform" action="" method="post">
<input type="hidden" value="" name="action"/>
<input type="hidden" value="" name="id"/>
</form>