Bug Tracker

Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#9020 closed bug (invalid)

tmpl() function does not populate href attribute in a tag in FF 3.6.16 64-bit

Reported by: jocapc Owned by:
Priority: low Milestone: 1.next
Component: web Version: 1.5.2
Keywords: Cc:
Blocked by: Blocking:


I have tried to use tmpl() function and it seems that it does not populate href attribute of the a tag in FireFow on 64-bit Windows7.

I have included following libraries:

<script src="http://code.jquery.com/jquery-1.5.2.min.js"></script> <script src="http://ajax.microsoft.com/ajax/jquery.templates/beta1/jquery.tmpl.min.js"></script>

In the HTML is placed following code as a template:

<ul id="template">


<a href="${Name}" alt="${Name}">${Name}</a> ${Address}



In the document ready is placed following code:

var markup = $("#template").html(); $.template("template", markup); var data = [{ Name: "The name 1", Address: "The address 1"},

{ Name: "The name 2", Address: "The address 2"}];

var output = $.tmpl("template", data); $("#template").html(output);

Results is:

<ul id="template"> <li> <a alt="The name 1" href="${Name}">The name 1</a> The address 1</li> <li><a alt="The name 2" href="${Name}">The name 2</a> The address 2 </li> </ul> Alt attribute is populated but href is not. Note that it works fine in the Google Chrome and IE8 (64bit)

Change History (3)

comment:1 Changed 5 years ago by jocapc

You can see this in jsfiddle. When it is opened in FireFox 3.6.16, ${Name} is left in href attribute but in IE8 and Chrome this value is replaced with a "The name 1" and "The name 2".

comment:2 Changed 5 years ago by rwaldron

  • Component changed from unfiled to web
  • Priority changed from undecided to low
  • Resolution set to invalid
  • Status changed from new to closed

According to the big red box displayed on the new tickets page:

<div class="ticket-guidelines"><h2 id="Areyouintherightplace">Are you in the right place?</h2>

<p> <strong>For Official jQuery Plugins (<a class="ext-link" href="http://github.com/jquery/jquery-tmpl/issues"><span class="icon"> </span>Templating</a>, <a class="ext-link" href="http://github.com/jquery/jquery-datalink/issues"><span class="icon"> </span>Data Linking</a>, <a class="ext-link" href="https://github.com/jquery/jquery-global/issues"><span class="icon"> </span>Globalization</a>):</strong><br /> This is NOT the correct form! Please use the Issue Tracker on the GitHub repository for each plugin, linked above. </p> </div>

Version 0, edited 5 years ago by rwaldron (next)
Note: See TracTickets for help on using tickets.