SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Wizard Wolf_22's Avatar
    Join Date
    Jul 2005
    Posts
    1,710
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Lasting form variable after submit?

    I have a form that allows you to type in a directory and then submit to retrieve all the files therein in a nice list. My question is this: how do I make that directory variable "last" after it's been submitted?

    Here's my issue... When I submit the form, the files are generated with a check box (which will allow me to do stuff to the files) but once I check the files, I have to then re-type the directory prior to submit. I know this is probably trivial, but how do you make a variable submitted last after submit? Do I need to put it in an array?

    Let me know if you need an example...

  2. #2
    SitePoint Wizard Wolf_22's Avatar
    Join Date
    Jul 2005
    Posts
    1,710
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry everybody. I think I figured it out.

    Based from what I found here, I decided to check to see if the directory variable isset() after which I then use a little conditional to print the strlen() of directory if it's available, otherwise, I have it print blank space.

    Seems to be working, but as always, I'd love to know if any of you know of better approaches outside of sessions and storing variables in external files...


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •