File upload validation for two fields - first field must be filled before second

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • great12
    New Member
    • Aug 2008
    • 1

    File upload validation for two fields - first field must be filled before second

    file upload 1
    and file upload 2

    when any one not select file from file uplaod 1 and select from file upload 2

    show pupup message alert("first select file one")

    plz
  • acoder
    Recognized Expert MVP
    • Nov 2006
    • 16032

    #2
    I have split your post from the thread you posted in. It had nothing to do with your problem. Please do not hijack other's threads.

    What have you managed so far. Please post your code using code tags.

    PS. welcome to Bytes!

    Comment

    • Rsmastermind
      New Member
      • Sep 2008
      • 93

      #3
      Hi Youu can do this.........

      Which quite simple......... .
      [CODE=javascript]//function should be call on some event I am not mentioning that.
      function abc()
      {

      var fileField1=$('I d of the field where is the file going to be uploaded');
      var fileField2=$('I d of the field where is the file going to be uploaded');
      if((fileField1= ='' || fileField1=null ) && (fileField2!='' && fileField2!=nul l);
      alert('first select file one');



      }[/CODE]
      Last edited by acoder; Sep 18 '08, 03:29 PM. Reason: Added [code] tags

      Comment

      • acoder
        Recognized Expert MVP
        • Nov 2006
        • 16032

        #4
        Rsmastermind, I've had to add code tags to a number of your posts. Please enclose your posted code in [code] tags (See How to Ask a Question).

        This makes it easier for our Experts to read and understand it. Failing to do so creates extra work for the moderators, thus wasting resources, otherwise available to answer the members' questions.

        Please use [code] tags in future. Thanks.

        Moderator.

        Comment

        • Rsmastermind
          New Member
          • Sep 2008
          • 93

          #5
          Originally posted by acoder
          Rsmastermind, I've had to add code tags to a number of your posts. Please enclose your posted code in [code] tags (See How to Ask a Question).

          This makes it easier for our Experts to read and understand it. Failing to do so creates extra work for the moderators, thus wasting resources, otherwise available to answer the members' questions.

          Please use [code] tags in future. Thanks.

          Moderator.
          Rsamstermind]Ok I was unaware of this thing I will keep this in mind. I am a new user.I don t know exactly regarding the tags or quotes that is mentioned in your forum .Anyways I am trying to do as per the rule

          Comment

          • acoder
            Recognized Expert MVP
            • Nov 2006
            • 16032

            #6
            I see you have done now. Thanks.

            Comment

            Working...