WordPress plugin

There are multiple ways to use the plugin:

Any combination of these is also possible. For example, you can enable option 1, use the shortcode from option 2, and create a custom rendition in theme as per option 3 all at the same time.


Installation

Check https://wordpress.org/plugins/flockler-social-wall for latest install instructions.


Option 1: Flockler posts among default posts

To show Flockler posts on WordPress alongside default WordPress blog content simply enable the “Automatically display Flockler posts alongside other main blog content” option in settings (screenshot).


Option 2: How to add a Social Wall

If you want to show Flockler post as a social wall, you can do so with the “flockler-stream” shortcode: [flockler-stream webhook=562ae45faa3ef2ff count=5 width=200]

Social wall for whole site
  1. Follow the installation instructions above
  2. Make sure to ask for a webhook that sends all site content
  3. Open Flockler's newsroom https://flockler.com/newsroom
  4. Hover your mouse over “Frontpage” to reveal the site ID
  5. Use this shortcode to add Flockler Wall onto a WordPress page or post:

    [flockler-stream site=365 count=20]
  6. Replace the site in shortcode with the ID you looked up in Flockler Newsroom
  7. Done!
Social wall for a single section
  1. Follow the installation instructions above
  2. Open Flockler's newsroom https://flockler.com/newsroom
  3. Hover your mouse over the section to reveal the section ID
  4. Use this shortcode to add Flockler Wall onto a WordPress page or post:

    [flockler-stream section=2500 count=20]
  5. Replace the section in shortcode with the ID you looked up in Flockler Newsroom
  6. Done!
Shortcode Usage

The shortcode for rendering a social wall is [flockler-stream].

You must supply one of these parameters:

The following optional parameters are supported:

Please note that with the social wall, you’ll need an area of at least 1050px to show three posts side-by-side and 700px to show at least two.


Option 3: Advanced Usage (rendering HTML in theme)

Flockler posts can be handled and rendered in your custom theme or plugin. The posts can be retrieved in PHP simply via WordPress's own get_posts() function. You can then use the retrieved post data as you normally would.

See our advanced usage examples to jump straight into it.


Technical requirements


Troubleshooting

Q: No content in WordPress

  1. Make sure you've sent some articles from Flockler; simply creating a webhook does not send old content => posts created before creating webhook have to be sent manually
  2. Check Posts > Flockler on WordPress admin and see if there any posts there
    • => No posts? None have been sent from Flockler
    • => Posts say "Scheduled"? The server clock is probably misaligned. Check the UTC time in WP from Settings > General > Timezone. It should match the UTC time (can be off by some minutes)
  3. Check your technical requirements
  4. Still nothing? Contact team@flockler.com , we are happy to help :)

Q: Some posts show up, some don't, some show up incomplete

Check if the missing posts can be found under Posts > Flockler on WordPress admin. If the posts are there but they are missing content:

  1. If you're using [flockler-stream] shortcode, check that the shortcode's parameters match the posts you want to show up
  2. Check if there are any CSS or JavaScript errors in the browser
  3. Check that your MySQL version is 5.5+. If MySQL version is 5.1, or anything below 5.5, it cannot save emojis to the database => the post is saved only partially => WordPress cannot display the post
  4. Check that wp_posts and wp_postmeta tables use utf8mb4 encoding
  5. Check that all the string columns in wp_posts and wp_postmeta tables use utf8mb4_unicode_ci collation with SHOW FULL COLUMNS FROM wp_postmeta; and SHOW FULL COLUMNS FROM wp_posts; MySQL commands
    • If your tables and/or columns are not in utf8mb4, see the question below about wrong MySQL encoding & collation

If the posts cannot be found under Posts > Flockler then the webhook has failed somehow.

Q: WordPress gives error about libssl/openssl something when trying to register webhooks in WP

Your WordPress server might not have libssl, or it's not configured properly. Please install or configure libssl. Our WordPress plugin uses SSL for encryption so that your WordPress site stays safe.

Q: Duplicate content

Most common cause is other plugins. Check your plugins. W3TC (W3 Total Cache), WP Super Cache and other plugins are known to cause this.

If you have W3TC (W3 Total Cache) plugin installed: open W3TC's Database cache settings > Reject query words > add word "lock" on its own line like here: W3TC query word settings

If you have some other plugin, especially cache plugins, check if they have an option to disable database cache or query cache or to disable caching certain queries. All queries containing the word "lock" should not be cached.

Second: Check your MySQL version (see requirements above) and your MySQL configuration. DB locking should be enabled.

Technical details: We use MySQL's GET_LOCK and RELEASE_LOCK commands to lock the database when we are adding or updating posts so that we can prevent duplicates. Some plugins break these commands, such as W3TC which incorrectly caches these commands.

Q: How do I change MySQL tables & columns to use utf8mb4?

If your database tables are not using utf8mb4 you might be missing or have problems with posts with emojis.

WordPress actually has a feature that can upgrade your database to use utf8mb4:

  1. Add the snippet from https://gist.github.com/flori...0ba7046200fd0b7519918e0 into e.g. your theme's functions.php
  2. Open your site with "?update-utf8bm4=1" e.g. http://www.example.com/?update-utf8bm4=1
  3. Confirm that the columns in wp_posts and wp_postmeta were changed with SHOW FULL COLUMNS FROM wp_posts; and SHOW FULL COLUMNS FROM wp_postmeta;
  4. Remove the snippet from functions.php so it can't be triggered anymore

Note: We have tested this only up to WordPress 4.9.2