-3

So I posted a question and received and answer that was exactly what I needed and ran into the same issue once again I went back to reference the question and found that the answer posted had been changed and was not what was needed and i unaccepted the answer

I believe this is a bug in the system imagine how many users may have viewed that question with that accepted answer and had to go somewhere else because the answer doesnt work for what was needed?

In any case the answer was posted by Samir and I would appreciate the answer being changed back to what was originally accepted

Remove html entities from user input

8
  • Just a guess, but it looks to me like the answer was deleted and a new one was posted, since that answer has no revision history. Also please take the needed time to spell words completely.
    – Daedalus
    Aug 11, 2016 at 5:20
  • thats funny? the original answer tht was posted dealt with htmlspecialchars or something of the sort i cant exactly remember what the exact function was so i was referencing it the one thing i know is it had nothing to do with mysqli cause i havent ever used it
    – user5491906
    Aug 11, 2016 at 5:32
  • Like I said; no revision history; so either you accepted the answer in the first five minutes it was posted, and then before 5 minutes were up the author changed it(unlikely) or they deleted and re-posted. Last time I ask before I give up: Please spell words completely; for instance; 'that', 'completely'.
    – Daedalus
    Aug 11, 2016 at 5:50
  • There is another answer from another user that was deleted by owner Feb 28, maybe you're thinking of that one? Maybe you accidentally accepted the wrong answer? Are these the links you were thinking of? php.net/manual/en/function.addslashes.php and.... php.net/manual/en/function.stripslashes.php Aug 11, 2016 at 18:59
  • How would I see the deleted answer? @DanielNugent
    – user5491906
    Aug 11, 2016 at 21:46
  • @JoséphFlames Over 10k rep you can see all deleted content.... Aug 11, 2016 at 21:47
  • is it possible u can undelete the answer?
    – user5491906
    Aug 11, 2016 at 21:49
  • i.stack.imgur.com/diCd5.png Aug 11, 2016 at 22:33

1 Answer 1

10

At the time the answer was posted (7:14 UTC), you couldn't have accepted it before the grace period for edits to the answer ended, since the answer would have been 9 minutes old before you could accept it (15 minutes from asking to accept an answer). There is no evidence whatsoever that suggests any changes were made to Samir's answer, by himself or anyone else. And Samir couldn't have performed a bait-and-switch by deleting his original answer and reposting a completely new one while you weren't looking, since answers can't be self-deleted after being accepted.

You must have misremembered the original answer. Considering that this all happened almost half a year ago, it could very well have been the case. Not to mention that there aren't actually any "html entities" in your sample as you allude to in your question title, so I don't understand why you think anyone would suggest using htmlspecialchars() to filter your user input.

3
  • theres no way i would have accepted an answer suggesting mysqli considering ive never used it and im not saying someone suggested htmlspecialchars i just remeber something along the lines but it was a function unrelated to sql or sqli it was a plain php function
    – user5491906
    Aug 11, 2016 at 6:45
  • 3
    @Joséph: please don't post answers with code/libraries you've never used then.
    – Mat
    Aug 11, 2016 at 8:14
  • ust bc i have never used them personally does not mean im not well aware of how they work @Mat
    – user5491906
    Aug 11, 2016 at 10:18