0

if i use tinymce i get

Request-URI Too Large The requested URL's length exceeds the capacity limit for this server.

my code:-

  <!-- TinyMCE -->
<script type="text/javascript" src="../jscripts/tiny_mce/tiny_mce.js"></script>
<script type="text/javascript">
    tinyMCE.init({
        //mode : "textareas",
        mode : "specific_textareas",
        editor_selector : "myBasicEditor",
        theme : "simple"
    });
</script>
<!-- /TinyMCE -->



        if(tinyMCE.get('txtourcmnt').getContent() !="" )
        {
                //var test = tinyMCE.get('txtourcmnt').getContent();
                //alert(test);
                var ordid = '<?php echo $ordid; ?>';
                var cmnt  = tinyMCE.get('txtourcmnt').getContent();
                cmnt = encodeURIComponent(cmnt);
                var typ   = 'o';
        }
        if(cmnt != "")
        {
            var url = "display_comments.php?ordid="+ordid+"&cmnt="+cmnt+"&typ="+typ;        
            xmlHttp = GetXmlHttpObject(funcsubcatval);
            xmlHttp.open("POST", url , true);
            alert(url);
            xmlHttp.send(null);
        }
Navruk
  • 927
  • 6
  • 17
  • 29
  • You are implementing a dynamic URL, which seems to be exceeding the max length. Here is a great [SO answer](https://stackoverflow.com/questions/417142/what-is-the-maximum-length-of-a-url/417184#417184) about it. – Dustin Laine Apr 26 '11 at 20:33

1 Answers1

3

It looks like you're attempting to send the contents of the editor via a querystring parameter. You should send it as a post parameter instead.

jessegavin
  • 74,067
  • 28
  • 136
  • 164