techiefreak05 Posted August 24, 2006 Share Posted August 24, 2006 i have a PM system on my site..it works fine.. but im lacking a reply button ..... how would i add one?? that goes back to the send message page ... and fills the form in with the message and subject and to ..?? Quote Link to comment Share on other sites More sharing options...
.josh Posted August 24, 2006 Share Posted August 24, 2006 make a form on your page that shows the message, with the stuff you want to send to the reply screen, like, original message, user, etc.. as hidden inputs. then make a submit button called 'reply' or whatever, and the form action whisks you away to some other replay page, and you have your info in the $_POST array just like any other form. On your new page, just auto-fill your reply fields like the 'to:' input field with the $_POST values. If you made your own pm system then you should know how to do all of this already... Quote Link to comment Share on other sites More sharing options...
techiefreak05 Posted August 24, 2006 Author Share Posted August 24, 2006 Well, I want to have something like this: ex..../sendMessage.php?id=6where the form will be filled out with the message, subject, to,etc. with the id 6.cuz all my messages have an ID so.. if i go to ?id=6, the message that has the id of 6 would be in the message box Quote Link to comment Share on other sites More sharing options...
.josh Posted August 24, 2006 Share Posted August 24, 2006 so if all of your messages have their own unique id, and you want to pass them via url, what's to stop someone from putting in random id numbers in the address bar and having other people's messages popup on their reply form? Quote Link to comment Share on other sites More sharing options...
techiefreak05 Posted August 24, 2006 Author Share Posted August 24, 2006 i was thinknig of that ... well could i do some sort of mysql query? like SELECT * FROM messages where id = $id AND to = '$_SESSION[username]'thats how i make sure that only the user that was supposed to get the message.. gets the messageidk ... 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.