If you want you can use an access token from flagrow.io to read premium extensions and then compile a complete repo with its language files. I'll make sure the functionality will be forward compatible.

Only thing you need is to get your admin permission back on flagrow.io to get wildcard access to all premium extensions.

Sorry everyone else. I was hoping to have the rewrite finished sooner and thus sustain and expand the functionality of extiverse earlier. This exact question was something I had an answer to. I'm currently moving and as such all time I do have is to continue managing the organization.

  • [deleted]

  • Edited

@clarkwinkelmann I get an error when attempting to access latest posts from my root site at phenomlab.com. This is a simple WordPress function I wrote that creates dynamic links to posts on the forum. It uses the Flarum Embed extension, but most posts generate an error when clicked.

Can this be looked at asap please ?

For info, this is the WordPress function I'm using

function front_page_news () {
$json = file_get_contents('https://forum.phenomlab.com/api/discussions');
$obj = json_decode($json, true);
//print_r($obj);
for($i = 0; $i < 12; ++$i) {
$posturl = $obj['data'][$i]['id'];
$thistitle = trim($obj['data'][$i]['attributes']['title']);
$thisurl =  '<a class="recent-items" href="https://forum.phenomlab.com/d/' . $posturl . "-". $obj['data'][$i]['attributes']['slug'] . '">';
$thisitem .= "<div class='recent-list'><div class='icon'><i class='fal fa-crosshairs'></i></div>" . $thisurl . $thistitle. "<br></a></div>";

}
		return $thisitem;
}
add_shortcode( 'fpn', 'front_page_news' 
);

This is the error that appears in the log

[2020-02-23 15:50:52] production.ERROR: BadMethodCallException: Call to undefined method Kilowhat\Wordpress\WordpressSummaryPost::formatContent() in /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/illuminate/support/Traits/ForwardsCalls.php:50
Stack trace:
#0 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/illuminate/support/Traits/ForwardsCalls.php(36): Illuminate\Database\Eloquent\Model::throwBadMethodCallException('formatContent')
#1 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/illuminate/database/Eloquent/Model.php(1610): Illuminate\Database\Eloquent\Model->forwardCallTo(Object(Illuminate\Database\Eloquent\Builder), 'formatContent', Array)
#2 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Database/AbstractModel.php(202): Illuminate\Database\Eloquent\Model->__call('formatContent', Array)
#3 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/v17development/flarum-seo/src/Managers/Discussion.php(101): Flarum\Database\AbstractModel->__call('formatContent', Array)
#4 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/v17development/flarum-seo/src/Managers/Discussion.php(41): V17Development\FlarumSeo\Managers\Discussion->createTags()
#5 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/v17development/flarum-seo/src/Listeners/PageListener.php(150): V17Development\FlarumSeo\Managers\Discussion->__construct(Object(V17Development\FlarumSeo\Listeners\PageListener), Object(Flarum\Discussion\DiscussionRepository), '1433-s2-ep27-bl...')
#6 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/v17development/flarum-seo/src/Listeners/PageListener.php(116): V17Development\FlarumSeo\Listeners\PageListener->determine()
#7 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Frontend/Frontend.php(63): V17Development\FlarumSeo\Listeners\PageListener->__invoke(Object(Flarum\Frontend\Document), Object(Zend\Diactoros\ServerRequest))
#8 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Frontend/Frontend.php(55): Flarum\Frontend\Frontend->populate(Object(Flarum\Frontend\Document), Object(Zend\Diactoros\ServerRequest))
#9 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Frontend/Controller.php(32): Flarum\Frontend\Frontend->document(Object(Zend\Diactoros\ServerRequest))
#10 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/RouteHandlerFactory.php(38): Flarum\Frontend\Controller->handle(Object(Zend\Diactoros\ServerRequest))
#11 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/DispatchRoute.php(65): Flarum\Http\RouteHandlerFactory->Flarum\Http\{closure}(Object(Zend\Diactoros\ServerRequest), Array)
#12 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\DispatchRoute->process(Object(Zend\Diactoros\ServerRequest), Object(Closure))
#13 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/kilowhat/flarum-ext-wordpress/src/Middlewares/LogoutOverrideMiddleware.php(16): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#14 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Kilowhat\Wordpress\Middlewares\LogoutOverrideMiddleware->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#15 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/kilowhat/flarum-ext-wordpress/src/Middlewares/LoginWarningMiddleware.php(21): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#16 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Kilowhat\Wordpress\Middlewares\LoginWarningMiddleware->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#17 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/kilowhat/flarum-ext-wordpress/src/Embed/WordpressEmbedNotFoundMiddleware.php(18): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#18 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Kilowhat\Wordpress\Embed\WordpressEmbedNotFoundMiddleware->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#19 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/ShareErrorsFromSession.php(56): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#20 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\ShareErrorsFromSession->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#21 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/SetLocale.php(50): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#22 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\SetLocale->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#23 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/CheckCsrfToken.php(23): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#24 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\CheckCsrfToken->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#25 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/AuthenticateWithSession.php(32): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#26 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\AuthenticateWithSession->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#27 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/RememberFromCookie.php(51): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#28 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\RememberFromCookie->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#29 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/StartSession.php(61): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#30 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\StartSession->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#31 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/CollectGarbage.php(46): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#32 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\CollectGarbage->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#33 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/ParseJsonBody.php(28): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#34 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\ParseJsonBody->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#35 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Middleware/HandleErrors.php(57): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#36 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\HandleErrors->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#37 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/MiddlewarePipe.php(83): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#38 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/middlewares/request-handler/src/RequestHandler.php(84): Zend\Stratigility\MiddlewarePipe->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#39 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Middlewares\RequestHandler->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#40 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/middlewares/base-path-router/src/BasePathRouter.php(97): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#41 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Middlewares\BasePathRouter->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#42 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Middleware/OriginalMessages.php(41): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#43 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Zend\Stratigility\Middleware\OriginalMessages->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#44 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/middlewares/base-path/src/BasePath.php(53): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#45 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/Next.php(60): Middlewares\BasePath->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
#46 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/MiddlewarePipe.php(83): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
#47 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-stratigility/src/MiddlewarePipe.php(72): Zend\Stratigility\MiddlewarePipe->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\EmptyPipelineHandler))
#48 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/zendframework/zend-httphandlerrunner/src/RequestHandlerRunner.php(95): Zend\Stratigility\MiddlewarePipe->handle(Object(Zend\Diactoros\ServerRequest))
#49 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/vendor/flarum/core/src/Http/Server.php(44): Zend\HttpHandlerRunner\RequestHandlerRunner->run()
#50 /var/www/vhosts/phenomlab.com/forum.phenomlab.com/index.php(22): Flarum\Http\Server->listen()
#51 {main}  

