@ Marjoline van der Jagt
Well I spent the better part of my day tracking this down… I eventually tracked down thru the Connections code that the file names for the template were being changed. The file names being searched for, not the actual files themselves.
Thru some trial and error I narrowed it further down to the core WordPress sanitize_file_name() function was basically “hashing” the file names instead of simply ensuring the files sames were safe.
So… with that knowledge I new for a fact another plugin or a theme was indeed the cause. Another plugin was changing the behavior of this core WordPress function thru the use of the sanitize_file_name filter within that function.
I downloaded the installed plugins one at a time looking for one which hooked into the sanitize_file_name filter. On the fifth one, I found it.
The culprit, “Discussion Board Pro”.
It hooked into the sanitize_file_name and under the following conditions would “hash” the file name.
- The user was logged in.
- The login in user was not an admin
- The user was permitted to post a discussion.
- The user was permitted to upload a featured image or had access to the media button when posting a discussion.
The bad part is all those above criteria were met, their filter would be applied to all usages of sanitize_file_name() globally — all other plugins, theme and even WordPress.
The solution…
Fortunately there was a simple solution. In the Discussion Board Pro setting under the Pro tab, uncheck both the “Upload featured image” and “Allow media button” options.
Bingo! The editor and user can view the directory just fine because Connections can now find its template files because the name it was looking for were not correct.
I personally would consider this a major bug in “Discussion Board Pro”. Their filter should only be applied within the strictest scenarios as possible to help reduce the possibility of this type of conflict. They really should refactor this so their filter is only applied to when a logged in user is posting a discussion and not globally like they are now.
Hope this helps!
