Search
 
SCRIPT & CODE EXAMPLE
 

PHP

select option edit in laravel

<select name="like_to" id="like_to" class="form-control">
  <option value="giveaway" {{$data->like_to=='giveaway' ? 'selected' : ''}}>Give Away</option>
  <option value="lend" {{$data->like_to=='lend' ? 'selected' : ''}}>Lend</option>
  <option value="borrow" {{$data->like_to=='borrow' ? 'selected' : ''}}>Borrow</option>
</select>
Comment

select option selected laravel edit foreach

<div class="form-group">
    <strong>Country:</strong>
    <select name="country" class="form-control custom-select">
      <option value="">Select Country</option>
      @foreach($countries as $country)
        <option value="{{ $country->id }}" @if($country->id == $user->country) selected @endif>{{ $country->name }}</option>
      @endforeach
    </select>
</div>
Comment

PREVIOUS NEXT
Code Example
Php :: select multiple option in laravel 
Php :: How do I get current taxonomy "term id" on wordpress? 
Php :: img upload in php 
Php :: qr code generator php 
Php :: php unique associative array by value 
Php :: php invoke 
Php :: laravel model wherein 
Php :: php insert array into mysql 
Php :: if request type is post 
Php :: laravel mysql specified key was too long 
Php :: get all sort by laravel 
Php :: curl json post 
Php :: add a controller method in laravel routes 
Php :: checkbox options wordpress 
Php :: how to make a loop that adds numbers to a variable in php 
Php :: update laravel 
Php :: how to clear php form data after submit 
Php :: protected gaurded in laravel 
Php :: php curl empty response 
Php :: Create a table with PHP in html 
Php :: do artisan laravel in code 
Php :: create model, controller and migration in single command laravel 
Php :: wordpress plugin functions exist 
Php :: symfony form get errors 
Php :: laravel model uploaded file name 
Php :: laravel simplexmlelement not found 
Php :: wordpress nav menu align right 
Php :: Create Mysqli Table Using Php 
Php :: preg_replace allow spaces 
Php :: round to 0.5 php 
ADD CONTENT
Topic
Content
Source link
Name
2+1 =