summaryrefslogtreecommitdiff
path: root/email.php
diff options
context:
space:
mode:
authordavehauenstein <davehauenstein@d4e419ec-0920-11de-bbfd-a7c1bc4c261e>2009-04-16 14:58:31 +0000
committerdavehauenstein <davehauenstein@d4e419ec-0920-11de-bbfd-a7c1bc4c261e>2009-04-16 14:58:31 +0000
commit023a90eba43c51519943f58724fa51d373a1974d (patch)
treed95b8f0710c619290baa7e97abbee33e14f2d4dc /email.php
parentc53d8d026021f97075fb2f4940ba22793c38fb6e (diff)
downloadreadability-simple-023a90eba43c51519943f58724fa51d373a1974d.tar.bz2
readability-simple-023a90eba43c51519943f58724fa51d373a1974d.zip
added spanish translation, minor updates to email: link and title werent being passed along, updated subject
git-svn-id: http://arc90labs-readability.googlecode.com/svn/trunk@33 d4e419ec-0920-11de-bbfd-a7c1bc4c261e
Diffstat (limited to 'email.php')
-rw-r--r--email.php20
1 files changed, 11 insertions, 9 deletions
diff --git a/email.php b/email.php
index a83b97a..4791fc1 100644
--- a/email.php
+++ b/email.php
@@ -28,11 +28,13 @@
//FILTER DATA
- $from = $filters->filter($_POST['from']);
- $to = $filters->filter($_POST['to']);
- $to = array_map('trim', split(',', $to));
- $note = $filters->filter($_POST['note']);
- $key = $filters->filter($_POST['key']);
+ $from = $filters->filter($_POST['from']);
+ $to = $filters->filter($_POST['to']);
+ $to = array_map('trim', split(',', $to));
+ $note = $filters->filter($_POST['note']);
+ $key = $filters->filter($_POST['key']);
+ $pageUrl = $filters->filter($_POST['pageUrl']);
+ $pageTitle = $filters->filter($_POST['pageTitle']);
if(!Readability::validateSecureKey($key))
{
@@ -77,7 +79,7 @@
$mailer = new Zend_Mail_Transport_Smtp('smtp.googlemail.com', Array(
'auth' => 'login',
'username' => 'readability@arc90.com',
- 'password' => 'arc90inc',
+ 'password' => '*******',
'ssl' => 'ssl',
'port' => 465,
));
@@ -105,7 +107,7 @@
$mail->addTo($toAddress);
}
- $mail->setSubject("Arc90 Readability: {$pageTitle}");
+ $mail->setSubject("Sent via Readability: {$pageTitle}");
try
{
@@ -232,7 +234,7 @@
public static function hasValidParams()
{
- $requiredParams = array('from', 'to', 'note', 'key');
+ $requiredParams = array('from', 'to', 'note', 'key', 'pageTitle', 'pageUrl');
$sentParams = array_keys($_POST);
foreach($requiredParams as $required)
{
@@ -371,7 +373,7 @@
<h2>Email Page</h2>
<?php if($page == 'form'){ ?>
- <form action="" method="post" accept-charset="utf-8" id="send-email-form">
+ <form action="./email.php" method="post" accept-charset="utf-8" id="send-email-form">
<div class="section">
<label for="from">From :</label>
<input type="text" name="from" id="from" value="<?php echo Readability::getParam('from') ?>" <?php echo Readability::getErrorClass('from', $errors); ?> />