Support the ongoing development of Laravel.io →
Authentication Input Forms
Last updated 1 year ago.
0

You can do

$rules = array();

if ( Input::has('image') )
{
    $rules['image'] = 'required';
}
Last updated 1 year ago.
0

eriktisme said:

You can do

$rules = array();

if ( Input::has('image') ) { $rules['image'] = 'required'; }

This works only if user submits new image. But since I stored image information in database I can use your code to solve my problem. Thanks

Last updated 1 year ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

alenn-m alenn-m Joined 5 Mar 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.