Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7641605
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T08:57:59+00:00 2026-05-31T08:57:59+00:00

Every time a POST is made I get escaped characters. \ -> \\ ‘

  • 0

Every time a POST is made I get escaped characters.

\ -> \\
' -> \'
" -> \"

I have a multistep form, which transmits the data from one form to another. I save the values with prepared statments in the database. The values in the database currently look like Paul\'s House. User should have the possiblity to use single and double quotes in their string.

This is a simple example demonstrating the escaping effect:

<?php
echo $_POST['value'];
?>
<form action="form.php" method="post" enctype="multipart/form-data">
    <input type="hidden" name="value" value="Paul's House">
    <input type="submit" value="Next">
</form>

Why or who escapes the string? What is the correct way for handling data over multiple forms? What is the correct way for saving it in the database? Should I use stripslashes() or I’m opening a big security hole?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T08:58:00+00:00Added an answer on May 31, 2026 at 8:58 am

    Looks like you have Magic Quotes turned on.

    http://www.php.net/manual/en/security.magicquotes.disabling.php

    Check that out for how to disable.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have made this mistake several times, and found myself referencing This Post every
I'm trying to set my blog up where every time a post is made
Every time I try to post to twitter in my rails app, the first
Every time I turn on my company-owned development machine, I have to kill 10+
Every time I have to estimate time for a project (or review someone else's
So, i'm trying to learn python and every time i post a question here
Every time a POST value is not equal to the list of values set
For example, every time I post I question on stackoverflow.com, the UI suggest me
I am using preg_match function to filter unwanted characters from a textarea form in
I have a old website that generate its own RSS everytime a new post

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.