175 lines
5.4 KiB
PHP
175 lines
5.4 KiB
PHP
<?php
|
|
require("../functions.php");
|
|
// Define variables for file names
|
|
$pdf_name = "STAFF-STATE-TAXLIENS-COURT-L4D1-Letter4Day1-Court-Of-Record-First-Letter-Direct-688-INQUIRY-Challenge-letter.pdf";
|
|
$html_format_name = "STAFF-STATE-TAXLIENS-COURT-L4D1-Letter4Day1-Court-Of-Record-First-Letter-Direct-688-INQUIRY-Challenge-letter_FORMAT.html";
|
|
|
|
//collect required POST form's input
|
|
$experian_report = "";//$_POST["experian_report"];
|
|
$name_address = nl2br($_POST["name_address"]);
|
|
$records = nl2br($_POST["records"]);
|
|
$report_file_name = 0; //$_POST["report_file_name"];
|
|
|
|
$report_name_prefix = "";
|
|
$address = "";
|
|
|
|
|
|
/* if($report_file_name == "1"){
|
|
|
|
$report_name_prefix = "Experian";
|
|
|
|
$address = '<table style="width:100%">
|
|
<tr><td>Lee Lundy</td><td>Experian North America</td><td>Experian</td></tr>
|
|
<tr><td>SVP Consumer Services</td><td>Vice President and Assistant General Counsel</td><td>PO Box 9701</td></tr>
|
|
<tr><td>Experian NCAC</td><td>Office of the Corporate Counsel</td><td>Allen, TX 75013</td></tr>
|
|
<tr><td>701 Experian Pkwy</td><td>Ann Sterling (or ACTING VP/AGC)</td><td></td></tr>
|
|
|
|
<tr><td>Allen, TX 75013</td><td>475 Anton Blvd</td><td></td></tr>
|
|
<tr><td></td><td>Costa Mesa, CA 92626</td><td></td></tr>
|
|
|
|
</table> ';
|
|
|
|
} else if($report_file_name == "2"){
|
|
|
|
$report_name_prefix = "Equifax Confirmation";
|
|
|
|
$address = '<table style="width:100%">
|
|
<tr><td>Katherine Dunn</td><td>Equifax Information Services</td><td>Equifax Information Services</td></tr>
|
|
<tr><td>Assistant General Counsel</td><td>PO BOX 740241</td><td>PO BOX 740256</td></tr>
|
|
<tr><td>Equifax LLC</td><td>Atlanta, GA 30374</td><td>Atlanta, GA 30374</td></tr>
|
|
<tr><td>1550 Peachtree St</td><td></td><td></td></tr>
|
|
|
|
<tr><td>NE Atlanta, GA 30309</td><td></td><td></td></tr>
|
|
|
|
|
|
</table> ';
|
|
} else if($report_file_name == "3"){
|
|
|
|
$report_name_prefix = "TransUnion File";
|
|
|
|
$address = '<table style="width:100%">
|
|
<tr><td>Gary S. Friedlander</td><td>TransUnion</td><td>TransUnion</td></tr>
|
|
<tr><td>Vice President & Division General Counsel for TransUnion LLC,</td><td>PO Box 1000</td><td>PO Box 2000</td></tr>
|
|
<tr><td>Office of the General Counsel/td><td>Chester, PA</td><td>Chester, PA</td></tr>
|
|
<tr><td>Transunion Corp.</td><td>19022-1000</td><td>19016-2000</td></tr>
|
|
|
|
<tr><td>555 W. Adams Street</td><td></td><td></td></tr>
|
|
<tr><td></td><td>Chicago IL 60661</td><td></td></tr>
|
|
|
|
</table> ';
|
|
}
|
|
*/
|
|
|
|
// the unique pdf filename which will be saved on server
|
|
$file_name = mt_rand(0, 1000).time().'_'.$pdf_name;
|
|
|
|
if(isset($name_address)){
|
|
|
|
//get html content from pre defined format
|
|
$today = date("d M, Y");
|
|
$html = file_get_contents($html_format_name);
|
|
|
|
$personal_tracking_number = getPersonalTrackingNumber();
|
|
|
|
if(empty($_POST['clientId'])){
|
|
$varList = array(
|
|
'__EXPERIAN_REPORT__', '__NAME_ADDRESS__','__RECORDS__' ,'__TODAY__',
|
|
'__SOCIAL_SECURITY_NUMBER__' ,'__ADDRESS__' ,'__REPORT_NAME_PREFIX__'
|
|
|
|
|
|
);
|
|
|
|
|
|
$valueList = array(
|
|
$experian_report, $name_address,$records,$today,$personal_tracking_number,$address,$report_name_prefix);
|
|
|
|
}
|
|
//$deletionArray = array();
|
|
|
|
/*
|
|
$serialLineHTML = "";
|
|
$fileNameArray = array(
|
|
"Copy of SS Card",
|
|
"Copy of State Photo ID",
|
|
"Copy of PROOF of my CURRENT and ONLY REQUISITE REPORTED ADDRESS"
|
|
|
|
);
|
|
|
|
|
|
for($i=1;$i<= 3;$i++){
|
|
if(isset($_FILES["image".$i]["name"]) && !empty($_FILES["image".$i]["name"])){
|
|
|
|
$imagefilename[$i] = mt_rand(0, 1000).time().'_'.$_FILES["image".$i]["name"];
|
|
move_uploaded_file($_FILES["image".$i]["tmp_name"], $imagefilename[$i]);
|
|
$deletionArray[] = $imagefilename[$i];
|
|
|
|
|
|
|
|
$varList[] = "__image".$i."__";
|
|
$valueList[] = $imagefilename[$i];
|
|
|
|
$start = "__START".$i."__";
|
|
$end = "__END".$i."__";
|
|
|
|
$html = str_replace(array($start,$end),array("",""),$html);
|
|
|
|
$serialLineHTML = $serialLineHTML.$fileNameArray[$i-1]."<br/>";
|
|
|
|
|
|
} else {
|
|
|
|
$from = strpos($html, "__START".$i."__");
|
|
$to = strpos($html, "__END".$i."__");
|
|
|
|
$html = str_replace(substr($html,$from,($to-$from)+7+strlen($i)),"",$html);
|
|
|
|
}
|
|
}
|
|
|
|
|
|
if(!empty($serialLineHTML)){
|
|
$serialLineHTML = "See Enclosed:<br/>".$serialLineHTML;
|
|
}
|
|
|
|
$html = str_replace('__SERIAL_LINES__',$serialLineHTML,$html); */
|
|
|
|
if(empty($_POST['clientId'])){
|
|
for($i=1;$i<=5;$i++){
|
|
if(isset($_FILES["image".$i]["name"]) && !empty($_FILES["image".$i]["name"])){
|
|
|
|
$imagefilename[$i] = mt_rand(0, 1000).time().'_'.$_FILES["image".$i]["name"];
|
|
upload_media($imagefilename[$i],$_POST['image'.$i]);
|
|
$deletionArray[] = $imagefilename[$i];
|
|
|
|
|
|
|
|
$varList[] = "__image".$i."__";
|
|
$valueList[] = $imagefilename[$i];
|
|
|
|
$start = "__START".$i."__";
|
|
$end = "__END".$i."__";
|
|
|
|
$html = str_replace(array($start,$end),array("",""),$html);
|
|
|
|
// $serialLineHTML = $serialLineHTML.$fileNameArray[$i-1]."<br/>";
|
|
|
|
|
|
} else {
|
|
|
|
$from = strpos($html, "__START".$i."__");
|
|
$to = strpos($html, "__END".$i."__");
|
|
|
|
$html = str_replace(substr($html,$from,($to-$from)+7+strlen($i)),"",$html);
|
|
|
|
}
|
|
}
|
|
}
|
|
include("../common_image_file.php");
|
|
require("../common_file.php");
|
|
|
|
} else {
|
|
$url = "http://".$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']."STAFF-STATE-TAXLIENS-COURT-L4D1-Letter4Day1-Court-Of-Record-First-Letter-Direct-688-INQUIRY-Challenge-letter.html";
|
|
header("Location:".$url);
|
|
}
|
|
|
|
?>
|