Go Back   Web Hosting UK Forums | Linux Windows Dedicated Server and cPanel VPS Hosting Forum > Support > php issues.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-22-2007, 02:20 PM
new member
 
Join Date: Jun 2007
Posts: 5
Default PHP MySQL issue.

My website is hosted in webhosting.uk.com , I write a script to post news .I have user tag : <textarea> </textarea> . i types html in tag <textarea> then i post , a problem is exist . the page where i post my news is transfer to homepage , the posted is not successful .! please take me a solution ?
Note: ii'm use php & mysql
Thanks for reading !

Last edited by m4trix.v2; 06-22-2007 at 02:25 PM.
Reply With Quote
  #2 (permalink)  
Old 06-22-2007, 02:57 PM
Pumazooma's Avatar
Senior Member
 
Join Date: Jun 2006
Location: Oxford
Posts: 271
Default

Same problem I suspect
Serve Dislikes < and > brackets
Reply With Quote
  #3 (permalink)  
Old 06-22-2007, 03:00 PM
Administrator
 
Join Date: Mar 2006
Posts: 1,702
Default

It seems that mod_security rules on our server don't like what you are trying to post. You can contact one of our senior system administrators from our helpdesk support.webhosting.uk.com and get this rectified or you can put following code in your .htaccess to disable mod_security :-


<IfModule mod_security.c>

SecFilterEngine Off

SecFilterScanPOST Off

</IfModule>
__________________
Web Hosting UK - ASP MSSQL Hosting - cPanel Linux Hosting
AIM : webredback || msn : andrew @ webhosting.uk.com
Toll Free : 0808 262 0855
Reply With Quote
  #4 (permalink)  
Old 08-04-2007, 10:00 PM
Pumazooma's Avatar
Senior Member
 
Join Date: Jun 2006
Location: Oxford
Posts: 271
Default

Is it safe to add that to htaccess?
I want to be able to add a custom BBcode to my phpBB3 forum and applying that code above is the only way to do it. I just want to make sure I'm not compromising anything by doing it.
Reply With Quote
  #5 (permalink)  
Old 08-05-2007, 08:27 PM
Administrator
 
Join Date: Mar 2006
Posts: 1,702
Default

Quote:
Originally Posted by Pumazooma View Post
Is it safe to add that to htaccess?
I want to be able to add a custom BBcode to my phpBB3 forum and applying that code above is the only way to do it. I just want to make sure I'm not compromising anything by doing it.
You will need to ensure that you keep on upgrading your PHPBB forum as and when new patches are released. If you fail to do so then you may face problems and we wont be taking any sort of responsibility for any sort of intrusion if we find the mod_security disabling code in your .htaccess
__________________
Web Hosting UK - ASP MSSQL Hosting - cPanel Linux Hosting
AIM : webredback || msn : andrew @ webhosting.uk.com
Toll Free : 0808 262 0855
Reply With Quote
  #6 (permalink)  
Old 08-05-2007, 09:15 PM
Pumazooma's Avatar
Senior Member
 
Join Date: Jun 2006
Location: Oxford
Posts: 271
Default

Fair enough.
I do always keep up with the updates so that wouldn't be an issue if I choose to do it.
Is there no alternative to allow < and > in the forum that doesn't disable mod_security altogether?
Reply With Quote
  #7 (permalink)  
Old 08-05-2007, 10:27 PM
Pumazooma's Avatar
Senior Member
 
Join Date: Jun 2006
Location: Oxford
Posts: 271
Default

S'ok found a simple way around it and kept mod_security on.
Reply With Quote
  #8 (permalink)  
Old 09-03-2007, 11:21 PM
Junior Member
 
Join Date: Aug 2006
Posts: 12
Default

Quote:
Originally Posted by Pumazooma View Post
S'ok found a simple way around it and kept mod_security on.
Do you fancy telling us what it was? I have spent the last two hours searching the web on the assumption that it was a PHP thing (html forms sent to perl do it too) and 12:20am is too late for me to be messing with things...
__________________
Why me?
Reply With Quote
  #9 (permalink)  
Old 09-04-2007, 08:16 AM
Pumazooma's Avatar
Senior Member
 
Join Date: Jun 2006
Location: Oxford
Posts: 271
Default

Yep, easy really.

mod_security doesn't let you do posts with <> in them. In my case I was wanting to add some custom BBcode.
So, I edited the htaccess file to turn off mod_security, as explained in post #3 above, then entered my BBcode, then edited it back out of the htaccess file.

mod_security only freaks out at the time that code is initially posted. So, turn it off, post it, turn it back on. Now it's actually IN the forum it doesn't worry about it any more.
Reply With Quote
  #10 (permalink)  
Old 09-04-2007, 10:30 AM
Junior Member
 
Join Date: Aug 2006
Posts: 12
Default

Ah, thanks...

That wouldn't really help in my case, but it is not a bad idea.
__________________
Why me?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 04:12 AM.
Copyright 2002-2007 WebHosting.uk.com. All rights reserved.
Web Hosting UK Forum