Navaldesign wrote:What's the version ?
// DBTS Form Processor Extension version 2.7.5.1
Navaldesign wrote:What's the version ?
Yes, I did upgrade.Navaldesign wrote:Please upgrade, as I mentioned this version had a bug. Current version is 2.7.5.3
Code: Select all
http://maps.google.com/maps?q=
Code: Select all
http://maps.google.com/maps?q=53.774891736079375,-2.6968002319335938
Code: Select all
<?
//set the random id length
$random_id_length = 8;
//generates a random id encrypt it and store it in $rnd_id
$rnd_id = crypt(uniqid(rand(),1));
//removes any slashes that might have been generated
$rnd_id = strip_tags(stripslashes($rnd_id));
//Removing any . or / and reversing the string
$rnd_id = str_replace(".","",$rnd_id);
$rnd_id = strrev(str_replace("/","",$rnd_id));
//finally take the first 8 characters from the $rnd_id
$rnd_id = substr($rnd_id,0,$random_id_length);
// I've added this later in the echo and e-mail
//echo "When contacting us please quote: $rnd_id";
//Converts the reference to uppercase
$rnd_id = strtoupper($rnd_id);
$_POST['Submission ID'] = $rnd_id; // This line adds in the POST superglobal the unique ID you created
$autoresponderend .= "\nWhen contacting us please quote: $rnd_id"; // This line adds to the autoresponder footer the message with the quote ID
?>
Code: Select all
<input type="text" id="Editbox7" style="position:absolute;width:200px;height:24px;border:0px #CCCCCC solid;background-color:transparent;font-family:Tahoma;font-size:13px;" name="ID" value="<?php
//set the random id length
$random_id_length = 5;
//generate a random id encrypt it and store it in $rnd_id
$rnd_id = crypt(uniqid(rand(),1));
//to remove any slashes that might have come
$rnd_id = strip_tags(stripslashes($rnd_id));
//Removing any . or / and reversing the string
$rnd_id = str_replace(".","",$rnd_id);
$rnd_id = strrev(str_replace("/","",$rnd_id));
//finally I take the first 5 characters from the $rnd_id
$rnd_id = substr($rnd_id,0,$random_id_length);
echo "ID: $rnd_id" ;
echo "";
?>"tabindex="1">
No, dident work. Do you have any idea of how i could get an unic id no in to the mails. Not using code like this?Navaldesign wrote:I'm sorry but I can't help you with custom coding. Using PHP code in a page that already contains PHP code and uses sessions, requires some coding experience on your end.
However, if you look at previous pages (but not sure if this is on this same thread or a different one) I had helped Kevinp implementing something similar.
However, if you set the functionin mode to "Debug" the processor will display the error on the screen and you will come to know what's causing the issue.
Code: Select all
<?
//set the random id length
$random_id_length = 8;
//generates a random id encrypt it and store it in $rnd_id
$rnd_id = crypt(uniqid(rand(),1));
//removes any slashes that might have been generated
$rnd_id = strip_tags(stripslashes($rnd_id));
//Removing any . or / and reversing the string
$rnd_id = str_replace(".","",$rnd_id);
$rnd_id = strrev(str_replace("/","",$rnd_id));
//finally take the first 8 characters from the $rnd_id
$rnd_id = substr($rnd_id,0,$random_id_length);
// I've added this later in the echo and e-mail
//echo "When contacting us please quote: $rnd_id";
//Converts the reference to uppercase
$rnd_id = strtoupper($rnd_id);
$_POST['Submission ID'] = $rnd_id; // This line adds in the POST superglobal the unique ID you created
$autoresponderend .= "\nWhen contacting us please quote: $rnd_id"; // This line adds to the autoresponder footer the message with the quote ID
?>
Hey Kevinp have you solved this yet?kevinp wrote:Naval
I thought I had it worked out but there are significant differences to the new processor.
I used to be able to add a unique ID to the email and success page by including the file below.
I saved this on the server as "random.php" then called it from the "After Form Data Reception Include URL" Include.Code: Select all
<? //set the random id length $random_id_length = 8; //generates a random id encrypt it and store it in $rnd_id $rnd_id = crypt(uniqid(rand(),1)); //removes any slashes that might have been generated $rnd_id = strip_tags(stripslashes($rnd_id)); //Removing any . or / and reversing the string $rnd_id = str_replace(".","",$rnd_id); $rnd_id = strrev(str_replace("/","",$rnd_id)); //finally take the first 8 characters from the $rnd_id $rnd_id = substr($rnd_id,0,$random_id_length); // I've added this later in the echo and e-mail //echo "When contacting us please quote: $rnd_id"; //Converts the reference to uppercase $rnd_id = strtoupper($rnd_id); $_POST['Submission ID'] = $rnd_id; // This line adds in the POST superglobal the unique ID you created $autoresponderend .= "\nWhen contacting us please quote: $rnd_id"; // This line adds to the autoresponder footer the message with the quote ID ?>
On the new version this doesn't seem to work. I added "include 'random.php';" After Form Data Reception Custom Processing but it doesn't pick it up. I know I'm missing something simple
Ahh, now it works perfect. Thank you for all your help.Navaldesign wrote:The method is correct. The only thing that Kevin has had to change is the code in the "Custom Processing":
include "random.php";
Cold this code then bee used to change the ex, Username, Password fields in to what ever? Like in the Formprocessor's email field?Navaldesign wrote:If the purpose is to have the HTML email, yes, I can do it, price can not be discussed here, you can contact me through my website contact form.
If the only reason is to use the words "username" and "password" in swedish, you can already do this.
OK. I will try to translate every login tool, in to Swedish. Wil'l see how it goesNavaldesign wrote:if you don't need the HTML emails, simply modify the wording in the Signup object code (after you convert it to Form)
Code: Select all
$crypt_pass
Code: Select all
$mailto = $newepost;
Code: Select all
<?php
$error_message = "";
if ($_SERVER['REQUEST_METHOD'] == 'POST')
{
$action = isset($_POST['action']) ? $_POST['action'] : '';
$mysql_server = 'mysql315.loopia.se';
$mysql_username = 'pers@f47255';
$mysql_password = '';
$mysql_database = 'fcab_se_db_4';
$mysql_table = 'USERS';
$success_page = './anslut.php';
if ($action == 'signup')
{
$newanvändarnamn = $_POST['användarnamn'];
$newlösenord = $_POST['lösenord'];
$newepost = $_POST['epost'];
$bekräftalösenord = $_POST['bekräftalösenord'];
$newnamn = $_POST['namn'];
$telefon = $_POST['telefon'];
$mobil = $_POST['mobil'];
$företag = $_POST['företag'];
$orgnr = $_POST['orgnr'];
$kategori = $_POST['kategori'];
$meddelande = $_POST['meddelande'];
if ($newlösenord != $bekräftalösenord)
{
$error_message = 'Lösenord och bekräfta lösenord är ej lika!';
}
else
if (!ereg("^[A-Za-z0-9_!@$]{1,50}$", $newanvändarnamn))
{
$error_message = 'Ogiltigt användarnamn, försök igen!';
}
else
if (!ereg("^[A-Za-z0-9_!@$]{1,50}$", $newlösenord))
{
$error_message = 'Ogiltigt lösenord, försök igen!';
}
else
if (!ereg("^[A-Za-z0-9_!@$.' &]{1,50}$", $newnamn))
{
$error_message = 'Ogiltigt namn, försök igen!';
}
else
if (!ereg("^.+@.+\..+$", $newepost))
{
$error_message = 'Ogiltig epost adress, försök igen!';
}
if (empty($error_message))
{
$db = mysql_connect($mysql_server, $mysql_username, $mysql_password);
mysql_select_db($mysql_database, $db);
$sql = "SELECT användarnamn FROM ".$mysql_table." WHERE användarnamn = '".$newanvändarnamn."'";
$result = mysql_query($sql, $db);
if ($data = mysql_fetch_array($result))
{
$error_message = 'Användarnamn upptaget, välj ett annat.';
}
}
if (empty($error_message))
{
$crypt_pass = md5($newlösenord);
$sql = "INSERT `".$mysql_table."` (`användarnamn`, `lösenord`, `namn`, `epost`, `active`, `telefon`, `mobil`, `företag`, `orgnr`, `kategori`, `meddelande`) VALUES ('$newanvändarnamn', '$crypt_pass', '$newnamn', '$newepost', 1, '$telefon', '$mobil', '$företag', 'orgnr', '$kategori', '$meddelande')";
$result = mysql_query($sql, $db);
mysql_close($db);
$mailto = $newepost;
$subject = 'Nytt konto hos Jobler.se';
$message = 'Nytt konto hos Jobler.se.';
$message .= "\r\nAnvändarnamn: ";
$message .= $newanvändarnamn;
$message .= "\r\nLösenord: ";
$message .= $newlösenord;
$message .= "\r\n";
$header = "From: noreply@jobler.se"."\r\n";
$header .= "Reply-To: noreply@jobler.se"."\r\n";
$header .= "MIME-Version: 1.0"."\r\n";
$header .= "Content-Type: text/plain; charset=utf-8"."\r\n";
$header .= "Content-Transfer-Encoding: 8bit"."\r\n";
$header .= "X-Mailer: PHP v".phpversion();
mail($mailto, $subject, $message, $header);
header('Location: '.$success_page);
exit;
}
}
}
?>