Skip to main content
Topic: Broken link redirects to 404 WSOD instead of board index (Read 9059 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #15

Quote from: Flavio93Zena – 3) Elkarte itself not redirecting to board index with that unread broken link.
That one absolutely not.
Elk doesn't use pretty/friendly/etc. urls. The gateway is index.php, anything that doesn't point to index.php is just ignored (apart few exceptions), so the response to random urls is not within the scope of elk at this moment. It would be the day Elk starts using friendly urls by default, but not at all now (and even later on, it should not show the board index, but a 404 page).
Bugs creator.
Features destroyer.
Template killer.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #16

@emanuele
What I think he means, is since the URL is not working right, it's getting the 404 error, instead of redirecting to the main page.
However, I think that's going to be normal, since the error due to the SP mod, is stripping the scripturl from it, so it wont redirect. It will get the 404, since it's treating the link as a complete page, and not part of the forum.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #17

I didn't think about it emanuele, true :) It's because it doesn't have the index.php part. Scratch that then.
~ SimplePortal Support Team ~

Re: Broken link redirects to 404 WSOD instead of board index

Reply #18

 Burke Knight slaps @Flavio93Zena around a bit with a large trout.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #19

Where's that dislike button when I need it?  ???
~ SimplePortal Support Team ~

Re: Broken link redirects to 404 WSOD instead of board index

Reply #20

 emanuele thinks a slap button would be more effective. :P
Bugs creator.
Features destroyer.
Template killer.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #21

Ehy you two stop making fun of me D: offended
xD
~ SimplePortal Support Team ~

Re: Broken link redirects to 404 WSOD instead of board index

Reply #22

That is very strange that it only occurs on sites updated to 1.0.4 from a previous version, not sure what to make of that.  Maybe uninstall and reinstall SP to "reset" the hooks.  Really that should not matter, but until I get a change to dig in to this I'm  ???

Re: Broken link redirects to 404 WSOD instead of board index

Reply #23

@Spuds
Tried it, and no-go...
Which is strange to me, because really, the idea sounded pretty sound.
Seemed like it was a hook issue, but now, not too sure....

Re: Broken link redirects to 404 WSOD instead of board index

Reply #24

Thank you for giving that a try, looks like I'm going to actually have to do some work :D

Re: Broken link redirects to 404 WSOD instead of board index

Reply #25

While I ponder what is going on ... for the can't load the main template error, for now I'd say just add
Code: [Select]
function template_main(){}
to the Portal.template..php file  obexit() is calling that template, just not sure from where or why.

On the recent posts link error, how do you have the blocks defined?  Are those blocks there for all actions, and which blocks specifically are on that page.  Trying to reproduce that error.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #26

Where add that line in the file? Anywhere?

All side blocks are set to everywhere, as is the news and shoutbox, and the footer affiliates block.
I had tried before, to disable the blocks, but it made no difference.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #27

The /%7Bunread_all_url%7D error seems to be caused by the who's online block, at least when I disable that block the link goes back to normal.  So right now I've at least duplicated the issue :D

QuoteWhere add that line in the file? Anywhere?
Just anywhere will do, put it at the end, it really does not matter.  Just don't add it inside one of the functions of course.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #28

File edit worked.
As for it being Who's Online block, that seems to be it.
But, why is it not affecting forums that were 1.0.4 installs, and just those updated to 1.0.4?

The 2 sites that are 1.0.4 installs, still do not have this issue, but they do have the Who's Online Block. Strange... LOL

EDIT: Test site now has the issue, yet the other one does not.

Re: Broken link redirects to 404 WSOD instead of board index

Reply #29

Looking at the who's online block, it has
Code: [Select]
loadLanguage('index', '', false, true);
its that last true that forces the reload of the index language and I'd suspect that is what is stomping on the substitution.  TBH I'm not sure why that is there, its how it was/is in SP 2.3, not sure if it was just and sm thing and if its still needed :scratch head:

So, the quick fix should be to add after the above line:
Code: [Select]
	$txt['unread_topics_visit_none'] = str_replace('{unread_all_url}', $scripturl . '?action=unread;all', $txt['unread_topics_visit_none']);