Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Preview option in private mail?

Options
  • 10-05-2003 12:19pm
    #1
    Registered Users Posts: 648 ✭✭✭


    Any chance of adding a "Preview Post" option in private mail, like you get when sending public messages? I'd find it quite useful.
    Post edited by Shield on


Comments

  • Business & Finance Moderators, Entertainment Moderators Posts: 32,387 Mod ✭✭✭✭DeVore


    Would be nice but its just too much hacking for too little return :(
    It would mean hacking the renderer into the PM system.... every time the VBB guys choose to release a enw version!

    Hopefully its one of the things we will get when the holy grail of VBB 3.0 comes out...

    DeV.


  • Banned (with Prison Access) Posts: 16,659 ✭✭✭✭dahamsta


    You could do it with Javascript and templates DeV. In the PM compose template, add a Preview button like this:
    <form>
     <input type="button" value="Preview" 
      onClick="pmPreview=window.open('preview.php?touser=' + 
       document.vbform.touser.value + '&title=' + 
       document.vbform.title.value + '&iconid=' + 
       document.vbform.iconid.value + '&message=' + 
       document.vbform.message.value, 
        'pmPreview', 
        'width=600,height=450,scrollbars=1');
         return false">
    </form>
    
    Note that this mightn't work out of the box, I've had to wrap the code to avoid it going, like, over there ->

    The file preview.php can be an entirely new file that links into vB in the backend to render the post -- this should be relatively simple because vB renders posts in several places, so there's prolly a common function. Better still, put preview.php in a different directory and use chdir() to move execution into the vB directory. Then when you upgrade, you don't even have to move the file.

    adam


  • Closed Accounts Posts: 5,500 ✭✭✭Mercury_Tilt


    This post has been deleted.


Advertisement