Quote:
Originally Posted by mfoley
The text "John M." neither shows with Courier New, nor in blue. What am I doing wrong?
|
At least four things...
* Not stating which browser(s) you are testing this with.
* Not using the browser developer tools to inspect the element and see whether styles are applied or not and whether anything is overriding it.
* Not re-testing your partially-simplified example before - your example (first code block below)
does do what you say it doesn't.
* Not simplifying your test case as far as possible - i.e. strip out everything not directly relevant to your issue, as per second code block below.
Code:
<!doctype html><meta charset=utf-8 />
<style>
div.booga input[type="text"] { font-family: 'Courier New'; color: blue }
</style>
:
:
<div class=booga style="position: absolute; top: 190px; left: 180px">
<input type="text" name="FMname" readonly width: 35em; border: 1px solid blue;" value="John M."/>
</div>
Code:
<!doctype html><meta charset=utf-8 />
<style>
div.booga input[type="text"] { font-family: 'Courier New'; color: blue }
</style>
<div class=booga>
<input type="text" value="John M." />
</div>
Both of those show blue text in Courier New font here (with the relevant entry showing in browser dev tools).
Do you have Courier New font installed? Maybe what you actually want is the generic "monospace" instead?