Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET Javascript CSS
I have an issue that only happens when the application is loaded on the IIS web server.
 
When run locally, the problem doesn't occur.
 
The css file and javascript file are in subfolder and linked using relative paths.
 
Running the app on IIS, some of the JavaScript functions don't run, but some do.
 
Running the app on IIS, some of the css is rendered and some are not.
 
For example, my button backgrounds are blue consistently, but some table spacing/padding (?) are not the same as anticipated.
 
Using the same laptop and same browser (IE 9) the locally run app runs all javascript functions and renders all css classes properly.
 
I have no idea how to figure out what could be going on.
 
One other note: the server is locked down so that I cannot connect to it remotely for debugging with VS. I can only copy the files there and remote desktop to it.
 
Thanks,
Posted 29-Aug-12 12:40pm
Edited 30-Aug-12 4:47am
v2
Comments
Sandip.Nascar at 29-Aug-12 18:17pm
   
It seems a caching issue. It often happens after we publish the file to the server.
Try clearing your cache and see.
ARBebopKid at 30-Aug-12 9:46am
   
Unfortunately, that's not it for this case.
 
I can even change the css and see colors change, but something is affecting the table/cell spacing/padding/placement differently on the server.
 
enhzflep at 30-Aug-12 9:59am
   
Then the next thing I would do would be to debug the page. I'd check affected elements 1 by 1, comparing the applied style with those specified in the css. Any browser would work fine, though my first choice would be for Chrome, followed by Opera then IE - but it's likely just personal preference.
F12 - IE
Ctrl-Shift-I - Chrome, Opera
 
Of course, you could always open the page that's stored on the server, save a local copy *using your webbrowser* then compare the saved data with that whih should have been displayed. It should be pretty trivial to isolate exactly which rules/scripts exhibit odd behaviour.
ARBebopKid at 30-Aug-12 10:02am
   
Thanks for the idea. I have now created a flat html copy of the server output and the local output and beginning to compare them line be line.
 
As for browser, the client specified IE as the supported browser, otherwise, IE would be last on my list.
enhzflep at 30-Aug-12 10:16am
   
:Grins:
Yeah, you should find the difference pretty quickly by comparing the files.
The command-line tool "comp" should have the job done in anywhere from seconds to minutes, depending on the number of files in the site.
 
I only mention my preference for the browser to use to do the debugging -
being really comfortable with the Chrome debugging tools - but similarly, find myself using IE only when compelled to by external forces. :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 195
1 ProgramFOX 130
2 Maciej Los 105
3 Sergey Alexandrovich Kryukov 85
4 Afzaal Ahmad Zeeshan 82
0 OriginalGriff 6,564
1 Sergey Alexandrovich Kryukov 6,048
2 DamithSL 5,228
3 Manas Bhardwaj 4,717
4 Maciej Los 4,150


Advertise | Privacy | Mobile
Web03 | 2.8.1411022.1 | Last Updated 30 Aug 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100