Can't move/edit/delete widgets (2.6 & 2.7 RC)

Topics: Controls
Oct 22, 2012 at 3:00 PM
Edited Oct 22, 2012 at 3:01 PM

I have tried installing the web version of 2.6 and 2.7 RC1 (Windows Web Server 2008 R2) and can't move, edit or delete the widgets when logged in as admin.

I have also tried turning off 'Enable Optimization'. 

Fiddler is showing 404 for the following files:

http://xxx/Scripts/Header/01-jquery.js
http://xxx/Scripts/Header/blog.js
http://xxx/Scripts/02-jquery.cookie.js
http://xxx/Scripts/04-jquery-jtemplates.js
http://xxx/Scripts/05-json2.js

Which I assume is the cause but would expect this stuff to just work with a clean install?

Oct 22, 2012 at 3:12 PM
Edited Oct 22, 2012 at 3:13 PM

I can't duplicate your issue on a clean install of 2.6.0.5 and 2.7 RC1. I can successfully move, edit, or delete widgets when logged in as admin. What is "Fiddler" that you mentioned is showing 404?

Oct 22, 2012 at 3:17 PM

Fiddler (http://www.fiddlertool.com/) is a very popular utility for tracing http traffic, I just used it to check all the requests to the blog application.

I am stuck as to how to fix this then at the moment. Frustrating as I have been using older versions of this Blog platform for years and would love to upgrade. 

Coordinator
Oct 22, 2012 at 3:28 PM

Do you actually have these scripts on the server? I've seen more than once people FTP files and didn't notice some failed to upload. What if you just enter script path in the browser address bar - do you have it served?

Oct 22, 2012 at 3:33 PM

Yes they're definitely there - It's a dedicated server so I RDP'ed in and download the zip from the server itself.

If I try just the script path on its own it doesn't work, nor would I expect it to having seen in Fiddler it's not downloading.

All I can guess is that somehow the blog engine app is intercepting requests for these scripts (perhaps this is related to the feature which can bundle them all up in one request when the optimization is turned on?) and failing to then server them up.

Or there is something wrong with my IIS7 setup, but everything else seems OK with blogengine and my other sites.

Coordinator
Oct 22, 2012 at 4:13 PM

With optimization off, blogengine just let IIS serve scripts/styles as is. Do you have all scripts failing to serve or only some of them? What about admin panel scripts - do they work fine? That would be very odd if some scripts loaded fine and others fail. Can you share public site address so I can look at it?

Oct 22, 2012 at 4:13 PM

Can you access the Admin panel? If so, try disabling Optimization and HTTP Compression.

Oct 22, 2012 at 5:11 PM

Yes the admin panel is working fine and it's the same issue with compression and optimization turned off.

Oct 22, 2012 at 5:35 PM

What theme are you using?

Oct 22, 2012 at 5:43 PM

The default, I literally just unzipped the latest 2.7 RC and made no changes.

Oct 22, 2012 at 7:20 PM
rtur wrote:

Can you share public site address so I can look at it?

I agree with rtur... can you share a public link to it? Also, what browser are you using?

Oct 22, 2012 at 9:06 PM

Sure - it's:
http://blog.qvsource.com/

Sorry - I missed this earlier question! 

Coordinator
Oct 23, 2012 at 3:19 AM

Ok, so none of the scripts added by URL rewrite from /scripts and /scripts/header loaded for you. I see you running in sub-domain - are you using GoDaddy as your host? We ofter run into issues with their rewrite engine. Anyway, first try edit this file: /themes/standard/site.master to include one of the javascript files directly. Your header section should look like this:

<head runat="server" profile="http://gmpg.org/xfn/11">
    <link rel="shortcut icon" href="~/pics/blogengine.ico" type="image/x-icon"/>
    <link rel="stylesheet" href="style-min.css" type="text/css" />
    <script type="text/javascript" src="<%#Utils.ApplicationRelativeWebRoot %>admin/admin.js"></script>
</head>

If that admin.js gets loaded we might look at work around this issue.

Oct 23, 2012 at 10:04 AM

Thanks for the replies.

OK I have added that, admin.js seems to be downloading OK but I still can't manage the widgets.

We are not using GoDaddy no - it's a hosted dedicated server which we have root access to so I would assume it is using the standard ASP.NET 4/IIS7 functionality.

Should I try adding manual references to other javascript files? And is this not a theme specific solution which might mean I also need to figure out what scripts to add manually for other themes I might use?

Oct 23, 2012 at 3:50 PM

I'm seeing all of the scripts load properly when I visit your page.

<script type="text/javascript" src="/Scripts/Header/01-jquery.js"></script>
<script type="text/javascript" src="/Scripts/Header/blog.js"></script>
<script type="text/javascript" src="/Scripts/02-jquery.cookie.js" defer="defer" async="async"></script>
<script type="text/javascript" src="/Scripts/04-jquery-jtemplates.js" defer="defer" async="async"></script>
<script type="text/javascript" src="/Scripts/05-json2.js" defer="defer" async="async"></script>

Again, what browser are you using?

Oct 23, 2012 at 4:08 PM

Sorrry - I'm using Chrome. And the following all seem to be failing still.

/Scripts/Header/01-jquery.js
/Scripts/Header/blog.js
/Scripts/04-jquery-jtemplates.js
/Scripts/02-jquery.cookie.js
/Scripts/05-json2.js

Have tried IE too and it looks like the same issue. Not sure why the browser would make a difference anyway as this looks like a server side issue doesn't it?

Oct 23, 2012 at 5:15 PM

Logically thinking, yes, it does look like a server side issue, but that doesn't explain why I can see it and you can't. I've now tried it with IE7/8/ and 9, Opera, Chrome, and FireFox and I always see the scripts loading, so I'm thinking more along the lines of something is prohibiting you seeing it on your PC or maybe your network, such as a firewall or proxy server.

Coordinator
Oct 23, 2012 at 5:39 PM
MGD_King wrote:

Logically thinking, yes, it does look like a server side issue, but that doesn't explain why I can see it and you can't. I've now tried it with IE7/8/ and 9, Opera, Chrome, and FireFox and I always see the scripts loading, so I'm thinking more along the lines of something is prohibiting you seeing it on your PC or maybe your network, such as a firewall or proxy server.

You probably just see page loading and looking fine with script links added to the header in source view, but if you check it with FireBug or alike all JS files are 404ed.

Not sure why this is happening, could have something to do with URL rewrite module not installed, sub-domain somehow getting in the way or something else missing in IIS install. I just can't reproduce it with my IIS7. Even IIS6 runs it fine with optimization off. You can still try to add all failing scripts to the theme header same way you did with admin.js (which you don't need, it was for testing only). May be installing asp.net mvc 3 (or 4) can help, BE is not MVC project but it updates IIS with some additional components that may not be installed otherwise. And if you have full access to the server try to check logs for application errors, may be something will show up there.

