HTML Tutorial


 /help/HTML Help Forum   FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
RegisterRegister - Not registered yet? Got something to say? Join HTML Code Tutorial!
HTML Span
Post new topic   Reply to topic    HTML Help Forum -> General HTML
View previous topic :: View next topic  
Author Message
leelee23



Joined: 24 Oct 2009
Posts: 2

PostPosted: Sat Oct 24, 2009 9:36 am     HTML Span Reply with quote

Hi everyone,

Been stuck on this problem for some time now! I'm wondering why the below isn't working:

Code:
<a href="http://www.blabla.com/catalog/shopping_cart.php" <span class= "headerlinks">Shopping Cart:</span> <span class= "headercheckoutitems">1&nbsp;Item&nbsp;(£64.95)</span>  </a> &nbsp;|&nbsp;


whereas the below works fine:

Code:
<a href="http://www.blabla.co.uk/catalog/account.php" class="headerlinks">My Account</a> &nbsp;|&nbsp;


I'm assuming this is due to the span code in the first example, but after having looked around I can't seem to find out what is wrong with this!

Any help would be much appreciated!!!

Thanks!
sticks464



Joined: 31 Dec 2006
Posts: 2625

PostPosted: Sat Oct 24, 2009 12:41 pm     Reply with quote

What exactly are you trying to accomplish with the span tag?
leelee23



Joined: 24 Oct 2009
Posts: 2

PostPosted: Sat Oct 24, 2009 1:07 pm     Reply with quote

I wanted the first part of the text within the link to be bold and the second not to be (but the other font attributes that were listed in the css file to be the same) hence the two different classes within the statement.

Hopefully aiming for something like this:

e.g. Shopping Cart: 1 Item
sticks464



Joined: 31 Dec 2006
Posts: 2625

PostPosted: Sat Oct 24, 2009 3:00 pm     Reply with quote

In you stylesheet there should be a style rule for "headerlinks" that is written something like
Code:
a.headerlinks {...}


To get what you want...

Code:
<a href="http://www.blabla.com/catalog/shopping_cart.php" class="headerlinks"> <span>Shopping Cart:</span> 1&nbsp;Item&nbsp;(£64.95)</a> &nbsp;|&nbsp;

You will have to write a rule for the span;
css
Code:
a.headerlinks {
   color:#000;
   text-decoration:none;
}
a.headerlinks span{
   font-weight:bold;
}


For any link with the class="headerlinks" just put a span tag around the text you want to be bold.
Labhrainn Aemilianus



Joined: 06 Nov 2009
Posts: 2

PostPosted: Sat Nov 07, 2009 12:45 am     HTML Span Reply with quote

if the span you are talking about is a table column span or a span tag. If the span tags are used and you do not want the effects then delete the open and close span tags. If it is a column span then you will need to remove the column span and add enough additional td tags to make up the difference.
Display posts from previous:   
Post new topic   Reply to topic    HTML Help Forum -> General HTML All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
HTML Help Archive
Powered by phpBB © 2001, 2005 phpBB Group
HTML Help topic RSS feed 

 
DARFUR
HOSTING / DESIGN
MAKE MONEY

Home
  |   Tutorials   |   Forum   |   Quick List   |   Link Directory   |   About
Copyright ©1997-2002 Idocs and ©2002-2007 HTML Code Tutorial