quotes Property - Javascript CSS Style Property

Javascript examples for CSS Style Property:quotes

Description

The quotes property sets or gets the type of quotation marks.

Property Values

Value Description
noneopen-quote and close-quote values will not produce any quotation marks. This is default
string string string string quotation marks to use. The first two values sets the first level of quotation, the next two values sets the next level of quote, etc
initial Sets this property to its default value.
inherit Inherits this property from its parent element.

Technical Details

Item Value
Default Value: none?
Return Value: A String, representing the type of quotation marks for embedded quotations
CSS VersionCSS2

Change quotation marks:

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
<body>

<p><q id="myQ" style="quotes:'\00ab' '\00bb';">This is a quote.</q></p>

<button type="button" onclick="myFunction()">Return quotation marks</button>

<script>
function myFunction() {/* w  ww.  jav a2s  .  c om*/
    document.getElementById("myQ").style.quotes ='$ $';
}
</script>

</body>
</html>

Related Tutorials