-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Call to undefined function bcmod() while calling tests.php #133
Comments
It looks like your docker is missing the PHP extension bcmath. But I can't help here because I don't know much about docker. |
Like I said, I don't know much about Docker. Is it possible that the PHP extension bcmath is missing from the official Docker image? I haven't received any other messages yet that bcmod is not defined. |
It's the official admidio docker container. So it's very possible that the extension is missing. I'd have to check with the latest version. Are there any downsides in including the extension by default? If not a pullrequest for admidio would be more appropriate. Sorry for late reply, very busy currently |
I see - ok, so the current admidio Docker image (more precisely: Docker images created after February 12, 2024) should contain bcmath. After switching from php:apache-bullseye to vanilla Ubuntu as the base image, the modules (and thus also php-bcmath) are installed explicitly during image creation. |
@cmellwig : tried it at home with admidio/admidio:v4.3.4 (and v4.3.6) - there is bcmath included (php 8.1.2 and bcmath extension is installed). So it should work (a quick php --re bcmath shows funcion bcmod is present). |
When calling tests I get a 500 Error Call to undefined function bcmod()
Tested with v5.2.1 on Admidio 4.2.14 (official docker image)
[Thu Dec 28 04:35:28.032099 2023] [php:error] [pid 62540] [client 172.20.0.4:46404] PHP Fatal error: Uncaught Error: Call to undefined function bcmod() in /opt/app-root/src/adm_plugins/membership_fee/common_function.php:1145\nStack trace:\n#0 /opt/app-root/src/adm_plugins/membership_fee/common_function.php(1100): test_iban('dexxxxxxxxxxxx...')\n#1 /opt/app-root/src/adm_plugins/membership_fee/tests.php(97): check_iban()\n#2 {main}\n thrown in /opt/app-root/src/adm_plugins/membership_fee/common_function.php on line 1145, referer: https://admidio.domain.tdl/adm_plugins/membership_fee/membership_fee.php
The text was updated successfully, but these errors were encountered: