=== WP-Beautifier === Contributors: tillkruess Donate link: http://wordpress.pralinenschachtel.de/donations/ Tags: clean, tidy, strip, remove, indent, indentation, format, formatting, source, code, output, html, xhtml, xml, feed Requires at least: 3.0 Tested up to: 3.0.1 Stable tag: 1.3 Beautifier provides several options to clean up WP's messy (X)HTML source code output, such as code indentation. == Description == Beautifier provides the following options to clean up WP's messy (X)HTML source code output: * Strip unnecessary whitespace, like new lines and trailing whitespace * Format (indent) the (X)HTML source code output * Remove all HTML comments * Convert single quoted tag attributes values into uniform double quoted values * Remove *anything* you want from the output by using custom regular expressions If something is not working, please read the [FAQ](http://wordpress.org/extend/plugins/wp-beautifier/faq/) or open a topic in the [support forum](http://wordpress.org/tags/wp-beautifier). == Installation == 1. Upload the `/wp-beautifier/` directory and its contents to `/wp-content/plugins/`. 2. Login to your WordPress installation and activate the plugin through the _Plugins_ menu. 3. If desired, refine the plugin's options in the _Settings_ menu under _Beautifier_. == Frequently Asked Questions == = Excuse me, what exactly is this plugin doing? = This plugin provides a bunch of options to change what WordPress is sending to the browser. The text sent to the browser is called HTML/XHTML and you can usually see it by doing a right-click on the page and select something like "View Page Source" or "Show Sourcecode". This plugin provides the ability to indent all lines correctly for easier reading, the removal of unnecessary whitespace characters, the ability to remove anything you want from the output using regular expressions and a few other options. = This plugin leaves my (X)HTML untouched! = The reason for that is most likely a invalid or missing Doctype declarations (DTD). This plugin only takes action, if a valid (X)HTML DTD is found in the first 200 characters of the page. If you don't know what a Doctype declarations is, read this [article about Doctypes](http://www.w3.org/QA/Tips/Doctype) or see this [list of valid doctypes for (X)HTML documents](http://www.w3.org/QA/2002/04/valid-dtd-list.html). = My HTML source code isn't indented correct! = Most likly the reason for that is the actual source code output of your WordPress theme is using [HTML](http://www.w3.org/TR/html401/) syntax. This plugin only supports valid [XHTML](http://www.w3.org/TR/xhtml1/) syntax, which can also be used in HTML5 documents. = When I activate the plugin, my theme breaks! = To narrow down the cause, start disabling every single option (under *Settings*->*Beautifier*) one by one and see if the problem persists. If it persists, deactivate the plugin and copy-paste the working generated (X)HTML source code into a txt-file; afterwards activate the plugin again and copy-paste the _broken_ (X)HTML output into another txt-file. Send these two files to [the author](http://wordpress.pralinenschachtel.de/contact/) with a short description of your problem. = I see a white/blank page where my website used to be! = Try the _Reset Options_ button in the _Settings_ menu under _Beautifier_. If that doesn't help, deactivate the plugin and [contact the author](http://wordpress.pralinenschachtel.de/contact/). To resolve your problem faster, attach your server's PHP error-log-file to the email. == Screenshots == 1. Clean and nicely formatted HTML-code. == Changelog == = 1.3 = * Added basic RSS and Atom-Feed output cleaning * Moved admin related code into `options.php` file * Made most of the language strings easier to understand * Added settings link to plugin actions in plugin listing * `beautifier_clean_whitespace()` is now also removing tabs between tags = 1.2 = * Prevented permanent `E_NOTICE` caused by strict `ob_start()` * Added toggle for *custom regular expressions* * Added contextual help to administration menu * Added German translation * `beautifier_uninstall()` is now working again * Updated language strings and old comments * *Custom regular expressions* are now applied before the code cleaning to enhance their potential * Moved the *single quotes conversion* before the tag preservation * Cleaning only if `WP_USE_THEMES` is defined and a valid DTD is found in the beginning of the output buffer = 1.1.1 = * Improved tag preservation to keep `