filter · HTML filters
Compute HTML statistics (compute_statistics)
- Category:
- HTML
- CoreFilters:
- No
- OptimizeForBandwidth:
- No
- Risk:
- Not rated
Computes statistics about the HTML (element counts and sizes) for the admin console. It adds a parsing pass per page and changes nothing in the output; enable it while you need the numbers.
When to use it
- Not in CoreFilters: it runs only when you enable it by name.
Risks
The
HTML filters
page lists no specific risks for this filter.
If a page misbehaves with it, DisableFilters compute_statistics turns it off for
the scope you set it in.
Configuration
Enable it in the module configuration, at server, virtual-host or location scope:
Apache
ModPagespeedEnableFilters compute_statisticsnginx
pagespeed EnableFilters compute_statistics;IIS (pagespeed.config)
pagespeed EnableFilters compute_statistics
Scoping, ForbidFilters and the thresholds filters read:
Choosing filters
.
Frequently asked questions
- What does the compute_statistics filter do?
- Computes statistics about the HTML (element counts and sizes) for the admin console. It adds a parsing pass per page and changes nothing in the output; enable it while you need the numbers.
- Is compute_statistics enabled by default?
- No.
compute_statisticsis not in CoreFilters, the default RewriteLevel; it runs only when you enable it by name withEnableFilters. - How do I enable compute_statistics on Apache and nginx?
- Add
ModPagespeedEnableFilters compute_statisticson Apache orpagespeed EnableFilters compute_statistics;on nginx. On IIS, addpagespeed EnableFilters compute_statisticsto pagespeed.config.
Related filters
- add_base_tag — Add base tag
- add_head — Add head
- add_ids — Add IDs
- add_instrumentation — Add instrumentation
- collapse_whitespace — Collapse whitespace
- combine_heads — Combine heads
- convert_meta_tags — Convert meta tags
- debug — Debug comments
This page is drawn from the compute_statistics entry on HTML filters. Every filter in one table: PageSpeed filters.