1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Not a Bug <noscript> users can not write content

Discussion in 'Resolved Bug Reports' started by Marcus, Nov 14, 2013.

  1. Marcus

    Marcus Well-Known Member

    Users using firefox noscript addon who do not allow ajax.googleapi.com can not write content.

    In my settings I tell xenforo to fetch javascript from google.
  2. Chris D

    Chris D XenForo Developer Staff Member

    What do you mean by "write content"?

    The site should work with Javascript disabled.
  3. Chris D

    Chris D XenForo Developer Staff Member

    I've just tried my local dev board on Firefox with Google as the jQuery source with that add-on... what a lifeless, boring experience. Why would anyone even want to surf a website like that?

    Anyway, it works... so you may need to be a little bit more specific about what is going wrong, if there are any bugs, what the exact behaviour is and under what conditions.

    Either way, if the site works fine with jQuery and fine with JavaScript disabled via official methods (in Chrome you can disable javascript on a per-site basis) then it is hardly a bug if it doesn't work when a particular browser extension is used.
    MattW likes this.
  4. Freddie Agricola

    Freddie Agricola Active Member

    For the record, Noscript is primarily a defense against unfriendly websites - you typically whitelist sites you wish to have a relationship to.
    Chris D likes this.
  5. Marcus

    Marcus Well-Known Member

    The report came from one of my users. My site and scripts on it was whitelisted. The newly added ajax.googleapi.xx was not approved.
  6. Chris D

    Chris D XenForo Developer Staff Member

    You're still not really being clear. And I still don't understand how this is a XenForo bug.

    It sounds like he just needs to white list the Google address.
  7. Marcus

    Marcus Well-Known Member

    If the user whitelists the google address, everything works. However if he doesn't, from my understanding the javascript editor is displayed (grayed out), and not the plain editor.

    So here is the bug from my understanding: The not working javascript editor is displayed to the user which browser does not have the resources to display it (the browser does not accept scripts from ajax.googleapi.xx)

    I am not familiar on how noscript works and I also do not know which routines the javascript editor needs, or when the editor is displayed and when not. Also I do not insist on whether this is a bug or not, I wrote this report to keep the developers informed - if there would be a higher bug count in this forum I would not want the devs worry about this little problem obviously.
  8. MattW

    MattW Well-Known Member

    I had the same issue when users were trying to access my site over SSL, when I was serving the JS directory over HTTP CDN. None of the JS functions worked.

    I told members to stop using HTTPS, as of course anything needed the js files isn't going to work if the browser can't access them or is blocking them.
  9. Chris D

    Chris D XenForo Developer Staff Member

    That's fine. The bug report just seemed really vague so I wasn't able to really work out exactly what the problem was, but the additional explanation gave me something to try and reproduce: and I can't reproduce it.

    XenForo has a built in fall back where jQuery is concerned, so if your jQuery source is not local, it adds this:

    <script>if (!window.jQuery) { document.write('<scr'+'ipt type="text/javascript" src="js/jquery/jquery-1.10.2.min.js"><\/scr'+'ipt>'); }</script>
    I believe if jQuery is not detected as a result of the CDN version being blocked, it uses Javascript to re-add back the local version.

    I have just installed NoBlock and whitelisted localhost and set the Google address as untrusted and the end result is everything is working fine, thanks to the fallback above.

    So with that in mind:

    1) Have you made any changes to your page_container_js_head template?
    2) Is your local jQuery source still available? e.g. js/jquery/jquery-1.10.2.min.js
    Marcus likes this.
  10. Marcus

    Marcus Well-Known Member

    My local jquery source is not available. That caused the problem. Chris, you are awesome!
    Chris D likes this.

Share This Page