<fake_person>
<goto url="http://#this_domain#/">
<BREAK>
</fake_person>
<var _submit_btn_txt = "Send Invites >">
<div class="noverflow">
<div style="float:right; width:140px;">
<img src="http://#this_domain#/?&f=site-#site_id#&picwidth=140" border="0">
</div>
<div style="margin-right:180px;">
<div class="noverflow"><div style="margin-bottom:0.36em; float:left;">
<tag.roundedDiv color="##fdc">
<div style="padding:5px;">
<h3 style="margin:0px;">Super Secret Invite Page</h3>
</div>
</tag.roundedDiv>
</div></div>
<var _did_submit = 0>
<var _invalid_fields = "">
<if isdefined("POST.Submit")>
<var _did_submit = 1>
<if POST.first_name EQ "" OR POST.first_name EQ "(first)">
<var _invalid_fields = _invalid_fields & "," & "first_name">
</if>
<if POST.last_name EQ "" OR POST.last_name EQ "(last)">
<var _invalid_fields = _invalid_fields & "," & "last_name">
</if>
<if POST.activity EQ "" OR POST.activity EQ "(activity)">
<var _invalid_fields = _invalid_fields & "," & "activity">
</if>
<var _tst = trim(replace(POST.emails,",",CHR(10),"all"))>
<if _tst EQ "">
<var _invalid_fields = _invalid_fields & "," & "emails">
</if>
<if _invalid_fields EQ "">
<!--- send the email(s) --->
<!--
<loop list="#_tst#" index="i">
<try><email to="#i#" subject="#escapeMarkup(client_name)# wants you to try iqtpi">Dear #escapeMarkup(POST.first_name)# #escapeMarkup(POST.last_name)#,
Please make an account on iqtpi so we can
#escapeMarkup(POST.activity)# as soon as possible.
Thanks!
- #escapeMarkup(client_firstname)#
--
sent by the friendly robots at iqtpi</email><catch></catch></try>
</loop>
-->
<div class="noverflow"><div style="margin-bottom:0.36em; float:right; min-width:67%;">
<tag.roundedDiv color="##ffa">
<div style="padding:14px;">
<h4>Invites Sent.</h4>
<p>
Thanks for spreading the word!
</p>
<p>
<a href="http://#this_domain#/"><b>iqtpi home</b></a>
|
<a href="http://#this_domain#/People">more people</a>
|
<a href="http://#this_domain#/Invite">more invites</a>
</p>
</div>
</tag.roundedDiv>
</div></div>
</if>
</if>
<if _did_submit EQ 0 OR _invalid_fields NEQ "">
<postform>
<tag.roundedDiv color="##ffc"><div style="padding:7px;"><small><small>
<if _invalid_fields EQ "">
<p>
Oh no! It looks like you've found our super secret invite page. You can use this
page to invite people to iqtpi, but only if you promise not to tell them about the
super secret invite page.
</p>
<p>
<b>In fact,</b> we'll do most of the writing for you, just to be safe.
</p>
</if>
<if _invalid_fields NEQ "">
<p>
<b>You need to fill in ALL OF the blanks.</b>
</p>
<else>
<p>
You just need to fill in the blanks.
</p>
</if>
</small></small></div></tag.roundedDiv>
<div style="margin-right:5em; margin-left:2em; margin-top:0.36em;">
<tag.roundedDiv color="##eef">
<div style="padding:5px;">
<div class="noverflow" style="padding-bottom:5px; border-bottom:1px solid black;">
<div style="float:left; width:2.4em;"><b>To:</b></div>
<div style="margin-left:3em;"><small>
<div><textarea name="emails" id="emails" style="display:inline; width:80%; background:##f3f3ff; font-family:Tahoma,Arial,Sans-Serif; font-size:1em; height:36px;"
><if isdefined("POST.emails")>#escapeMarkup(POST.emails)#<else>(enter emails)</if></textarea></div>
<div style="color:##555; padding-top:3px;"><small>
Enter a list of email addresses. Type one email address per line.
</small></div>
</small></div>
</div>
<P>MESSAGE FROM #UCASE(ESCAPEmARKUP(CLIENT_NAME))#</P>
<p>
Dear
<select name="first_name">
<option value="">(first)</option>
<ensure variable="POST.first_name" value="">
<loop list="Ralphie,Cuckoo,Old,Agent,Mrs.,Emperor,Queen,Bob,J." index="i">
<option value="#i#" <if POST.first_name EQ i>selected</if>>#i#</option>
</loop>
</select>
<select name="last_name">
<option value="">(last)</option>
<ensure variable="POST.last_name" value="">
<loop list="Rutherford,Squareshoes,Mouse,Fentriss,Squiggles,K.,Bluth" index="i">
<option value="#i#" <if POST.last_name EQ i>selected</if>>#i#</option>
</loop>
</select>,
</p>
<p>
Please make an account on iqtpi.com so we can
<select name="activity">
<option value="">(activity)</option>
<ensure variable="POST.activity" value="">
<loop list="be internet buddies,play with unfurlme.com,make our friends jealous,become celebrities,get this over with,throw a party" index="i">
<option value="#i#" <if POST.activity EQ i>selected</if>>#i#</option>
</loop>
</select>
as soon as possible.
</p>
<p>
Thanks!
<br>- #escapeMarkup(client_firstname)#
<br>
</p>
<p>
--
<br>sent by the friendly robots at iqtpi
</p>
</div>
</tag.roundedDiv>
</div>
<div style="margin-left:18em; margin-top:0.36em;">
<tag.roundedDiv color="##dfc">
<input type="submit" name="Submit" value="#_submit_btn_txt#"
style="display:block; width:99%; text-align:center; cursor:pointer; border:0px solid white; background:##dfc; font-size:1.6em;">
</tag.roundedDiv>
</div>
</postform>
<tag.jquery>
<script type="text/javascript">
$(document).ready(function() {
$('##emails').bind('click focus', function() {
var _v = $(this).val();
if (jQuery.trim(_v.toLowerCase()) == '(enter emails)') {
$(this).val('');
$(this).select();
}
});
$('##emails').keydown(function() {
if ($(this).val().indexOf('\n',2) > 3) {
$(this).animate({'height':'92px'},180);
}
else {
$(this).animate({'height':'36px'},180);
}
});
$('##emails').bind('focus keyup change', function() {
var _v = $(this).val();
var _new = _v.replace(/,/g,'\n');
var _s = _new.split('\n');
if (_s.length > 1) {
var _newer = '';
var i = 0;
while (i < _s.length-1) {
var _line = jQuery.trim(_s[i]);
if (_line && isValidEmail(_line)) {
var _newer = _newer + '\n' + _line;
}
var i = i + 1;
}
_newer = _newer + '\n' + _s[_s.length-1];
try {
var _newer = _newer.replace('\n','');
} catch(err) {}
var _new = _newer;
}
if (_new !== _v) {
$(this).val(_new);
}
});
$('##emails').bind('blur', function() {
var _v = $(this).val();
if (jQuery.trim(_v) == '') {
$(this).val('(enter emails)');
}
});
});
function isValidEmail(str) {
return (str.indexOf(".") > 2) && (str.indexOf("@") > 0);
}
</script>
</if>
</div>
</div>