Código PHP:
Ver original<?php
if($boton == "Ingresar"){
echo "aqui ingresas";
}
if($boton == "Modificar"){
echo "Aqui modificas";
}
$boton = "Modificar";
}else{
$boton = "Ingresar";
}
?>
<html>
...
....
.....
Código HTML:
Ver original//...en el value del boton le colocas la variable q tiene el nombre
<input type="submit" name="boton" value="<?php echo $boton; ?>">