The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Can I change the font style of of an existing page with css?
johnminkough
post Feb 26 2012, 06:43 PM
Post #1


Newbie
*

Group: Members
Posts: 17
Joined: 6-December 11
Member No.: 16,008



Hi

I'm a css novice.

I have 40 or so html pages that look like this:

http://johnminkoff.com/forward.html

They all use the Abadi font. I want to change them all to the Courier font.

If I understand how this works, I should be able to create a stylesheet which will specify a different font,
and if the page head section has code linking it to that stylesheet, the desired font will be displayed on the page.

So far my efforts to accomplish this haven't worked out.

Right now the word
'Abadi" occurs countless times in the code. Changing all that manually in 40 pages is not sounding appealing.

Am I on the right track here? Any tips on coding?

Thanks.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Darin McGrew
post Feb 26 2012, 07:53 PM
Post #2


WDG Member
********

Group: Root Admin
Posts: 8,365
Joined: 4-August 06
From: Mountain View, CA
Member No.: 3



QUOTE
Am I on the right track here? Any tips on coding?
Yes, it sounds like you're on track.

Yes, you've scattered <span style="..."> tags all over your markup. Yes, you're going to need to change all that markup on all your pages.

Whether you need to change all that markup on all your pages manually depends on the tools you use. Some editors include tools to make the same changes in multiple places, in multiple files. Some scripting languages can be used to make such changes automatically too.

Whether you make the changes manually or automatically, the key is to do what you can so you don't need make similar changes again if possible. Convert the pages to structural markup, with all the style specified in shared, linked style sheets.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
johnminkough
post Feb 26 2012, 11:11 PM
Post #3


Newbie
*

Group: Members
Posts: 17
Joined: 6-December 11
Member No.: 16,008



Thanks. Someone reminded me of the old "find-and-replace" technique. Seems like a manageable solution for
the time being.

Do plan to build future pages on more sound principles.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Frederiek
post Feb 27 2012, 02:26 AM
Post #4


Programming Fanatic
********

Group: Members
Posts: 5,146
Joined: 23-August 06
From: Europe
Member No.: 9



QUOTE
Someone reminded me of the old "find-and-replace" technique. Seems like a manageable solution for
the time being.

Indeed, and it would even be a better solution, if your editor can use that technique on multiple files at once (batch find-replace).
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Feb 27 2012, 10:07 AM
Post #5


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,730
Joined: 9-August 06
Member No.: 6



Actually, it wouldn't be much more work to remove those attributes (and sometimes the tags they are used with) and replace them with classes and IDs so you can use an external style sheet. But if you plan to rewrite the whole site I don't know if I would bother with either. Better start with the rewrite.

P.S. Courier is extremely hard to read on screen, me thinks.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
2 User(s) are reading this topic (2 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 24th April 2024 - 01:26 PM