Home » Forum
  • If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Announcement

Collapse
No announcement yet.

Javascript issues

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Javascript issues

    Hi

    My site is running fine on my local apache install, but when switching to flyingant I get a ton of javascript errors.

    Is there something I've missed that might cause this?

    Thanks for any pointers.

    Cheers

    Nick

  • #2
    What are the actual errors?
    Javascript runs in the browser, so the web server used should not matter.
    Maybe you use some absolute URLs in the Javascript, which might now be broken if you have moved the site to a new location.

    Comment


    • #3
      Thanks for getting back to me

      There are no absolute urls used in the entire site.

      From firebug the actual error is:

      Code:
      array is not defined
         array.prototype.clean = function(deletevalue) {
      It appears as if the html is being rewritten, for instance in my html I have:

      Code:
      <!DOCTYPE html 
           PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
          "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
      But when served by flyingant as:

      Code:
      <!doctype html 
           public "-//w3c//dtd xhtml 1.0 strict//en"
          "http://www.w3.org/tr/xhtml1/dtd/xhtml1-strict.dtd">
      Actually looking at the source code served by flyingant a lot of uppercase characters are now lower case, for instance I have a function called printKnockoutTemplate, which when served by flyingant appears as printknockouttemplate.

      Also, I don't know if this is related but I don't see the 'flyingant server demo' box although I haven't purchased a license yet.

      Cheers

      Nick

      Comment


      • #4
        What operating system (include version) are you running FlyingAnt on when this occurs? Have you tried other computers/operating systems?

        Also, what browser (and version) are you using?

        We have never seen nor had any reports of such a behaviour. Nor can we quite imagine what could be causing this. At this point, we still suspect there is an external cause, but given the above information we can look further.

        What you're saying would also imply that all the actual content would be converted to lowercase (and should show up as such on the rendered page). Is this the case? If not, it's hard to imagine why only the code is appearing in lowercase as FlyingAnt has no such processing.

        Are you using any authoring application for your HTML? Is it possible that your authoring program is modifying the code to lowercase (because XHTML Strict expects lowercase tag names)? And you perhaps, have multiple copies of the HTML, and you are not looking at the files that you are hosting under the FlyingAnt folder?
        Last edited by Ray; 06-21-2010, 01:44 AM.
        --Ray
        Wrensoft Web Software
        Sydney, Australia
        Zoom Search Engine

        Comment


        • #5
          Thanks Ray

          I've managed to get around this by dumping all my JS to an external file, I then had the same issue where I was loading content into divs using jquery (all content lowercase). Changing the file extension of these html 'partials' from htm to txt seems to have done the trick.

          Thanks again

          Comment

          Working...
          X