• Register
    • Help

    striker  0 Items
    Currently Supporting
    • Home
    • News
    • Forum
    • Wiki
    • Support
      • Manage Subscriptions
      • FAQ
      • Support For
        • VaultWiki 4.x Series
        • VaultWiki.org Site
    • What's New?
    • Buy Now
    • Manual
    • 
    • Support
    • VaultWiki 4.x Series
    • Bug
    • [4.1 Beta 4] 1) Problem with WIKI bbcode with option parameter and special page target: Undefined index: text. 2) Placeholder text encountered when moderated template is embedded into itself.

    1. Welcome to VaultWiki.org, home of the wiki add-on for vBulletin and XenForo!

      VaultWiki allows your existing forum users to collaborate on creating and managing a site's content pages. VaultWiki is a fully-featured and fully-supported wiki solution for vBulletin and XenForo.

      The VaultWiki Team encourages you to join our community of forum administrators and check out VaultWiki for yourself.

    Issue: [4.1 Beta 4] 1) Problem with WIKI bbcode with option parameter and special page target: Undefined index: text. 2) Placeholder text encountered when moderated template is embedded into itself.

    • Issue Tools
      • View Changes
    1. issueid=5896 October 14, 2019 1:03 PM
      ACL ACL is offline
      Regular Member
      [4.1 Beta 4] 1) Problem with WIKI bbcode with option parameter and special page target: Undefined index: text. 2) Placeholder text encountered when moderated template is embedded into itself.

      While performing tests for issue 5894, I've run the following issue that appears to be BB code link related.

      From what I can gather, this is encountered when a page has used the WIKI bbcode with the optional option parameter, i.e. [wiki='name-of-page']text to display[/wiki]. Basic WIKI bbcode without the parameter is not enough to trigger the error, i.e. [wiki]name-of-page[/wiki].

      ----

      The above theory is due to the following two symptoms.

      I have a wiki template page that contains a handful of wiki links - This template is used on my wiki index to link to some of the most frequently referenced wiki pages around my site. This page is currently in a moderated state (as a result of the 4.1 Beta 4 upgrade as discussed in issue 5894).

      1) When attempting to approve this page, an undefined index error is encountered: [E_NOTICE] Undefined index: text src/addons/vw/vw/_core/model/parser/handle/link/vw.php:102

      Code:
      XF::handlePhpError() in src/addons/vw/vw/_core/model/parser/handle/link/vw.php at line 102
      vw_Parser_Handle_Link_Model->handle_bbcode_link() in src/addons/vw/vw/_core/model/parser/handle/wrapper/vw.php at line 184
      vw_Parser_Handle_Wrapper_Model->bbcode_wrapper()
      call_user_func() in src/XF/BbCode/Renderer/Html.php at line 295
      XF\BbCode\Renderer\Html->renderTag() in src/addons/vw/vw/XF/BbCode/Renderer/Html.php at line 499
      vw\vw\XF\BbCode\Renderer\Html->renderTag() in src/XF/BbCode/Traverser.php at line 61
      XF\BbCode\Traverser->renderSubTree() in src/addons/vw/vw/XF/BbCode/Renderer/Html.php at line 529
      vw\vw\XF\BbCode\Renderer\Html->renderSubTree() in src/addons/vw/vw/_core/model/parser/handle/wrapper/xf2.php at line 69
      vw_Parser_Handle_Wrapper_Model_XF2->format_args() in src/addons/vw/vw/_core/model/parser/handle/wrapper/vw.php at line 189
      vw_Parser_Handle_Wrapper_Model->vwcode_wrapper()
      call_user_func() in src/XF/BbCode/Renderer/Html.php at line 295
      XF\BbCode\Renderer\Html->renderTag() in src/addons/vw/vw/XF/BbCode/Renderer/Html.php at line 499
      vw\vw\XF\BbCode\Renderer\Html->renderTag() in src/XF/BbCode/Traverser.php at line 61
      XF\BbCode\Traverser->renderSubTree() in src/addons/vw/vw/XF/BbCode/Renderer/Html.php at line 529
      vw\vw\XF\BbCode\Renderer\Html->renderSubTree() in src/XF/BbCode/Traverser.php at line 37
      XF\BbCode\Traverser->renderAst() in src/addons/vw/vw/XF/BbCode/Renderer/Html.php at line 142
      vw\vw\XF\BbCode\Renderer\Html->renderAst() in src/XF/BbCode/Traverser.php at line 20
      XF\BbCode\Traverser->render() in src/addons/vw/vw/XF/BbCode/Renderer/Html.php at line 137
      vw\vw\XF\BbCode\Renderer\Html->vwParentRender() in src/addons/vw/vw/XF/BbCode/Renderer/Html.php at line 85
      vw\vw\XF\BbCode\Renderer\Html->vwRender() in src/addons/vw/vw/_core/instance/parser/renderer/xf2.php at line 352
      vw_Parser_Renderer_Instance_XF2->render() in src/addons/vw/vw/_core/model/parser/instance/xf2.php at line 212
      vw_Parser_Instance_Model_XF2->parse() in src/addons/vw/vw/_core/controller/dm/page/vw.php at line 1242
      vw_DM_Page_Controller->process_links() in src/addons/vw/vw/_core/controller/dm/page/vw.php at line 904
      vw_DM_Page_Controller->process_revision() in src/addons/vw/vw/_core/controller/dm/page/vw.php at line 793
      vw_DM_Page_Controller->pre_save() in src/addons/vw/vw/XF/Entity/EntityBase.php at line 490
      vw\vw\XF\Entity\EntityBase->_preSave() in src/XF/Mvc/Entity/Entity.php at line 1297
      XF\Mvc\Entity\Entity->preSave() in src/addons/vw/vw/XF/Entity/EntityBase.php at line 481
      vw\vw\XF\Entity\EntityBase->vwPreSave() in src/addons/vw/vw/XF/Entity/EntityBase.php at line 536
      vw\vw\XF\Entity\EntityBase->vwSave() in src/addons/vw/vw/_core/controller/dm/xf2.php at line 369
      vw_DM_Controller_XF2->save() in src/addons/vw/vw/_core/controller/ui/imod/action/approve/vw.php at line 217
      vw_UI_iMod_Action_Approve_Controller->process_approve_generic() in src/addons/vw/vw/_core/controller/ui/imod/action/approve/vw.php at line 164
      vw_UI_iMod_Action_Approve_Controller->perform_doapprove() in src/addons/vw/vw/_core/controller/ui/imod/action/base/vw.php at line 91
      vw_UI_iMod_Action_base_Controller->process() in src/addons/vw/vw/Handler/InlineMod/Base/AbstractAction.php at line 183
      vw\vw\Handler\InlineMod\Base\AbstractAction->applyToEntity() in src/XF/InlineMod/AbstractAction.php at line 87
      XF\InlineMod\AbstractAction->applyInternal() in src/XF/InlineMod/AbstractAction.php at line 80
      XF\InlineMod\AbstractAction->apply() in src/XF/Pub/Controller/InlineMod.php at line 131
      XF\Pub\Controller\InlineMod->actionPerform() in src/addons/vw/vw/XF/Pub/Controller/InlineMod.php at line 41
      vw\vw\XF\Pub\Controller\InlineMod->actionPerform() in src/XF/Mvc/Dispatcher.php at line 321
      XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 244
      XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 100
      XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 50
      XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2178
      XF\App->run() in src/XF.php at line 390
      XF::runApp() in index.php at line 20
      2) Placeholder text is shown instead of the page's real content. However, viewing the page source does display the real contents.
    Issue Details
    Issue Number 5896
    Issue Type Bug
    Project VaultWiki 4.x Series
    Category BB-Code Parsing
    Status Fixed
    Priority 3 - Loss of Functionality
    Affected Version 4.1.0 Beta 4
    Fixed Version (none)
    Milestone (none)
    Software DependencyAny
    License TypePaid
    Users able to reproduce bug 0
    Users unable to reproduce bug 0
    Attachments 0
    Assigned Users (none)
    Tags (none)




    1. October 14, 2019 1:55 PM
      pegasus pegasus is offline
      VaultWiki Team
      1) I cannot reproduce this issue or see any logical path that would lead to this error. Please provide a minimal example that can be used to reproduce the problem.

      2) Placeholder text is shown if the page's BB-Code content renders as an empty string. Please provide an example that you do not expect to render as an empty string but that does.
      Reply Reply  
    2. October 14, 2019 2:08 PM
      ACL ACL is offline
      Regular Member
      Further testing shows that it seems to be limited to WIKI links with a prefix, where a colon is one of the characters of the WIKI bbcode option parameter.

      The simplest way to reproduce 1) is to start creating a new page with the following contents and then try to preview it:
      Code:
      [wiki='special:recentchanges']wiki bbcode option test[/wiki]
      2) This has only started occurring with Beta 4. The affected page does contain at least one wiki link in the format of [wiki='prefix:page']label[/wiki].
      Reply Reply  
    3. October 15, 2019 10:44 AM
      pegasus pegasus is offline
      VaultWiki Team
      1) I was only able to reproduce this issue when creating an optioned wiki link to an existing Special page. In src/addons/vw/vw/_core/model/url/special/vw.php, find:
      Code:
      $urlinfo = vw_Hard_Core::controller('Fetch')->get('Special', $itemid);
      Replace with:
      Code:
      $urlinfo = vw_Hard_Core::controller('Fetch')->get('Special', $itemid) + $urlinfo;
      2) I created a page on the demo containing one link in the format suggested, but I cannot reproduce the issue. Please try to reproduce the issue on said page: https://www.vaultwiki.org/xf-wiki/in...-Prefixed-Link
      Reply Reply  
    4. October 15, 2019 12:02 PM
      ACL ACL is offline
      Regular Member
      1) You're right, it does seem that this issue is limited specifically to special pages, and not all prefixed page as I assumed.

      2) With your file edit applied I'm able to approve the page now without the 'undefined index: text' problem preventing the action. Now that the page isn't stuck in an awaiting approval state, the situation is much more clear. This is different to what I originally thought and actually has nothing to do with special page wiki links. It is a combination of some of the following:
      a. When a template is pending moderation the template contents aren't shown on pages that embed it (regardless of whether the user has permission to view moderated pages)
      b. On other pages where a moderated template is embedded and the page has other content, an empty space is left where the moderated template would be inserted.
      c. If all of a page's content is generated via a moderated template, then placeholder text is inserted as there is no page content available.

      The affected page where placeholder text was showing is a template and it normally shows its own rendered content via [NOINCLUDE] without any other content. It is a combination of a) and c) that is the reason for the unexpected placeholder text.

      Now that the real cause of the situation has been realised it makes sense why it works this way. Whether there is any potential improvement here, I'm not sure (and perhaps it would add unnecessary processing overhead and/or be too cumbersome). To be honest, this scenario is a rare one and I don't see it being intentionally repeated on my public site. It only happened this time as a chain reaction to the previously reported Beta 4 upgrade moderation state change issue.
      Reply Reply  
    5. October 15, 2019 12:52 PM
      pegasus pegasus is offline
      VaultWiki Team
      Marked as fixed in the next build.

      Yes, it is intentional that a template will not render inside another page while the template is still waiting for approval.

      However, I think we should make an exception if the template is rendering inside itself, since you must have permission to view the template to get that far.
      Reply Reply  
    6. October 16, 2019 7:21 AM
      ACL ACL is offline
      Regular Member
      Quote Originally Posted by pegasus
      Yes, it is intentional that a template will not render inside another page while the template is still waiting for approval.

      However, I think we should make an exception if the template is rendering inside itself.
      This does sound like a good solution, if it isn't too cumbersome to implement .
      Reply Reply  
    + Reply

    Assigned Users
    Loading Please Wait
    Tags
    Loading Please Wait
    • Contact Us
    • License Agreement
    • Privacy
    • Terms
    • Top
    All times are GMT -4. The time now is 12:34 PM.
    This site uses cookies to help personalize content, to tailor your experience, and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Learn more… Accept Remind me later
  • striker
    Powered by vBulletin® Version 4.2.5 Beta 2
    Copyright © 2025 vBulletin Solutions Inc. All rights reserved.
    Search Engine Optimisation provided by DragonByte SEO (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
    Copyright © 2008 - 2024 VaultWiki Team, Cracked Egg Studios, LLC.