SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Best way to do this?

    I posted something similar a while ago and have been contemplating the "best" method for way too long. I'm killing my brain and I think working further away from a solution.

    Let me explain the situation:
    - You would create a mailing list subscription form
    - You would select which lists to include on the form (let's say A and B)
    - You would select which fields to include on the form (let's say Name, Phone #, Country)

    Now in fact Name is attached to A, and so is Country - but also made available to B. So it makes sense to have each of them on my form since I have list A and B on it. Phone #, on the other hand, is attached to list C which was not included in the form.

    As I've come to realize though, it isn't such a horrible thing to have a user fill in an extra field that basically just gets discarded afterwards in the case that the creator selected a field that doesn't match with a selected list.

    Follow me so far? Hope so!

    On the backend certain fields can be marked as required - let's just assume every field is marked as required. The issue is that not every field was selected to be included, so we can't tell the user that field 'Address' wasn't filled out when it wasn't selected to be included.

    So, what is the best way to make sure the form/backend will know what data is supposed to be sent? I thought about storing the form information in a database, but as people create more and more forms this database would get overloaded and people would lose track of anything they wanted to go back to.

    I then thought about creating an array (of the lists, fields, etc.) and serializing that, then including it in a hidden field in the form. I don't want to store it as it's open-viewable serialized state... but most encoding methods end up with a longer/same length string... ideally something shorter would be nicer .

    So those are the two methods I thought about. Either one of those or something else, what do you think is the best way to set everything up so that the resulting form processor will know what data is to be expected and can validate/process based on that?

    I hope I made enough sense.... haha
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  2. #2
    SitePoint Addict Trent Reimer's Avatar
    Join Date
    Sep 2005
    Location
    Canada
    Posts
    228
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by triexa View Post
    As I've come to realize though, it isn't such a horrible thing to have a user fill in an extra field that basically just gets discarded afterwards in the case that the creator selected a field that doesn't match with a selected list.
    Actually, as a user I find that quite annoying, as in "why do they think my time is so much more worthless than theirs?"

    Perhaps instead of creating lists which contain different kinds of information AND selecting which information to include you might get further ahead doing one or the other.

    i.e. You could standardize what kinds of information can be collected in a list and then on your form you can select what to display from a list of fields which are common to all the lists. (whether or not they are all filled in)

  3. #3
    reads the ********* Crier silver trophybronze trophy longneck's Avatar
    Join Date
    Feb 2004
    Location
    Tampa, FL (US)
    Posts
    9,854
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    i vote for collecting the minimum amount of data to complete the requested subscriptions. if a user later wants to add more subscriptions, then prompt them for the additional info.

    some of your users may decide which lists to sign up for based on the amount of information collected.

    and i would ABSOLUTELY want to see what info is transmitted to each list, especially after i come back to sign up for a third list.


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
  •