# MyIntervals/PHP-CSS-Parser

A Parser for CSS Files written in PHP. Allows extraction of CSS files into a data structure, manipulation of said structure and output as (optimized) CSS

Repository: https://github.com/MyIntervals/PHP-CSS-Parser
Canonical: https://ross.abutalabs.com/products/php-css-parser
Homepage: http://www.sabberworm.com/blog/2010/6/10/php-css-parser
Language: PHP
License: MIT
License Family: permissive
Topics: hacktoberfest, composer-package, css, parser
Last push: 2026-08-25T09:11:36+00:00

## Health v2 (maintenance only)
Score: 87/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 99, release rhythm 65, longevity 100
- inputs: {"age_days": 5853, "days_push": 8, "days_rel": 76, "gap_med": 106, "n_releases_24m": 8}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1826, forks 153 (observed 2026-08-28T04:05:41.359509+00:00)

## What it is
A PHP library that parses CSS files into a manipulable data structure and can output the structure back as (optimized) CSS. It supports strict or lenient parsing, charset handling, and programmatic manipulation of rules, selectors, and values.

## Use cases
- parse css files in php
- extract css rules into a data structure
- programmatically modify css stylesheets
- minify or optimize css output
- analyze css selectors and rules in php
- convert css files to structured data

## When to choose
- you need to parse, inspect, or transform CSS from PHP code
- you want to build CSS tooling like minifiers or linters in PHP
- you need tolerant parsing of real-world CSS including legacy IE constructs

## When to avoid
- you need a browser-grade CSS engine or full CSS selector matching
- you work outside PHP
- you need to render or apply CSS to HTML documents

## Facets
- artifact type: library
- maturity: active
- function: parser, css-framework
- domain: web-development, frontend, parsers
- platform: php, cli
- tags: css, css-parser, composer-package, css-manipulation, css-optimization

## Member repositories
- MyIntervals/PHP-CSS-Parser (main) score 87

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:41.359509+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:19:33.356891+00:00, confidence not recorded.
  - readme: https://github.com/MyIntervals/PHP-CSS-Parser (fetched 2026-08-28T04:05:41.359509+00:00, sha 96ea55647ac7)
  - homepage: http://www.sabberworm.com/blog/2010/6/10/php-css-parser (fetched 2026-08-29T10:58:25.546624+00:00, sha 9084ee79ffc6)
  - site_page: https://www.sabberworm.com/about (fetched 2026-08-29T10:58:25.574187+00:00, sha 98a046a51f4c)
- Data as of 2026-08-30T08:39:29.467469+00:00.
