Edits: Feb 2.
removed “a” from codes for bold and strong in HTML; and I just noticed that the LateX for color and for size does not display when you hold the mouse over it.
(This wasn’t the first post I intended to put out after the long layoff, but it’s the one that is ready, so here it is. I’ve got a couple in the works, and I hope that one will be ready for Wednesday.)
I keep a draft post for testing HTML and latex. I’ve decided to clean it up and post it, so that other people can see how I do this. Oh, one reason for using my own HTML is that we need to use the HTML tab rather than the visual tab. About the only thing I let WordPress do for me is add a link. (Actually, in the course of typing this, I have gotten used to using the WordPress “bold” button.)
I keep a text file of just about everything I’ve ever used in a post, so I can copy-and-paste. In other words, my draft post is used for testing new things, but I didn’t bother throwing out all the old things after they worked. The equations involving square brackets ended up in here in response to a question in the forums. (And that question and answer, truth be told, was my fundamental motivation for posting this.)
Note that HTML and latex behave differently.
If you want to know what latex created a particular equation, all you have to do is hold the mouse cursor over it: WordPress will display the latex. On the other hand, I don’t want to have to search my own posts to find out how I got, for example, the double dot for acceleration.
As far as I can tell, however, the HTML does not display when you hold the cursor over it. You may know HTML, and you may not need to see any of these, but I pretty much learned what HTML and latex I know in the course of the past year.
Only because my HTML entries occur first, let’s look at the HTML that I use. Oh, I have to show you another trick.
How can we display code in a post? Easy enough.The reference is
here. This will tell us how to display HTML code. Oh, but how do I show you the code one level up?
Here is a picture of the code which displayed the HTML code:

Here are the HTML examples
Italic:
how complicated is this?
how <em>complicated</em> is this?
(That is, the preceding little box is the output of that “sourcecode” stuff.)
Bold (two ways):
now, strong words.
now, bold words.
now, <strong>strong words</strong>.
[sourcecode language='html']
now, bold words.
[/sourcecode]
centered:
what gets me centered?
<p style="text-align:center;">what gets me centered?</p>
Aligned right:
on the right?
<p style="text-align:right;">on the right?</p>
A small heading:
how about a small heading?
<h2>how about a small heading?</h2>
Colored text:
and what about color?
<span style="color:#ff0000;">and what about color?</span>
strike-out:
and this?
<span style="text-decoration:line-through;">and this?</span>
underline:
I mean this.
<span style="text-decoration:underline;">I mean this.</span>
an ordered list:
- yaba
- daba
- do
<ol> <li>yaba</li> <li>daba</li> <li>do </li> </ol>
an unordered list:
- yaba
- daba
- do
<ul> <li>yaba</li> <li>daba</li> <li>do </li> </ul>
Here are the latex examples that i still have in here
As I said, to see the latex, just hold the cursor over the equation or symbol. By the way, I have one very nice but very expensive resource for latex: there is a command in Mathematica (//TeXForm) which produces TeX output. It isn’t perfect, but its failures are very rare.
a vector cross product
acceleration
set intersection and ^
implication
.
not an element
foreground and background colors for an equation! I just found this and have not used it for real, yet. And for these commands, I have to show the code myself: here is the code without the dollar signs:
latex How’s this?&bg=ffcccc&fg=cc00ff
bigger equations
latex { [plain\ text] }&s=4
By the way, the curly braces are essential outside the square-bracketed stuff. See below.
to get parentheses of appropriate size
to get square brackets of appropriate size
Since it may be difficult to see, let me say that just as we used \left( and \right) to get parentheses of the appropriate size, so we use \left[ and \right] to get square brackets of the appropriate size.
I have also discovered that if I simply want square brackets in latex, I have to put the expression in curly braces. That is, the following works, although the brackets have not been sized nicely (the \left and \right are gone):
in contrast to using parentheses. To write the same expression using parentheses, we do not need curly braces; as before, plain parentheses are not sized nicely:
an alternative display of a matrix. (Again, I haven’t used this yet, and since Mathematica creates usable latex for this, I have no reason to use this; perhaps you do.)