SMF Code Mod

PopUpSteve

Administrator
Staff member
Gold Supporting Member
Dec 22, 2002
21,146
Southeastern PA
Modified the "/Themes/default/PersonalMessage.template.php" script to allow for input of the SUBJECT field from the URL.

Start Line Line: 1010

ORIGINAL LINE
Code:
<input type="text" name="subject" value="', $context['subject'], '" tabindex="', $context['tabindex']++, '" size="60" maxlength="60" />

NEW LINES
Code:
<!-- Then INPUT line for the PM Subject has been replaced so that GETs can be used and the Subject line contents obtained from the URL -->
<!-- ================================================================================================================================= -->
<!-- Original Line -->
<!-- <input type="text" name="subject" value="', $context['subject'], '" tabindex="', $context['tabindex']++, '" size="60" maxlength="60" /> -->
<!-- New Line -->
<input type="text" name="subject" value="', !empty($_GET['subject']) ? $_GET['subject'] : $context['subject'], '" tabindex="', $context['tabindex']++, '" size="60" maxlength="60" />
<!-- ================================================================================================================================= -->

It will now allow input from the URL as follows:
Code:
http://www.popupportal.com/index.php?action=pm;sa=send;u=12754,29367,12878,4764;subject=Bogus%20Acronyms%20-%20JimmyJohn
 
P

pgordemer

Guest
I don't recommend you do that code. That is a spam script waiting to happen as now someone can register and write a script that will create the messages in multiple forums at once then leave you the mess to clean up.
 




Top