| @@ 13-43 (lines=31) @@ | ||
| 10 | ||
| 11 | namespace vse\abbc3\migrations; |
|
| 12 | ||
| 13 | class v310_m6_update_bbcodes extends bbcodes_migration_base |
|
| 14 | { |
|
| 15 | /** |
|
| 16 | * {@inheritdoc} |
|
| 17 | */ |
|
| 18 | public static function depends_on() |
|
| 19 | { |
|
| 20 | return array('\vse\abbc3\migrations\v310_m4_install_data'); |
|
| 21 | } |
|
| 22 | ||
| 23 | /** |
|
| 24 | * {@inheritdoc} |
|
| 25 | */ |
|
| 26 | public function update_data() |
|
| 27 | { |
|
| 28 | return array( |
|
| 29 | array('custom', array(array($this, 'install_abbc3_bbcodes'))), |
|
| 30 | ); |
|
| 31 | } |
|
| 32 | ||
| 33 | /** |
|
| 34 | * {@inheritdoc} |
|
| 35 | */ |
|
| 36 | protected static $bbcode_data = array( |
|
| 37 | 'soundcloud' => array( |
|
| 38 | 'bbcode_helpline' => 'ABBC3_SOUNDCLOUD_HELPLINE', |
|
| 39 | 'bbcode_match' => '[soundcloud]{URL}[/soundcloud]', |
|
| 40 | 'bbcode_tpl' => '<iframe width="100%" height="166" scrolling="no" frameborder="no" src="https://w.soundcloud.com/player/?url={URL}&color=ff5500&auto_play=false&hide_related=false&show_comments=true&show_user=true&show_reposts=false"></iframe>', |
|
| 41 | ), |
|
| 42 | ); |
|
| 43 | } |
|
| 44 | ||
| @@ 13-43 (lines=31) @@ | ||
| 10 | ||
| 11 | namespace vse\abbc3\migrations; |
|
| 12 | ||
| 13 | class v322_m8_update_bbcodes extends bbcodes_migration_base |
|
| 14 | { |
|
| 15 | /** |
|
| 16 | * {@inheritdoc} |
|
| 17 | */ |
|
| 18 | public static function depends_on() |
|
| 19 | { |
|
| 20 | return array('\vse\abbc3\migrations\v310_m4_install_data'); |
|
| 21 | } |
|
| 22 | ||
| 23 | /** |
|
| 24 | * {@inheritdoc} |
|
| 25 | */ |
|
| 26 | public function update_data() |
|
| 27 | { |
|
| 28 | return array( |
|
| 29 | array('custom', array(array($this, 'install_abbc3_bbcodes'))), |
|
| 30 | ); |
|
| 31 | } |
|
| 32 | ||
| 33 | /** |
|
| 34 | * {@inheritdoc} |
|
| 35 | */ |
|
| 36 | protected static $bbcode_data = array( |
|
| 37 | 'align=' => array( |
|
| 38 | 'bbcode_helpline' => 'ABBC3_ALIGN_HELPLINE', |
|
| 39 | 'bbcode_match' => '[align={IDENTIFIER}]{TEXT}[/align]', |
|
| 40 | 'bbcode_tpl' => '<div style="text-align:{IDENTIFIER}">{TEXT}</div>', |
|
| 41 | ), |
|
| 42 | ); |
|
| 43 | } |
|
| 44 | ||
| @@ 13-43 (lines=31) @@ | ||
| 10 | ||
| 11 | namespace vse\abbc3\migrations; |
|
| 12 | ||
| 13 | class v322_m9_delete_bbcodes extends bbcodes_migration_base |
|
| 14 | { |
|
| 15 | /** |
|
| 16 | * {@inheritdoc} |
|
| 17 | */ |
|
| 18 | public static function depends_on() |
|
| 19 | { |
|
| 20 | return array('\vse\abbc3\migrations\v310_m4_install_data'); |
|
| 21 | } |
|
| 22 | ||
| 23 | /** |
|
| 24 | * {@inheritdoc} |
|
| 25 | */ |
|
| 26 | public function update_data() |
|
| 27 | { |
|
| 28 | return array( |
|
| 29 | array('custom', array(array($this, 'delete_abbc3_bbcodes'))), |
|
| 30 | ); |
|
| 31 | } |
|
| 32 | ||
| 33 | /** |
|
| 34 | * {@inheritdoc} |
|
| 35 | */ |
|
| 36 | protected static $bbcode_data = array( |
|
| 37 | 'youtube' => array( |
|
| 38 | 'bbcode_helpline' => 'ABBC3_YOUTUBE_HELPLINE', |
|
| 39 | 'bbcode_match' => '[youtube]{URL}[/youtube]', |
|
| 40 | 'bbcode_tpl' => '<a href="{URL}" class="bbvideo" data-bbvideo="560,315">{URL}</a>', |
|
| 41 | ), |
|
| 42 | ); |
|
| 43 | } |
|
| 44 | ||