Skip to main content

Questions tagged [php]

PHP is an open-source, multi-paradigm, dynamically-typed, and interpreted scripting language designed initially for server-side web development. Use this tag for questions about programming in the PHP language.

0 votes
0 answers
4 views

Cannot using API Inside middleware in laravel

so this is my api.php // Rute Publik Route::post('register', [AuthController::class, 'register']); Route::post('login', [AuthController::class, 'login']); // Rute yang Memerlukan Token Akses Route::...
Tsabit's user avatar
  • 65
-1 votes
0 answers
15 views

How to insert script code in php code in script code again [duplicate]

hello Can some one solve my bizzare code, I wrote code then I put a php code inside function variable, and in that function I adding again code inside php, it means Script code in php code in script ...
Ricky Suwandi's user avatar
0 votes
0 answers
8 views

I get 401 unauthorized error after successful login in reactjs app with laravel & sanctum

I have created an app with React while using Laravel 10 as back-end (using Sanctum for auth). When I try to log in on first attempt I get "401: unauthorized" error, but on second attempt it ...
Noor's user avatar
  • 7
0 votes
0 answers
9 views

combine class properties to reduce the code lines [duplicate]

I want to combine class properties this <?php $pagination = new Pagination(); $pagination->setLink("$appDir/category/?c=$c&p=%s"); $pagination->setPage($p); $pagination->...
Ziad Nassar's user avatar
0 votes
0 answers
7 views

Laravel 10 connects to SQL Server

This's first time i learn Laravel 10. I want to learn Laravel 10 by using Sql Server Database. When i try to coconnect SQL Server to Laravel 10, it always be failed. I don't know the reasons. I use ...
Stefanus Nigel Anggriawan's user avatar
1 vote
0 answers
29 views

php-fpm status on port 9000

I've set up my php-fpm status in /status. I'm having problems collecting this information with php-fpm_exporter using a tcp connection. My stack: Docker(aws ecs ec2) + Nginx+php-fpm I'm using hipages/...
juan ferreira's user avatar
-2 votes
1 answer
28 views

Problem with .htaccess redirection to my api

I have a wordpress site in wich i develop a plugin. Inside this plugin, I developed a api. In my local environment, my url to acess my site is http://localhost:81/site. I'd like requests made to http:/...
Marlon's user avatar
  • 1,817
0 votes
0 answers
13 views

Commented old comments value remaining at textarea after submit

Commented old comments value remaining at textarea after submit . livewire3 ,filemant3 and laravel10 laravel blog I want to clear the text area after submmited the comment . the text area input box is ...
KhuiShing's user avatar
-1 votes
1 answer
22 views

Laravel custom helper function bug when attempting to alter navigation links to show the current active page in Laravel blade

When I pass my custom helper function as a variable to Laravel Blade, the bug occurs when I click a link to a new page. The error will read the variable was not found. There are a total of 6 ...
Mr. Daniels's user avatar
-3 votes
0 answers
18 views

Web Scraping with PHP - Asycnchronous site [closed]

I'm helping a friend to migrate their blog from a "homemade" platform to Wordpress and the original developers have not been helpful in extracting the data. I'd like to use PHP to scrape the ...
Sanfly's user avatar
  • 1,015
0 votes
2 answers
30 views

Return embedded non-php block as a `string`

public function script(): string { ?> <script type="text/javascript"> const foo = { widgetcode: '<?= $this->...
kross's user avatar
  • 3,696
-2 votes
0 answers
34 views

how to solve this wordpress plugin problem

<form method="post" action="" id="genpro-add-form"> <h3>Adding New Products:</h3> <table> <tr valign="top"...
Roham Parsa's user avatar
-3 votes
0 answers
17 views

Struggling to fix the routing problems I'm having in php [closed]

I'm having problems accessing the pages on my website using the routes that I set in the route.php file eg. localhost/online_library_1/categories, does not work, here is my folder structure, I don't ...
programmer's user avatar
0 votes
1 answer
16 views

Woo Subscription fails because class definition Stripe is loaded after unserialize()

I'm getting this error on WooCommerce: An error has occurred while processing recent subscription related events. For steps on how to fix the affected subscriptions and to learn more about the ...
ecairol's user avatar
  • 6,463
-1 votes
1 answer
34 views

How to redirect in htaccess without blocking php api?

I have an index.php file which is located in the root directory. This outputs either HTML or JSON, depending on the URL: <?php require_once('./../private/Router.php'); new Router(); ?> &...
RoyBlunk's user avatar
  • 111

15 30 50 per page
1
2 3 4 5
97761