• Resolved soulwasted

    (@soulwasted)


    Hi.

    I am just asking.
    How do you sanitize inputs? I mean SQL injections and those things.
    I wasn’t walking through your code. I am just curious.

    Thank you.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author easyregistrationforms

    (@easyregistrationforms)

    Hi,

    We loop through post data against the field settings saved into the database. Then our system sanitize data on the basis of field type. ie: If field type is text, System will use sanitize_text_field. If it is Textarea then sanitize_textarea_field will be used etc.

    Let me know if you have any more questions or you have any suggestions.

    Thread Starter soulwasted

    (@soulwasted)

    Hi.

    What about input type “hidden”?

    Plugin Author easyregistrationforms

    (@easyregistrationforms)

    Hi,

    As of now hidden fields are not sanitized. Thank you for bringing this. We will include it in next patch.

    Thread Starter soulwasted

    (@soulwasted)

    I am now rendering some simple HTML into this hidden ipnuts.
    Just text and “br” tags.
    Nothing harmful.

    But “sanitize_text_field” will break my JS scripts and the whole process.
    Is it possible to use this? https://codex.www.ads-software.com/Function_Reference/wp_kses
    And somewhere allow tags? Or by default “br”?
    Please ??

    Thank you.

    Plugin Author easyregistrationforms

    (@easyregistrationforms)

    Hi there,

    Could you please clarify the purpose of HTML in hidden field ?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘How do you sanitize inputs?’ is closed to new replies.