473,386 Members | 1,745 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

slashes

Ok this is a follow up to a very old topic so I thought it qualified a
new topic the original topic is:
http://groups.google.com/group/comp....5dcbf1f15e235f
now I have talked to my resseller (a friend of mine) and he told me he
doesnt have ANY problems with backslahses going wherever any quotes are
and he told me I could possibly use the "str_replace" function to get
around this problem so I tried that but of course trying to put a
backslash in quotes is either VERY complex or impossible so if you know
how thats great please tell me. But as I say its very odd as he doesnt
have the same problem that I have, and being my resseller surely he's
on the same server as me?

James.

Oct 31 '06 #1
1 1203
James54321 wrote:
Ok this is a follow up to a very old topic so I thought it qualified a
new topic the original topic is:
http://groups.google.com/group/comp....5dcbf1f15e235f
now I have talked to my resseller (a friend of mine) and he told me he
doesnt have ANY problems with backslahses going wherever any quotes are
and he told me I could possibly use the "str_replace" function to get
around this problem so I tried that but of course trying to put a
backslash in quotes is either VERY complex or impossible so if you know
how thats great please tell me. But as I say its very odd as he doesnt
have the same problem that I have, and being my resseller surely he's
on the same server as me?

James.
Hi,

Backslashes are added for a good reason namely escaping the next character
all great yeah so you need to know where to use them and where not no such
thing as a general solution yeah please use functions like strip_slashes()
and add_slashes() to make the string fit your needs and do not forget to
understand in the first place where the backslahes come from because if you
do not understand the issue chances are that your application is vunarable
to SQL-injection yeah also it is very well possible that your friends
server has another php.ini than you do so his application behaves
differently look for magic_quotes_gpc settings in your php.ini file and
read the part at www.php.net that covers it just type php.ini in the
searchbox and it will take you there.

Next time use a little more punctuation if you make a posting. :-)

Regards,
Erwin Moller
Oct 31 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Randell D. | last post by:
Folks, I'm using Apache/1.3.28 (SuSE 7.1, kernal 2.4) with PHP/4.3.2. I have the following code to help cleanse form data. function cleanData($sourceData, &$cleanData) { foreach($myData as...
1
by: mr_burns | last post by:
Hi, I have been sending emails using PHP with the mail() command/method. When I send them tho it adds slashes, for example: 'hi guy's' gets sent as 'hi guy\'s' Why is this? How do I sort...
13
by: lawrence | last post by:
A user writes this sentence: "It was the New Urbanist's nightmare of sprawl run amok." They input that and my PHP script hits it with addslashes() and then the sentence gets put in the database....
16
by: droog | last post by:
Hello! I have just started learning python and encountered a problem. All I wanted to do, was to open a text file search and count the number of occurances of a single word and print that count....
10
by: Carlos Ribeiro | last post by:
Hello all. I'm sending this to the list because I would like to know if someone else has ever stumbled across this one, and also because one possible solution is to patch, or simply "decorate",...
7
by: Alex | last post by:
I'm new to Oracle, so this question may sound silly. I have been given a list of Oracle tables (they may be views, I'm not sure) that are available to me. I can run simple SQL select statements...
5
by: Treetop | last post by:
I have noticed with various codes that the slashes are not consistent. Is there a reason for this. For example </td> </\td> <\/td> <td /> what is the difference with these tags?
4
by: bdwise | last post by:
I have a textbox in a form, and I need to allow users to enter dates in US Format (MM/DD/YYYY). But they do not want to type any slashes, just 8 numbers, and have the slashes added for them. ...
10
by: Julie | last post by:
Why does the faq make this statement regarding slashes in paths: "This is because the library routines on these operating systems handle "/" and "\" interchangeably. " ...
0
by: Henrik de Jong | last post by:
Hello, I'm using radeditor. When I set the html-property to the text wich has to be altered, it gives me an error when try to save the new values of the html-proterty. It occurs only when i'm...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.