835 questions
3
votes
1
answer
320
views
Laminas MVC upgrade from ZF3 and to PHP8.2
Questions:
Has anyone used Laminas MVC components on PHP8.2 without depracted warnings?
What's the best way to adjust the session settings when migrating.
Issue: using Laminas Migrate and upgrading ...
0
votes
2
answers
897
views
Laminas Unable to resolve service "Laminas\Authentication\AuthenticationService" to a factory
I'm learning Laminas Framework for PHP and expanding the features of the Album tutorial provided in the official documentation. I've successfully added features like login and registration to the ...
1
vote
1
answer
507
views
LaminasStorageCache issue after migration from Zend Framework 3 to Laminas
I migrated a project from Zend Framework 3 to Laminas.
Since I occur an error with Doctrine and DoctrineModule\Cache\LaminasStorageCache.
The message says:
Service with name "DoctrineModule\Cache\...
0
votes
1
answer
689
views
Laminas Framework Routing Issues
I am developing a website using the Laminas Framework. Some URIs (listed below) are not behaving as expected. I am unsure if the problem is Laminas or php:fpm or nginx.
Questions:
How can I have (G) ...
0
votes
1
answer
268
views
Using JSON_EXTRACT in WHERE clause using Laminas-Db
I have a mysql table with a json datatype used to store json_encoded data:
id|author_id|date_inserted|comments
---------------------------------------------
1|32|2022-04-01|{"id": "343&...
0
votes
1
answer
73
views
Zend Framework 3 - Module won't load
So i've a web app using Zend Framework 3. It ran perfectly until today. I tried to add a module ("Params") and i can't figure why it doesn't load.
My Module tree :
My config/Module.config....
0
votes
0
answers
38
views
Problem with Oci8 and php7. 4 on command line
I have some troubles with my php7.4 and Oci8.
I have configured it in my apache2 installation and it works for the web application.
But when I try to execute a php script in command line, I get the ...
0
votes
1
answer
182
views
Extending module but keep no-overwrite template map
I was looking for how to re-use my User module across other projects.
As I have custom features for each my clients, I decided to create:
One generic UserModule to be packaging
One extend-module ...
1
vote
1
answer
273
views
PHP Foreach in foreach loop
I have this long foreach code I want to use to get folders and subfolders ids in order to be able to delete them.
// first foreach code
$idsToDelete = $this->entityManager->getRepository(...
1
vote
1
answer
2k
views
Problems when creating a new project with zendframework 3, using a Composer
Please i'm trying to learn the Framework Zend 3, even i know it is outdated framework but i should learn it because i have to use it in alternation in the company.
I am trying to follow the ...
0
votes
0
answers
184
views
PHP Laminas Framework Flash Messenger replaces space with " + "
The flash messenger replaces the message spaces with the " + " symbol when trying to create something, but it works perfectly when updating.
How to remove the " + " symbol?
code ...
0
votes
0
answers
73
views
How To import excel (.xlsx) Zend3 framework
I have tried integrate phpExcel library into zend 3 framework.
for this I have added phpexcel library into vendor folder and modified the
following files to install library without composer
1.modules....
1
vote
1
answer
537
views
Laminas (Zend Framework 3) Doctrine input filter callback validator - "Call to a member function getId() on null" when isValid false
I have a book management module in my application. When editing a book (in the form) I want to check whether the current reading progress (number of read pages) is not greater than the number of all ...
0
votes
1
answer
291
views
Zend Framework compability with Lucene 8.4.1
I am using Lucene 3.5.0 for index creation. Zend-Framework-1.8.2 with PHP-7.1.12 is being used to search index.
I have upgraded Lucene from 3.5.0 to 8.4.1. The indexes are now created with Lucene 8.4....
0
votes
1
answer
193
views
Laminas acl navigation with multiple roles
I have question about laminas navigation and acl.
In my application, a user can have multiple roles non hierarchicals. But in the documentation, I have read that only one role should be passed to it ...
0
votes
0
answers
63
views
How to Solve this error- Deprecated: You are retrieving the service locator from within the class
Deprecated: You are retrieving the service locator from within the class Application\Controller\myController. Please be aware that ServiceLocatorAwareInterface is deprecated and will be removed in ...
0
votes
0
answers
228
views
Could not instanciate mail function with PhpMailer
I'm using Laminas framework for a project I'm developing. I installed Node.js to use maildev as SMTP server for sending mail e-mails with PHPMailer and everything is working well.
The next step is to ...
3
votes
3
answers
679
views
laminas-migration migrate -> "command not found" (ubuntu 20.04)
I am trying to migrate a ZF3 app to laminas. I have installed composer via apt, and added its vendor/bin to the PATH environment variable, for global usage:
$ composer -V
Composer version 2.2.4 2022-...
1
vote
1
answer
1k
views
Laminas, problem with passing filtered fieldset inputs values to validator factory
I use Laminas of most recent version. I have a fieldset that is added to a form via init() and it is set as a base fieldset. If you define getInputFilterSpecification() in the fieldset, before the ...
0
votes
1
answer
974
views
Laminas / Zf3 - getting parameters from Fieldset but it return null values
I was following the instructions of @crash and I get the value of my parameter passed in my fieldset. But sometimes it returns a null value. Here are my complete code
My RapportEffetForm :
<?php
/*...
3
votes
2
answers
1k
views
Adding events to Laminas
I am trying to add event for Laminas Framework that will fire when \Laminas\Mvc\MvcEvent::EVENT_DISPATCH is triggered. But absolutelly nothing happends, like this triggers not exists. What am I doing ...
0
votes
1
answer
996
views
Laminas / Zf3 - Accessing form parameters from Fieldset
I'm facing to a problem in my Laminas project.
In my controller I called my form with parameters. My form contains a add function for fieldset and I would like to read the parameters in my fieldset. ...
0
votes
0
answers
74
views
View is not getting rendered in Zend Framework 3
We have recently migrated one of our application to Zend Framework 3 (ZF3) from Zend Framework 1.x.
The migrated application is working fine in my local. When we deployed the changes to the TEST ...
1
vote
0
answers
121
views
How to inject service manager into a Model file in Zend Framework 3
I just upgraded one project to Zend Framework 3 from ZF 1.x version.
In ZF 1.x version, we have implemented a functionality like provided an unique id for a request being made in the application using ...
0
votes
1
answer
51
views
Zend Framework. A plugin by the name "prg" was not found
After updating Zend Framework to 3 version I got an error on user registration page:
Zend\ServiceManager\Exception\ServiceNotFoundException
File:
../vendor/zendframework/zend-servicemanager/src/...
0
votes
1
answer
273
views
Invalid Language: 'fil' on 'hreflang'
I'm trying to translate a website made with Laminas for Philippines in Filipino language and inform the search engines of this via the rel="alternate" and hreflang="fil" tags.
...
1
vote
2
answers
642
views
Laminas Unit-test controller-action POST parameter does not work
I have a controller extends AbstractHttpControllerTestCase.
I try to pass a parameter (some_uuid) to the dispatch() function (inside my testFoo function):
$this->dispatch('/my-special-url', 'POST', ...
1
vote
1
answer
739
views
Writing logs based on log level in Zend Framework 3
We recently started migrating a project from Zend Framework 1 to Zend Framework 3. With Zend Framework 1, we were using Log4PHP library for application logging. With Log4PHP we are able to log the ...
0
votes
2
answers
145
views
how to view image stored in data zf2
i have an image to display in view, when i put it in public/assets/img folder and writing in view(.phtml) enclosed code it works:
<img src="/assets/img/logo.jpg" width="150" ...
0
votes
1
answer
1k
views
I am following Laminas MVC tutorial, Routs I created return 404 error instead of the relevant view
I'm following the laminas MVC tutorial on official website. I have followed all the steps as said. but my Album routes return 404 error.
I made the autoload entry and ran composer dump-autoload ...
0
votes
2
answers
88
views
Zend Framework 3, why can't I bind doctrine entities to forms in the factory?
Have run into a curious behavior a few times over the years, have always meant to ask about it.
It has to do with a behavior I don't understand around binding objects to forms in Zend Framework.
...
0
votes
1
answer
60
views
How can I configure doctrine with migrations?
I have this problem when I try to generate a migration from the terminal. How can I configure doctrine with migration?
https://i.ibb.co/HqWYBdT/imagen.png
0
votes
0
answers
103
views
This result is a forward only result set, calling rewind() after moving forward is not supported
i want to iterate à table to view tables data 2 time (in listbox and dropdown boutton), when i use one foreach for 1 inout it's ok, but when i use 2 foreach for 2 inputs i hade the bellow error i ...
0
votes
2
answers
1k
views
Laminas / ZF3: Add manually Error to a field
is it possible to add manually an Error Message to a Field after Field Validation and Input Filter ?
I would need it in case the Username and Password is wrong, to mark these Fields / Display the ...
-1
votes
1
answer
363
views
Lamians/ZF3: Adding CSS Class to invalid Form Fields
I would like to add an Red Border - for example through adding an CSS Class - to invalid input fields. What is the best way to do so ?
Or does Laminas already have something built in for this ?
kind ...
1
vote
1
answer
637
views
Zf3 populate select Element with data from Database
I know this topic was discussed 2 years ago. But I stuck on difficulty that I would like to solve.
I would like to create a zf3 form which contains more than two Select Element.
I would like to ...
0
votes
1
answer
598
views
What does Laminas\InputFilter\FileInput do exactly?
I've been researching Laminas documentation for their FIleInput class and i haven't found a decent explanation of what those filters and validators actually do.
I'm building a community website and ...
0
votes
1
answer
555
views
Laminas: Different Layout Files for each Module
i would like to use a different layout file for each module which is set under view_manager- template_mapin the module.config.php
But for some reason both modules are always using the same Layout File....
0
votes
1
answer
868
views
PHPUnit testing a Laminas form with custom validator with dependencies
I am trying to test a Laminas/Laminas-Form, that has a custom validator and this validator has a dependency that gets not injected.
If I run the application in a normal environment it is working as ...
3
votes
1
answer
397
views
Status 404: ZF3 and Nginx
Nginx is giving me a 404 on my Laminas application when I try to navigate anywhere other than the base URL; from the looks of my log, it seems it is trying to serve routes as files/directories.
I used ...
0
votes
1
answer
221
views
ZF3: The requested URL could not be matched by routing
I'm setting up a ZF3 project for the first time, and I can't seem to get routing to work. On my homepage, I'm getting 404: "The requested URL could not be matched by routing."
Here's my ...
1
vote
1
answer
699
views
Injecting SQL Tables in Laminas / Zend Framework - is this the correct way?
I probably have some understanding problem with Laminas, or maybe I'm just too complicated :-)
hopefully someone can bring light in this...
I have an IndexController, an IndexController Factory and 2 ...
0
votes
2
answers
2k
views
Laminas: Get instance of DB Adapter in an Class (Injection?)
I'm relative new to Laminas and some things still doesn't make sense to me - in terms of - it looks to me very complicated how things have to be done in laminas. in my case now I need the instance of ...
1
vote
2
answers
2k
views
laminas: application wide access of variables from config files
i'm on this for several hours.
i'm looking for a way to access easily application wide variables from config files.
i've read under https://discourse.laminas.dev/t/define-global-constant-for-use-site-...
0
votes
0
answers
82
views
How to get "forward" controller plugin in service manager in Zend Framework 3?
According to this https://docs.zendframework.com/zend-mvc/plugins/#forward-plugin :
$foo = $this->forward()->dispatch('foo', ['action' => 'process']);
return [
'somekey' => $somevalue,
...
2
votes
1
answer
1k
views
Does Laminas Framework DB Adapter automatically strip tags etc. like mysqli_real_escape_string?
I'm using Laminas framework (formerly ZEND Framework) and would like to know if the DB Adapter automatically strip tags etc. at Insert and Select Statements / Execution ($statement->prepare() / $...
0
votes
0
answers
50
views
multidots/zf3-rest-api no longer exists
I've been using this library for a long time in my project, yesterday i tried to install my project with composer and i found out the package was abandoned on packagist and page was not found on ...
0
votes
1
answer
884
views
A simple REST API implementation for a website created on ZF
I have a website that stores inventory and I need to make a REST API because I have to put the web component and deliver the data to it. Communication will be secured by JWT. I found a very simple ...
0
votes
1
answer
78
views
Populate Multi select drop drop down zend 3
Hello everyone i am getting really hard time populating my multi select drop down in my form.
what i have tried so far was adding factory for my form which is like this
class MovieFormFactory
{
...
-1
votes
1
answer
37
views
how to use IN-function within Zend_Select
I different string values komma separated out of a form.
In the code I cast them and then it looks like this:
$kritkeyword ='test, abc, xyz';
Now I want to use the variable within an IN-function. In ...