SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    Always learning kigoobe's Avatar
    Join Date
    May 2004
    Location
    Paris
    Posts
    1,565
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    advance form processing

    Hi guys,

    I was wondering how much freedom we can give to users who fill up a form to submit any content. Well, we can let them upload images and enter texts, thats OK, but let's say, if we want them to insert data in tables (not mysql tables, I'm speaking about html tables that we put in webpages to display any data in a clear way), what should we do ?

    Of course, by table I mean a table that will be dynamically generated as wished by the user, not a pre-designed one what u can fill up by variables.

    Well, so far I have thought there may be two ways:

    1. To let them use html in the form, and they can start something like [table] etc.

    2. To let them create seperately, say a small form where they can enter number of rows and columns, and depending on that entry x number of inboxes will come for the columns, and y number for the rows. They, they can fill up those inboxes and I will get my table ...

    any experience anybody, which one might be a better way ?

    Tx.

  2. #2
    SitePoint Enthusiast
    Join Date
    Dec 2004
    Location
    Finland
    Posts
    89
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey!

    I’m not sure if I understand right your needs, but this might be some kind of answer?

    Use FCK richtext editor http://www.fckeditor.net/ . You can edit toolbar options and set only table-button visible or any combination you want.
    FCK works in (IE 5.5+ (Windows), Firefox 1.0+, Mozilla 1.3+ and Netscape 7+).

  3. #3
    Always learning kigoobe's Avatar
    Join Date
    May 2004
    Location
    Paris
    Posts
    1,565
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi

    This seems to be a wonderful solution ... I didn't think anything as such would be possible ... btw, have u used this kind of stuff? Any drawback using this ? I have just tried to see the demo, and it is appearing to me that it is a bit slow to download ...

    I'm trying to read their 'how-to' now ... tx a lot for the link.
    Cheers.

  4. #4
    SitePoint Zealot
    Join Date
    Oct 2005
    Location
    Hegelsom, The Netherlands
    Posts
    126
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Well, for the normal PHP approach, as long as you properly validate the user input and make sure that you are correctly using the types you need, you'll be fine. Eg a value that needs to be number, cast it to an integer. Also making sure that quotes are sanitized would be a good idea, so people can't break your attribute values.

    Are you thinking of displaying this once, or inserting it in a database, for multiple access by different users?
    Yeap, I'm new here :P

    Game Insight

  5. #5
    Always learning kigoobe's Avatar
    Join Date
    May 2004
    Location
    Paris
    Posts
    1,565
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Putting it in a database of course, so that user can (that's not me) change things if needed ...

  6. #6
    SitePoint Zealot
    Join Date
    Oct 2005
    Location
    Hegelsom, The Netherlands
    Posts
    126
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Well, I'd say it depends on the type of users you're gonna allow access to this script. If it's your fellow mates or colleagues, I can't see why not just allow HTML all together. Though if it's on a normal user basis, you should of course not take a simple approach like that.

    I like the kinda BBcode idea of [table], but I'm not sure if it's worth the effort. Really depends on the situation.
    Yeap, I'm new here :P

    Game Insight


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
  •