When using the Catalogue module as an ecomerece catalogue I am getting this error
PHP WARNING [2] preg_match() expects parameter 2 to be string, object given in sources/urls.php on line 631 (version: 8.1.1, PHP version: 5.2.17, URL: /site/index.php?page=shopping&type=misc&redirected=1)
Here is the stack trace:
Below is a stack trace revealing the state the software was in when the error occurred. If this represents a bug in the unmodified software, you may want to check ocPortal website for a fix, and if there isn't one, report this as a bug. Please note that merely posting a stack trace is not sufficient for us to solve your problem; the stack trace is just an aid that presents us with additional information. We still need to know the error message, what you tried to do, how you tried to do it, version numbers, and any other appropriate information.
We apologise for this problem and if it's a bug we hope you will work with us so that we can fix it for you promptly.
File
'/home/davidlfr/public_html/sources/failure.php'
Line
'684'
Function
'get_html_trace'
Args
File
'/home/davidlfr/public_html/sources/global2.php'
Line
'983'
Function
'_fatal_exit'
Args
'PHP WARNING [2] preg_match() expects parameter 2 to be string, object given in sources/urls.php on line 631'
File
'/home/davidlfr/public_html/sources/failure.php'
Line
'217'
Function
'fatal_exit'
Args
'PHP WARNING [2] preg_match() expects parameter 2 to be string, object given in sources/urls.php on line 631'
File
'/home/davidlfr/public_html/sources/global2.php'
Line
'857'
Function
'_ocportal_error_handler'
Args
'warning'
2
'preg_match() expects parameter 2 to be string, object given'
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
It sounds like you've set another catalogue to be an eCommerce catalogue, but the fields don't quite match the specification needed. I'd advise just using the bundled 'products' catalogue which is provided for this.
This is a bug, it shouldn't be stack-tracing, but you'd still need to match up the fields. which is a bit of a pain to do.
If not, please let us know how we can do better (please make suggestions that are economically viable and scalable, not just requests to do more for free).
If so, please let others know about ocPortal whenever you see the opportunity.
This information has not loaded yet. It will be generated in the background, please come back later.
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
Yes I created a separate catalogue more suited to my need, so OK your answer is helping me in my decision making process about ocPortal ecommerce. Thanks again Chris!
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
OK so I used the ecommerce 'product' catalogue as it is but I still get an error message as shown below:
Error Code
PHP WARNING [2] preg_match() expects parameter 2 to be string, object given in sources/urls.php on line 631 (version: 8.1.1, PHP version: 5.2.17, URL: /site/index.php?page=shopping&type=misc&redirected=1)
Here is the stack trace:
Below is a stack trace revealing the state the software was in when the error occurred. If this represents a bug in the unmodified software, you may want to check ocPortal website for a fix, and if there isn't one, report this as a bug. Please note that merely posting a stack trace is not sufficient for us to solve your problem; the stack trace is just an aid that presents us with additional information. We still need to know the error message, what you tried to do, how you tried to do it, version numbers, and any other appropriate information.
We apologise for this problem and if it's a bug we hope you will work with us so that we can fix it for you promptly.
File
'/home/davidlfr/public_html/sources/failure.php'
Line
'684'
Function
'get_html_trace'
Args
File
'/home/davidlfr/public_html/sources/global2.php'
Line
'983'
Function
'_fatal_exit'
Args
'PHP WARNING [2] preg_match() expects parameter 2 to be string, object given in sources/urls.php on line 631'
File
'/home/davidlfr/public_html/sources/failure.php'
Line
'217'
Function
'fatal_exit'
Args
'PHP WARNING [2] preg_match() expects parameter 2 to be string, object given in sources/urls.php on line 631'
File
'/home/davidlfr/public_html/sources/global2.php'
Line
'857'
Function
'_ocportal_error_handler'
Args
'warning'
2
'preg_match() expects parameter 2 to be string, object given'
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
I worked around this error in 8.1.2, using the following file:
However I suspect its only needed if the default picture field's field type has been changed, or the field order changed, which would cause other problems.
If not, please let us know how we can do better (please make suggestions that are economically viable and scalable, not just requests to do more for free).
If so, please let others know about ocPortal whenever you see the opportunity.
This information has not loaded yet. It will be generated in the background, please come back later.
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
This fixed it enough to allow me to get to the next step but I get an error when I try to update or empty the cart. I see I am running 8.1.1. I am upgrading now to 8.1.2 now - I will check it out and see it it is 'all better' after the upgrade.
Thanks Chris.
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
I upgraded from 8.1.1 to 8.1.2 and am still getting the error when I try to empty or update the shopping cart. Here is the stack trace:
Stack Trace
PHP NOTICE [8] Object of class ocp_tempcode could not be converted to int in sources/hooks/systems/ecommerce/catalogue_items.php on line 167 (version: 8.1.2, PHP version: 5.2.17, URL: /site/index.php?page=shopping&type=update_cart)
Here is the stack trace:
Below is a stack trace revealing the state the software was in when the error occurred. If this represents a bug in the unmodified software, you may want to check ocPortal website for a fix, and if there isn't one, report this as a bug. Please note that merely posting a stack trace is not sufficient for us to solve your problem; the stack trace is just an aid that presents us with additional information. We still need to know the error message, what you tried to do, how you tried to do it, version numbers, and any other appropriate information.
We apologise for this problem and if it's a bug we hope you will work with us so that we can fix it for you promptly.
File
'/home/davidlfr/public_html/sources/failure.php'
Line
'698'
Function
'get_html_trace'
Args
File
'/home/davidlfr/public_html/sources/global2.php'
Line
'985'
Function
'_fatal_exit'
Args
'PHP NOTICE [8] Object of class ocp_tempcode could not be converted to int in sources/hooks/systems/ecommerce/catalogue_items.php on line 167'
File
'/home/davidlfr/public_html/sources/failure.php'
Line
'218'
Function
'fatal_exit'
Args
'PHP NOTICE [8] Object of class ocp_tempcode could not be converted to int in sources/hooks/systems/ecommerce/catalogue_items.php on line 167'
File
'/home/davidlfr/public_html/sources/global2.php'
Line
'859'
Function
'_ocportal_error_handler'
Args
'notice'
8
'Object of class ocp_tempcode could not be converted to int'
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
Again it looks like the main product fields have been altered or reordered.
I've attached a screenshot of the defaults.
The 4th field must be an integer field, and represents the stock level. If deleted/reordered/type-changed, then ocPortal will have errors trying to read it.
If not, please let us know how we can do better (please make suggestions that are economically viable and scalable, not just requests to do more for free).
If so, please let others know about ocPortal whenever you see the opportunity.
This information has not loaded yet. It will be generated in the background, please come back later.
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
This should suppress the errors, and provide some level of tolerance, but the wrong fields will still end up getting used for things, so its still important to get the order right.
If not, please let us know how we can do better (please make suggestions that are economically viable and scalable, not just requests to do more for free).
If so, please let others know about ocPortal whenever you see the opportunity.
This information has not loaded yet. It will be generated in the background, please come back later.
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
All Areas you are showing in the .png image are identical to what I have except as I noted here:
All the sorts had been set to no - so I changed it back to default position - STILL GET ERROR
PRODUCT CODE was changed to: A Codename (Short sequence of numbers and letters, no spaces) I changed it back to DEFAULT - STILL GET ERROR
PRODUCT TAX RATE Modified Default values (I believe this is an acceptable modification)
All other settings are the same as the .png image you provided.
A query that had to return something returned nothing: SELECT c_name FROM ocp5_catalogue_entries WHERE (id=5) (version: 8.1.2, PHP version: 5.2.17, URL: /site/index.php?page=shopping&type=misc)
Here is the stack trace:
Below is a stack trace revealing the state the software was in when the error occurred. If this represents a bug in the unmodified software, you may want to check ocPortal website for a fix, and if there isn't one, report this as a bug. Please note that merely posting a stack trace is not sufficient for us to solve your problem; the stack trace is just an aid that presents us with additional information. We still need to know the error message, what you tried to do, how you tried to do it, version numbers, and any other appropriate information.
We apologise for this problem and if it's a bug we hope you will work with us so that we can fix it for you promptly.
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
Based on your reply above, it looks like you did nothing wrong. Maybe v8 changed the catalogue API enough to through off the cart system. The eCommerce isn't widely used, so probably nobody was using it on v8 yet. So, sorry for the messing about there.
The above stack trace looks to be a different issue. I suspect you added something to your cart, then delete that entry - but it's still in the cart. I've just fixed that (it shouldn't let you delete something already in a cart), but you'll need to empty the contents of your shopping_cart table manually.
If not, please let us know how we can do better (please make suggestions that are economically viable and scalable, not just requests to do more for free).
If so, please let others know about ocPortal whenever you see the opportunity.
This information has not loaded yet. It will be generated in the background, please come back later.
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
Based on your reply above, it looks like you did nothing wrong. Maybe v8 changed the catalogue API enough to through off the cart system. The eCommerce isn't widely used, so probably nobody was using it on v8 yet. So, sorry for the messing about there.
The above stack trace looks to be a different issue. I suspect you added something to your cart, then delete that entry - but it's still in the cart. I've just fixed that (it shouldn't let you delete something already in a cart), but you'll need to empty the contents of your shopping_cart table manually.
Chris, how would I empty the contents of your shopping_cart table manually?
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
If not, please let us know how we can do better (please make suggestions that are economically viable and scalable, not just requests to do more for free).
If so, please let others know about ocPortal whenever you see the opportunity.
This information has not loaded yet. It will be generated in the background, please come back later.
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
OK that cleared the cart and it is empty now. I will continue to explore ecommerce here and hopefully that it is all good. Thanks Chris!!
I just tried the check out and it took me to PayPal! I'll have to get a sandbox to play in and check it out further!!
Art and Imagination
of David L Friend http://davidlfriend.com My Art Gallery powered by ocPortal
Prehistorics Illustrated http://prehistoricsillustrated.com Another ocPortal powered website &
The Fascinating World of Dinosaurs & Prehistoric Creatures of all Kinds
If not, please let us know how we can do better (please make suggestions that are economically viable and scalable, not just requests to do more for free).
If so, please let others know about ocPortal whenever you see the opportunity.
This information has not loaded yet. It will be generated in the background, please come back later.
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
1 guests and 0 members have just viewed this: None