Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-11824

Controller URLs do not work anymore

    Details

    • Type: Bug
    • Status: Unverified Fix
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 3.1.0-dev
    • Fix Version/s: 3.1.0-a1
    • Component/s: None
    • Labels:
      None

      Description

      Caused by Solution of PHPBB3-11215:

      Example:
      Create an event listener for "core.page_header", which generates a URL like:

      'U_NEWSPAGE'	=> $phpbb_container->get('controller.helper')->url('news'),

      This should generate the following, at least that is what the tests for the url method say ( https://github.com/phpbb/phpbb3/pull/1102/files#diff-6 ):
      phpBB/news

      Note: Functional tests use another route for tests, they use app.php/news
      https://github.com/phpbb/phpbb3/pull/1102/files#diff-7

      However if you hover the link while being on faq.php it generates:
      phpBB/faq.php/news

      and so on. These pages just display normal faq.php content.

      Feel free to use https://github.com/nickvergessen/phpbb3-mod-newspage/tree/develop-caitlyn for testing next time.........

      Also app.php?controller=news does not work anymore.
      It just says:

      No route found for "GET /"

      Also smilies have been broken on sub pages:
      phpBB/news < smilies work
      phpBB/news/topic_id < smilies won't work, as it looks for
      phpBB/news/images/smilies/icon_mrgreen.gif
      instead of phpBB/images/smilies/icon_mrgreen.gif

      tl;dr:

      1. restore functionality for app.php?controller=news
      2. remove current file from generated urls (please also test form adm/index.php and stuff)
      3. fix smilies and other phpbb_root_path usages while being on a non-root level
      4. change extensions test to NOT use app.php/ in path

        Issue Links

          Activity

          Hide
          nickvergessen Joas Schilling added a comment -

          Also

          {ROOT_PATH}

          does not point to the actual root.
          While being on phpBB/news/topic_id it points to phpBB/news/ instead of phpBB/

          Show
          nickvergessen Joas Schilling added a comment - Also {ROOT_PATH} does not point to the actual root. While being on phpBB/news/topic_id it points to phpBB/news/ instead of phpBB/
          Hide
          imkingdavid David King added a comment -

          The app.php?controller=route parameter is no longer being used. Instead, use app.php/route.

          To fix the issue with the filename being injected into URLs and paths I will introduce a new config option in the ACP to determine whether or not to use app.php in the URLs. When disabled, both types of URLs should still work (app.php/route and /route) if mod_rewrite is enabled, but links and asset paths will be built dependent on the setting.

          I'll look into

          {ROOT_PATH}

          as well.

          I did test admin login and browsing, so that works.

          Show
          imkingdavid David King added a comment - The app.php?controller=route parameter is no longer being used. Instead, use app.php/route. To fix the issue with the filename being injected into URLs and paths I will introduce a new config option in the ACP to determine whether or not to use app.php in the URLs. When disabled, both types of URLs should still work (app.php/route and /route) if mod_rewrite is enabled, but links and asset paths will be built dependent on the setting. I'll look into {ROOT_PATH} as well. I did test admin login and browsing, so that works.
          Hide
          VSE VSE added a comment - - edited

          I'm having issues with an extension since this fix was merged. Issues with the root_path var.

          EDIT: Never mind, issue will be resolved by ticket 11832 when merged.

          Show
          VSE VSE added a comment - - edited I'm having issues with an extension since this fix was merged. Issues with the root_path var. EDIT: Never mind, issue will be resolved by ticket 11832 when merged.

            People

            • Assignee:
              imkingdavid David King
              Reporter:
              nickvergessen Joas Schilling
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development