@Friendica Support

Hi there!

Having a strange behavior of one profile with respect to the domain.com/network page.
For some reason it just gives a blank page.
Same goes for:
/network?mention=1
/network?order=created
/network?order=commented
but not for:
/network?star=1

At the same time it does "feel" that this goes away sometimes, but this "feeling" will need some recheck.

As of now other related profiles that haven't posted anything or any interaction at all do display the network page without content as they do not have any contacts.

A first guess was that this is due to the startpage addon but changing the setting their from "network" to a different page didn't solve the problem.

This is happening on a "brand new" 2024.12 setup, hosted alongside a 2024.03 with the exact same admin settings that as of now hasn't any of these problems.


Any idea what this could be or how to solve this?

in reply to Hypolite Petovan

@Hypolite Petovan

Blank pages should have a related Fatal Error in the PHP log.

Uncaught Exception ValueError: "DOMDocument::loadHTML(): Argument #1 ($source) must not be empty" at /../domaincom/src/Model/Item.php line 3558
exception

Uncaught Exception ValueError: "DOMDocument::loadHTML(): Argument #1 ($source) must not be empty" at /../domaincom/src/Model/Item.php line 3558
exception
ValueError: DOMDocument::loadHTML(): Argument #1 ($source) must not be empty in /../domaincom/src/Model/Item.php:3558
Stack trace:
#0 /../domaincom/src/Model/Item.php(3558): DOMDocument->loadHTML()
#1 /../domaincom/src/Model/Item.php(3481): Friendica\Model\Item::replacePlatformIcon()
#2 /../domaincom/src/Object/Post.php(451): Friendica\Model\Item::prepareBody()
#3 /../domaincom/src/Object/Thread.php(190): Friendica\Object\Post->getTemplateData()
#4 /../domaincom/src/Content/Conversation.php(666): Friendica\Object\Thread->getTemplateData()
#5 /../domaincom/src/Content/Conversation.php(569): Friendica\Content\Conversation->getThreadList()
#6 /../domaincom/src/Module/Conversation/Network.php(223): Friendica\Content\Conversation->render()
#7 /../domaincom/src/BaseModule.php(236): Friendica\Module\Conversation\Network->content()
#8 /../domaincom/src/App.php(668): Friendica\BaseModule->run()
#9 /../domaincom/index.php(41): Friendica\App->runFrontend()
#10 {main}]
#3 #1 #2 #10 #4 #5 #6 #8 #9 #7 @Hypolite Petovan
in reply to Hypolite Petovan

How is this to understand @Hypolite Petovan.
Reading your link and follow ups I don't get much.
Is there a way tu pull only this fix from github or is it necessary to go "full dev branch"?
And why does this happen only on one profile, is there a way to create some situation that what ever is empty isn't anymore empty.
Like posting something, or commenting on some mastodon post or something like that?
Also, is this 2024.12 specific?
in reply to Hypolite Petovan

@Hypolite Petovan

In the "Files" tab you have the patch (code changes) that fixes this problem.


github.com/friendica/friendica…


Thx, just did the following and apparently it works.
Please see in any case the referred link on github to compare well the lines were to insert these changes!

nano /../friendicaflder/src/Model/Item.php

Search for the line:
[CTRL]+ [w]:
$s = self::replacePlatformIcon($s, $shared_item, $uid);
insert above:

		if (!$s) {
				DI::logger()->notice('Unexpected empty item HTML', ['item' => $item]);
			}

Search for the line:
[CTRL]+ [w]:
$dom = new \DOMDocument();

insert above:

	if ($html === '') {
			return $html;
		}

👍