Permalink
Browse files

Bugfix: ":jqmData(ajax='false')" might also match forms, which have n…

…either of "src" or "href". In that case, thisUrl is undefined, and the following replace results in an error.
  • Loading branch information...
1 parent daffc98 commit d99d096ab70cb1a0aaa30edd00186286f34733f9 @oliver-frietsch oliver-frietsch committed Jun 9, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 js/jquery.mobile.navigation.js
View
3 js/jquery.mobile.navigation.js
@@ -495,7 +495,8 @@
if( !$.support.dynamicBaseTag ) {
var newPath = path.get( fileUrl );
page.find( "[src], link[href], a[rel='external'], :jqmData(ajax='false'), a[target]" ).each(function() {
- var thisAttr = $( this ).is( '[href]' ) ? 'href' : 'src',
+ var thisAttr = $( this ).is( '[href]' ) ? 'href' :
+ $(this).is('[src]') ? 'src' : 'action',
thisUrl = $( this ).attr( thisAttr );
// XXX_jblas: We need to fix this so that it removes the document

0 comments on commit d99d096

Please sign in to comment.