-1

Comparing my localhost and my live websites show differently styled asp:LinkButtons.

I would like it to appear like the localhost example, but I am not sure what I am doing wrong.

I have attached the code and the images below.

HTML

<div class="green">
    <asp:LinkButton CssClass="linkbutton" ID="loginLinkButton"
    OnClick="loginLinkButton_Click" runat="server" Text="Go" />
</div>

CSS

.green
{
    background-color: #6FBD45;
    border: 1px solid #8CCA6A;
    color: #FFFFFF;
}
.linkbutton
{
    font-family: "Segoe UI" , "Helvetica Neue" , Helvetica, "Myriad Pro" , Myriad, Tahoma, Arial, sans-serif;
    font-size: 16px;
    color: #FFFFFF !important;
    line-height: 26px;
    padding-left: 6px;
}

Localhost example

Nice pretty localhost green icon :)

Live example

Sad frowny face live example :(

Would the published version be stripping something important from the code? Or am I missing something basic here?

Using Firefox 21.0

eggy
  • 2,836
  • 3
  • 23
  • 37

2 Answers2

0

Sounds most likely to be a browser caching issue. Have you tried ctrl-F5? Or clearing the cache?

ptutt
  • 1,338
  • 3
  • 18
  • 35
0

Perhaps the live website is importing some CSS that your localhost setup isn't. The most common reason for this is some relative path on the style tag.

Are you using any Visual Studio templates on your website?

It would help if you could you post the content of the tag from both websites.

Another tip is to use Dev Tools on Chrome to find if your localhost setup is missing any css file. Press F12, go to the Network tab and see if you can find any 404 on the Status row. Firefox Web Console can give you this information too.

Renato Todorov
  • 560
  • 3
  • 15