laravelcollective / docs Goto Github PK
View Code? Open in Web Editor NEWDocumentation for LaravelCollective Packages
Documentation for LaravelCollective Packages
https://laravelcollective.com/docs/5.2/html#form-model-accessors
The following parts' comments are both wrong. The funciton are used to "get the date_of_birth" instead of "Get the user's first name."
`
class User extends Model
{
/**
* Get the user's first name.
*
* @param string $value
* @return string
*/
public function getDateOfBirthAttribute($value)
{
return Carbon::parse($value)->format('m/d/Y');
}
/**
* Get the user's first name for forms.
*
* @param string $value
* @return string
*/
public function formDateOfBirthAttribute($value)
{
return Carbon::parse($value)->format('Y-m-d');
}
}
`
How i can use this submit button with laravel using form.
Materializecss: http://materializecss.com/buttons.html
<button class="btn waves-effect waves-light" type="submit" name="action">Submit
<i class="material-icons right">send</i>
</button>
Form::submit('Submit',array('class'=>'btn waves-effect waves-light');
<i class="material-icons right">send</i>
This not working.
This isn't documented anywhere, but the fact that all Form and HTML helper functions return HtmlString
objects means that they can be safely used with normal escaped Blade template tags. ie.
{{ Form::open() }}
works just as fine as
{!! Form::open() !!}
This is probably a safety feature, and there is a minor performance penalty for the former, but it might be worth mentioning anyway?
The documentation regarding form model accessors (https://laravelcollective.com/docs/5.2/html#form-model-accessors) does not match the implementation in the code. Currently, the getModelValueAttribute()
method in FormBuilder.php
, looks for a model method called getFormValue()
whereas the documentation says to create a model method like formMyAttribute()
. Does the documentation need to be updated to match the code or vice versa?
For what it's worth, I think I like the format suggested by the docs better than what the code currently implements. Having a single getFormValue()
method requires a bunch of conditionals to figure out which attribute to return; using multiple methods seems cleaner. Then again, once could implement a number of protected methods called by getFormValue()
...
I can submit a PR with either fix. And thanks for the work you've put into this package, it's been a pleasure to work with.
Any Documentation for Bootstrap modal with Form within ?
But still works as it used to do in 4x. It will be fine having it documented here.
Hi, I'm just testing on the SSH connection follow by the step inside, but when I reach the usage and try to run SSH2::into('staging')->put($localPath.$filename, $remotePath);, it return me the error of "Class 'App\Console\Commands\SSH2' not found". Not sure which step I did wrong, but i follow exactly the step given inside the documentation.
Hi, I'm not sure if this is the right place to request this, but the Section #Form Model Binding could use some examples/clarifications around other options -ie how do we specify the class when this method of creating a form is used.
When it comes to the form element, there isn't anything about assigning a class anywhere in the docs.
There's a mention of it under #Labels, as the 3rd parameter. Can it be used as the 3rd parameter in the form model binding?
Any clarification you can provide would be helpful - I tried figuring it out from the source code, but wasn't even sure where to start - Attributes maybe?
Currently there are no specific docs for versions 5.5 and 5.6 of the html package. They only go up to 5.4.
I'm not completely aware of all the changes between those (if any), but details like package auto-discovery from Laravel 5.5 and so could be better documented.
Is this something desirable? I'd be glad to work on it.
Hi,
Would it be possible to create a branch for the Laravel 5.4 documentation? I'm willing to go through the documentation and update stuff where needed, but I need a branch for that :)
All the doc pages not found. Any solution to this?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.