Checkboxes in php that apply style to input text
<p>Hello i have an issue with an exercise with checkboxes in php. I know how to get the value of each checkbox but in this case the value should be aplying style to an input text. The code i have till now it's this:</p>

<p>
</p>

<pre><code>&lt;?php
$negrita = 'unchecked';
$cursiva = 'unchecked';
$subrayado = 'unchecked';

if (isset($_REQUEST['submit'])) {

    if (isset($_POST['negrita'])){

        echo "&lt;p style='font-weight: bold'&gt;" . $_POST['texto']. "&lt;/p&gt;" ;
    }
    if (isset($_POST['cursiva'])){
        echo "&lt;p style='font-style: italic'&gt;" . $_POST['texto']. "&lt;/p&gt;" ;
    }
    if(isset($_POST['subrayado'])){
        echo "&lt;p style='text-decoration: underline'&gt;" . $_POST['texto']. "&lt;/p&gt;" ;
    }

}
?&gt;
</code></pre>

<hr>

<pre><code>&lt;form action="ejercicio2_form.php" method="post"&gt;
    &lt;p&gt;Introduce el texto a mostrar:
        &lt;input type="text" name="texto" value="&lt;?php if (isset($_REQUEST["texto"])) echo $_POST['texto'];?&gt;" size="20"&gt; &lt;br /&gt;
    &lt;/p&gt;
    Estilo del texto:
        &lt;input type="checkbox" name="negrita" &lt;?php if (isset($_POST['negrita']) &amp;&amp; $_POST['negrita']=="negrita") echo "checked";?&gt; value="negrita"&gt; Negrita
        &lt;input type="checkbox" name="cursiva" &lt;?php if (isset($_POST['cursiva']) &amp;&amp; $_POST['cursiva']=="cursiva") echo "checked";?&gt; value="cursiva"&gt; Cursiva
        &lt;input type="checkbox" name="subrayado" &lt;?php if (isset($_POST['subrayado']) &amp;&amp; $_POST['subrayado']=="subrayado") echo "checked";?&gt; value="subrayado"&gt; Subrayado &lt;br /&gt;
    &lt;input type="submit" name="submit" value="Aceptar"&gt;

&lt;/form&gt;

&lt;/body&gt;
</code></pre>

<p></p>

<p>If in the text box i write "hello!" and then click all 3 checkboxes i get 3 different "hello!" one in bold another in italic and the third one underline. What i want is to get only one "hello!" with all the three text styles applyed. </p>