How to get type of elements names & ids inside a DIV
<p>I would like to build a sort of all-purpose primitive CMS based on a kind of advanced editable area concept. The concept is the following:</p>

<p>A web site is built by dividing the content into a number of DIVs. Inside each DIV the developer places images, text, etc.</p>

<p>When the user enters the administration area, by hovering the mouse above the editable DIVs these are highlighted. If the user clicks one the DIVs a modal window pops up. This modal window contains a form with which the user may change the content of the DIV.</p>

<p>I know there are many 'editable area' scripts and I did used them, but this would be more generic as it would work with images too (upload/delete). </p>

<p>For example, let's say that a DIV contains some text. By clicking this DIV a modal window pops up with a form with one input field and a submit button that offers the user to change the text inside that DIV. If the clicked DIV has one image and some text the modal window should contain an input field to change the text, a upload field to upload a new image, a submit button and delete button to delete the image.</p>

<p><a href="http://www.mindteq.com/projects/divs/index.html" rel="nofollow">Click here to understand the layout</a> (this is not a working example)</p>

<p>In conclusion I would like to know if there's a way with jQuery to get the <strong>type</strong> of elements </p>

<pre><code>&lt;input&gt; &lt;img&gt; &lt;textarea&gt; etc
</code></pre>

<p>the <strong>name</strong> given to the elements and their <strong>ids</strong> inside the clicked DIV to <strong>dinamically</strong> build the modal window needed to edit the choosen DIV.</p>

<p>Thank you</p>
