Hi,
Will need to take a closer look to this. You know exactly what specific div is not closed?
Thanks
-Rui
No, I don.t. Basically, your plugin added an extra </div> which started out your code, so it really was trying to close something that doesn’t exist.
I see, thanks. Guess I found this line that doesn’t make sense and it’s probably causing that.
$output .= '</div></ul>';
It’s the line 116 in the file mobile-menu/includes/class-wp-mobile-menu-core.php
Or replace that file by this one
https://www.dropbox.com/s/9xsb56ce3e08gj8/class-wp-mobile-menu-core.php?dl=0
Can you give it a try?
Thanks
-Rui Guerreiro
-
This reply was modified 8 years, 9 months ago by
Rui Guerreiro. Reason: added a file link
You mean delete it, right?
Did that, but still getting lots of validation errors. Things like:
- No li element in scope but a li end tag seen.
- Element ul not allowed as child of element ul in this context. (Suppressing further errors from this subtree.)
- No li element in scope but a li end tag seen.
These comments existed previously.
I just noticed this for each and every menu item in the code:
<li class="menu-item menu-item-type-custom menu-item-object-custom menu-item-7911"><a title="Acne Essentials 2-Step System" href="http://vps30689.inmotionhosting.com/~myclar5/product/claritymd-2-step-system/" class="">ClarityMD 2-Step System</a></li></li>
That explains the last bullet point from the list above. It’s adding an extra to each and every link somehow.
Thanks. Manage to replicate that in my dev server.
replace the file class-wp-mobile-menu-walker-nav-menu.php located in mobile-menu/includes/ by this one in the link below.
https://www.dropbox.com/s/bbxe38ibyxs4t5o/class-wp-mobile-menu-walker-nav-menu.php?dl=0
-Rui
Yes, that seemed to have helped a lot. Almost there and thanks for the assistance so far.
One more nesting error. Seems this isn’t closed either:
<div class="mob-menu-header-holder mobmenu" > <div class="mobmenul-container"><a href="#" class="mobmenu-left-bt"><i class="mob-icon-menu mob-menu-icon"></i><i class="mob-icon-cancel mob-cancel-button"></i></a></div><div class="mob-menu-logo-holder"><a href="http://vps30689.inmotionhosting.com/~myclar5" class="headertext">ClarityMD Official Site</a></div></div></ul></div>
Maybe line 116 was meant to be $output .= '<div><ul>';
Actually, I did that and the errors went away!
However….
C’mon, you didn’t really think we’d be finished?
I see a new error by doing that. It is:
Element div not allowed as child of element ul in this context. (Suppressing further errors from this subtree.)
From line 1042, column 10; to line 1042, column 54
Huum that code doesn’t seem to be from WP Mobile Menu. I don’t have any <ul> like that in the code, mines always have classes or id’s.
Can you try to disable the plugin to see if that html it’s still there in the source?
Also can you send me an email to [support AT wpmobilemenu DOT com]
so I can ask some things I need in private.
Thanks
-Rui
I just turned it off and then ran the HTML validator again. The issues went away. So it is the plugin. Sorry.
I’ll email you in private shortly.
This situation was sorted.
-Rui Guerreiro