Can not get value from ClueTip generated element

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Can not get value from ClueTip generated element

ttturn
Hi,

Seems that the ClueTip has a bug on it's generated elements?
I got a problem like below, just can not get the value of the text field.

<script type="text/javascript">
  $(function() {
    $('a.ClueTip').cluetip({
      local: true,
      sticky: true,
      closePosition: 'title',
      activation: 'click'
    });
    $("#showTip").click(function() {
        var inputValue = $("#keyword").val();
        alert(inputValue);
      });
  });
</script>
<a class="ClueTip" href="#" rel="#tipPop" title="Clue Tip Popup">Search</a>
<table id="tipPop">
<tr>
<td><input id="keyword" type="text"/></td>
<td><input id="showTip" type="button" value="GO" /></td>
</tr>
</table>

Anyone can help me?
Thanks,
-Dan

--
You received this message because you are subscribed to the Google Groups "jQuery UI" group.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].
For more options, visit this group at http://groups.google.com/group/jquery-ui?hl=en.
Reply | Threaded
Open this post in threaded view
|

Re: Can not get value from ClueTip generated element

Andrés Muñoz
Hi Dan,

beam used:
var inputValue = $("#keyword").val();
        alert(inputValue);

for:
var inputValue = $("#keyword").attr('value');
        alert(inputValue);

es una segunda forma, espero que sirva
Andrés Muñoz.


2010/8/26 黄旭 <[hidden email]>
Hi,

Seems that the ClueTip has a bug on it's generated elements?
I got a problem like below, just can not get the value of the text field.

<script type="text/javascript">
  $(function() {
    $('a.ClueTip').cluetip({
      local: true,
      sticky: true,
      closePosition: 'title',
      activation: 'click'
    });
    $("#showTip").click(function() {
        var inputValue = $("#keyword").val();
        alert(inputValue);
      });
  });
</script>
<a class="ClueTip" href="#" rel="#tipPop" title="Clue Tip Popup">Search</a>
<table id="tipPop">
<tr>
<td><input id="keyword" type="text"/></td>
<td><input id="showTip" type="button" value="GO" /></td>
</tr>
</table>

Anyone can help me?
Thanks,
-Dan

--
You received this message because you are subscribed to the Google Groups "jQuery UI" group.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].
For more options, visit this group at http://groups.google.com/group/jquery-ui?hl=en.

--
You received this message because you are subscribed to the Google Groups "jQuery UI" group.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].
For more options, visit this group at http://groups.google.com/group/jquery-ui?hl=en.