{"id":74853,"date":"2026-09-30T03:01:00","date_gmt":"2026-09-29T17:01:00","guid":{"rendered":"https:\/\/www.rjmprogramming.com.au\/ITblog\/?p=74853"},"modified":"2026-09-27T11:38:03","modified_gmt":"2026-09-27T01:38:03","slug":"css-variables-at-the-root-level-tutorial","status":"publish","type":"post","link":"https:\/\/www.rjmprogramming.com.au\/ITblog\/css-variables-at-the-root-level-tutorial\/","title":{"rendered":"CSS Variables at the Root Level Tutorial"},"content":{"rendered":"<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_root_ideas.html\" rel=\"noopener\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"CSS Variables at the Root Level Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_root_usage.gif\" title=\"CSS Variables at the Root Level Tutorial\"  style=\"float:left;\"  \/><\/a><p class=\"wp-caption-text\">CSS Variables at the Root Level Tutorial<\/p><\/div>\n<p>For us, to think &#8230;<\/p>\n<table style=width:95%; border=5>\n<tr>\n<td>CSS<\/td>\n<td>var<font size=1>iables<\/font><\/td>\n<td>computes &#8230; is a lot harder to fathom and &#8220;more of a stretch&#8221; than &#8230;<\/td>\n<\/tr>\n<tr>\n<td>Javascript<\/td>\n<td>var<font size=1>iables<\/font><\/td>\n<td>computes<\/td>\n<\/tr>\n<\/table>\n<p> &#8230; but this is true, and it can be dynamic too, though we&#8217;re using Javascript to make it dynamic and using the &#8230;<\/p>\n<blockquote><p>\n<a target=\"_blank\" title='Great advice, thanks' href='https:\/\/www.google.com\/search?q=%3Aroot+in+CSS&#038;sca_esv=25c22cf5cb864701&#038;rlz=1C5OZZY_en&#038;sxsrf=APpeQntrPnXMGNj3imY7p8sNpsLFuBoG-Q%3A1790464383001&#038;ei=flG4aqjTPOWS1e8P3_aUuA8&#038;ved=2ahUKEwioiqDMr42XAxVlSfUHHV87BfcQ4dUDegQIBhAN&#038;uact=5&#038;oq=%3Aroot+in+CSS&#038;gs_lp=Egxnd3Mtd2l6LXNlcnAiDDpyb290IGluIENTUzIFEAAYgAQyBRAAGIAEMgUQABiABDIGEAAYFhgeMgYQABgWGB4yBhAAGBYYHjIGEAAYFhgeMgYQABgWGB4yBhAAGBYYHjIGEAAYFhgeSPQWUABYjRRwAHgAkAEAmAGFAqABugyqAQUwLjUuM7gBA8gBAPgBAvgBAZgCCKAC_QzCAggQLhiABBixA8ICCBAAGIAEGLEDwgILEC4YgAQYxwEYrwHCAhcQLhiABBixAxiXBRjcBBjeBBjgBNgBAcICCBAAGIAEGLQHwgIFEC4YgATCAhQQLhiABBiXBRjcBBjeBBjfBNgBAcICBxAAGIAEGAqYAwC6BgYIARABGBSSBwUwLjUuM6AHglOyBwUwLjUuM7gH_QzCBwUyLTcuMcgHMYAIAQ&#038;sclient=gws-wiz-serp' rel=\"noopener\">:root<\/a>\n<\/p><\/blockquote>\n<p> &#8230; CSS selector (globally to the whole webpage) repository to allow for this, when we wrote a simple <a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_root_ideas.html_GETME\" rel=\"noopener\">proof of concept<\/a> <a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_root_ideas.html\" rel=\"noopener\">web application<\/a> you can also try below with similarities to concepts to can read more about at the reecent <a title='CSS Variables Textarea Tutorial' href='#cssvtt'>CSS Variables Textarea Tutorial<\/a> below.<\/p>\n<p><iframe src=\"\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_root_ideas.html\" style=\"width:100%;height:900px;\"><\/iframe><\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=\"_blank\" href='\/\/www.rjmprogramming.com.au\/ITblog\/css-variables-at-the-root-level-tutorial\/' rel=\"noopener\">CSS Variables at the Root Level Tutorial<\/a>.<\/p-->\n<hr>\n<p id='cssvtt'>Previous relevant <a target=\"_blank\" title='CSS Variables Textarea Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/css-variables-textarea-tutorial\/' rel=\"noopener\">CSS Variables Textarea Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_property_usage.html\" rel=\"noopener\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"CSS Variables Textarea Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_property_usage.png\" title=\"CSS Variables Textarea Tutorial\"  style=\"float:left;\"  \/><\/a><p class=\"wp-caption-text\">CSS Variables Textarea Tutorial<\/p><\/div>\n<p>Today we&#8217;ve got a &#8220;proof of concept&#8221; CSS web application idea that is inspired by <a target=\"_blank\" title='https:\/\/www.w3schools.com\/css\/css3_property.asp' href='https:\/\/www.w3schools.com\/css\/css3_property.asp' rel=\"noopener\">this W3school&#8217;s webpage<\/a>, thanks, but adding user interaction functionality, regarding &#8230;<\/p>\n<p><code><br \/>\nCSS @property variables<br \/>\n<\/code><\/p>\n<p> &#8230; bringing some Javascript feeling logic excitement to CSS styling smarts.  You can try this user interactive approach with <a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_property_usage.html_GETME\" rel=\"noopener\">this first draft<\/a> <a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_property_usage.html\" rel=\"noopener\">CSS @property variables web application<\/a> &#8230;<\/p>\n<p><iframe style=\"width:100%;height:600px;\" src='\/\/www.rjmprogramming.com.au\/HTMLCSS\/css_property_usage.html'><\/iframe><\/p>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d69862' onclick='var dv=document.getElementById(\"d69862\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/textarea\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d69862' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d69862' onclick='var dv=document.getElementById(\"d69862\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/textarea\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d69862' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n","protected":false},"excerpt":{"rendered":"<p>For us, to think &#8230; CSS variables computes &#8230; is a lot harder to fathom and &#8220;more of a stretch&#8221; than &#8230; Javascript variables computes &#8230; but this is true, and it can be dynamic too, though we&#8217;re using Javascript &hellip; <a href=\"https:\/\/www.rjmprogramming.com.au\/ITblog\/css-variables-at-the-root-level-tutorial\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12,37],"tags":[281,1683,1664,2212,997,1976,1070,1953,1209,1212,1262,1319,1721,1418],"class_list":["post-74853","post","type-post","status-publish","format-standard","hentry","category-elearning","category-tutorials","tag-css","tag-dynamic","tag-global","tag-head","tag-programming","tag-pseudo-class","tag-root","tag-selector","tag-style","tag-styling","tag-textarea","tag-tutorial","tag-variable","tag-webpage"],"_links":{"self":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/74853"}],"collection":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/comments?post=74853"}],"version-history":[{"count":6,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/74853\/revisions"}],"predecessor-version":[{"id":74859,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/74853\/revisions\/74859"}],"wp:attachment":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/media?parent=74853"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/categories?post=74853"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/tags?post=74853"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}