Jump to content

searls03

Members
  • Posts

    907
  • Joined

  • Last visited

Everything posted by searls03

  1. so I need action to be dashboard.php, but I need it to go to message.php.........
  2. .............this is going to be like a mail system.........I need the link to ACT as a button, not look like one..............not button as a link.......
  3. how do I make a link as a submit button? action is dashboard.php. help please
  4. ok, so this doesn't work: <?php if (!$_GET[message_id]){ ?> <SCRIPT LANGUAGE="JavaScript"> <!-- function checkAll(field) { for (i = 0; i < field.length; i++) field[i].checked = true ; } function uncheckAll(field) { for (i = 0; i < field.length; i++) field[i].checked = false ; } --> </script> <?php $select = mysql_query("SELECT * FROM members") or die(mysql_error()); while ($member = mysql_fetch_array($select)) { echo '<input type="checkbox" name="user[]" value="'.$member[name].'">'.$member[name].'<br>'; } ?> <br> <input type="button" name="CheckAll" value="Check All" onClick="checkAll(document.form1.user)"> <input type="button" name="UnCheckAll" value="Uncheck All" onClick="uncheckAll(document.form1.user)"> <? } ?>
  5. ok, here is a snippet of code, how do I make it if the message is unread, the $from will be bold, if not, it is normal?
  6. ok, do you have a website to help me with that?
  7. sorry, I am not talking about the comment page, but the original posting page that we originally started talking about........
  8. ok, so how do I make it so that on the new message page, how do I make it so that I can have one of those check boxes that select all the check boxes?
  9. but I need the replies in a database...........................how do I do that? or is it I need like messageid userid and the comment and just link them together?
  10. how can I make it so people can reply to the message............without a limit..........I can't use table associations in database........
  11. yep, I realized that!!!!!!!I got it working now!!!!!! :D :D :D :D :D :D
  12. so now tyhe content and recipient is posting...........not from1 or title?
  13. what is the code that adds to database? or is it there already?
  14. I tried changing those and i don't believe it worked......let me go ahead and post all of it: <form id="form1" name="form1" method="post" action="newmess.php"> <p>Subject: <label for="subject"></label> <input type="text" name="subject" id="subject" /> </p> <p> <?php $select = mysql_query("SELECT * FROM members") or die(mysql_error()); while ($member = mysql_fetch_array($select)) { echo '<input type="checkbox" name="user[]" value="'.$member[name].'">'.$member[name].'<br>'; } ?> </p> <p> <label for="content">Content:</label> <textarea name="content" id="content" cols="45" rows="5"></textarea> <input type="hidden" name="from" id="from" value='<?php echo $name; ?>' /> </p> <p> <input type="submit" name="submit" id="submit" value="Post" /> </p> </form> <p> </p> <p> </p> <p> </p> <p> </p> <p> </p> <p> </p> and here is the post again: <?php $members = explode(',', str_replace (' ', '', $_POST[recipient])); foreach ($members as $member){ if ($_POST[recipient]){ foreach ($_POST[recipient] as $key => $value){ // [..] code that adds the message to the database $content = $_POST['content']; $user = $_POST['recipient']; $from = $_POST['from1']; $subject = $_POST['title']; $query ="insert into messages(title, content, recipient, from1) VALUES ('$subject', '$content', '$user','$from')"; mysql_query($query) or die('Error, query failed'); } } } ?> I may have changed some stuff in that.....
  15. don't I need like a loop or something that runs the submit?
  16. anyone know what I am talking about???????? :confused: :confused:
  17. I don't believe I put things where they are supposed to be..........
  18. what is wrong with this, the recipients are not posting........: <?php $members = explode(',', str_replace (' ', '', $_POST[to])); foreach ($members as $member){ if ($_POST[user]){ foreach ($_POST[user] as $key => $value){ // [..] code that adds the message to the database $id = $_POST['id']; $content = $_POST['content']; $user = $_POST['recipient']; $from = $_POST['from1']; $subject = $_POST['title']; $query ="insert into messages(title, content, recipient, from1) VALUES ('$subject', '$content', '$user','$from')"; mysql_query($query) or die('Error, query failed'); } }} ?>
  19. how do I make it auto add columns, my hosting service does not support relations in it.
  20. Let me make this clear really quick, I am not talking about this forum. Ok, so how do I set up a way that I can make a simple messaging system on my website and make it so that I can have check boxes of who I can send a message to on my website. I have a recipient field and I need to know how I can make it so that only the specific members that are checked will get the message.........does this make sense?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.