Project

General

Profile

Actions

Bug #14795

closed

JS Error with JSMENU

Added by Bernhard Kraft almost 19 years ago. Updated almost 18 years ago.

Status:
Closed
Priority:
Should have
Category:
Frontend
Target version:
-
Start date:
2005-06-06
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
3.8.0
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

When no <base> tag is set in a page containing a JSMENU then an JS Error occurs in Firefox 1.0.3 when selecting a select-box entry.
The line in question is:
if (document.getElementsByTagName("base")[0].href != "") {

The problem is if there is no Tag named "base" then the .href operator will fail.

I attached a solution as unified diff .

(issue imported from #M1167)


Files

01__jserror_fix_jsfunc_menu_js.patch (680 Bytes) 01__jserror_fix_jsfunc_menu_js.patch Administrator Admin, 2005-06-06 15:16
jsfunc.menu.js (4.28 KB) jsfunc.menu.js Administrator Admin, 2005-07-07 20:24
T3D__09-11-09-20-38-z.t3d (1.77 KB) T3D__09-11-09-20-38-z.t3d Administrator Admin, 2005-11-09 09:20
jsfunc.menu.js.new (4.16 KB) jsfunc.menu.js.new Administrator Admin, 2005-11-09 14:46

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #14757: JSmenu with RealURL is broken (jsfunc.menu.js)ClosedBenni Mack2005-05-27

Actions
Actions #1

Updated by Zach Davis over 18 years ago

I think you're missing a closing paranthesis on the IF statement in the diff.

--Zach

Actions #2

Updated by Thomas Hempel over 18 years ago

Thanks a lot... It works fine for me. :-) (I used the complete jsfunc.menu.js and not the patch)

Greets,
Thomas

Actions #3

Updated by Sebastian Kurfuerst over 18 years ago

Hi,
is it possible for you to create a test pagetree export file to validate the patch?
Greets, Sebastian

Actions #4

Updated by Thomas Hempel over 18 years ago

Here is a very simple pagetree for testing

Actions #5

Updated by Sebastian Kurfuerst over 18 years ago

I just checked the code, and IMO, the bug doesn't exist anymore in CVS. I have uploaded a new jsfunc.menu.js, please verify this.

Greets, Sebastian

Actions #6

Updated by Thomas Hempel over 18 years ago

Hi,
I can confirm, that the JSMENU works with the current CVS version of the core.

Greets,
Thomas

Actions #7

Updated by Sebastian Kurfuerst over 18 years ago

this bug was already resolved in CVS.

Actions

Also available in: Atom PDF