Oct 23, 2012 at 6:17 PM
rtur wrote:

You probably just see page loading and looking fine with script links added to the header in source view, but if you check it with FireBug or alike all JS files are 404ed.

You are correct. I can't view the code of the .JS files.

Oct 23, 2012 at 9:41 PM

Thanks for your help and suggestions. I am - or would be - really surprised I am the only one having this issue - I will try to install MVC4 perhaps.

Also if any of you would be willing/interested in taking a look at my setup over a screen share I would also happily set that up.

Oct 23, 2012 at 9:56 PM

Have older versions of BE worked on this server?

Coordinator
Oct 23, 2012 at 9:58 PM
cbplex wrote:

.. I am - or would be - really surprised I am the only one having this issue ....

That's what I'm warring about. As I said, I can't reproduce this locally or on my host. But if you have FTP account that I can use to upload files, I could add some debugging trace and hopefully track down where it breaks. If so, let me know (you can send me a message using CodePlex account).

Oct 24, 2012 at 8:06 AM

Hi rtur,

I don't have FTP setup unfortunately but if you would be willing to send me a zip folder I could upload it manually myself.

Coordinator
Oct 24, 2012 at 8:23 PM

Will do.

Oct 29, 2012 at 10:27 AM

Hi rtur - Thanks, I have sent you a DM.

Coordinator
Oct 29, 2012 at 5:57 PM

I looked at it and with optimization off there is no code that runs on back-end while serving JavaScript. There is nothing to trace - after BE adds links to the page header it does nothing else.

One thing I noticed about working link you added to the page is that it has no "/" in front: src="admin/admin.js"

Links that don't work start with "/": src="/Scripts/05-json2.js"

Check if that makes any difference. Add forward dash and see if it breaks working link. Also try to add manually link to the file within "scripts" folder to make sure this folder is not somehow "special" (permissions etc.)

Nov 1, 2012 at 9:40 AM

Hi rtur,

I think the pattern is that scripts in the /Scripts folder don't work and scripts in /admin do work - rather than it being to do with a leading '/' symbol.

For example you can just try the full path to a script file in the address bar, e.g.:

http://blog.qvsource.com/Scripts/02-jquery.cookie.js

And it fails.

Nov 1, 2012 at 9:58 AM

I think I have found the cause, a bit of googling for 'iis 7 scripts folder 404' returned this post:
http://forums.iis.net/p/1191833/2030484.aspx

And it seems to be because I have another piece of software (QlikView) installed which is somehow hijacking the Scripts folder - I don't see how because it's on a different host name. Unfortunately I can't figure out how to fix this.

However, if I rename my Scripts folder to Scripts2 the 404 issue disappears.

So - is there anyway I can reconfigure BE to use Scripts2 as the folder name without changing the source code and recompiling?! 

Thanks for all your help so far and sorry it was due to something you would never have been able to know :-/