0

Hi Guys

Im kind of new to this and i hope you will be able to understand my question.

I have a little dynamic news website. I have a form (called add_post.php)i use to insert my articles (blog_enrty). Unfortunately i get an error saying "you do not have permission to access add_post.php" each time i try to insert an article with html/xhtml characters.

The strange this is that it works perfect when i do it on my computer's local host but refuses on the website's. It also works on the web server when artcles have ano hatml characters.

This is the code on the add_post.php:

if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
  $insertSQL = sprintf("INSERT INTO news (title, blog_entry,article_id,arthor_id) VALUES (%s, %s, %s, %s)",
                       GetSQLValueString($_POST['title'], "text"),
                       GetSQLValueString($_POST['blog_entry'], "text"),
                       GetSQLValueString($_POST['article_id'], "int"),
                       GetSQLValueString($_POST['arthor_id'], "int"));

Help will be gratly appreciated.

Edited by Ezzaral: Moving to php and adding code formatting.

2
Contributors
1
Reply
2
Views
5 Years
Discussion Span
Last Post by pritaeas
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.