1,462,059 questions
Advice
2
votes
5
replies
103
views
In Laravel, when should I use Controllers, Services, Actions, Repositories, Model?
I'm trying to understand the commonly accepted architecture patterns used in Laravel applications.
I've come across different approaches in various projects:
Controller → Model
Controller → Service → ...
Best practices
0
votes
2
replies
120
views
How would you implement category and location based SMS notifications in WordPress?
I'm building a marketplace website with WordPress and HivePress and I'm trying to figure out the best way to handle SMS notifications.
The idea is fairly simple:
Customers can post job requests.
...
-1
votes
1
answer
128
views
Selenium Python ReadTimeoutError: HTTPConnectionPool(host='localhost', port=53487): Read timed out. (read timeout=120)
It turns out that when I run these instructions in my command line in AWS Ubuntu:
/usr/bin/python3.11 && /home/bitnami/spacy_venv/bin/python3.11 /home/bitnami/htdocs/android_app_selenium.py ...
-1
votes
0
answers
102
views
YouTube Aspera rejects a valid playlist ID returned by YouTube Data API with PLAYLIST_ID_WRONG_FORMAT
We create playlists programmatically using the YouTube Data API v3 (playlists.insert) with the official PHP SDK.
Example:
$playlist = new Google_Service_YouTube_Playlist();
$playlist->setSnippet($...
Best practices
0
votes
0
replies
81
views
Laravel AI SDK: Best practices of parsing PDF documents
Looking for best practices of Laravel AI SDK:
I'm passing an AI agent a document (a Safety Data Sheet for a chemical), and I want a predefined JSON output.
Would using a tool in this case be a good ...
-4
votes
0
answers
42
views
for brizy navbar due to cls my navbar becoome a horizotal in loading and after that is look normal what is the solution for it [closed]
for my wordpress site in that i use the brizy i attach photo please check it : enter image description here
Issue: We are experiencing a Cumulative Layout Shift (CLS) issue with the Brizy navigation ...
Advice
1
vote
3
replies
123
views
why is there no Docker Hardened Image for PHP with Apache?
As of now, none of dhis for php include Apache server per default. For me this means either rebuilding with NGINX as a separate container or not using the hardened image.
In general, how good does the ...
-4
votes
0
answers
124
views
AES Encryption/Decryption Fails in PHP [closed]
AES encryption/decryption issue for specific input lengths (23 vs 24 bytes) in PHP
I’m using a custom AES implementation in PHP:
$Cipher = new AESCipher(AES::AES192);
Problem
Two similar inputs ...
-6
votes
0
answers
105
views
Faced with such a problem, the MISP web interface does not work [closed]
Faced with such a problem, the MISP web interface does not work. When switching to the interface, the error "Gateway timeout appears.
The requested URL could not be resolved"
The necessary ...
Advice
0
votes
7
replies
92
views
How to save a colored JPG image to the Milvus database?
I have an application on Symfony, through which images are uploaded.
Image data should be saved to the Milvus database to be processed by AI in the future. If I understand everything correctly, for ...
0
votes
1
answer
115
views
Wordpress / php / shortcode - remove hyphen from the output
The problem is when the topic has a space I need to include the hyphen to create a corresponding link that goes to that topic - how do I remove the hyphen from the output text but keep it in the url.
...
2
votes
1
answer
208
views
In a php program, I include some echo "javascript code..." but it doesn't execute
This is the end of the program. It downloads either a PDF file or an ePUB file.
This part works very well. But the alert doesn't show up and the redirection doesn't occur. What is wrong ?
The code :
&...
3
votes
0
answers
75
views
sharing to LinkedIn using curl and PHP - post photo AND URL to click through
I am building an app to make posts to a LinkedIn page, written in PHP, using the curl library. I have successfully:
Authenticated (scopes: w_member_social, openid, profile, email
Registered and ...
1
vote
1
answer
79
views
curl resets owner of cookie file after run from root
<?php
$url = 'https://stackoverflow.com/questions/ask';
$file = '/home/www/.cookies2.txt';
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_COOKIEFILE, $file);
curl_setopt($ch, CURLOPT_COOKIEJAR, $...
1
vote
0
answers
72
views
Text matches pattern not in the Regex [duplicate]
I have a PHP regex which looks like this:
$special_characters_pattern = '/[£$%*}{~><>|=¬!?]/';
I test user input like this:
$test_value = "station n°12015";
$verified =1;
$...