No announcement yet.
  • Filter
  • Time
Clear All
new posts

  • #16
    @futlib If you read the original source you'll see that the code you're looking at is a fallback case if the skin has not been loaded.

    Not sure what you tried as far as loading files, but if you place the script includes in your host .html file before the GWT-generated JavaScript includes, there's no way for the load order to be wrong unless the files are just not at the URLs you specify. Check for errors of this kind.


    • #17
      If somehow you are still experiencing this issue, try including the SmartGwtNoScript module, then include the EnterpriseResources module instead of the Enterprise module, and manually adding the script include this eliminates:

      <script src="sc/skins/Enterprise/load_skin.js"/>
      This should appear after the core SmartClient script includes (ISC_Core.js et al). Adjust relative path as needed.

      We still don't have an environment that reproduces this problem but there's just no way it could happen if you take the above approach :)


      • #18
        Strange that removing the doctype actually solves this. Any details on that?

        * What I do is:
        <inherits name="com.smartgwt.debug.SmartGwtDebug" />
        In my HTML I do not load any ISC javascript files.
        In my body I call the module nocache.js and after that I call load_skin.js. All seems to work well.

        * If I call load_skin.js before loading nocache.js, I get this error because ISC is not loaded yet:
        Message: 'isc' is undefined
        Line: 7
        Char: 1
        Code: 0
        Which seems not totally wrong, because ISC is only loaded after the nocache.js call, which loads the app, which loads ISC.


        • #19
          IE related?

          Hi, a little more information .. I have the same problem - it only happens with IE (not FF) when loading one of our applications, and apparently only when certain widgets are loaded.

          We have an application that has a modal dialog for login, which triggers loading of a blank.gif (in FF it is correctly coming out of the skin, Graphite). After login I do notice in Firebug that there is a second request for blank.gif (again in FF correctly loads from Graphite).

          If I trace the requests for "blank.gif" in the server (after clearing the browser cache) with IE I get the following:

          a. Initial load of the application (login screen) requests blank.gif from Graphite.

          b. After login, there is another request for "blank.gif", this time incorrectly from "standard" (../sc/skins/standard/images/blank.gif)

          That might trigger some more thoughts, whilst I endeavour to find the code that is making the second request for "blank.gif".


          • #20
            I tried removing the doctype from my html file and the blank.gif error goes away but then text is really big now.


            • #21
              I am using SmartGWT 2.2 and having the same problem with the red x and the 404. I have created a test project from My gwt.xml file includes:

              	<inherits name="com.smartgwt.SmartGwtNoScript" />
              	<inherits name="com.smartclient.SmartClientDefault"/>
              	<inherits name="com.smartclient.theme.enterprise.Enterprise" />
              and I've included the following javascript files:

              	<script var isomorphicDir="smartgwtsample/sc/"></script>
              	<script src=smartgwtsample/sc/modules/ISC_Core.js?isc_version=8.0.js></script>
              	<script src=smartgwtsample/sc/modules/ISC_Calendar.js?isc_version=8.0.js></script>
              	<script src=smartgwtsample/sc/modules/ISC_ClassBrowser.js?isc_version=8.0.js></script>
              	<script src=smartgwtsample/sc/modules/ISC_Foundation.js?isc_version=8.0.js></script>
              	<script src=smartgwtsample/sc/modules/ISC_Containers.js?isc_version=8.0.js></script>
              	<script src=smartgwtsample/sc/modules/ISC_Grids.js?isc_version=8.0.js></script>
              	<script src=smartgwtsample/sc/modules/ISC_Forms.js?isc_version=8.0.js></script>
              	<script src=smartgwtsample/sc/modules/ISC_DataBinding.js?isc_version=8.0.js></script>
                  <script type="text/javascript" language="javascript" src="smartgwtsample/smartgwtsample.nocache.js"></script>
              When I run in Firefox, I don't get any errors - either on the client or the server. When running in IE, I get the 404 on the request for /smartgwtsample/sc/skins/standard/images/blank.gif. I can see that if I go to with IE it works. Any idea what I am doing wrong?



              • #22
                Try removing inherits name="com.smartclient.SmartClientDefault"


                • #23
                  I did that but the behavior is the same. The gwt.xml is now:

                  <?xml version="1.0" encoding="UTF-8"?>
                  <module rename-to='smartgwtsample'>
                  	<!-- Inherit the core Web Toolkit stuff. -->
                  	<inherits name='' />
                  	<!-- Other module inherits -->
                  	<!--  inherits name='com.smartgwt.SmartGwt' / -->
                  	<inherits name="com.smartgwt.SmartGwtNoScript" />
                  	<inherits name="com.smartclient.theme.enterprise.Enterprise" />
                  	<!-- Specify the app entry point class. -->
                  	<entry-point class='test.client.SmartGWTSample' />
                  	<!-- Specify the paths for translatable code -->
                  	<source path='client' />
                  	<source path='shared' />


                  • #24
                    Do you have a DOCTYPE in your host html? If so, try removing it.


                    • #25
                      I removed it and it seems to be working fine. Thanks for your quick responses.



                      • #26
                        I have the same issue, if I run in dev mode via eclipse after removing doctype and suggested import it is ok but running on the tomcat (our prod env)there are still red X in text boxes.
                        Any ideas?

                        thank you



                        • #27
                          I have the same issue only on IE8.
                          Commenting out
                           <!doctype html>
                          in my html page solved it. But now the HTML text is showing exessively big.

                          Haven't you solved this yet after more than 2 years??


                          • #28
                            There's nothing for us to solve here - no user has ever shown a correct configuration that reproduces the problem, although several bad configurations that can cause the problem have been identified.

                            To summarize this thread: this red X appears because there is a 404 for an image that is part of the skin - the image is missing in the deployment.

                            This can happen because:

                            1. you switched skin incorrectly and you're loading two skins - see QuickStart Guide for correct instructions for switching skin

                            2. very important - you switched your <inherits> in your .gwt.xml file, but did not run a GWT compile or failed to clear the browser cache before retesting. For some browsers it may be necessary to kill all instances of the browser, restart it on a blank page and clear cache before retesting.

                            3. load order issues, where load_skin.js is loaded after the application starts. There are a few different ways to determine if this is your problem, but one is to call Page.getSkinDir() from onModuleLoad(). If the path includes "standard" your load_skin.js file hasn't loaded yet. There are a few known misconfigurations that can cause this:
                            a. you did #1 or #2 above
                            b. incorrect order of <inherits> - skin appears before SmartGWT(Pro/EE/Power) include
                            c. you set the isomorphicDir variable *after* your *.nocache.js include
                            d. you are manually calling SmartClient APIs in JavaScript before load_skin.js loads
                            e. (possibly) you use a very old version of GWT (some user's posts seem to indicate GWT pre-2.0 was not deterministic in load order for IE)

                            If you have the load order issue and you just can't figure out how you're managing to create widgets before load_skin.js loads, then post *complete* details of your .gwt.xml, host .html file and GWT and SmartGWT version (anything less detailed is useless and both the community and Isomorphic are likely to ignore it).

                            If you don't even want to bother troubleshooting how you got the load order wrong, there are "shotgun approaches" guaranteed to fix the problem:

                            1. switch to manual includes for *both* the SmartClient runtime (ISC_Core.js et al) *and* load_skin.js, as explained in post 17.

                            2. don't solve the load order issue, just hand-create a war/standard/images/blank.gif file in your project. You may still experience skin glitches if you do this but it will remove the 404s and red X

                            3. remove the DOCTYPE from your .html file. The image is still missing and 404 errors still occur, but IE stops showing a big red X for the missing image.


                            • #29
                              I am working with SmartGwt 3.0
                              The development console says:
                              SmartClient Version: 8.2/LGPL Development Only (built 2011-12-05)

                              The problem happens in IE8 and not in FF10

                              My project.gwt.xml contains the following code
                                <inherits name="com.smartgwt.SmartGwt"/>
                                <inherits name=""/>
                                <inherits name="com.smartgwt.Drawing"/>
                                <inherits name="com.smartclient.theme.graphite.Graphite"/>
                              my project.html contains the line
                              <script type="text/javascript" language="javascript" src="gwttest/gwttest.nocache.js"></script>
                              the generated gwttest.nocache.js loads the smartgwt javascript files in the following order
                              the problem happens because in the file ISC_Forms.js
                              there is the following line
                              This line is called when loading the ISC_Forms.js. At this time, the skin has not been initialized yet. It will be initialized only after all the smartGwt scripts are initialized.
                              Therefore the blank.gif is not found.

                              If the order was changed so that the skin is loaded immediately after the ISC_Core.js then the problem would be solved

                              Please solve this


                              • #30
                                Thanks for the report, we've addressed that last issue in 8.3d and 8.2p - the change will make it into the nightlies over the next couple of days.