<?xml version='1.0' encoding='ISO-8859-1'?>
<?xml-stylesheet type='text/xsl' href='docs.xsl'?>
<docs>
<method cat='DOM/Manipulation' type='jQuery' see='prepend(&lt;Content&gt;)' short='Prepend all of the matched elements to another, specified, set of elements.' name='prependTo'>
<desc>Prepend all of the matched elements to another, specified, set of elements.
This operation is, essentially, the reverse of doing a regular
$(A).prepend(B), in that instead of prepending B to A, you're prepending
A to B.</desc>
<params type='&lt;Content&gt;' name='content'>
<desc>Content to prepend to the selected element to.</desc>
</params>
<examples>
<desc>Prepends all paragraphs to the element with the ID "foo"</desc>
<before>&lt;p&gt;I would like to say: &lt;/p&gt;&lt;div id="foo"&gt;&lt;b&gt;Hello&lt;/b&gt;&lt;/div&gt;</before>
<code>$("p").prependTo("#foo");</code>
<result>&lt;div id="foo"&gt;&lt;p&gt;I would like to say: &lt;/p&gt;&lt;b&gt;Hello&lt;/b&gt;&lt;/div&gt;</result>
</examples>
</method></docs>
