Category "php"

Parsing WSDL: coudln't load from URL only for my current URL in SOAPCLIENT?

I am using SOAPclient in PHP for my integration but after so many tries and so many efforts I am not able to achieve what I was supposed to, Actually I am integ

Strange behaviour in getting Real User IP [closed]

Maybe someone could help me understand, because I m facing something that seems strange for me... maybe for a lake of knowledge arround http r

Get database value based on another input field

I've been searching for this kind of problem and I couldn't find one. I am using ajax to solve this problem but it didn't work out. I really want to have this s

Stylize woocommerce price decimals

I want to stylize the decimals in the price tag and want to delete zero decimals (before 190,00) and it should be (after 190,-) And the decimals after the "," i

how do I create custom WordPress live search?

I have already created a non-live chat search on Wordpress, but I am stuck on how to make a live dropdown search. I aim to achieve this; when one clicks on the

how to fetch specific number of rows (6 rows) from database and get average of those values , then output average to an integer [duplicate]

i am creating php script to take input from a data base containing [id,value,date] , there are many rows (increasing every minute using an api

How to have a fork of a php project still get security checks with owasp dependency check

We use owasp dependency check against a php project using composer. Many of the modules are forked from an upstream repo and into an internal git repo. Since th

how add image upload in TinyMCeditor laravel

i'm trying to upload images in between my blog content but when i select images from the gallery its shoes the error Route[/] not found, even though the route i

PHP header() redirect is working when I serve the page from VS code, but not when I fire the script from a cron job or a Cli

I have a simple PHP script that queries MySQL DB and deletes(unlinks) file(s) from an uploads folder when a condition (expiry timestamp) is met. Then it redirec

2 Forms, Same Method but different task

How can I make 2 forms which has the same method? One is responsible to open editaddresss.php with hidden addresse ID, and the second form (editaddress.php)shou

What causes the data validation error in this Laravel API? [duplicate]

I am working on a registration form with Laravel 8 and Vue 3. The back-end is an API. In the users table migration file I have: class CreateUs

Hide or show input on dropdown selection

I am trying to create a sign-up page for my app. All the code works, but when I try to hide input box based on dropdown select, it doesn't work. I tried this: &

Loading Captcha image form a site does not work

I am trying to collect Captcha images using the Python requests module and save them to file or load in memory for further processing, but nothing works as belo

strpos works with php 8.1 not php 7.2

Hi this code is working on php 8.1 PHP 8.1.2 (cli) (built: Apr 7 2022 17:46:26) (NTS) but not with PHP 7.2.24-0ubuntu0.18.04.11 (cli) (built: Mar 2 2022 17:52

pdo wrapper last id return 0

hello Iam trying to make a project using php mvc and I used on it pdo wrapper package the main problem that when I use lastinsertid it always return 0 I know th

Laravel cashier (stripe) - retrieve invoice without user

I'm using Laravel Cashier. I dont use reel users for payment $stripeCharge = (new User)->charge(100, $paymentMethod); Now, I need to preview invoice informa

How to include model attribute automatically?

I have the User model which define the following attribute: public function getAvatarUrlAttribute() { return 'https://i.pravatar.cc/300?u=' . $this->

Clickatel WhatsApp Integration Unable to Send Images

I am unable to send media files especially images(jpeg) using the Clickatel One API. However, text messages are being delivered. Below is my code snippet for se

How to use more than 1 quotation using getRows method and .implode in sql Query, using PHP

I'm trying to get all records from db using getRows method, to achieve that I need to implode special characters. In previous function, to get $ids I used: fore

Yii1 DB transaction timeout is ignored when selecting for update and the row is locked longer than the timeout

When the DB transaction is timeouted the transaction is still active and seems to only finish executing after PHP transaction timeout If I lock the table outsid