miniBB ® 

miniBB

®
Support Forums
  
 | Start | Register | Search | Statistics | File Bank | Manual |
The Other miniBB Support Forums / The Other /  
 

Set magic_quotes_sybase to OFF when running miniBB on a server

 
Author acidsneaker
Partaker
#1 | Posted: 17 Oct 2010 22:58 
I have installed minibb in my locals and it's running fine. But when I moved it to the server, post message button is missing. Means that users cannot post messages and reply to messages in the forum. After doing some error checking on the javascript. This is what I found:

if(document.forms[''postMsg'']) document.forms[''postMsg'']
.elements[''subbut''].disabled=false;

it's supposed to be like this

if(document.forms['postMsg']) document.forms['postMsg'].elements['subbut'].disabled=false;

I have check the source file, its using single quotes.
Not sure why single quotes when open in the browser, it becomes double quotes.

can somebody please help me.

Thanks in advance.

Author acidsneaker
Partaker
#2 | Posted: 17 Oct 2010 23:00 
I found the wrong script by right click and view source.

Author acidsneaker
Partaker
#3 | Posted: 18 Oct 2010 02:02 
Through thorough investigations, I found that any single quotes will be turn into double quotes. This will definitely disturb any coding especially javascript from the template files.
So I suspected this must be something to do with server settings. I differentiate my local phpinfo with the server phpinfo.
It's magic_quotes_sybase is on at the server but off in my locals. I already ask my admin to off the magic_quotes_sybase. Later I will reply with the results.

Why do I think that is the problem? Based on the php manuals:
Note: If the directive magic_quotes_sybase is ON it will completely override magic_quotes_gpc. So even when get_magic_quotes_gpc() returns TRUE neither double quotes, backslashes or NUL's will be escaped. Only single quotes will be escaped. In this case they'll look like: ''
So If magic_quotes_sybase is on, a single-quote is escaped with a single-quote instead of a backslash

I hope this info will benefits others.

Thank you.

Author juminosy
Partaker
#4 | Posted: 18 Oct 2010 04:23 
acidsneaker
Thanks for the info. I don't know about others but it definitely benefited me :)

Author acidsneaker
Partaker
#5 | Posted: 18 Oct 2010 04:27 
Need to off both magic_quotes_sybase and magic_quotes_runtime. Now minibb forum are running fine in the server.

Author Paul
Lead Developer 
#6 | Posted: 18 Oct 2010 04:41 
Thanks for the info. As it's listed on miniBB's requirements page, The only requirement about PHP is that magic_qoutes_runtime setting must be set to OFF, which is set so by default.

So I guess we shall put there 'magic_quotes_sybase' as well. Thanks.

Author sumaniuot
Partaker
#7 | Posted: 29 Oct 2010 07:14 
acidsneaker:
So If magic_quotes_sybase is on, a single-quote is escaped with a single-quote instead of a backslash

I hope this info will benefits others.
Thanks for the helpful tip. It helped me a lot. :)

The Other miniBB Support Forums / The Other /
 Set magic_quotes_sybase to OFF when running miniBB on a server
 Share Topic's Link

Your Reply Click this icon to move up to the quoted message


  ?
Post as a Guest, leaving the Password field blank. You could also enter a Guest name, if it's not taken by a member yet. Sign-in and post at once, or just sign-in, bypassing the message's text.


Before posting, make sure your message is compliant with forum rules; otherwise it could be locked or removed with no explanation.

 

 
miniBB Support Forums Powered by Forum Software miniBB ® Home  Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Get the Captcha add-on: protect your miniBB-forums from the automated spam and flood.


  ⇑