Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

I need some help with table CSS please :-)

Featured Replies

I'm on mobile right now but if you haven't already learn to use chrome inspector tools or Firefox firebug. This is a tool you'll need to learn how to use in order to copy styles from one site to another

Hi. If I have understood your question correctly;

 

This is the HTML for the bottom table (formatting is peculiar, but this is probably the fault of the site):

<div class="cart-collaterals">
		<div class="cart_totals ">

	
	
		<h2>Cart Totals</h2>

		<table cellspacing="0">
			<tbody>

				<tr class="cart-subtotal">
					<th><strong>Cart Subtotal</strong></th>
					<td><strong><span class="amount">£790</span></strong></td>
				</tr>

				
				
				
				
				
				
				<tr class="total">
					<th><strong>Order Total</strong></th>
					<td>
						<strong><span class="amount">£790</span></strong>
											</td>
				</tr>

				
			</tbody>
		</table>

		
	
	
</div>	</div>

 

You'll find the CSS for .cart-collaterals and .cart_totals in this section here:

 

/*-------------------------------- Cart -------------------------------*/

table.cart {
	margin-bottom:2.5em;
}

table.cart .product-remove,
table.cart .product-thumbnail,
table.cart .product-price {
	position:static;
}

table.cart td.actions {
	text-align:right;
}

table.cart td.actions .coupon {
	float:left;
	width:50%;
}

table.cart td.actions .input-text,
table.cart td.actions .button,
table.cart td.actions .checkout-button {
	display:inline-block;
	margin-bottom:0 !important;
	width:auto !important;
}
.cart-collaterals:after {
	display:block;
	clear:both;
	overflow:hidden;
	height:0;
	content:" ";
}

.cart-collaterals .cross-sells,
.cart-collaterals .cart_totals,
.cart-collaterals .shipping_calculator {
	width:48%;
}

.cart-collaterals .cross-sells,
.cart-collaterals .cart_totals {
	float:right;
}

.cart-collaterals .shipping_calculator {
	float:left;
}

.cart-collaterals .cross-sells ul.products li.product {
	width:48%;
}

.cart .product-thumbnail .bordered-image {
	margin:0 auto;
	width:40px;
}

.cart td.product-subtotal,
.cart td.product-price {
	color:#777;
	font-weight:bold;
	font-size:1.1em;
}

.variations select,
.cart .product-quantity input {
	margin-bottom:0;
}

.cart .product-quantity input {
	width:40px;
}

.cart .product-name a {
	color:#333;
}

.cart .product-remove {
	text-align:center;
	font-size:1.5em;	
}

.cart .product-remove a {
	color:#555;	
	font-weight:bold;
}

.cart .button {
	margin-left:10px;
}

.my_account_orders .order-number,
.my_account_orders .order-actions {
	text-align:center;
}

.woocommerce-checkout .shop_table,
.woocommerce-checkout .payment-listing,
p.myaccount_user {
	margin-bottom:2em;
}

...and this section here:

 

.woocommerce-cart .woocommerce .button,
.woocommerce.widget .button,
.cart-collaterals .button,
.woocommerce-message .button,
.single_add_to_cart_button,
.add_to_cart_button,
.order-actions .button,
.button.show_review_form,
.product_type_variable {
	padding:0.2em 10px 0.2em 10px;
	line-height:1.8em;
}

 

If I am not mistaken, you appear to be migrating carts - and so, I would recommend slimming the necessary CSS down somewhat. You're probably doing this anyway. :p

Edited by jakdothtml

Have you made any changes to the styling of this as it looks like you are using a Woocommerce plugin.

 

As such could you not add the plugin to the new domain?

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.