![]() |
Default PM Subject Line
I made a little 2 line hack (I guess you could almost call it that) that will input a default subject line in a new PM. I always get tired of having to redo all of my new PMs because I preview it or try to send it and get the error that I didn't fill out all of the information. This way, it will always be there, preview or not. What I would like to ask is this: Does anyone have any good ideas for a default line that will work for the entire board? [high]Any[/high] ideas will be appreciated and welcomed.
|
Can't you just edit the PM templates? :confused:
|
I did the same thing for my forums a long time ago.
What I used as a subject when none is entered is "No subject entered". :) |
Quote:
@ Erwin - LOL I never thought of that one. Thanks. Right now I have "Just a note to say hello" and thought about "From the desk of xxx (the username of the poster would go here). On the forums, I have it default to "Re ; threadtitle" if there is no post title. If they change it, it will stay at the new title. |
Well you could use conditionals in templates (the hack)...:)
|
That's true, I never even thought of that. I have Logician's hack already installed. Maybe I'll play with it and see what I can come up with. Thanks. ;)
|
@filburt1 - Here's what I came up with. The code in the php is only 3 small lines and this is what I need to do in the template to get the same thing. Which is better?
Quote:
|
Actually, it can be done in the javascript in the send pm template. There is a check when the submit button is clicked. If the subject is blank, a box pops up. You can add a check right before that line so that if the title is blank, the title is set to "No Subject Entered"
I did it the PHP way as well in both private.php and private2.php, but I am pretty sure the javascript is all that is required. Amy |
You lost me here. Where would you do the check for that at? Just before the submit button? And I don't think it would work there for a private message preview, though, would it?
|
In priv_sendprivmsg
Find: Code:
if (theform.touser.value=="" || theform.message.value==""|| theform.title.value=="" ) { Code:
Amy |
All times are GMT. The time now is 09:27 PM. |
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:
|