1 Reply Latest reply on Mar 16, 2012 9:50 AM by osgood_

    php special character

    iconofsin14 Level 1

      I want to use the \ character in a string as regular text

      this character is normally put in front of other syntax and operating characters to make php treat them as regular text so when i try and use it i get an error


      I get this error

      Warning:  Unexpected character in input:  '\' (ASCII=92) state=1 in /home/swcwebde/public_html/flowersfolder/editlist.php on line 5


      the code looks like this

      $needle = \'\\';

      the middle \ is the text string

      without the other 2 \ characters it converts the second ' into a string character not a quote to close the string

      i get the same result even if replace ' with "


      even with the error the whole script does what it is supposed to do properly, it just displays the error