Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    May 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Forces spaces to be filled with   on form submit

    I have setup a form that adds data to a MySQL database, however I need spaces in textarea form inputs to be filled with   instead of just a regular space when the data is added to the MySQL table.

    For example, if someone enter "Ice Cream" in the text box and clicks submit, "Ice Cream" is what actually needs to be added in the database table.

    I am wonder if this is possible and how to set this up. Not sure if it can be accomplished with HTML, PHP, or in MySQL.

    -DruX

  • #2
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,485
    Thanks
    6
    Thanked 981 Times in 954 Posts
    Do a str_replace when the form data is submitted?

  • #3
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,801
    Thanks
    160
    Thanked 2,216 Times in 2,203 Posts
    Blog Entries
    1
    For example, if someone enter "Ice Cream" in the text box and clicks submit, "Ice Cream" is what actually needs to be added in the database table.
    Let me ask, what's your actual purpose?
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)


  •  

    Tags for this Thread

    Posting Permissions

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