Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5982165
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T22:02:52+00:00 2026-05-22T22:02:52+00:00

I just completed an MVC tutorial , but some of my webpages don’t look

  • 0

I just completed an MVC tutorial, but some of my webpages don’t look right. This is mine: Screenshot of my webpage

But it’s supposed to look like this:enter image description here

The code for this page is:

@model MvcSuper.Models.MusicStore.Genre

@{ 
    ViewBag.Title = "Browse Albums"; 
} 

<div class="genre"> 
    <h3><em>@Model.Name</em> Albums</h3> 

    <ul id="album-list"> 
        @foreach (var album in Model.Albums) 
        { 
            <li> 
                <a href="@Url.Action("Details",  
                    new { id = album.AlbumId })"> 
                    <img alt="@album.Title"  
                        src="@album.AlbumArtUrl" /> 
                    <span>@album.Title</span> 
                </a> 
            </li> 
        } 
    </ul> 
</div>

The left menu (partial view):

@model IEnumerable<MvcSuper.Models.MusicStore.Genre>
<ul id="categories"> 
    @foreach (var genre in Model) 
    { 
        <li>@Html.ActionLink(genre.Name, 
                "Browse", "MusicStore",  
                new { Genre = genre.Name }, null) 
        </li> 
    } 
</ul>

Entire CSS:

{
    margin: 0px;
    padding: 0px;
    border: none;
}

body
{
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    background-color: #FBF9EF;
    padding: 0px 6%;
}

#container
{
    float: left;
}

#header
{
    float: left;
    width: 100%;
    border-bottom: 1px dotted #5D5A53;
    margin-bottom: 10px;
}

#header h1
{
    font-size: 18px;
    float: left;
    background: url(/content/Images/logo.png) no-repeat;
    padding: 45px 0px 5px 0px;
}

#promotion
{
    height: 300px; 
    width: 700px; 
    background: url(/content/Images/home-showcase.png) no-repeat;
}

ul li a
{
    font-size: 16px;
}

#main
{
    overflow: hidden;
    padding: 0 0 15px 10px;
    float: left;
}

ul
{
    list-style-type: square;
    margin-left: 25px;
    font-size: 14px;
}

ul#album-list
{
    list-style: none;
    margin-left: 0px;
}

ul#album-list li
{
    height: 130px;
    width: 100px;
    float: left;
    margin: 10px;
    text-align: center;
}

ul#album-list li a, ul#album-list li .button
{
    font-size: 13px;
    float: left;
}

ul#album-list li a span
{
    color: #9b9993;
    text-decoration: underline;
}

#cart
{
    float: right;
}

#update-message
{
    color: #F6855E;
    font-weight: bold;
}

.button, input[type=submit]
{
    clear: both;
    display: inline-block;
    padding: 5px;
    margin-top: 10px; 
    border: 1px;
    background: #5e5b54;
    color: #fff;
    font-weight: bold;
}

.button a
{
    color: #fff !important;
}

#footer
{
    clear: both;
    padding: 10px;
    text-align: right;
    border-top: 1px dotted #8A8575;
    border-bottom: 1px dotted #8A8575;
    font-family: Constantia, Georgia, serif;
}

/******************** Top Navigation ************************/
ul#navlist
{
    float: right;
}

ul#navlist li
{
    display: inline;
}

ul#navlist li a
{
    border-left: 1px dotted #8A8575;
    padding: 10px;
    margin-top: 10px;
    color: #8A8575;
    text-decoration: none;
    float: left;
}

ul#navlist li:first-child a
{
    border: none;
}

ul#navlist li a:hover
{
    color: #F6855E;
}

/********************* End top navigation ***************************/

p
{
    margin-bottom: 15px;
    margin-top: 0px;
}

h2
{
    color: #5e5b54;
}

h2, h3
{
    margin-bottom: 10px;
    font-size: 16px;
    font-style: italic;
    font-weight: bold;
}

h3
{
    color: #9B9993;
}

#header h1 a, h3 em
{
    color: #5E5B54;
}

a:link, a:visited
{
    color: #F6855E;
    text-decoration: none;
    font-weight: bold;
}

a:hover
{
    color: #333333;
    text-decoration: none;
    font-weight: bold;
}

a:active
{
    color: #006633;
    text-decoration: none;
    font-weight: bold;
}

/***************************** sidebar navigation ****************************/

#categories
{
    font-family: Constantia, Georgia, serif;
    list-style-type: none;
    border-right: #5d5a53 1px dotted;
    padding-right: 10px;
    margin: 0 25px 0 0;
    float: left;
}

#categories a:link, #categories a:visited
{
    color: #9B9993;
    text-decoration: none;
}

#categories a:hover
{
    color: #F46739;
}

div#album-details p
{
    margin-bottom: 5px;
    color: #5e5b54;
    font-weight: bold;
}

p em
{
    color: #9b9993;
}

/* Form styles */
legend
{
    padding: 10px;
    font-weight: bold;
}

fieldset
{
    border: #9b9993 1px solid;
    padding: 0 10px;
    margin-bottom: 10px;
    clear: left;
}

div.editor-field
{
    margin-bottom: 10px;
}

input[type=text], input[type=password], select
{
    border: 1px solid #8A8575;
    width: 300px;
}

/* Styles for validation helpers */
.field-validation-error {
    color: #ff0000;
}

.field-validation-valid {
    display: none;
}

.input-validation-error {
    border: 1px solid #ff0000;
    background-color: #ffeeee;
}

.validation-summary-errors {
    font-weight: bold;
    color: #ff0000;
}

.validation-summary-valid {
    display: none;
}

/* Tables */
table
{
    border: 1px solid #000;
    border-collapse: collapse;
    color: #666666;
    min-width: 500px;
    width: 100%;
}

tr
{
    border: 1px solid #000;
    line-height: 25px;
}

th
{
    background-color: #9b9993;
    color: #000;
    font-size: 13px;
    text-align: left;
}

th, td
{
    padding-left: 5px;
}

tr:hover
{
    background-color: #fff;
}

I did download the source code (the author’s finished version), and it turned out like mine when I ran it. The top most screenshot is from FF4 on XP, but it looks the same in IE8 on XP. Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T22:02:53+00:00Added an answer on May 22, 2026 at 10:02 pm

    To push that Album listing back up to its rightful place and put your mind at ease…

    add a width to your main css class:

    #main
    {
        overflow: hidden;
        padding: 0 0 15px 10px;
        float: left;
        width: 500px;
    }
    

    also add a * to first css class

    *{
        margin: 0px;
        padding: 0px;
        border: none;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I just completed the ios tutorial, and while I can manipulate a single screen
i just completed a web based chat application based on ajax/php. But the problem
We have just completed implementing a successful but problematic project. We want to get
Not that level of failure indeed. I just completed the 4 part tutorial from
I am new in this community. I just completed my Btech in Computer science,
I'm using ASP.NET, but I'm sure this pertains to any (or most) MVC frameworks.
I'm just starting to learn ASP.NET MVC and I'd like to know how I
i just started to learn struts(+spring) MVC, and I could use some explanation of
I've just completed an automation script that: downloads a project build to local storage
I have just completed an application for my final year project and I need

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.