protected function Exporter::cssSafe in Loft Data Grids 7.2
Same name and namespace in other branches
- 6.2 vendor/aklump/loft_data_grids/src/AKlump/LoftDataGrids/Exporter.php \AKlump\LoftDataGrids\Exporter::cssSafe()
2 calls to Exporter::cssSafe()
- HTMLExporter::collapseCell in vendor/
aklump/ loft_data_grids/ src/ AKlump/ LoftDataGrids/ HTMLExporter.php - Collapse a single cell in a row.
- HtmlListExporter::compile in vendor/
aklump/ loft_data_grids/ src/ AKlump/ LoftDataGrids/ HtmlListExporter.php - Build the string content of $this->output and return $this for chaining.
File
- vendor/
aklump/ loft_data_grids/ src/ AKlump/ LoftDataGrids/ Exporter.php, line 370
Class
- Exporter
- Class Exporter
Namespace
AKlump\LoftDataGridsCode
protected function cssSafe($string) {
$string = preg_replace('/[^a-z0-9\\-]/', '-', strtolower($string));
$string = preg_replace('/^\\d/', 'c-\\0', $string);
return trim(preg_replace('/-{2,}/', '-', $string), '-');
}