adam291086 Posted September 10, 2008 Share Posted September 10, 2008 Ok i am using this free rte and i have the following code <?php function freeRTE_Preload($content) { // Strip newline characters. $content = str_replace(chr(10), " ", $content); $content = str_replace(chr(13), " ", $content); // Replace single quotes. $content = str_replace(chr(145), chr(39), $content); $content = str_replace(chr(146), chr(39), $content); // Return the result. return $content; } ?> <form method="get" action=""> <!-- Include the Free Rich Text Editor Runtime --> <script src="../js/richtext.js" type="text/javascript" language="javascript"></script> <!-- Include the Free Rich Text Editor Variables Page --> <script src="../js/config.js" type="text/javascript" language="javascript"></script> <!-- Initialise the editor --> <?php if(isset($_GET['freeRTE_content'])) { $content = $_GET['freeRTE_content']; echo $content; } else { // Send the preloaded content to the function. $content = freeRTE_Preload("<i>This is some <b><br>preloaded</b> content</i>") ?> <script> initRTE('<?= $content ?>'); </script> <input type="submit" name="submit"> </form> <?php } ?> When i click submit the rte content appears in the URL like so http://www.rubberduckiee.co.uk/admin/RTE/code/addnote.php?freeRTE_content=%3Ci%3EThis+is+some+%3Cb%3E%3Cbr+%2F%3Epreloaded%3C%2Fb%3E+content%3C%2Fi%3E but the RTE is displayed and not the content and i dont know why Link to comment https://forums.phpfreaks.com/topic/123608-problem-with-getting-form-variable/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.