also detect hashtags at the start of a paragraph
This commit is contained in:
parent
3f92bcc41b
commit
0b881bb9fd
1 changed files with 1 additions and 1 deletions
|
@ -19,7 +19,7 @@ namespace Activitypub;
|
||||||
* Initialize plugin
|
* Initialize plugin
|
||||||
*/
|
*/
|
||||||
function init() {
|
function init() {
|
||||||
\defined( 'ACTIVITYPUB_HASHTAGS_REGEXP' ) || \define( 'ACTIVITYPUB_HASHTAGS_REGEXP', '(?:(?<=\s)|^)#([A-Za-z0-9_]+)(?:(?=\s|[[:punct:]]))' );
|
\defined( 'ACTIVITYPUB_HASHTAGS_REGEXP' ) || \define( 'ACTIVITYPUB_HASHTAGS_REGEXP', '(?:(?<=[\s>])|^)#([A-Za-z0-9_]+)(?:(?=\s|[[:punct:]]))' );
|
||||||
\defined( 'ACTIVITYPUB_ALLOWED_HTML' ) || \define( 'ACTIVITYPUB_ALLOWED_HTML', '<strong><a><p><ul><ol><li><code><blockquote><pre><img>' );
|
\defined( 'ACTIVITYPUB_ALLOWED_HTML' ) || \define( 'ACTIVITYPUB_ALLOWED_HTML', '<strong><a><p><ul><ol><li><code><blockquote><pre><img>' );
|
||||||
\defined( 'ACTIVITYPUB_CUSTOM_POST_CONTENT' ) || \define( 'ACTIVITYPUB_CUSTOM_POST_CONTENT', "<p><strong>%title%</strong></p>\n\n%content%\n\n<p>%hashtags%</p>\n\n<p>%shortlink%</p>" );
|
\defined( 'ACTIVITYPUB_CUSTOM_POST_CONTENT' ) || \define( 'ACTIVITYPUB_CUSTOM_POST_CONTENT', "<p><strong>%title%</strong></p>\n\n%content%\n\n<p>%hashtags%</p>\n\n<p>%shortlink%</p>" );
|
||||||
\defined( 'ACTIVITYPUB_PLUGIN' ) || \define( 'ACTIVITYPUB_PLUGIN', __FILE__ );
|
\defined( 'ACTIVITYPUB_PLUGIN' ) || \define( 'ACTIVITYPUB_PLUGIN', __FILE__ );
|
||||||
|
|
Loading…
Reference in a new issue