Usage of container

Discussion forum for Extension Writers regarding Extension Development.
Post Reply
Wardormeur
Registered User
Posts: 142
Joined: Sun Jan 27, 2013 9:22 am

Usage of container

Post by Wardormeur »

Hi,
I'm working on bridges between phpBB & Wordpress, and to integrate it properly I, normally, include the common.php file.
To do so, I'm in the obligation to overwrite the phpbb_path to an absolute path. The container name is based on the phpbb_path, and based on a Windows system, it contains a ":" which isn't parsed and create an error when included (invalid path actually).
I can get through relative path to still support Windows( or break Windows support ), but it breaks the facilitation of configuration for the users.
Am i doing it wrong, or can i send a PR to either fix the name parsing of container.php, or a PR to add namespace to those files (inb4 lot of modifications) ?

Edit : "why do i override the path" : phpbb & wp share the same name for functions and doesn't have namespaces to differenciate, creating conflicts (functions_content.php for make_clickable and functions_users.php for validate_username). So i automatically create a copy with an enclosure "function_exists" so I cache to then include "safely".
nicofuma
3.2 Release Manager
3.2 Release Manager
Posts: 546
Joined: Sun Apr 13, 2014 1:47 am
Location: Grenoble - France

Re: Usage of container

Post by nicofuma »

For the container name I want to fix that and I have to ways in mind:
1) get ride of the rule of one directory => one container. (for that we have to ways: move everything to the same directory -hard- or find a way to dynamically inject some parameters (I prefer this way and I have some ideas in mind)
2) change the name of the container to: container_env_md5(absolute path).php or something like that
Member of phpBB Development-Team
No Support via PM
Wardormeur
Registered User
Posts: 142
Joined: Sun Jan 27, 2013 9:22 am

Re: Usage of container

Post by Wardormeur »

Can I be of any help? Filling a bug report + moving this discussion to an ongoing development?
nicofuma
3.2 Release Manager
3.2 Release Manager
Posts: 546
Joined: Sun Apr 13, 2014 1:47 am
Location: Grenoble - France

Re: Usage of container

Post by nicofuma »

yes off course
Member of phpBB Development-Team
No Support via PM
User avatar
AmigoJack
Registered User
Posts: 5904
Joined: Tue Jun 15, 2010 11:33 am
Location: グリーン ヒル ゾーン
Contact:

Re: Usage of container

Post by AmigoJack »

Wardormeur wrote:Filling a bug report
nicofuma wrote:off course
Do you two share the same dictionary? :shock:
  • "The problem is probably not my English but you do not want to understand correctly. ... We will not come anybody anyway, nevertheless, it's best to shit this." Affin, 2018-11-20
  • "But this shit is not here for you. You can follow with your. Maybe the question, instead, was for you, who know, so you shoved us how you are." axe70, 2020-10-10
  • "My reaction is not to everyone, especially to you." Raptiye, 2021-02-28
Post Reply

Return to “Extension Writers Discussion”