News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Quick editing not working - JS Error

Started by Jade Elizabeth, September 18, 2014, 12:50:05 AM

Previous topic - Next topic

Jade Elizabeth

Issue: When I click quick reply my console says "Uncaught TypeError: Cannot read property 'innerHTML' of null script.js?fin20:484"

It did not start after any mod in particular, or if it did I do not know. The theme I use does not have this issue.

Website: Awesome Crazy


Mods:
1.   Simple Audio Video Embedder   2.6
2.   Tapatalk SMF 2.0 Plugin   4.1.0
3.   Member Color Link   3.1
4.   Auto Merge Double Post   1.5
5.   Pretty URLs   1.1.2
6.   Mentions   1.1.1
7.   New Topic Button   1.0
8.   ENotify   2.0.2
9.   TopicStarter Mod   1.7
10.   Karma Description Mod   2.7.1
11.   Users Online Today   2.1
12.   Social Login   3.1
13.   httpBL   2.5.1
14.   Stop Spammer   2.3.9


Theme: Reseller (no changes yet that I can recall)
Once proud Documentation Writer and Help Squad Leader | Check out my new adult coloring career: Color With Jade/Patreon.

kat

With reference to my reply to your other topic, I just tried the Quick reply, there. Seems fine, for me.

Jade Elizabeth

You clicked this button for quick edit right? ?

I'm wondering if you're on the right theme....does it look like this?

Once proud Documentation Writer and Help Squad Leader | Check out my new adult coloring career: Color With Jade/Patreon.

kat

I had a feeling you meant the inline editor, rather than the quick edit... So, I tried both and they were both fine.

Oddly, though, that icon no longer appears...

Illori

the inline editor is quick edit ;) since it is quick to use to edit.

TehCraw

Got it. It looks like this line in topic.js is referencing an element that doesn't exist.


this.oCurSubjectDiv = document.getElementById('subject_' + this.sCurMessageId.substr(4));


As it turns out, the actual problem is that there's a blank space at the end of the id in this line containing the subject text that the JavaScript is looking for.


<div id="subject_119946 " class="smalltext">


Therefore, remove the trailing space, and that should solve the problem.
Any fool can write code that a computer can understand. Good programmers write code that humans can understand. - Martin Fowler

Jade Elizabeth

Thank you Carvin!! :D

If that's the case then maybe it IS in the original theme. I will let the author know. Thank you so much!!
Once proud Documentation Writer and Help Squad Leader | Check out my new adult coloring career: Color With Jade/Patreon.

TehCraw

You're welcome. Glad to have been a help.
Any fool can write code that a computer can understand. Good programmers write code that humans can understand. - Martin Fowler

Advertisement: