MyBB Community Forums

Full Version: Quick edit function working intermittently
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I am having an absurd issue with the quick edit / quick reply function on MyBB 1.8.2. with my new theme.

Issue one: the quick reply spinner keeps spinning when I post a reply using quick reply; the post shows in the thread but the quick reply textarea still has text in it and the spinner spins until I refresh the page. 

I looked in the console log and the error message is 


Uncaught TypeError: Cannot set property 'display' of undefined 

The referred line is the head tag..... 

I have checked my html and it is correct; there is an error in the HTML verification but that is due to tapatalk and the same error is present on the MyBB theme where the quickreply works fine and the quick edit work fine.

Issue two: the quick edit is randomly broken; I have threads where on the whole thread the quick edit does not work; on other threads only the ones on the first page are broken, whilst subsequent pages work fine, on other threads the entire thread the quick edit works.

Theme details:  the theme is built in HTML5 and the postbit is very heavily customised; its a port of my 1.6 theme to MyBB 1.8  

I am currently using the default quick reply and NO plugins that I would expect to affect the editor.  

Settings:  
Editor style: Mybb
User CP settings - show MyBB formatting options ticked as yes, partial set as no, all options available in the editor. Partial mode is set to none.


I am using Opera Browser and I have checked this issue as an admin, a moderator and a user. All the same issue. Also tested in Chrome - same issue. I can provide a link to the board on request if this issue is not already known....
Yeah the quick reply and quick edit feature misbehave depending on theme changes. I haven't got to the root of the issue but I assume you use xThreads? I do too.
It even did it pre XThreads and pre tapatalk. 

I have no XThreads templates installed, but I am using template conditionals, though there are NO ifs in the postbit or showthread, it's barebones.  I have taken out the firstpost variable added by XThreads, I have checked the HTML a million times.....

What baffles me is why on page one of a thread quick edit doesn't work - and then on page two it does, so it can't be the HTML of the postbit - it must be  something to do with the pagination? But then I have other threads where the thing works on all posts on all pages. 

What is constant as an issue is the quick reply, as in it hangs, and I am (in my despair) using the standard MyBB template for quick reply and it still hangs.

I cannot use a theme where things work sometimes; if I have to I will remove the quick edit function from the postbits (a damn shame) but the quick reply issue is really unacceptable. I can't remove quick reply.

If you would like a link to look at it I will PM it to you.

On page load this issue is showing for the quickreply js (see screenshots)

Uninstalled XThreads - STILL happening. Do I have to use the exact class names in my theme templates as in the default? If so - what a crock of orange.
(2014-11-19, 04:44 PM)Leefish Wrote: [ -> ]Do I have to use the exact class names in my theme templates as in the default? If so - what a crock of orange.

Well yes, it always has been like that, the JS needs to know to which selectors should the script be 'attached', there is no way to avoid that unless you edit the scripts too.
When I say exact names, I mean on every single aspect; obviously on those classes that the js needs the class needs to be the same. But should it really matter if my postbit buttons holder is called "postbitstuff" or "thatthing" apart from semantics?

However as I said in my previous post, the issue is NOT the postbit, or the classes.

The issue is that somehow that sometimes the posts on the first page of a thread do NOT fire the quick edit and that the quickreply can be best described as wonky (despite being the exact template as MyBB default).

As I said to Omar, I can PM you the details of the board url etc if you would like me to.
Sorry for the delay. I will see if I can find the issue within my board and then come back to you Leefish. Indeed it seems something dirty is around the templates. It doesn't seem to be an matter of classes or id's but the order of those.
Bumping this as the issue is still not solved.

Its a bigger issue than it seems as the random failure on quick edit is ALSO breaking the inline moderation as all js loading after the break fails.

The ISSUE:

I go to a post and try to click on inline moderation checkbox; the number does not show in the count next to the inline moderation dropdown. I reload the page and I check console and I get this

Uncaught TypeError: Cannot read property 'replace' of undefined

Referring to line 177 in thread js.  See the screenshot.

I edited the postbit edit button to separate out the quick and full edit (its how I like it) - and I would accept that it is my problem if it happened all the time, but it doesnt. Is it some sort of race condition?

The BIG Issue? It doesn't happen on all threads; only some threads and it NEVER happens on the default theme.
since I know what theme/forum leefish is referring to, if I go to my debugger console in firefox, click on quick edit and then view the debugger window, it shows this:

Error loading source:
loadSourceError
The resources failing to load are a stylesheet as the theme cache is buggy; I deleted the stylesheet and the issue - that the thread.js is throwing an error on line 177 persists. You can see this in the Firefox console.

This whole issue is absurd. As the inline moderation works sometimes then something else is the issue.

Please can a MyBB developer give some help here?
Well, I tried to provide you help but you ignored it. The problem is that the id variable stores undefined in JS => element with .post_body class doesn't have ID in one of your templates. You can send me ACP access so I can have a quick look.
Pages: 1 2