Back to Modification Graveyard

Pre-Defined PM Text For each user
Mod Version: 1.0.0, by Omranic

This thread is in the Modification Graveyard.
vB Version: 3.5.3 Rating: (0 vote - 0 average) Installs: 3
Released: 13 Feb 2006 Last Update: 13 Feb 2006 Downloads: 7
Not Supported Template Edits  

This Mod isn't supported any more!

hello every one here,

This hack is very simple & effective, it give every user the ability to specify a Pre-Defined PM Text to be shown automatically in PM Sending text area.

simply two profile fields added & one template edit

Ist go to admincp & click "Add New User Profile Field"
Profile Field Type: Single-Selection Radio buttons
click continue
Title: Pre-Defined PM text active or not.
Description: Here you can determine is this option is on or off, if on select yes if not select off.
Options:
Code:
No
Yes
Set Default: Yes
Display Order: leave it as it is
Field Required: No
Field Editable by User: Yes
Private Field: No
Field Searchable on Members List: No
Show on Members List: No

leave other options as it is & go to the last option "Display Page" & select the value "Options Messaging & Notification".

Now Press Save

_________________________________________

Now we will add the second Profile field
Ist go to admincp & click "Add New User Profile Field"
Profile Field Type: Multiple-Line Text Box
click continue
Title: Pre-Defined PM text.
Description: Here you can write your Pre-Defined PM text.
Default Value: leave it blank
Max length of allowed user input: 500
Display Size: 63
Text Area Height: 6
Display Order: leave it as it is
Field Required: No
Field Editable by User: Yes
Private Field: No
Field Searchable on Members List: No
Regular Expression: leave it blank

leave other options as it is & go to the last option "Display Page" & select the value "Options Messaging & Notification".

Now Press Save

_________________________________________

No from User Profile Field Manager see the name of each profile field we have added, the first one we added I called it fieldX & the second I called it fieldY So note for this, you must replace X by the number of the first field we have added & Y with the second field we have added in the following template edit

go to template "editor_toolbar_on" & search in it for the following code:
HTML Code:
<textarea name="message" id="{$editorid}_textarea" rows="10" cols="60" style="width:$stylevar[messagewidth]; height:{$editor_height}px" tabindex="1" dir="$stylevar[textdirection]">$newpost[message]</textarea>
& replace it by the following code:
HTML Code:
<textarea name="message" id="{$editorid}_textarea" rows="10" cols="60" style="width:$stylevar[messagewidth]; height:{$editor_height}px" tabindex="1" dir="$stylevar[textdirection]">$newpost[message]<if condition="THIS_SCRIPT == 'private'"><if condition="$bbuserinfo['fieldX'] == 'Yes'">$bbuserinfo[fieldY]</if></if></textarea>
click save

Now you are done

Known Issues: when forwarding or replying to a PM the Pre-Defined PM text will be written also after the PM quoted

Don't forget to click

Download

This modification cannot be downloaded.


vblts.ru supports vBulletin®, 2022-2025