optikalefx Posted July 26, 2007 Share Posted July 26, 2007 i have this form that updates a database. the feild is called value and it has the attribute of longtext in phpmyadmin i can paste a whole 300 words or more and it works fine. but if i try to past that 300 words into my form, it doesnt do anything but i can do 20 words just fine, and 50. and i change those all i want to but when i try to paste in large ammounts of text, it just doesnt do it... longtext doenst have a character set ammount so that shouldnt be the problem, so i dont know what is Quote Link to comment Share on other sites More sharing options...
teng84 Posted July 26, 2007 Share Posted July 26, 2007 may we see your code Quote Link to comment Share on other sites More sharing options...
optikalefx Posted July 26, 2007 Author Share Posted July 26, 2007 <html> <FORM METHOD="POST" ACTION="http://www.4tenproductions.com/jrinput.php"> <?php $con = mysql_connect("xxxx","xxxx","xxxx"); mysql_select_db("update1", $con); $team = $_POST["teamchoice"]; $table = $_POST["table"]; $sql = mysql_query("SELECT value FROM $table WHERE fname='$team'"); while($row = mysql_fetch_array($sql)) { $text = $row['value']; } echo "<center>"; echo "<table border='0' cellpadding=10><tr><td>"; echo "<TEXTAREA NAME='teampage' ROWS=36 COLS=80>$text</TEXTAREA></td>"; echo "<td valign='middle' align='center'> To start a new paragraph type <p> </td></tr></table>"; echo "<br><center>"; echo "<INPUT TYPE='submit' value='Update'>"; echo "<INPUT type='hidden' name='teamchoice' value='$team'>"; echo "<INPUT type='hidden' name='table' value='$table'>"; ?> </form> </html> now whats odd, is i have this block of text that im trying to paste and post. the text can be seen here at www.4tenproductions.com/phptext.txt when i paste that whole block, it doesnt work, but if i paste just up to the word specializes than it does work ??? Quote Link to comment Share on other sites More sharing options...
redarrow Posted July 26, 2007 Share Posted July 26, 2007 set the text field to medium text try that and in all your forms the attubutes like name= use uppercase or lowercase for all not one or the over ok. Quote Link to comment Share on other sites More sharing options...
optikalefx Posted July 26, 2007 Author Share Posted July 26, 2007 good thought, still nothing. I would think if longtext didnt work, mediumtext wouldnt either. I keep thinking that the length is the problem, but it cant be because you can put in all the text if you do it through phpMyAdmin Quote Link to comment Share on other sites More sharing options...
jcarouth Posted July 26, 2007 Share Posted July 26, 2007 where is the form processing code? Quote Link to comment Share on other sites More sharing options...
redarrow Posted July 26, 2007 Share Posted July 26, 2007 we need your insert code not that code lol Quote Link to comment Share on other sites More sharing options...
optikalefx Posted July 26, 2007 Author Share Posted July 26, 2007 ha my bad <?php $con = mysql_connect("xxxx","xxxx","xxxx"); //connect to database mysql_select_db("update1", $con); //choose database $myText = $_POST["teampage"]; //the text you wrote from jrform.php variable $team = $_POST["teamchoice"]; //which page you selected variable $table = $_POST["table"]; // which table in the database we are in $sql = mysql_query("UPDATE $table SET value = '$myText' WHERE fname = '$team'"); // update the current table with the new text entered echo "<table border='0' width='100%' height='100%'><tr><td valign='middle' align='center'>"; //align the page vertically and horizontally echo "<form method='post' action='http://www.4tenproductions.com/jrlistpage.php'>"; //action will take you back to the list of pages to select from echo "<INPUT type='hidden' name='table' value='$table'>"; //keep track of the table we are in so you dont have to log back in echo "<input type='submit' value='Go back'></form></tr></td></table>"; //submit button and ending html tags ?> those 3 variables that are being brought in, they all work fine, ive tested that. i also commented the whole thing so you know what each part does. its like it allows for 250 words and then cuts off, but like i said in phpMyAdmin it works fine, i cant figure out why my textarea and my form wont do it. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.