Results 1 to 3 of 3
  1. #1

    Validation using fsockopen?

    Hi,

    I have about 20 client websites who send their data via forms to my web server for database storage and other processes. Right now all the processing code is in a file on each of their servers, but I'd rather have the processing code on my server so that I will not have to update each of their files when I add/subtract code from the processing script.

    That being said, I decided to use fsockopen to POST the form data to my server. Should I do the server side validation on my server or validate on their servers before sending the data? Also, any concerns about my new idea to have the processing script in one centralized location?

    Thanks,
    b

  2. #2
    Join Date
    Apr 2009
    Location
    USA / UK
    Posts
    4,553
    Quote Originally Posted by burnside View Post
    Hi,
    Should I do the server side validation on my server or validate on their servers before sending the data?
    Ideally you would do it at both places.

    However, it is most important to do the validation as far up the chain as possible - in this case that means at your server.
    RAM Host -- Premium & Budget Linux Hosting From The USA & EU
    █ Featuring Powerful cPanel CloudLinux Shared Hosting
    █ & Cheap Premium Virtual Dedicated Servers
    Follow us on Twitter

  3. #3
    Thanks for the reply. I guess I'll do it in both places then. Some of my clients forms are different than other client forms, so the variables coming in will differ. That's why for sure I want to do validation on their server first to make sure we don't have to open a connection if the data is invalid. Once it makes it through the first validation process on their server, then I guess I'll send the data over to my server for another round of validation, database storage, other processes such as email, then finally return the results back to the client's server and show a success page.

    Any other helpful tips about what I'm thinking of doing would be very helpful. I want to get this all done right so that I don't have to spend time in the future redoing this stuff!

    Thanks,
    b

Similar Threads

  1. fsockopen
    By Danny159 in forum Programming Discussion
    Replies: 6
    Last Post: 11-23-2008, 08:09 PM
  2. fsockopen
    By sachin_linux in forum Hosting Security and Technology
    Replies: 2
    Last Post: 08-27-2008, 01:51 AM
  3. fsockopen
    By engrkhalid in forum Programming Discussion
    Replies: 6
    Last Post: 08-15-2005, 02:41 PM
  4. fsockopen()
    By DSD in forum Programming Discussion
    Replies: 2
    Last Post: 04-11-2003, 10:21 AM
  5. fsockopen
    By insaneraptor in forum Web Hosting Lounge
    Replies: 0
    Last Post: 03-22-2003, 11:41 PM

Posting Permissions

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