Morning, I have form with dynamically rows and select option into first column. I would like to set a value into specific element of my row after event select. Actually for each row, all elements change after select. My form: <tbody> <tr> <td> <Select class="form-control form-control-sm" name="item_desc[]" id="item_desc" type="integer" onchange="select_field(this)"> <option> </option> @foreach ($articles as ..

Read more

I can update my email and password but i can’t udpate my profile photo. Here is my code which i wrote.I don’t know where I did it wrong, could you help me?I guess i missed something about of ProfileInformationController.php in Fortify <form method="POST" action="{{ route(‘user-profile-information.update’) }}" enctype="multipart/form-data"> @csrf @method(‘PUT’) <div class="form-group row"> <label for="name" class="col-md-4 ..

Read more

After intalling Docker on windows and setting some settings for that. after opening firefox and locating localhost its take a long time to opening my web application which i should see on browser. as far i installed Ubuntu linux from windows store i’m not sure my projects should be placed on that or not. without ..

Read more

I am using Laravel 8 and JWTAuth package for the api requests, often the request throws error when trying to access user info with the following line: JWTAuth::user()->id The error: 500 Internal Server Error ErrorException: Trying to get property ‘id’ of non-object … The only way I could resolve this, temporary however, is to refresh ..

Read more

I host an Apache PHP server on which there’s a couple of websites. Let’s call these X and Y. After I cleared the cache (and made some changes) on both my laravel websites, I get the following error often: [previous exception] [object] (PDOException(code: 42S02): SQLSTATE[42S02]: Base table or view not found: 1146 Table ‘Y.events_ip’ doesn’t ..

Read more

game id name matches belong to the game id game_id teamA teamB score id match_id teamA_Score teamB_Score point user_id I want to add a calculated field to the game (total points) public function getPointsAttribute() { return $this->points()->sum(‘point’); } public function points() { return $this->hasManyThrough(Score::class,Match::class); } This is working fine. But I want to filter the ..

Read more

I am currently trying to setup the Twinfield API, it should be pretty straight forward when using the php-twinfield/twinfield library. But there is one thing I don’t fully understand. Here is my code: $provider = new OAuthProvider([ ‘clientId’ => ‘someClientId’, ‘clientSecret’ => ‘someClientSecret’, ‘redirectUri’ => ‘https://example.org/’ ]); $accessToken = $provider->getAccessToken("authorization_code", ["code" => …]); $refreshToken = ..

Read more

I must update my currency rate and I have this in my Plugin.php: { $schedule->call(function () { $url = "https://cbu.uz/ru/services/open_data/rates/json/"; $json = json_decode(file_get_contents($url), true); file_put_contents("currency.json", json_encode($json[0][‘G4’])); })->everyMinute(); } I ran my cron job in cpanel /usr/local/bin/ea-php72 /var/www/u1041398/public_html/agroparts.uz/artisan schedule:run >> /dev/null 2>&1 Path is correct I checked php version it is correct also. My cron codes ..

Read more

What I’m trying to achieve is to sync mobile app data with server database. I was thinking for an optimal solution because fetching all data from the server and updating mobile app this way is not very optimal solution. I came up with this thought to implement: Mobile app will send list of id’s and ..

Read more

What I’m trying to do: Send a post request using postman to a laravel API which in-turn sends 2 post requests using guzzle, one request to the same laravel application api and other to 3rd party api like: $responses = all([ $client->postAsync(‘www.someurl.com/here’, [‘form_params’ => $postData]), $client->postAsync($hook, [‘form_params’ => $sendNotification]) ])->wait(); Here, the 1st request is ..

Read more

my web.php like that Route::group([‘middleware’ => [‘auth’, ‘admin’], ‘domain’ => config(‘app.domain_admin’)], function() { Route::get(‘/’, [AppHttpControllersAdminTranslationController::class, ‘info’])->name(‘index’); Route::get(‘/paymentSys’, [AppHttpControllersAdminAdminController::class, ‘paymentSys’])->name(‘paymentSys’); Route::post(‘destroy’, [AppHttpControllersAdminAdminController::class, ‘destroy’])->name(‘destroy’); Route::get(‘index’, [AppHttpControllersAdminAdminController::class, ‘index’])->name(‘index’); Route::post(‘update/{news}’, [AppHttpControllersAdminAdminController::class, ‘update’])->name(‘update’); }); config(‘app.domain_admin’) equals to admin.paysys.ssd.uz. My admin middleware has this: public function handle(Request $request, Closure $next) { if (Auth::user() && Auth::user()->user_role == "admin") { return $next($request); } ..

Read more

I have a blade as shown <input type=’text’ id="input1"> <div > <h3 id="showData"> Data will be shown here </h3> </div> <script> var input=document.getElementById(‘input1’).value; document.getElementById(‘showData’).innerHTML=input; </script> What I want is to write the script part as a separate file (say called externalScript.js) and call it here in the blade page. Also, I have a doubt about ..

Read more

I would like to make a component. However It does not work. I tried to @component(‘components.pulldown’)@endcomponent however , it happnens 500 error. so I used @exntend instead. but it only displays upper side of the page. @foreach ($users as $user) <tr> <td>{{ $user->id }}</td> <td>{{ $user->name }}</td> @if($user->country) <td>{{ $user->country }}</td> @else <td>Select @extends(‘components.pulldown’) </td> ..

Read more

I have API which I have uploaded on the server. The url looks like this: api.subdomain.domain.com/ I’ve made .htaccess to go directly to the public but when accessing it should be like this: api.subdomain.domain.com/api/login How can I access it directly like api.subdomain.domain.com/login. This is my .htaccess RewriteEngine On RewriteCond %{HTTPS} !on RewriteRule ^.*$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] ..

Read more

I just started laravel lately and i need help on this ajax uncaught reference, it got solved with some help from here. but right now it is having "jquery.min.js:6 GET http://127.0.0.1:8000/bd/quotation/search?query=Sun 500 (Internal Server Error)" which unable to fetch the data when i search from the list. this is the index blade file, which shows ..

Read more

[enter image description here][1]I’m using Laravel 7x and flysystem-google-drive. i want get body to report bugs to api instead of reporting the error directly. code error i want to get: [2021-05-06 10:28:31] local.ERROR: { "error": { "errors": [ { "domain": "global", "reason": "notFound", "message": "File not found: 1S1QYxpypWItSTx8gSUVHDq-PeQeqyKt.", "locationType": "parameter", "location": "fileId" } ], "code": ..

Read more