Skip to main content

Bug Tracker

Side navigation

#3941 closed bug (wontfix)

Opened January 21, 2009 05:50PM UTC

Closed January 27, 2009 07:08PM UTC

jQuery 1.3.0 and current SVN pack versions $('select').val() returns undefined (minified version is OK)

Reported by: beat Owned by:
Priority: critical Milestone: 1.3.2
Component: core Version: 1.3.1
Keywords: Cc:
Blocked by: Blocking:
Description

The packed version val() method seems broken. Following code (with "select" and with "#mysel" selectors works fine in packed and in minified versions, but not in packed version of 1.3.0-release and 1.3.1-pre versions (today's from SVN).

minimal code to reproduce bug:

<!DOCTYPE html PUBLIC "-W3CDTD XHTML 1.0 TransitionalEN" "http:www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<script type="text/javascript" src="http://localhost/jquery-1.3.0/jquery.pack.js"></script>

<script type="text/javascript"><!--

jQuery.noConflict();

--></script>

<script type="text/javascript"><!--

jQuery(document).ready(function($){

alert($('select').val());

});

--></script>

</head>

<body>

<form>

<select name="mysel" id="mysel" class="inputbox">

<option value="A" selected="selected">choice A</option>

<option value="B">choice B</option>

</select>

</form>

</body>

</html>

It looks like either packer is broken, OR there is a missing ";" or something else somewhere.

VERY interestingly, packing with variable shrinking the SVN jquery-1.3.1-pre using this online tool:

http://dean.edwards.name/packer/

produces a working packed version.

Attachments (0)
Change History (3)

Changed January 21, 2009 05:51PM UTC by beat comment:1

The produced packed version is only 100 bytes bigger than the one produced by jQuer'y "make" packer used, but at least works.

Changed January 22, 2009 01:30AM UTC by dz comment:2

Pack isn't supported any longer, and I think won't be included with the 1.3.1 release

Changed January 27, 2009 07:08PM UTC by john comment:3

component: unfilledcore
milestone: 1.3.11.3.2
resolution: → wontfix
status: newclosed
version: 1.31.3.1

Yeah, we no longer support packed scripts - pleased use minification instead.