RESOLVED Custom Skin site, problem with alignment....

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
14 лет назад
http://www.wholesalemilitary.net

As you can see on the site, I am trying to put the mini shopping cart, facebook, and the newsletter subscription in the same headermenu spot. However for some reason I can get the mini shopping cart and facebook to align in the container however the newsletter is offset sitting below. I have tried everything for the past several hours with no luck. Any help would be appreciated.

Headermenu.ascx

<%@ Control Language="C#" AutoEventWireup="true" Inherits="NopSolutions.NopCommerce.Web.Modules.HeaderMenuControl"
    CodeBehind="HeaderMenu.ascx.cs" %>
<%@ Register TagPrefix="nopCommerce" TagName="SearchBox" Src="~/Modules/SearchBox.ascx" %>
<%@ Register TagPrefix="nopCommerce" TagName="CategoryNavigation" Src="~/Modules/CategoryNavigation.ascx" %>
<%@ Register TagPrefix="nopCommerce" TagName="MiniShoppingCartBox" Src="~/Modules/MiniShoppingCartBox.ascx" %>
<%@ Register TagPrefix="nopCommerce" TagName="NewsLetterSubscriptionBoxControl" Src="~/Modules/NewsLetterSubscriptionBoxControl.ascx" %>
<div class="headermenu">
    <div class="searchbox">
        <nopCommerce:SearchBox runat="server" ID="ctrlSearchBox" style="background-image:url(../App_Themes/BK%20Industries/images/Searchbox.gif)">
        </nopCommerce:SearchBox>
    </div>
    <ul>
        <li><a href="<%=CommonHelper.GetStoreLocation()%>">
            <%=GetLocaleResourceString("Content.HomePage")%></a> </li>
        <% if (ProductManager.RecentlyAddedProductsEnabled)
           { %>
        <li><a href="<%=Page.ResolveUrl("~/RecentlyAddedProducts.aspx")%>">
            <%=GetLocaleResourceString("Products.NewProducts")%></a> </li>
        <%} %>
        <li><a href="<%=Page.ResolveUrl("~/Search.aspx")%>">
            <%=GetLocaleResourceString("Search.Search")%></a> </li>
        <li><a href="<%=Page.ResolveUrl("~/Account.aspx")%>">
            <%=GetLocaleResourceString("Account.MyAccount")%></a> </li>
        <% if (BlogManager.BlogEnabled)
           { %>
        <li><a href="<%=Page.ResolveUrl("~/Blog.aspx")%>">
            <%=GetLocaleResourceString("Blog.Blog")%></a> </li>
        <%} %>
        <% if (ForumManager.ForumsEnabled)
           { %>
        <li><a href="<%= SEOHelper.GetForumMainURL()%> ">
            <%=GetLocaleResourceString("Forum.Forums")%></a></li>
        <%} %>
        <li><a href="<%=Page.ResolveUrl("~/ContactUs.aspx")%>">
            <%=GetLocaleResourceString("ContactUs.ContactUs")%></a> </li>
    </ul></div>
        <div class="Headercategory">
            <nopCommerce:CategoryNavigation ID="ctrlCategoryNavigation" runat="server" />
            </div>
            <div class="Headercartnews">
              <div class="Headercartnews-shoppingcart">
               <nopCommerce:MiniShoppingCartBox ID="ctrlMiniShoppingCartBox" runat="server" />
              </div>
                <div>
            <script type="text/javascript" src="http://static.ak.connect.facebook.com/connect.php/en_US"></script>
      <script type="text/javascript">FB.init("83a06d379ef1b764c96675a4b19767cf");</script>
            <fb:fan profile_id="232992492803" stream="0" connections="0" logobar="1" width="280"></fb:fan>
            </div>
            <div class="Headercartnews-newsletter">
            <nopCommerce:NewsLetterSubscriptionBoxControl runat="server" />
            </div>
            </div>

Style.ascx (just the headercartnews section)


.Headercartnews
{
    font-size: 0.9em;
  font-weight: bold;
  text-transform: uppercase;
  color: #000;
  height: 100%;
  background-color: #fcf000;
  background-image: url(images/topleftcorner.gif), url(images/toprightcorner.gif), url(images/bottomleftcorner.gif), url(images/bottomrightcorner.gif);
  background-position: left top, right top, left bottom, right bottom;
  background-repeat:no-repeat;
  padding: 5px 5px 5px 5px;
  text-align: Left;
  vertical-align: middle;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.Headercartnews a
{
  color: #000;
  font-size: 0.9em;
  font-weight: bold;
  text-transform: uppercase 0.9em;
  padding-left: 5px;
  padding-right: 5px;
  vertical-align: middle;
}

.Headercartnews ul
{
  padding: 0;
  margin: 0;
}

.Headercartnews li
{
  list-style: none;
  display: inline;
  border-right:1px solid #000;
}

.Headercartnews-shoppingcart
{
    font-size: 0.9em;
  font-weight: bold;
  text-transform: uppercase;
  color: #000;
  padding: 5px 5px 5px 5px;
  text-align: Left;
  vertical-align: middle;
  letter-spacing: 1px;
  float:left
}

.Headercartnews-newsletter
{
    font-size: 0.9em;
  font-weight: bold;
  text-transform: uppercase;
  color: #000;
  padding: 5px 5px 5px 5px;
  text-align: Left;
  vertical-align: middle;
  letter-spacing: 1px;
  float:right
}
14 лет назад
I know it might have something to do with the float: command in the style sheet. If I eliminate the float:right on the newsletter than it is put back into the box but it places it below the shopping cart and not to the right. So what can I do to ensure its put to the right of facbook?
14 лет назад
Alright I got it figured out. I simply switched the newsletter location in the headermenu.ascx to before the facebook and it straightened out.... dum

<div class="Headercartnews">
              <div class="Headercartnews-shoppingcart">
               <nopCommerce:MiniShoppingCartBox ID="ctrlMiniShoppingCartBox" runat="server" />
              </div>
                            <div class="Headercartnews-newsletter">
            <nopCommerce:NewsLetterSubscriptionBoxControl runat="server" />
            </div>
                <div class="Headercartnews-facebook">
            <script type="text/javascript" src="http://static.ak.connect.facebook.com/connect.php/en_US"></script>
      <script type="text/javascript">FB.init("83a06d379ef1b764c96675a4b19767cf");</script>
            <fb:fan profile_id="232992492803" stream="0" connections="0" logobar="1" width="280"></fb:fan>
            </div>

            </div>
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.