Problems with loading when modifying post

Rob Novitsky

  • Posts: 12
Problems with loading when modifying post
« on April 23rd, 2014, 07:20 AM »
Hi guys,

I set up wedge for the first time today and everything works great, except when I modify a post. The problem is that after I click "save", a "loading" box appears, and it doesn't stop. It continues to say "loading." So when I finally go back and refresh the post, it seems to have modified anyway...but this is annoying and shouldn't be happening.

I noticed that this sometimes happens when simply posting something or replying, but mostly when I modify something.

Any help would be greatly appreciated. This forum is awesome and I thank you for the hard work.

Alanthar

  • Congratulations. :)
  • Posts: 22

Nao

  • Dadman with a boy
  • Posts: 16,062
Re: Problems with loading when modifying post
« Reply #2, on April 23rd, 2014, 03:48 PM »
This is either a JavaScript problem or a malformed XML response. Check for js problems first. What does your developer console say?

Rob Novitsky

  • Posts: 12

Nao

  • Dadman with a boy
  • Posts: 16,062
Re: Problems with loading when modifying post
« Reply #4, on April 28th, 2014, 11:31 PM »
Hmmm... Who wrote this plugin, already? I think it was @Dragooon, but he's too busy to look into the bugs of his plugins (same with the mass-attach plugin), so... I guess I'll still wait for him to determine whether he wants to fix it or not.

If anyone knows how to fix this and can save me the time to look into it, please share!

CerealGuy

  • Posts: 343
Re: Problems with loading when modifying post
« Reply #7, on April 29th, 2014, 12:17 AM »Last edited on April 29th, 2014, 12:29 AM
Same error just occured on wedge. Message was send correctly but i stucked on the screen with the loading animation.
That post: http://wedge.org/pub/plugins/support/8600/add_js-ul/msg295634/#msg295634
Quote
reflow: 9.63ms
POST http://wedge.org/pub/bugs/do/post2/ [HTTP/1.1 302 Moved Temporarily 5181ms]
reflow: 0.12ms function o.fn[d]/<, jquery.min.js line 4
reflow: 0.5ms function o.fn[d]/<, jquery.min.js line 4
reflow: 1.08ms function h, jquery.min.js line 3
reflow: 0.96ms function xb, jquery.min.js line 3
reflow: 1ms function h, jquery.min.js line 3
reflow: 0.87ms function xb, jquery.min.js line 3
Unknown property 'box-sizing'.  Declaration dropped. post
reflow: 0.1ms
reflow: 0.4ms
GET http://wedge.org/pub/bugs/8588/problems-with-loading-when-modifying-post/msg295637/#msg295637 [HTTP/1.1 200 OK 4141ms]
EDIT: Check locally, bug only appears with Ajax QR enabled.

Nao

  • Dadman with a boy
  • Posts: 16,062
Re: Problems with loading when modifying post
« Reply #8, on April 29th, 2014, 12:32 AM »
What?
You said quick edit was broken. You didn't mention quick reply... :-/

Anyway, yes, Ajax quick reply is broken. I've narrowed it down to the $.post() call that requests a full copy of the page.
It toggles infinite mode, meaning Wedge should internally load the index template even on an Ajax query, but it doesn't... :-/ As a result, an error is sent back to JS ("can't find template_page_index function"), instead of the actual page content, and the plugin doesn't account for error pages. Hmmmm........

I'm a bit stuck at this point. And tired!! I'll leave the rest up to @live627.

Note: much of ajaxqr.js is re-using the infinite scroll code from Wedge itself, but lacks any copyright information. (Or, AFAICR, an authorization from me.) Not great.. on a live plugin :-/

CerealGuy

  • Posts: 343
Re: Problems with loading when modifying post
« Reply #9, on April 29th, 2014, 12:35 AM »
I just had a short look on it, too tired for now but why is he using a class? Will have a look on it tomorrow (damn its already "today" oO)...

Nao

  • Dadman with a boy
  • Posts: 16,062
Re: Problems with loading when modifying post
« Reply #10, on April 29th, 2014, 12:40 AM »
His function is mostly based off an old version of the infinite post loader. I did some changes to it over time, so maybe the 'old' version isn't compatible with it, but I doubt it.

CerealGuy

  • Posts: 343
Re: Problems with loading when modifying post
« Reply #11, on April 29th, 2014, 08:11 PM »
Is there any use for if its loaded when you are not on Post Display (full editor etc.?!). I think not but perhaps i miss something... But if theres not, why dont move from "load_theme" hook to "display_message_list"? That one is already used and we would have one hook less.
Just sayin not finished with "understanding" the plugin.

Nao

  • Dadman with a boy
  • Posts: 16,062
Re: Problems with loading when modifying post
« Reply #12, on April 30th, 2014, 06:53 PM »
Okay, I just saw John made a pull request on the plugin repo (why the hell am I not getting a github.com notification for these..?!), and I'm testing it here.

Hmm... Yep, still not working. Instead of just crashing, it crashes and gives me the error message (i.e. call to undfined template_page_index function), which only happens if INFINITE is not set, and in this case it's set, so... I dunno. I'll have a further look at it.
Re: Problems with loading when modifying post
« Reply #13, on June 15th, 2014, 01:01 AM »
Anyone interested in having this fixed, or fixing it themselves..?

John, are you sworn to SMF now and leaving Wedge? Need to know if I should take over your plugins or something...