Skip to content

Commit c779825

Browse files
author
Raphael Schweikert
committed
fixed missing loop in readme
1 parent f1eab3e commit c779825

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,11 @@ There are a few convenience methods on CSSDocument to ease finding, manipulating
8080
$oCss = $oParser->parse();
8181
foreach($oCss->getAllSelectors() as $oSelector) {
8282
$aSelector = $oSelector->getSelector();
83-
$oSelector->setSelector($sMyId.' '.$aSelector);
83+
foreach($aSelector as $iKey => $sSelector) {
84+
//Loop over all selector parts (the comma-separated strings in a selector) and prepend the id
85+
$aSelector[$iKey] = "$sMyId $sSelector";
86+
}
87+
$oSelector->setSelector($aSelector);
8488
}
8589

8690
#### Shrink all absolute sizes to half

0 commit comments

Comments
 (0)