Thanks

    [deleted] I'll take a look ASAP.

    I'm pretty sure it's a side effect of the last update. The SEO extension is probably reading the first post and expecting it to be a comment post, but just like with the other issues discussed above a Wordpress Summary isn't a plain text post.

    Hopefully I can solve that by implementing the missing functions That a comment would have.

    Technically it's the fault of the SEO extension for not checking the post is a comment before treating it like one 😛

      • [deleted]

      clarkwinkelmann I'll take a look ASAP.

      Thanks Clark. I really appreciate this.

      Version 1.2.3 - February 23, 2020

      • Add formatContent method for compatibility with third-party extensions that expect firstPost to be a CommentPost.

      You can update the Flarum extension via Bazaar or Composer.
      Works with any version of the Wordpress plugin.

      Compatibility

      When used together with FriendsOfFlarum Follow Tags, the post content for new discussions will not be rendered. Instead you will see Array, maybe accompanied by the "Array to string conversion" error message if you have not hidden the PHP notices on your server. This problem will have to be fixed in FriendsOfFlarum Follow Tags FriendsOfFlarum/follow-tags7

        • [deleted]

        clarkwinkelmann Thanks Clark. Just installed, this resolves the issue I posted. Eagerly awaiting the fix for Follow Tags.. 🙂

        Hey, I can't find where to translate the "comments" here. It's in the commenting iFrame. Maybe it's hard-coded? If so, where?

          • [deleted]

          @clarkwinkelmann is it possible to add a setting where you can choose which tag to assign WordPress posts to ? Currently, they aren't assigned anywhere, which looks a bit odd.

            • [deleted]

            @clarkwinkelmann fof/Share Social doesn't seem to be triggered when viewing posts created by WordPress. Works fine on posts created directly in Flarum.

            Can you have a look please ?

            Thanks

              • [deleted]

              clarkwinkelmann potentially, although the share buttons still do not appear after comments are added

              @clarkwinkelmann if it's possible sometime in the future, it would be great if we can choose different Flarum tags for different WP categories.

              Now we can choose to place topics from all WP categories only in one tag. For example, with my proposal, we will be able to place comments from category "news" to Flarum tag ID 1 and place comments from the category "blog" to tag ID 2.

              Also, we should be able to do the same with other post types.

                clarkwinkelmann I'll see what I can do. The fixed height and the current iframe layout is a compromise to get everything working. I tried making the height flexible, but Flarum wouldn't play nice with it and the Composer would end up out of screen.

                Do you think you'll be able do that? 🤞

                  danielunited nothing new at this time.

                  Ideally I'd want to create an extension that reverses the flow of the discussion and places the composer at the top. Then the Wordpress extension could use that, either globally or just in the iframe.

                  I have not yet tested how feasible it is, and whether to make it premium as well or open-source.

                    clarkwinkelmann I think it's possible to show the composer at the top (at least in the comments section) with CSS (with position attribution and other manipulation). But can you just make it visible (like it is when you click "Reply") by default? If you can send the JavaScript function to do that I'll see if I can place it at the top with CSS - that will be a good solution for now (until an extension is available).

                    5 days later

                    beta 12 is the first Flarum update since the release of the Wordpress extension. I will be testing the extension with beta 12 in the next few days to ensure compatibility. I'll then tag a new release that marks it as compatible.

                    The extension is using a very restrictive Composer constraint, so you won't be able to update to beta 12 if you have the extension installed until I tag that new version. Thanks for your patience.

                    As beta 12 isn't a security update, I wouldn't recommend updating right away anyway. It's best to wait until all the main extensions have been properly tested and/or updated.