Saving A Windows File Path

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • xtianixm
    New Member
    • Jul 2007
    • 52

    Saving A Windows File Path

    hola everyone,

    how can i save a file path into mysql database without removing the '\'

    im using XAMPP for my database or phpmyadmin then when i try to insert a file path (ex. D:wallpaper\me. jpg) it removes the backslash and now it became
    D:wallpaperme.j pg ..when i try load it an error occur "file not found" because the backslash was remove!

    ..help!
  • docdiesel
    Recognized Expert Contributor
    • Aug 2007
    • 297

    #2
    Hi,

    this doesn't sound like a MySQL problem to me. I guess it's a topic related to your programming language, like you have to escape the "\" by a double one, "\\".

    Providing more information could definitely help. Are you using Perl or PHP? Please post at least that part of your code that's relevant to this problem.

    Regards, Bernd

    Comment

    • mwasif
      Recognized Expert Contributor
      • Jul 2006
      • 802

      #3
      Use addslashes() if you are using PHP to insert the data in DB.

      Comment

      Working...