skip to Main Content

Mysql – save checkbox in db as 0 or 1 using livewire

I have difficulty how to save the checkboxes on to the database using livewire. view: <div class="mt-2"> <div class="flex items-center space-x-8 justify-center"> <label for="Email"> Email</label> <input type="checkbox" value="{{$notificationEmail}}" id="notification_email" wire:model="notificationEmail"> <label for="Phone"> Phone Number</label> <input type="checkbox" value="{{$notificationPhone}}" id="notification_phone" wire:model="notificationPhone"> <label…

VIEW QUESTION

Laravel: Getting 'SQLSTATE[HY000]: General error: 1 no such table: webServiceLogs' when trying to store in database – Phpmyadmin

I have set up a migration file: use IlluminateDatabaseMigrationsMigration; use IlluminateDatabaseSchemaBlueprint; use IlluminateSupportFacadesSchema; class LogggingTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::connection('mysql2')->create('webServiceLogs', function (Blueprint $table) { $table->bigIncrements('id'); $table->timestamps(); $table->string('query');…

VIEW QUESTION
Back To Top
Search