• 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
    • Undefined variable: filename

    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: Undefined variable: filename

    • Issue Tools
      • View Changes
    1. issueid=4913 February 13, 2017 8:18 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      Undefined variable: filename

      Code:
      ErrorException: Undefined variable: filename - library/vw/XenForo/Option/Seo.php:26 
      Generated By: Alfa, A moment ago
      
      Stack Trace
      #0 /library/vw/XenForo/Option/Seo.php(26): XenForo_Application::handlePhpError(8, 'Undefined varia...', '/home/...', 26, Array)
      #1 /library/XenForo/DataWriter/Option.php(365): vw_XenForo_Option_Seo::validate(1, Object(vw_XenForo_DataWriter_Option), 'vw_seo')
      #2 /library/vw/XenForo/DataWriter/Option.php(32): XenForo_DataWriter_Option->_validateOptionValuePreSave(1)
      #3 /library/XenForo/DataWriter/Option.php(222): vw_XenForo_DataWriter_Option->_validateOptionValuePreSave('1')
      #4 /library/XenForo/DataWriter.php(1460): XenForo_DataWriter_Option->_preSave()
      #5 /library/XenForo/DataWriter.php(1399): XenForo_DataWriter->preSave()
      #6 /library/XenForo/Model/Option.php(572): XenForo_DataWriter->save()
      #7 /library/vw/XenForo/Model/Option.php(162): XenForo_Model_Option->updateOptions(Array)
      #8 /library/XenForo/ControllerAdmin/Option.php(179): vw_XenForo_Model_Option->updateOptions(Array)
      #9 /library/XenForo/FrontController.php(351): XenForo_ControllerAdmin_Option->actionSave()
      #10 /library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
      #11 /admin.php(13): XenForo_FrontController->run()
      #12 {main}
      Request State
      array(3) {
        ["url"] => string(65) "https://site.com/admin.php?options/save/vw_server_settings"
        ["_GET"] => array(1) {
          ["options/save/vw_server_settings"] => string(0) ""
        }
        ["_POST"] => array(3) {
          ["options"] => array(12) {
            ["vw_enabled"] => string(1) "1"
            ["vw_bburl"] => string(24) "https://site.com/"
            ["vw_cdn_url"] => string(0) ""
            ["vw_filename"] => string(4) "wiki"
            ["vw_protocol"] => string(1) "2"
            ["vw_titlevar"] => string(5) "title"
            ["vw_spaces"] => string(1) "0"
            ["vw_seo"] => string(1) "1"
            ["vw_languageid"] => string(1) "1"
            ["vw_wiki_name"] => string(4) "Wiki"
            ["vw_apikey"] => string(16) "xxx"
            ["vw_cache_life"] => string(1) "7"
          }
          ["options_listed"] => array(12) {
            [0] => string(10) "vw_enabled"
            [1] => string(8) "vw_bburl"
            [2] => string(10) "vw_cdn_url"
            [3] => string(11) "vw_filename"
            [4] => string(11) "vw_protocol"
            [5] => string(11) "vw_titlevar"
            [6] => string(9) "vw_spaces"
            [7] => string(6) "vw_seo"
            [8] => string(13) "vw_languageid"
            [9] => string(12) "vw_wiki_name"
            [10] => string(9) "vw_apikey"
            [11] => string(13) "vw_cache_life"
          }
          ["_xfToken"] => string(8) "********"
        }
      }
    Issue Details
    Issue Number 4913
    Issue Type Bug
    Project VaultWiki 4.x Series
    Category Admin Panel
    Status Duplicate
    Priority 4 - Warnings / Script Errors
    Affected Version 4.0.16
    Fixed Version (none)
    Milestone (none)
    Software DependencyXenForo 1.x
    License TypePaid
    Users able to reproduce bug 0
    Users unable to reproduce bug 0
    Attachments 0
    Assigned Users (none)
    Tags (none)




    1. February 13, 2017 8:31 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      It will not save options.
      Reply Reply
    2. February 14, 2017 8:18 AM
      pegasus pegasus is offline
      VaultWiki Team
      It will save; this is an E_NOTICE. If you're having trouble, you probably have XenForo debug mode turned on.

      The only other case where this would fail to save is if you already have a real directory /wiki. In this case, the /wiki route will fail to overwrite it, so the setting will be rejected.

      Same as:
      https://www.vaultwiki.org/issues/4911/
      https://www.vaultwiki.org/issues/4903/
      Reply Reply
    3. February 14, 2017 9:48 AM
      Alfa1 Alfa1 is offline
      Distinguished Member
      I cant get it to save and have no wiki directory.
      Reply Reply
    4. February 14, 2017 10:37 AM
      pegasus pegasus is offline
      VaultWiki Team
      Which specific setting is unchanged after the save processes? If multiple settings were altered but no settings are being saved, check the browser network activity when you hit the save button. If an unusual redirect is occurring, this may be a server configuration issue.

      I have seen similar issues occur when XenForo's base URL is set to http, but the web server has a rule that redirects all http to https. In that case, the web server redirects http to https before a POST can be received by PHP. Usually this kind of issue affects more than just one settings page, or multiple panels in the wiki cp. Are you able to change settings on other setting pages? If not, there is probably a problem with your server configuration.
      Reply Reply
    5. February 15, 2017 2:42 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      admin.php?options/list/vw_server_settings

      If I change 'Use Friendly Wiki URLs' then I get the above error and nothing is saved.
      All other options work.
      Reply Reply
    6. February 15, 2017 3:32 PM
      pegasus pegasus is offline
      VaultWiki Team
      The above error is logged or the above error is shown to you upon saving? If the above error is shown to you then you need to disable debug mode.

      There are only two ways this setting will give you an "invalid option value" error, which prevents it from saving:
      1. The wiki route was a blank value as of the last save, and you are disabling friendly URLs. You must save a wiki route first.
      2. If you are turning on friendly URLs, or changing the friendly type, and the last-saved wiki route matches a real directory.
      Reply Reply
    7. February 15, 2017 6:25 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      The above error is shown to me and logged.
      I am enabling friendly URLS. I am settign it to: /wiki/Prefix:Article
      There is no /wiki/ directory.
      Debug mode is on for my IP as I need this multiple times a day.
      Reply Reply
    8. February 16, 2017 9:18 AM
      pegasus pegasus is offline
      VaultWiki Team
      If the error is shown to you, then the save action never completes. That is the design of debug mode. VaultWiki is not refusing your setting choice, as you suggested in your earlier posts.

      When the error is an E_NOTICE, changing the debug mode true/false state in the config file is usually easier and faster than making file edits to VaultWiki files, especially if it's to save a setting that you will only change one time. The file edit to fix the error itself is in library/vw/XenForo/Option/Seo.php. Find:
      Code:
      $settings = array('vw_filename' => $filename);
      Before it, add:
      Code:
      $filename = vw_XenForo_Model::fetch('XenForo_Model_Option')->vwGetUpdatedOption('vw_filename');
      From what you have told me there is no reason that VaultWiki will reject the setting value you have chosen.
      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 7:34 AM.
    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.