CSS Designer / Property Inspector fails to recognise classes from pre-existing linked stylesheets
Summary
In Dreamweaver 2021 (confirmed on versions 21.8 and 21.8.1, Build 15907), the CSS Designer panel does not reliably discover and parse external stylesheets that are already linked via <link> tags present in a document before it is opened — so the Selectors pane shows no classes (or an incomplete set), and the Property Inspector's Class dropdown offers no classes to apply in Design view. This happens even though the linked stylesheets are valid, present on disk, and correctly resolve.
By contrast, if the same external stylesheet is attached to a document using CSS Designer's own "+" > Attach Existing CSS File > Link function, it works correctly: the file appears in Sources, its selectors populate, and the Property Inspector's Class dropdown offers its classes as expected, both immediately and in later sessions.
Environment
- OS: Windows 10
- Dreamweaver: version 21.8.1, Build 15907 (also reproduced identically on version 21.8)
- Reproduced independently on two separate physical PCs (a desktop and a laptop), each with its own Windows installation
- Reproduced under a brand-new Windows local user account with freshly imported Dreamweaver site definitions and freshly copied site files (i.e. not the original, long-used Windows profile)
- Site structure: static HTML site built from a single Dreamweaver Template (.dwt); pages link to external stylesheets using site-root-relative paths, e.g.: <link rel="stylesheet" type="text/css" href="/Templates/Universal.css" media="all" />
Steps to Reproduce
- Create a Dreamweaver Template (.dwt) whose <head> links an external CSS file via a site-root-relative path, where that CSS file defines multiple class selectors (e.g. .exampleClass { color: red; }).
- Create or open an ordinary page generated from that template (i.e. one where the <head> linking code is in the template's locked region).
- Open Window > CSS Designer. In "All" mode, click the linked stylesheet in the Sources pane.
Expected result: The Selectors pane lists every class/rule defined in that stylesheet, and the Property Inspector's Class dropdown offers those classes when text/an element is selected in Design view.
Actual result: The Sources pane may or may not list the stylesheet consistently, and even when it does, the Selectors pane remains empty (or shows only a small, unpredictable subset — in one observed case, exactly one ID selector out of dozens of classes actually present in the file). The Property Inspector's Class dropdown offers no classes at all, making it impossible to apply the site's predefined classes through Design view's normal UI.
- As a contrast test: create a brand-new blank HTML page (not based on the template), and attach the same CSS file via CSS Designer's "+" > Attach Existing CSS File > Link. This works correctly every time — Sources, Selectors, and the Property Inspector's Class list all populate and persist correctly across save/reopen.
Troubleshooting already performed (ruling out other causes)
The following were each tested and individually ruled out as the cause:
- Local Site Definition configuration, including the "Web URL" setting (a separate, genuine misconfiguration was found and corrected here — an outdated technical hosting hostname causing a 403 error — but correcting it did not resolve the behaviour described above)
- Dreamweaver preferences corruption (used the official Reset Preferences procedure — Ctrl+Shift+Windows key while launching Dreamweaver.exe)
- The site cache file (WinFileCache-<random>.dat in the Dreamweaver Configuration folder under AppData) — deleted and allowed to rebuild
- The "Enable Cache" site setting — toggled off, saved, re-enabled, forced a full site cache rebuild
- Dreamweaver version — identical behaviour on 21.8 and 21.8.1
- A complete uninstall (via Windows Control Panel) and fresh reinstall (via Creative Cloud) of Dreamweaver
- Third-party security software: Norton 360 (Program Control confirmed Dreamweaver and its Helper process at full trust level and "Allow" network access) and Malwarebytes (fully closed and confirmed not running via Task Manager)
- Windows user profile/registry corruption — reproduced identically under a freshly created Windows local user account
- Physical machine/hardware — reproduced identically on a second, independent PC
- The CSS file's own validity — inspected manually; no syntax errors that would explain a wholesale parsing failure (two unrelated minor errors were found — two selectors missing a leading dot — but these do not account for the rest of the file's classes being unavailable)
- @import chains — checked all other linked stylesheets on affected pages for @import statements that might pull in the affected file indirectly; none found
- CSS Designer's "All" vs "Current" selection-scope toggle — confirmed set to "All"; no change
Additional observation (possibly relevant to root cause)
On one page that was temporarily detached from its template (Modify/Tools > Templates > Detach from Template) so its locked <head> region could be edited, a stylesheet's <link> tag was deleted from the code and then re-added via CSS Designer's own Attach Existing CSS File > Link function. This appeared to fix the page — Sources, Selectors, and the Property Inspector's Class list all worked correctly, both immediately and after closing/reopening Dreamweaver.
However, on later inspection of the saved HTML file in a plain text editor, the <link> tag for that stylesheet is not present anywhere in the file's code at all, despite Dreamweaver continuing to correctly recognise and apply that stylesheet's classes for this specific document (and the page's Design view rendering is visually correct, matching the stylesheet's rules). This suggests Dreamweaver may be retaining an internal, per-document association that is not reflected in the saved markup — which may be a related but distinct issue worth investigating, since it means the document's behaviour inside Dreamweaver does not currently match what its own saved code would produce when opened elsewhere.
Impact
This makes it impossible to use Design view's normal workflow (Property Inspector's Class dropdown) to apply predefined CSS classes to any pre-existing page in a large, long-maintained, template-based static site — a workflow this installation of Dreamweaver had used correctly for many years prior to this issue appearing. The only current workarounds are typing class="..." attributes directly in Code view, or repeating a manual detach/delete-link/reattach-via-CSS-Designer procedure on each affected page.
