CodeIgniter Forums

Full Version: The form field dont appears
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]bibos[/eluser]
Hi,
I'm new with CodeIgniter, i start by doing a login form, i have a login_form.php file :

Code:
<?=form_open('base_url').'main/login'?>
    <div id="basic" class="myform">
        <h1>Title</h1>
        <p>Message</p>
        
        <label>Login
            <span class="small">Add your login</span>
        </label>
        &lt;?=form_input('UserLogin',set_value('UserLogin'))?&gt;  

        <label>Password
            <span class="small">Add your password</span>
        </label>
        &lt;?=form_password('UserPassword')?&gt;

        &lt;?=form_submit('','Login')?&gt;
    
        <div class="spacer"></div>
    </div>
&lt;?=form_close()?&gt;

and into my main.php controller i do :

Code:
?php

class Main extends Controller {

    function Main()
    {
        parent::Controller();    
    }
    
    function test()
    {
        echo 'je suis un teste Yass';
    }
        
    function index()
    {
        
        $this->load->view('main/login_form');
    }
}

i alsow do in my autoload.php :

Code:
...
$autoload['libraries'] = array('database','session','form_validation');
...

...
$autoload['helper'] = array('url','form');
...

But when i brows to http://127.0.0.1/YASS/ the form fields dosnt apears but all text is ok (Title, login, password)!

Can some one help please.

THKS

El Forum

[eluser]clip[/eluser]
Do you have short tag support enabled? If your dead set on using short tags I would recomend changing the setting in your config/config.php file rewrite short tags to TRUE.

http://ellislab.com/codeigniter/user-gui...e_php.html

El Forum

[eluser]bibos[/eluser]
OK it's WOrking i just modifie php.ini file :
short_open_tag = Off

THKS