((Yes, when I see something not looking right I *really* like to be able to change it right away.)) Before we can get into the comparisons here is why I want such an app: for making quick CSS tweaks to this site when I am no where near my MacBook Air. However a few brave folks mentioned Koder.Īt first glance Koder caught my eye, but Textastic had such praise that I needed to buy and try them both. The overwhelming majority voted Textastic. This requires at least version 3.3 of Wordpress.Last week I asked on Twitter what everyone was using to edit code from FTP sites on their iPads. Add this code at the end of your theme's functions.php file. You can enable support for Crayon comments by adding TinyMCE to the comment box. This is where user themes are stored when you customise stock themes in the Theme Editor. You can add custom themes in wp-content/uploads/crayon-syntax-highlighter/themes with the same format as those in the plugin directory and they will remain after plugin updates. The specification for CSS classes is here. If you know CSS, take a look at themes/default/default.css to get an idea of how they work and how you can change/create them. Themes are structured themes/theme-name/theme-name.css. See a sample of the current set of themes. ![]() ThemesĬrayon comes with built-in Themes to style your code. You can add custom languages in wp-content/uploads/crayon-syntax-highlighter/languages with the same format as those in the plugin directory and they will remain after plugin updates. See the readme in langs/readme.md for more information about the language file syntax. Take a look at langs/default/default.txt and check out the neat regex of the default/generic language. Languages are structured langs/lang-name/lang-name.txt. Language information is found here in the Wordpress Admin: Settings > Crayon > Languages > Show Languages You can customise and create new languages and define how to capture each element (keywords, comments, strings, etc.) with regular expressions. You can even mix code together like on a real HTML page, by having, and tags all in a single Crayon and setting the language to HTML. You can specify a single number or a single range. Specify the range of lines from the input code to use in the output. You can specify single numbers, comma separted, a range, or a combination. Mark some lines as important so they appear highlighted. For languages with defined extensions (see Languages in Settings) you don't even need to provide the lang attribute, as this will be detected if your file ends with it, as in the example. You give a relative local path instead of absolute (see Files). Load a file from the web or a local path. Specify a Language ID, these are the folders in the langs directory and appears in the list of Languages in Settings. ![]() You can optionally provide the following attributes: Attributes Name Enforces proper encoding of entities (.Disabling Crayon still presents the code as pre-formatted text and is readable.I'd recommend it over the manual approach, since you can fine-tune the Crayon after the editor generates it :) Pre-formatted Tags The Tag Editor makes adding code, changing settings and all that much easier with a simple dialog. Crayon is a Wordpress plugin, but can be used in any PHP environment. Supports multiple languages, themes, fonts, highlighting from a URL, local file or post text.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |