#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2009
    Posts
    101
    Rep Power
    16

    [Solved] With JS detect what form an element is in


    I need to detect the name of the form that an <INPUT> element lives in. Using JavaScript how can i accomplish this?
    -------------------------------------------------------

    EDIT:

    Code:
    var x=document.getElementById("barcode").form.id;
    i figured it out, I only had the element name defined so it wasn't picking it up.
    Last edited by dsfx; April 27th, 2013 at 11:25 AM.

IMN logo majestic logo threadwatch logo seochat tools logo