I had been courting a high profile business prospect, but after a few months my prospect was becoming increasingly distant. One morning after I had made some follow up calls, my prospect called me right back stating he had seen a news story about my company on Yahoo news. This is the type of instant gratification and credibility I have experienced working with Grossi Web. -- Bob : Dorfman Capital

Website Marketing

Adding Referring URLs to RS Form


1. Back up the site files of the site you are working on.

2. Login to the backend of the site(www.domain.com/administrator) mouse-over Extensions -> click on Template Manager and check to see which template is in use as default (you don't need to do/change anything, you just need to know which template files you will be working with)


3. Go to Filezilla (or your preferred FTP tool) and connect to the relevant site. Browse out to the Templates folder, go into the directory structure of your active template and download the index.php.


4. When you have the file downloaded, open it up in dreamweaver (or notepad) and search for the closing head tag  - </head>

- Add this piece of code above it (as per below image):

//$document->setGenerator('Atlanta Web Design, Search Engine Optimization, and Internet Marketing Company | Grossiweb.com');

if ($_SESSION['source']=="") {

if($_SERVER['HTTP_REFERER']) { // referred from another web page


} //else {

//$_SESSION['source'] = "http://www.grossiweb.com/" ;// typed yourdomain.com directly into browser






5. Save the file and upload it to the same directory - templates/{template name}



1. Go to filezilla again, and go up to the root directory - Go to the components->com_rsform->controller directory and download the functions.php file to your hard drive (please note there are two files functions.php and functions.js - DO NOT TOUCH THE functions.js FILE)


2. When you have the functions.php file downloaded, open it up in dreamweaver and search for //mail admins


4. Replace the code that was within //mail admins and the closing } tag above functionRSgetSubmissionValue ($SubmissionId, $ComponentId) with this code:

//mail admins

$recipients = explode(',',$adminEmail['to']);


foreach($recipients as $recipient)


$adminEmail['text']=$adminEmail['text']."<p>Refering Url: ".$_SESSION['source']."</p><p>test: ".$_SERVER['HTTP_REFERER']."</p><p>IP: ".$_SERVER['REMOTE_ADDR']."</p>";

//$adminEmail['text']=$adminEmail['text']."<p>Refering Url: ".$_SESSION['source']."</p>";


$adminEmail['text'] .="<p>Refer ID: ".$_GET['referid']."</p>";

$RSadapter->mail($adminEmail['from'], $adminEmail['fromName'], $recipient, $adminEmail['subject'], $adminEmail['text'], $adminEmail['mode'], !empty($adminEmail['cc']) ? $adminEmail['cc'] : null, !empty($adminEmail['bcc']) ? $adminEmail['bcc'] : null, $adminEmail['files'], !empty($adminEmail['replyto']) ? $adminEmail['replyto'] : '');


$thankYouMessage = RSprocessField($r['Thankyou'],$SubmissionId);


// SESSION quick hack - we base64 encode it here and decode it when we show it

$_SESSION['form'][$formId]['thankYouMessage'] = base64_encode($thankYouMessage);

$_SESSION['form'][$formId]['submissionId'] = $SubmissionId;




return false;



5. Save the file, upload the file back to where it was (/public_html/components/com_rsform/controller) and test the form to see if it works. Please also go to backend and click on RS Form Component under Components -> RSForms PRo and ensure that everything is working correctly.

ALWAYS BACKUP THE SITE FIRST BEFORE YOU START - So we can revert back if accidents happen (and they do happen)