Showing posts with label font size. Show all posts
Showing posts with label font size. Show all posts

Thursday, November 15, 2012

XML links or Xlink

In XML, tags are made up which makes XML links almost impossible. The solution to this is Xlink, which is a standard for XML links. To display links use a code like this;
<?xml version="1.0"?>

 <homepages xmlns:xlink="http://www.google.com">

<homepage xlink:type="simple"
 xlink:href="http://ddg.gg">Duck Duck Go</homepage>

<homepage xlink:type="simple"
 xlink:href="http://www.google.com">Google</homepage>

</homepages>


An easy example would be this;
<plantstore xmlns:xlink="http://www.w3.org/1999/xlink">
 <plant name="Petunia">
<description
xlink:type="simple"
  xlink:href="http://plants.com/images/petunia.png"
xlink:show="new">
  The familiar petunia at a bargain price.
</description>
</book>

</bookstore>


You can repeat the highlighted text as often as you like. 

Tuesday, October 30, 2012

Special Symbols ¢, ™, ® and others

Trademark, copyright, and other symbols may be displayed in webpages by way of simple HTML code. Here they are:

®      &reg;
¢       &cent; 
™      &trade;
¿       &iquest;
©      &copy;
÷      &divide;
§       &sect;
¥       &yen;
£       &pound;
€       &euro;
µ       &micro;
¶       &para;
±       &plusmn;
·        &middot;

How to display this chart with the codes:
</span>® &nbsp; &nbsp; &nbsp;&amp;reg;<br />
¢ &nbsp; &nbsp; &nbsp; &amp;cent;&nbsp; <br />
™ &nbsp; &nbsp; &nbsp;&amp;trade;<br />
¿ &nbsp; &nbsp; &nbsp; &amp;iquest;<br />
© &nbsp; &nbsp; &nbsp;&amp;copy;<br />
÷ &nbsp; &nbsp; &nbsp;&amp;divide;<br />
§ &nbsp; &nbsp; &nbsp; &amp;sect;<br />
¥ &nbsp; &nbsp; &nbsp; &amp;yen;<br />
£ &nbsp; &nbsp; &nbsp; &amp;pound;<br />
€ &nbsp; &nbsp; &nbsp; &amp;euro;<br />
µ &nbsp; &nbsp; &nbsp; &amp;micro;<br />
¶ &nbsp; &nbsp; &nbsp; &amp;para;<br />
± &nbsp; &nbsp; &nbsp; &amp;plusmn; <br />
· &nbsp; &nbsp; &nbsp; &nbsp;&amp;middot;<br />
&nbsp; <br />

Thursday, October 25, 2012

Links, part 3: Colors & CSS

In a previous post I explained the link. In this post I will go into how to change link colors, add hover effects and visited colors. The first will be changing the link colors by some basic HTML in the body. Insert this code between the <body> and </body> tags.
<body link="#C0C0C0" vlink="#808080" alink="#FF0000">
body link is when the link is displayed on the page. #COCOCO is the blue you see everywhere. vlink is the visited color. #808080 is the purple you see on most pages when you revisit a page after clicking a link. #FF0000 is red, and alink is the hover color. 

Link color in your CSS stylesheet

Its easy, and you can do even more, like making a link suddenly underline when hovered over. Here's the code:

a.nav:link {color: blue; text-decoration: none; }
a.nav:visited {color: purple; text-decoration: none; }
a.nav:hover {color: green; text-decoration: underline; }
a.nav:active {color: red; }

Multiple Link effects through CSS stylesheet
You can make "classes" of link effects in CSS that will make links in each class act differently. For example, you could make a class called nav for links in the body, and a class called foot for links in the footer. Here is the code: 
a.nav:link {color: blue; text-decoration: none; }
a.nav:visited {color: purple; text-decoration: none; }
a.nav:hover {color: green; text-decoration: underline; }
a.nav:active {color: red; }


a.foot:link {color: red; font-size: 14pt; font-weight: bold; }
a.foot:visited {color: green; font-weight: bold; }
a.foot:hover {text-decoration: underline; background-color: blue; }
a.foot:active {color: orange; }
Using the classes
It's much simpler than individually changing every link that you want different from the settings you put. 

For the class nav use this code: <a href="URL" class="nav">Link Text</a>

For the class foot use this code: <a href="URL" class="nav">Link Text</a>

Monday, October 22, 2012

CSS Stylesheets or Syncing Webpages Easily

Css was made to save time. If you have a site where you want all the background colors, links, text, link hover colors and stuff like that to be the same on all pages, CSS stylesheets are the quickest way to do that. In fact, CSS stands for Cascading Style Sheets. 
1. Open notepad or any plain-text editor. Enter this code: Highlighted text is for you to change.
h3
{
 color:black;
text-align:left;
font-size:8pt;
}


Now for the Background. Remember, multiple styles cascade into one style.

body {background-color:#FFFFFF;}

You could also use an image background. This is for positioning an image in the top right corner.:
body
{
 background-image:url('image_URL');
background-repeat:no-repeat;
back
ground-position:right top;
}


If you want the image to repeat the whole length of the page:
body
{
 background-image:url('image_URL.png');
background-repeat:repeat-x;
}


Save as "Stylesheet.css"
2.Adding the style sheet to webpages. Insert this code between the <head> AND </HEAD> tags. This is where the <TITLE> tag is. 

<link rel="stylesheet" type="text/css" href="stylesheet.css" />

Wednesday, September 26, 2012

HTML text

Html is an old programming code used quite often in webpages. This post is to show you how to write rich text in HTML. HTML is supported by all browsers. This does not include color, however. 
1. Fonts
Fonts are the way the text looks. the most common fonts and their code are:
Times New Roman: <span style="font-family: Times, Times New Roman, serif;">
Arial: <span style="font-family: Arial, Helvetica, sans-serif;">
Verdana: <span style="font-family: Verdana, sans-serif;">
Helvectica: <span style="font-family: Helvetica Neue, Arial, Helvetica, sans-serif;">
Georgia: <span style="font-family: Georgia, Times New Roman, serif;">
Courier New:<span style="font-family: Courier New, Courier, monospace;">
Trebuchet: <span style="font-family: Trebuchet MS, sans-serif;">
When you want a font to end and display the browser's defaut font, use this closing tag: </span> You can get many more fonts and their codes at the Google Web Fonts Directory'
2. Size
So how do you get your font size to change? Simple. The size tags. They are <h1></h1> <h2></h2> <h3></h3> <h4></h4> <h5></h5> <h6></h6> 
<h1> is the largest, and I do not know how far the fine print goes down. </h1> is the closing tag. 
3. Effects
The italics tag is <i>, while the closing tag is </i> example: This is Italics.
The bold tag is <b> with the closing tag of </b>
The underline tag is <u> while the closing tag is </u>
The strike through tag  is <strike> while the closing tag is </strike>
The Subscript  tag is <sub> and the closing tag is </sub>
The Superscript tag is <sup> while the closing tag is </sup>
<marquee> makes the text roll.example </marquee> is the closing tag. example 
<blink> makes the text blink in Firefox. </blink> is the closing tag.