Version: current

# Class BBCodeParser

BBCode parser object. Use on a text field in a template with $Content.Parse(BBCodeParser).

  Object
  TextParser
  BBCodeParser

Package: sapphire\misc
Located at sapphire/parsers/BBCodeParser.php

## Methods summary

`public static` | # `smilies_location( )`
`public static` | # `set_icon_folder( mixed $path )`
`public static` | # `autolinkUrls( )`
`public static` | # `disable_autolink_urls( mixed $autolink = false )`
`public static` | # `smiliesAllowed( )`
`public static` | # `enable_smilies( )`
`public static` | # `usable_tags( )`
`public` | # `useable_tagsHTML( )`
`public `Text`` | # `parse( )` Main BBCode parser method. This takes plain jane content and runs it through so many filters Main BBCode parser method. This takes plain jane content and runs it through so many filters #### Returns ``Text`` Text

### Methods inherited from TextParser

`__construct()`, `setContent()`

### Methods inherited from Object

`__call()`, `__toString()`, `__wakeup()`, `addMethodsFrom()`, `addStaticVars()`, `addWrapperMethod()`, `add_extension()`, `add_static_var()`, `allMethodNames()`, `cacheToFile()`, `cacheToFileWithArgs()`, `clearCache()`, `combined_static()`, `create()`, `createMethod()`, `create_from_string()`, `defineMethods()`, `exists()`, `extInstance()`, `extend()`, `getCustomClass()`, `getExtensionInstance()`, `getExtensionInstances()`, `get_extensions()`, `get_static()`, `hasExtension()`, `hasMethod()`, `has_extension()`, `invokeWithExtensions()`, `is_a()`, `loadCache()`, `parentClass()`, `parse_class_spec()`, `remove_extension()`, `sanitiseCachename()`, `saveCache()`, `set_stat()`, `set_static()`, `set_uninherited()`, `stat()`, `strong_create()`, `uninherited()`, `uninherited_static()`, `useCustomClass()`

### Magic methods summary

## Properties summary

`protected static `Boolean`` | $autolinkUrls | # Set whether phrases starting with http:// or www. are automatically linked Set whether phrases starting with http:// or www. are automatically linked
`protected static `Boolean`` | $allowSimilies | # Set whether similies :), :(, :P are converted to images Set whether similies :), :(, :P are converted to images
`protected static string` | $smilies_location | # Set the location of the smiles folder. By default use the ones in sapphire but this can be overridden by setting BBCodeParser::set_icon_folder('themes/yourtheme/images/'); Set the location of the smiles folder. By default use the ones in sapphire but this can be overridden by setting BBCodeParser::set_icon_folder('themes/yourtheme/images/');

### Properties inherited from TextParser

`$content`

### Properties inherited from Object

`$class`, `$extension_instances`, `$extensions`

[Raise a SilverStripe Framework issue/bug](https://github.com/silverstripe/silverstripe-framework/issues/new)
- [Raise a SilverStripe CMS issue/bug](https://github.com/silverstripe/silverstripe-cms/issues/new)
- Please use the Silverstripe Forums to ask development related questions. -