Wokring on a project where the user have the ability to chose from date and to date, and then chose one of the radio buttoms. After that chose pdf or excel to generate the to preferred format.
The problem is the form, I want it to action generateExcel.php if excel is pressed and generatePdf.php if PDF is pressed. This is how far I have came and not working yet:
<form action='generatePdf.php' method='Post'/>
Fra Dato: <input type="text" name="fraDato" value="<?php echo date('d-m-Y'); ?>" />
Til Dato: <input type="text" name="tilDato" value="<?php echo date('d-m-Y'); ?>"> <br>
<input type="radio" name="hent" value="timesmaling">Times malinger<br>
<input type="radio" name="hent" value="tredjetimesmaling">Tredje times malinger <br>
<input type="radio" name="hent" value="oppgaver">Oppgaver <br>
<input type="radio" name="hent" value="dagvakt">Dagvakt <br>
<input type="radio" name="hent" value="kveldsvakt">Kveldsvakt <br>
<input type="radio" name="hent" value="kontrollcm">Kontroll CM <br>
<input type='submit' name='pdf' value='PDF'>
<form action='generateExcel.php' method='Post'/>
<input type='submit' name='excel' value='excel'>
</form>