Working with magic_quotes_gpc set.
I'm working on a couple of platforms (local testing on a mac, stage at my own provider, live/livetest at a friends provider). Some of these platforms have magic_quotes_gpc set, others don't. I've tried to switch magic_quotes_gpc off, but have not had any luck; I'm beginning to suspect that it is not allowed.
As I've read the code, and what I've seen of the database, CoughPHP handles magic_quotes_gpc by calling stripslashes if appropriate in As_Database:
Now, what I'm trying to do is set a field from a form, save the object, then later get the field from the form. ($user-
On the other hand, if I stripslash the argument to setNotes myself, it will be stripslashed twice before it reaches the database. Not good, either.
Come to think of it, how does CoughPHP 'know' that the value of the field comes from Get/Post/Cookie? What if I set my field to a hardcoded value? ($user-
What is the suggested approach to dealing with magic_quotes_gpc when using CoughPHP? I'd almost go so far as to suggest that CoughPHP should not try to handle magic_quotes_gpc, and leave it up to the programmer using CoughPHP.
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- CoughPHP Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Anthony Bush
- Solved:
- Last query:
- Last reply: