1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to put validation in php form.

Discussion in 'Programming' started by pintoo, Oct 29, 2015.

  1. #1
    How to put validation in php form.
    SEMrush
     
    pintoo, Oct 29, 2015 IP
    SEMrush
  2. shureg

    shureg Active Member

    Messages:
    18
    Likes Received:
    2
    Best Answers:
    1
    Trophy Points:
    80
    #2
    If you mean html form, so you can do it on server or client side

    for validation on the client side you can use javascript
    http://www.w3schools.com/js/js_validation.asp

    or use a js frameworks like a jquery

    just try to use google
     
    shureg, Oct 29, 2015 IP
  3. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,463
    Likes Received:
    1,917
    Best Answers:
    246
    Trophy Points:
    515
    #3
    Just remember, NEVER trust client side validation -- even if you have the scripttardery or HTML 5, crackers can slap that aside as if it doesn't even exist so you HAVE to re-check things server-side...

    But the question becomes, what DATA are you validating? What information is the form sending? How many fields are we talking; so few you can hand code it, or so many you'd be better off building an array that builds the form for output and could be leveraged for validation as well?

    You're not quite telling us enough about what you have, where you are going, and what your applicable skillset even is.
     
    deathshadow, Oct 30, 2015 IP