![]() |
This is what the hack does: It let's you preview a message when you're editing it, you can only preview when you're posting or replying the way it is now:
It works on my testserver, but I've not tested on a 'live' forum, but it seems to be working allright... Instructions 1 Backup your editpost.php file!!! and open the original one... Then: after: PHP Code:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
Code:
<table width=100% border=0 cellspacing=1 cellpadding=4> insert the '$postpreview' variable at the appropiate place (look into the 'newthread' template for an example) and replace: Code:
<INPUT TYPE="Submit" NAME="SUBMIT" ACCESSKEY="S" VALUE="Submit Now"> Code:
<INPUT TYPE="Submit" NAME="preview" ACCESSKEY="P" VALUE="Preview"> |
I'll be working on the pm-preview btw
|
No-one's interested?
|
Sure i will use them both, I just wasn't doing much with hacks yet until 2.0 is released. I didn't want a beta 3 to come out and have to re-hack a bunch of stuff.
It would be great if you wrote a upgrade script that you ran and it automatically fixed the things, that way you could just update the script for each beta released. |
Hi there,
hopefully didn't overlook something in between, but I definetely would appreciate to use that hack! Does it work for 2.0.1? Did you have a solution meantime for PM Preview - I know there's a hack, just interested if you worked on it, too. Thanks, -Tom |
Yes Mas*Mind, I am very interrested in that hack !
I run v 2.2.1 is your hack fixed for that version ? any update since your former post ? waiting for news, see you |
great hack Mas*Mind
|
Thanks Mas*Mind! I really missed having the ability to preview my edited posts, especially when I'm using vB code. I keep finding myself using HTML instead and then I have to go in again and edit. This is a really good idea!
|
Does this work on 2.2.2?
|
Sweet Work!
|
I have installed it, but ist doesn?t work correct. :(
I can have a first preview and it works, but if I try to preview again, it posts the message. Any ideas? |
Three comments about this hack:
1. You do not need a separate template (editpost_postpreview). The contents of the existing template, newpost_postpreview, are almost exactly the same, but are a bit more polished in terms of HTML coding (including being the standard vBulletin table-within-a-table which I guess gives you the border or whatever). Plus, using the existing template saves space (even if only a tiny amount) in the database. (I tested that doing this works, and can confirm that it does indeed work properly to use the existing template. All you have to do is first of all, not create the new template, or delete it if you already did, then in editpost.php, change the part you added that says "editpost_postpreview" so that it says "newpost_postpreview".) 2. Whenever making a vBulletin .php file use a template it didn't use before, you should add it to the "$templateused" section at the top of the file. I'm told this saves a database query. You should do this regardless of what you do about my #1 above. 3. When you click the button to edit a post, then you click the Preview button, the edit is submitted and saved to the database. This means that whatever changes you made are saved before you tell it to save them! This is not the desired behavior of the Preview function. If you want to "preview" something, that means you want to see what it looks like, before you commit to it, right? Well, the mere act of previewing something now means you've committed the changes! This is not good. |
sorry guys, this was a beta for 2.01 if I'm correct. I've never tested it fully and never really released it fully (don't know why it says v2.2.2 before the title)
currently there's no change for me to work on this, so if a fellow hacker wants to do it: great :) |
I have fixed this long time ago, sorry I haven't posted it :p
It works perfect for vB2.2.x! @JJR512 We had the same thoughts, I also have just used the newpost_postpreview Template. I have attached the fixed version. |
Quote:
|
Yep, works fine now! :)
|
Works great on 2.2.2.
Thanks. |
Quote:
I installed perfectly without any problem. Just a couple of little things: 1) When an admin (me, for instance...) is previewing after edit an other user's post, the signature showed in preview mode is mine, instead of the user's one. When saved, everything works fine, as usual. 2) Html style question: how can I make the 'save changes' button selected by default as it was before adding a button just before ? I tried with 'tabindex' but ... :( Thanks a lot. Bye |
Quote:
Code:
<INPUT TYPE="Submit" NAME="SUBMIT" ACCESSKEY="S" VALUE="Submit Now"> I found this: Code:
<input type="submit" class="bginput" name="submit" accesskey="s" value="Save Changes" tabindex="3"> Thanks :) Alan (DWZ) |
Quote:
|
I'm using Mystics version on my forum and it stopped working after upgrading to v2.2.6. It seems to execute template 'standardredirect' in some way beacuse it's redirect to the post again after 1sec.
Please, can someone verify if this is working with v2.2.6. |
Quote:
I think, you have forgotten this step: Code:
Search for |
Yes, you're correct. I actually leaved it out since I thought both more or less did the same thing.
Many thanks Mystics :) |
So really,
Code:
<input type="submit" class="bginput" name="submit" accesskey="s" value="Save Changes" tabindex="3"> Code:
<input type="submit" class="bginput" name="submit" accesskey="s" value="Save Changes" tabindex="3"> Probably wouldn't hurt to change the tabindex= numbers for Preview, Save Changes & Reset Message. |
For anyone still using this hack, I have fixed the problem with the signature showing for the original poster instead of the person editing the post.
Change: PHP Code:
PHP Code:
|
works great on vbulletin 2.3 its a wonder why it isnt there as standard
|
very useful hack
thanks for it :) |
Flawless via 2.3.0
/me clicks install |
Very cool, i installed it, the only problem what i have is that the preview of the changes of the post looks good, but in the form the changes aren't there anymore. So i need to edit it again whenever i preview the edit post.
Anyone knows what could have caused that? Very ackward! :ermm: Ps: I am still running my faitfulll vb 2.2.7 |
Quote:
Just posting here to point out that that part of code isnt actually in the first post instructions :( So I missed it twice until I came further into the thread. just an FYI |
All times are GMT. The time now is 06:11 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|