Category : laravel

this is the error I get when installing compose my php v is 7.3.21 apache 2.4.46 mysql 5.7.31 The PHP exe file you specified did not run correctly: C:wamp64binphpphp7.3.21php.exe The php.ini used by your command-line PHP is: C:wamp64binphpphp7.3.21php.ini A setting in your php.ini could be causing the problem: Either the ‘extension_dir’ value is incorrect or ..

Read more

I get a binary mlm laravel file I checked its register controller file, it assign value like this $this->activeTemplate = activeTemplate(); in __construct() I finding where is activeTemplate(); not see where it exit. and it make return view by this template return view($this->activeTemplate . ‘user.auth.register’, compact(‘reference’, ‘page_title’,’country_code’)); How can use laravel as this complex way ..

Read more

$response is an array like below: [ { "courseId": 14, "tutorName": "admin" },] The below code gives a result like this: "data": 3 .I wanted add a new item called points with the first array. But here, it overwrites the existing array.How can i achieve this? $dat=array_push($response,array(‘points’=>"3")); return response()->json([‘data’ => $dat], 200); Expected output: [ ..

Read more

I make my first app with API. I am beginner in Laravel and php. I have this migration: Schema::create(‘users’, function (Blueprint $table) { $table->bigIncrements(‘id’); $table->bigInteger(‘company_id’)->unsigned(); $table->foreign(‘company_id’)->references(‘id’)->on(‘companies’)->onDelete(‘cascade’); $table->string(‘name’); $table->string(‘surname’)->nullable(); $table->string(‘phone’)->nullable(); $table->mediumText(‘description’)->nullable(); $table->string(’email’)->unique(); $table->timestamp(’email_verified_at’)->nullable(); $table->string(‘password’); $table->string(‘api_token’, 80) ->unique() ->nullable() ->default(null); $table->string(‘menuroles’); $table->boolean(‘status’)->default(false); $table->string(‘slug’, 160); $table->rememberToken(); $table->timestamps(); $table->softDeletes(); }); and this is my AuthController: class AuthController extends Controller ..

Read more

I’m trying to display a plot that is generated with plotly in python, inside my laravel application. When I execute python3.8 ../storage/app/public/rcs/line-chart.py command in my terminal from the public directory of my laravel project, the plot is displayed. However, when I send a request to my laravel application to execute the same command using symfony ..

Read more

i wanted to display id,FileName & FilePath from Files table and id & name from User table along with the course table columns. But it is returning null from both files & user relations.How can i fix this? $course=Course::with([‘files:id,FileName,FilePath’,’user:id,name’]) ->select(‘id’,’courseDisplayName’,’aboutCourse’) ->where(‘userId’,$request->tutorId) ->get(); Course Model public function files() { return $this->belongsTo(Files::class, ‘fileId’, ‘id’); } public function ..

Read more

I got error that says Method AppHttpControllersFrontendAtributAtributDashboardController::deleteData/{id} does not exist. I write my routes like this : Route::group([ ‘prefix’ => ‘atribut’, ‘as’ => ‘atribut.’ ], function () { Route::group([‘prefix’ => ‘tabHome’, ‘as’ => ‘tabHome.’], function () { Route::get(”, [AtributDashboardController::class, ‘showTab’])->name(‘showTab’); Route::post(”, [AtributDashboardController::class, ‘addData’])->name(‘addData’); Route::get(”, [AtributDashboardController::class, ‘deleteData/{id}’])->name(‘deleteData’); }); in the controller i also already write these ..

Read more