Product edit in admin - PHP v8.0 "Unsupported operand types: string + int"

Started by xur82, July 20, 2022, 15:35:23 PM

Previous topic - Next topic

GJC Web Design

This is not an error trace ... this is error reporting which is breaking your session header etc

https://forum.virtuemart.net/index.php?topic=117042.msg470068#msg470068

or try again with reporting set to default and the debug plugin enabled but all options set to off if u run out of memory
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

subn3t

Yes! I know what a backtrace is and how to find the problem in logs. It was just not showing. :)

I finally found out what was the problem. After upgrading to Joomla 4 I managed to switch on the error reporting and get the trace. It was a third party payment module that had the problem and when I fixed it wit adding (float) before the string in the problematic line everything worked perfectly.

I am now sending the problem to the guys that wrote the plugin so they can apply it.

Thank you very much for the time you spent with my problem.

Kind Regards,
Stefan

pico71

Hi Have problem with BACKEND ov VIRTUEMART when use PHP 8.1
Using PHP 8.1 - Give me error when I try to edit a product from backend.
Are we sure that VM VirtueMart 4.0.12 10777 (I have this versione) is fully compatible with PHP 8.1 ?
My JOOMLA Versione is: 3.10.11
THX

jenkinhill

What is the error?

Joomla 3.10.11 is not compatible with PHP 8.1, unless the level of error reporting in the Server tab of the Global Configuration is set to 'Simple' or 'None'. The recommended version of PHP for Joomla 3.10.11 is PHP 8.0, as you can see from the Technical Requirements for Joomla 3.x.
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

pico71

I have Error Level set to NONE but PHP 8.0 do nork at all (Nor frontend nor backend)
BUT PHP 8.1 works quite well in the frontend ... but have issues in the backend (virtuemart backend - Product edit)

GJC Web Design

Far more likely your template isn't compatible .. try with Beez etc
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

goooogy2000

I put the build (clean stable versions) of Joomla 4.2.7 + Virtuemart 4.0.12 on the XAMPP server with php 7.4 - editing the product card and category card works fine. If I put the same assembly on XAMPP with php 8.0 or php8.1, then there is no way to edit the product card or category card. What could be, where to look?

GJC Web Design

provide a FULL report of what is happening, what the error is etc etc

I have multiple installs on Joomla 4.2.7 + Virtuemart 4.0.12 + php8 working fine ( apart from the https://forum.virtuemart.net/index.php?topic=149553.msg534030#msg534030 problem fixed in 4.0.13)
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

goooogy2000

I tried to attach a screenshot, but the system does not skip such an answer


GJC Web Design

apart from the fact it looks like you have css not loading (check the console - have u fully cleared all caches ?  ) you also have these 3 things to correct.

The only error I assume is because u can't create thumbnails .. ( no GD library? )

GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

goooogy2000

the problem was solved by uncomenting the extension=gd string in php.ini

T.A. Garrison, LLC

Ok. I've read through the thread and don't find a resolve.

I "had" VM 4 installed with J4.2.8 yesterday and then had to reinstall everything. I "dropped" everything in the database and started over (it's a dummy site and nothing other than VM, Istraxx Quantity Discount, and JCE have been installed - using Cassiopeia). I also have Php 8.0 enabled.
Upon reinstall with VM 4.0.12 10777 and J 4.2.8 I created a product yesterday. It worked. Not today.

Today, I created a second product (a lot of testing required for this project). I also created "Custom Fields" - 2. One if for "Group" and a second for "Year".
Everything was working fine until I clicked on "Product Details" (either product has the same results), and got an error from Joomla:

The requested page can't be found.

An error has occurred while processing your request.

You may not be able to visit this page because of:

    an out-of-date bookmark/favourite
    a mistyped address
    a search engine that has an out-of-date listing for this site
    you have no access to this page

Go to the Home Page

If difficulties persist, please contact the website administrator and report the error below.

    0 Unsupported operand types: float * string



I've unpublished the Custom Fields and tried again. Same results.
I deleted the Custom Fields from both products and tried again. Same results.

Then I unpublished the plugin I installed after reinstalling everything else.
It turned out that the Quantity Discount plugin for which my client paid is causing the problem.

Because this is something for another thread I'll move over there now that I know what's causing the issue. But the Istraxx 1.10.0 is at fault and also has an error when debugging - Deprecated: Required parameter $plus follows optional parameter $currency in /home/schoolfo/store.schoolfortheblonde.com/plugins/vmcalculation/istraxx_quantity/istraxx_quantity.php on line 546

My problem throws the error that is discussed in this thread. I thought it would help others, but I began posting here before I ran down the culprit.


By the way. The "gross price" in the latest VM? I don't understand the value of having that "mandated" in every site that uses VM 4. Why isn't that an option? I'll hide that via CSS, but still....
Things like that "may" be helpful, IF one could arrange the order in which things like that appear. But where it appears is wrong. Too many "? - price" and it's becoming confusing for customers.
T.A. Garrison, LLC
3150 Orleans St. # 28261
Bellingham, WA 98228

pinochico

You don't need plugin, we have quantity range table in product detail too - is only 10 lines code in php, you can write self without error :)

I don't understand, every want plugin plugin plugin, but don't want do it self...
I don't developper, but this table created self, every info you have in object product price :)
www.minijoomla.org  - new portal for Joomla!, Virtuemart and other extensions
XML Easy Feeder - feeds for FB, GMC,.. from products, categories, orders, users, articles, acymailing subscribers and database table
Virtuemart Email Manager - customs email templates
Import products for Virtuemart - from CSV and XML
Rich Snippets - Google Structured Data
VirtueMart Products Extended - Slider with products, show Others bought, Products by CF ID and others filtering products

T.A. Garrison, LLC

If I had somewhere that I could get "updated" information with proper coding instructions, I would prefer to not use the plugin!
I've only been able to find "outdated" instructions.

I've been unable to find code / instructions on how to create the quantity steps. I searched for days before finally purchasing the plugin.
Are you saying that plugin is not going to work?
I have no problem uninstalling the plugin. But I would need to "updated" instructions for VM 4 and J 4 in order to not use the plugin.
T.A. Garrison, LLC
3150 Orleans St. # 28261
Bellingham, WA 98228