Sliding PayPal Shopping Cart Support Product Page

Answered

Website aligned center

Asked 07 Apr 2013 06:41:56
1
has this question
07 Apr 2013 06:41:56 Alex Crousset posted:
Width website aligned center the paypal box will always align to the body even if i set it to a parent element which is with 900px of width and margin 0px auto; (center)

dev.millettephotosdeplantes.com/25_les_hostas_reussir_la_culture_selon_les_especes.html#

Replies

Replied 08 Apr 2013 07:34:43
08 Apr 2013 07:34:43 Vulcho Vulev replied:
Hello Alex.

Our cart is constructed to always overlay the containers in order to make sure that is visible to the client.
You can add a little bit positioning to fit to your page layout opening the following file :

dev.millettephotosdeplantes.com/Styles/dmxSlidingCart/light-default/light-default.css

find the following rule:

#dmxSPSCart form {
border: 1px solid #ccc !important;
  border: 1px solid rgba(0, 0, 0, 0.2) !important;
  -webkit-box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
     -moz-box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
          box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
border-top:none !important;
}


Add property for margin:

#dmxSPSCart form {
border: 1px solid #ccc !important;
  border: 1px solid rgba(0, 0, 0, 0.2) !important;
  -webkit-box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
     -moz-box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
          box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
border-top:none !important;
margin-right: 90px !important;
}


Regards:Vulcho.
Replied 08 Apr 2013 08:47:10
08 Apr 2013 08:47:10 Alex Crousset replied:
Unfortunately it did not solve the problem for me and i tried some other things 2.

Position relative seems to work but it screw up all what is inside the form.

Is it suppose to stay fixed (x axis) depending of the width of the browser when you put it parent to an element that is centre?

Like in my layout.
Replied 08 Apr 2013 09:12:17
08 Apr 2013 09:12:17 Miroslav Zografski replied:
Hello Alex,

It is all about positioning. The real container of the cart is a div with id dmxSPSCart. When you set it as a child of an element that div is set in that element but the form is rendered with fixed positioning. You need to make the dmxSPSCart div have position relative also the parent element need to have a relative or any other positioning and the Form that is inside the dmxSPSCart position need to be set to absolute. Also some adjustments will need to be made in the top position of the form because once fixed position is changed to absolute for the form the top will be calculated relatively to the parent.

The x will stay fixed to the parent element. Since your parent element width does not change the x position of the form will not change as well.

Regards.
Replied 08 Apr 2013 09:22:55
08 Apr 2013 09:22:55 Alex Crousset replied:
It works!

Thx guys for the tips!

@lex

Reply to this topic