Category "php"

Why foreach not working with date changer?

I want to change my database dates from jalali to gregorian. but when I run the code, foreach not working and not getting all of my datas from database. This is

Target class controller does not exist - Laravel 8

Here is my controller: <?php namespace App\Http\Controllers\Api; use App\Http\Controllers\Controller; use Illuminate\Http\Request; class RegisterControlle

Wordpress how to get the post thumbnail inside a figure tag

I am running a query loop and want that 'if' the post has a featured image, it needs to be inside a <figure> tag. But the featured image's <img> tag

Q: How to override the Elementor's function in function.php?

I want to write a new code to override original function: For Exsample ori code: elementor-pro/modules/posts/skins/skin-cards.php class Skin_Card

error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure

I'm trying to connect to a service that requires a certificate for authorization, I import certificates on my machine and when I directly hit on the server by m

How to get array values using foreach in laravel

I am new to laravel and php. I have this code in one of my controllers: $group_by_precedence = array("true", "false"); And this code in the view: @foreach ($gr

Is it possible to change the table name in the migration file-laravel

I created a migration file using php artisan make:migration create_todoapps_table. The migration file was created with the table name as to_do_apps (Schem

Unable to open file stream for given path error with MSGraph SDK

I have a web app I wrote in JS. There is a form that allows file upload, which is then handled by PHP. I have an account already, and I've registered an applica

Laravel Passport - Not able to get token string in response?

i am getting result like below in registration using passport laravel "success": { "token": { "name": "MyApp", "abilities": [

Apache/PHP Correct permissions for uploading a binary that runs server side?

I've prepared a PHP browser interface (like a modem interface) for an embedded system, that is supposed to help manage the core application (uploading a new bin

nginx err_connection_refused, can anyone help me?

got installed my old site with php, mysql and so on, an everything work fine but my site is not reachable from the outside of my LAN. Did a ton of changes and t

Fatal error: Array and string offset access syntax with curly braces is no longer supported in php 8.0 pkcs5_unpad

I got this error after copying code from a tutorial. It's deprecated and I tried resolving it: Array and string offset access syntax with curly braces is no lo

How can I get user id from session in javascript?

How can I get the user id from session in javascript? I was using this: $( document ).ready(function() { var sessionUserId = '<?php $_SESSION['user_id']

Can I send a database in a zip folder with mantaining the connection between the database and the php file

I want to send a folder that contains my HTML code, CSS, js and PHP. how can I include the database and keep the connection between my files and the database?

how to hide previous markers when new markers added in google map javascript api

I have set store locator using google map javascript api. when someone enter their location they will find the stores within the 50km of radius. I want when use

I need a Variable from the MyBB-Forum

my previous attempts to declare a variable always failed. Task: In the table mybb->users there is the column verified. This column has either a "1 or a "0" (

How can I make this nested location configuration use the correct path to call a php program?

I have setup nginx to allow users to have a user website (https://example.org/username maps to /home/username/www). I want to allow my users to use php. Php is

Laravel print last executed SQL query with Query log

DB::enableQueryLog(); $mines = Cranks::where([['crank_id', '=', $this->crank_id], ['mine_id', 'like', '%'.$script_value->mine_id.'%'] ])->get(); $query

WooCommerce single product page by Woolentor : Related product customize

I use WooCommerce, Woolentor, and WooCommerce subscriptions to construct a website. I'm trying to use the 'WL:Related Product' widget for Woolentor's Single Pro

Warning: mysqli_stmt::bind_param(): Number of elements in type definition string doesn't match number of bind variables 11 [closed]

My code against SQL injection isn't working (error message in title). I simplified my code, but its still not working. <?php include "con