How do I call a defined variable with jQuery?
<p>I'm kinda stuck.</p>

<p>I defined three variables:<pre><code>var part1 = &quot;&lt;form&gt;&lt;input type='button' value='Open Window' onclick='window.open('http://jsfiddle.net/
&quot;;
var part2=&quot;5Xket,&quot;
var part3 = &quot;'toolbar=no',menubar='no')&gt;&lt;/form&gt;&quot;;</code></pre></p>

<p>My aim is to concat those variables to create a working link when clicking on the button.</p>

<p>This is my try to concat the values of the variables.</p>

<pre><code>var mytest_2=part1+part2+part3;
alert (mytest_2);</code></pre>

<p>By clicking a button the button from mytest2 should appear. Clicking on that button there should be opened a new window with the url <a href="http://jsfiddle.net/5Xket/" rel="nofollow">http://jsfiddle.net/5Xket/</a></p>

<pre><code>$('#searchbutton').click(function() {
$(&quot;&lt;td class='testclass'&gt;&lt;input id='an_id' type='text'&gt;&lt;/td&gt;&quot;).show();
$(mytest_2).insertAfter('#an_id');</code></pre>

<p>Well, the button appears as it should, but won't open a window.
My guess is that I'm wrong with the syntax somewhere because the alert puts out the correct order of variables.</p>

<p>Any ideas? Thank you.</p>
