Mysidia Adoptables Support Forum

Mysidia Adoptables Support Forum (http://www.mysidiaadoptables.com/forum/index.php)
-   Questions and Supports (http://www.mysidiaadoptables.com/forum/forumdisplay.php?f=18)
-   -   Quatation Mark Glitch O_o (http://www.mysidiaadoptables.com/forum/showthread.php?t=2060)

shiann 03-30-2011 07:09 PM

Quatation Mark Glitch O_o
 
You\'ve

\"I\'m so sorry!\"

This is what shows up when I type " or '. How do I fix it...?

I lurked a lot, and couldn't find anything.. ;_;

fadillzzz 03-30-2011 09:36 PM

Use stripslashes() & htmlspecialchars_decode()

PHP Code:

$string "You\'ve";
$string stripslashes($string); // You've 

PHP Code:

$string "\"I\'m so sorry!\"";
$string htmlspecialchars($string); // "I'm so sorry!" 


shiann 03-31-2011 10:07 AM

Oh, ok thank you!! :)

Hall of Famer 03-31-2011 12:41 PM

umm are you trying to do a quotation system for your adoptables site Shiann? This sounds interesting to me.

shiann 03-31-2011 03:58 PM

No, I was planning on using the quotation marks for the character interactions with the member.. But I may look into a quotation system, if I figure out what it is. :)

Plague 04-10-2011 01:00 AM

I've had issues with this as well.

@ fadillzzz: I'm a bit confused as to where the code is to be added to resolve the issue. Is this something put into the function page? Or is it to be specifically put on the pages where the issue is occurring?

Kaeliah 04-10-2011 01:08 AM

You'll want to put it just before you use the string. Or you can put

PHP Code:

$article_content stripslashes($article_content); 

AFTER

PHP Code:

// clean all our data
$_POST array_map('secure',$_POST);
$_GET array_map('secure',$_GET); 

in the functions page and that should effectively strip slashes from ALL of your content. But then BBCode wouldn't work I don't think.

Plague 04-10-2011 01:17 PM

That's so weird. I put it in the functions and for some reason it's still showing up everywhere.

fadillzzz 04-11-2011 04:04 AM

I suggest that you only use it on certain pages where the glitch is happening, and probably place it right before the echo showpage

PHP Code:

$article_content stripslashes($article_content);

echo 
showpage(...); 


Plague 04-11-2011 11:53 AM

@ fadillzzz: Excellent! Thank you very much. That finally took care of the problem. I really appreciate the help.


All times are GMT -5. The time now is 05:15 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.