Support the ongoing development of Laravel.io →
posted 10 years ago
Views Forms
Last updated 2 years ago.
0

So show us the actual implementation of the inputText() method then.

0

Here is the method (i know this is useless it is just for testing), when calling {{ HelperView::inputText() }} I get plain text..

namespace Tymax\Helpers;

use Illuminate\Http\Request;
use Illuminate\Html\FormBuilder;

class HelperView {

    public static function inputText() {
        return "Form::text('best_time_call', null, array('class' => 'input-sm'))";
    }

}
0

Try dropping the quotes:

public static function inputText() {
    return Form::text('best_time_call', null, array('class' => 'input-sm'));
}
Last updated 10 years ago.
0

Awsome, thanks rscafi! I didn't think of that. For anyone else I just had to add

use Illuminate\Support\Facades\Form
Last updated 10 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

moto485 moto485 Joined 24 Sep 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.