Welcome Guest, Not a member yet? Register   Sign In
new with codeigniter
#3

[eluser]kiga[/eluser]
i try again without "CI", this time nothing happens, the page is blank :S
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

&lt;html &gt;
&lt;head&gt;
    &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8"/&gt;

    &lt;title&gt;form_view&lt;/title&gt;
    &lt;style type="text/css" media="screen"&gt;
        label,input{
            display:block;
            padding:5px;
        }
        div.error{
            background-color:#FF8F8F;
            border: 1px solid #FF1111;
            margin-bottom:5px;
            padding:5px;
            width:400px;
        }
    &lt;/style&gt;
&lt;/head&gt;

&lt;body&gt;
&lt;?php echo validation_errors('<div class="error">','</div>') ?&gt;
&lt;?php echo form_open('formulario') ?&gt;
&lt;?php echo form_label('Nombre: ', 'nombre') ?&gt;
&lt;?php echo form_input(array('name' => 'nombre', 'id' => 'nombre', 'size' => '50', 'value' => set_value('nombre'))) ?&gt;
&lt;?php echo form_label('Email:', 'email'); ?&gt;
&lt;?php echo form_input(array('name' => 'email', 'id' => 'email', 'size' => '50', 'value' => set_value('email'))); ?&gt;
&lt;?php echo form_label('Contraseña:', 'password'); ?&gt;
&lt;?php echo form_password(array('name' => 'password', 'id' => 'password', 'size' => '50')); ?&gt;
&lt;?php echo form_label('Reescribe la contraseña:', 'repassword'); ?&gt;
&lt;?php echo form_password(array('name' => 'repassword', 'id' => 'repassword', 'size' => '50')); ?&gt;
&lt;?php echo form_submit('enviar', 'Enviar') ?&gt;
&lt;?php echo form_close() ?&gt;
&lt;/body&gt;
&lt;/html&gt;

//////////////////////
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

&lt;html &gt;
&lt;head&gt;
    &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8"/&gt;

    &lt;title&gt;exito_view&lt;/title&gt;
    &lt;style type="text/css" media="screen"&gt;
        div.exito{
            background-color:#C2FFAF;
            border:1px solid #2A7F0F;
            padding:5px;
            margin-bottom:15px;
            width:400px;
        }
    &lt;/style&gt;
&lt;/head&gt;

&lt;body&gt;
<div class="exito">
    El formulario se ha enviado correctamente<br />
    El nombre es: &lt;?php echo $nombre ?&gt;<br />
    La contraseña en md5 es: &lt;?php echo $password ?&gt;
</div>
&lt;?php echo anchor('formulario', 'Volver al formulario') ?&gt;
&lt;/body&gt;
&lt;/html&gt;

this is the complete code :S


Messages In This Thread
new with codeigniter - by El Forum - 04-13-2011, 01:44 PM
new with codeigniter - by El Forum - 04-13-2011, 02:02 PM
new with codeigniter - by El Forum - 04-13-2011, 04:57 PM
new with codeigniter - by El Forum - 04-14-2011, 08:47 AM
new with codeigniter - by El Forum - 04-14-2011, 11:07 AM
new with codeigniter - by El Forum - 04-14-2011, 02:11 PM
new with codeigniter - by El Forum - 04-14-2011, 03:39 PM
new with codeigniter - by El Forum - 04-14-2011, 03:43 PM
new with codeigniter - by El Forum - 04-14-2011, 04:02 PM
new with codeigniter - by El Forum - 04-14-2011, 04:07 PM
new with codeigniter - by El Forum - 04-14-2011, 04:14 PM
new with codeigniter - by El Forum - 04-14-2011, 04:17 PM
new with codeigniter - by El Forum - 04-14-2011, 04:29 PM
new with codeigniter - by El Forum - 04-14-2011, 04:43 PM
new with codeigniter - by El Forum - 04-14-2011, 04:55 PM
new with codeigniter - by El Forum - 04-14-2011, 06:43 PM
new with codeigniter - by El Forum - 04-14-2011, 08:52 PM
new with codeigniter - by El Forum - 04-15-2011, 12:02 AM



Theme © iAndrew 2016 - Forum software by © MyBB