Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

WebGL Builds only partially working

Discussion in 'WebGL' started by ATLAS-INTERACTIVE, Sep 27, 2015.

  1. ATLAS-INTERACTIVE

    ATLAS-INTERACTIVE

    Joined:
    Mar 3, 2014
    Posts:
    1,421
    I have posted here a few times about the state of the WebGL builds now and wanted to share my latest issues with it.

    I loaded my build up in IIS (Internet Information Services) in Windows 10, and got it to run locally on every browser. YES!!!!!

    This unfortunately is where the good news stopped.

    After uploading it to a windows-based host run by 1and1, absolutely nothing.

    In Chrome, I managed to pick out these errors:

    Failed to load resource: http://briggsmotors.co.uk/Release/UnityConfig.js
    the server responded with a status of 404 (Not Found)

    Failed to load resource: http://briggsmotors.co.uk/Release/fileloader.js
    the server responded with a status of 404 (Not Found)

    Failed to load resource: http://briggsmotors.co.uk/Release/1ShinyTiles.js
    the server responded with a status of 404 (Not Found)
     
    Reisender likes this.
  2. Reisender

    Reisender

    Joined:
    Jun 26, 2014
    Posts:
    35
    I have the exact same problem, also with 1and1
     
  3. jonas-echterhoff

    jonas-echterhoff

    Unity Technologies

    Joined:
    Aug 18, 2005
    Posts:
    1,666
  4. Reisender

    Reisender

    Joined:
    Jun 26, 2014
    Posts:
    35
    I ended up hosting it at itch.io :/
     
  5. danreesthomas

    danreesthomas

    Joined:
    Dec 15, 2015
    Posts:
    2
    Had the same problem, also with 1&1 but found a solution from reading your posts.

    They must be blocking folders called "Release" for some reason, I copied everything into a folder "Bulid/" and changed every reference to "Release/" in index.html to "Build/" the three .js files are being found now and the player works.

    I had to downgrade to 5.2 to get past a different problem concerning "unknown file compression." The same fix might work for that too seeing as everything was in a "Release/" folder...

    Hope that helps.
     
  6. Reisender

    Reisender

    Joined:
    Jun 26, 2014
    Posts:
    35
    Great! gonna try that! Thanks!!
     
  7. KannanKrish

    KannanKrish

    Joined:
    Jul 28, 2015
    Posts:
    4
    After uploading the game file, you got 404 error means, the file does not exist or not accessible. The solution for that, after your build, completed open build folder check what is the file extension. For me, some files have *.unityweb these files cause the problem. If you are using IIS server(Windows) you need to add web.config file at the index.html location and content is
    <?xml version="1.0" encoding="UTF-8"?>
    <configuration>
    <system.webServer>
    <staticContent>
    <remove fileExtension=".unityweb" />
    <mimeMap fileExtension=".unityweb" mimeType="application/octet-stream" />
    </staticContent>
    </system.webServer>
    </configuration>


    Apache server(Linux) means go to your build folder create .htaccess file.
    If you are using gzip-compression means .htaccess content is
    <IfModule mod_mime.c>
    AddEncoding gzip .unityweb
    </IfModule>


    If you are using brotli-compression means .htaccess content is
    <IfModule mod_mime.c>
    AddEncoding br .unityweb
    </IfModule>

    I think this information will help you guys. I am using Unity 2017.2. If you are using old version *.unityweb maybe differs.

    Thanks
     
  8. Aiursrage2k

    Aiursrage2k

    Joined:
    Nov 1, 2009
    Posts:
    4,835
    I am still having the same issue you would think unity would include this file
     
  9. Marco-Trivellato

    Marco-Trivellato

    Unity Technologies

    Joined:
    Jul 9, 2013
    Posts:
    1,654
    we actually used to generate a .htaccess file. Then stopped because you might use a different server than Apache so we created this page in the docs instead.