Page 1 of 1
form conditions and calculations
Posted: Fri Dec 09, 2022 10:27 am
by karolina
hello
my name is Karolina and I am not expert developer. I have small familly beakeeping and want to make web site and web shop. I have problems with calculations my items. On pictures is shown what i am using. I have two items to choose in combobox and edit box with quantity and editbox total.In editbox, conditions I am using code :
[item1]*[quantity]+[item2]*[quantity]
problem is with this code, in total I have calculation for both items, but what if costumer dont want to buy both items but only one and why on click item there is not shown only price in total?
sorry for bad english
![Image]()
sorry i dont know how to add image
Re: form conditions and calculations
Posted: Fri Dec 09, 2022 10:29 am
by Pablo
To be able to help you, I need a DEMO project (.wbs file) so I can see all your settings.
I do not need the complete project because that will only take more time to figure out what you have done.
Basically, I just need a small project with one page and object(s) that are relevant to your question.
For further details about how to share a project file, please see this FAQ:
https://www.wysiwygwebbuilder.com/forum ... 10&t=82134
Re: form conditions and calculations
Posted: Wed Dec 14, 2022 10:56 am
by karolina
Poštovani
I uploaded my testing web on public.html folder on 14.12. I hope it will work
My problem is in adding to shopping cart. I have two combobox and want to have option for costumers to choose from both combobox or just one combobox before adding to cart. Olso I would like for my costumers to see the price in editbox before adding to a cart.
https://nox.xhosting.biz:2083/cpsess076 ... ublic_html
Re: form conditions and calculations
Posted: Wed Dec 14, 2022 1:11 pm
by Pablo
I cannot access your website via the specified URL.
To be able to help you, I need a DEMO project (.wbs file) so I can see all your settings.
I do not need the complete project because that will only take more time to figure out what you have done.
Basically, I just need a small project with one page and object(s) that are relevant to your question.
For further details about how to share a project file, please see this FAQ:
viewtopic.php?f=10&t=82134
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 10:40 am
by karolina
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 11:09 am
by Pablo
In the condition, you are referring to objects that do not exist on the page.
cpuCvjetni
cpu2Cvjetni
Also, there may be an issue with the IDs of some object. For example: tekući2Kesten
Please use ASCII character only:
viewtopic.php?t=64868
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 12:00 pm
by karolina
Sorry, I did change ID and forgot to put replacement, I did that now and stil need help
https://www.dropbox.com/s/xb8m1jdul88j0 ... g.wbs?dl=0
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 12:32 pm
by Pablo
Can't you add an extra 'none; it to the list with value '0'?
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 12:48 pm
by karolina
I didnt solve my problem with editbox its not working
my paypalbutton add to cart is not adding anything to cart
https://www.dropbox.com/s/xb8m1jdul88j0 ... g.wbs?dl=0
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 1:29 pm
by Pablo
What exactly did you expect to happen?
Where did you link the price field to the paypal button?
Tip: if you want to try something new, then keep it simple. Do not try to do multiple things at the same time.
See also:
viewtopic.php?f=10&t=82134
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 1:39 pm
by karolina
I know first need to solve my editbox to show prices then that price needs to go to paypal but I dont know how to do that
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 2:23 pm
by Pablo
The name property of the editbox should be 'amount'
Then in PayPal button options -> Option 1 -> totalCvjetni
Remove the option 2.
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 2:43 pm
by karolina
THANKS for paypal button but my editbox is still not working it doesnt show any number
https://www.dropbox.com/s/kx7at0ysp72ig ... g.wbs?dl=0
Re: form conditions and calculations
Posted: Thu Dec 15, 2022 3:23 pm
by Pablo
Now there is an error in the condition of the other PayPal button
Code: Select all
Number([kristalKesten])).toFixed(2)
Please do one thing at a time.
Re: form conditions and calculations
Posted: Fri Dec 16, 2022 7:40 pm
by karolina
hello
I have manage to solve my problems with editbox and add to cart button, thanks
I share my work so you can check, I am not sure what can you see but there is an issue with wwb18.Yesterday when I made preview everything was ok, but today I didnt change anything and on preview there are missing some items even they are checked visible
https://www.dropbox.com/t/IcZWJz9nqr28Tsc3
https://www.dropbox.com/t/A78hOxPssIT2m7ef
Re: form conditions and calculations
Posted: Fri Dec 16, 2022 9:15 pm
by Pablo
The problem is related to the way you have configured the elements.
- ad PayPal button is a form
- You also have configured the layer as form. So, you have nested multiple forms. This is not allowed in HTML. This breaks the structure of the page.
Again , please do not try to do multiple things at the same time otherwise you end up breaking things that previously were correct.
Re: form conditions and calculations
Posted: Sat Dec 17, 2022 9:54 pm
by karolina
THANK YOU for your help. I repaired mistakes and everything is ok now.
I do need your help. I am using a paypal button add to cart, and if I put in original form shipping price example 6€ problem is that goes for every item in my cart so if costumer add in cart 4 items then he will have to pay 4 shippings. How to charge 1 shipping per order not for each item?
https://www.dropbox.com/t/DQeIkAwdiDURPVO4
Re: form conditions and calculations
Posted: Sun Dec 18, 2022 8:18 am
by Pablo
Sorry, that is not possible when using the cart this way. If you need a flat shipping fee then you will have to configure this is the PayPal account.