Home | Products | Consulting | Forums | Support | Order | 1-800-752-0455
  Main
Index
Search
Posts
Who's
Online
Log
In

Home: Products: Listings Manager Add-ons:
A Simple Estimated Payment Script.

 

First page Previous page 1 2 Next page Last page  View All


Deven
User

Apr 4, 2005, 6:10 PM

Post #26 of 30 (2061 views)
Shortcut
Re: [mw5cents] A Simple Estimated Payment Script. [In reply to] Can't Post

To change assumptions I just use a simple calculator and call it in it own pop-up window.

Put this between your <head> </head> tags:

Code
    <script> 
function openpopup1(){
var popurl="http://yourdomain.com/calculate.html"
winpops=window.open(popurl,"","left=200 top=0 width=290,height=355,")
}
</script>


Then add this where you want it to say "change assumptions:

Code
<a href="javascript:openpopup1()"><b>Change Assumptions</b></a>


I've attached the calculator. Be sure to put in the correct path above...i.e. http://yourdomain.com/calculate.html

As for the creating a field for the Simple Estimated Payment Script, you could go into Listing Manager and create a text field and call it perhaps "Interest Rate". Then in the script instead of hard-coding the interest rate you replace that number with your $lfield#$. ( # = your listing field number). That way you could change the rates in the listing itself instead of updating your template. Hope this makes sense.

Regards, Deven
Attachments: calculate.html (7.56 KB)


mw5cents
User

Apr 5, 2005, 10:53 AM

Post #27 of 30 (2053 views)
Shortcut
Re: [Deven] A Simple Estimated Payment Script. [In reply to] Can't Post

Deven,

Thank you for your prompt reply! I am still having a few minor issues. I am able to call the calc as you described via a popup...however my problem is automatically inserting the price. No matter what I tried I always got NaN for purchase price, downpayment & monthly payment.

When looking through the script I noticed:

Code
 function getPrice() {  
var targetStr = "?price=";
var searchStr = window.location.search;


So I made my popup code look like this:

Code
 <script language="javascript">  
function mortcalc()
{
var popurl="mortcalc.html?price=$lfield4_je$"


I tried everything I could think of:
var popurl="mortcalc.html?price=$lfield4_ue$"
var popurl="mortcalc.html?price=$lfield4_he$"
var popurl="mortcalc.html?price=$lfield4$"

I also tried renaming the mortgage calc to .php but still no luck. As it stands now I added the calc you attached, but the user has to manually fill in purchase price & downpayment. I would like to avoid this if at all possible. About the only thing I did not try was changing the published file extension to .php or .shtml.

The only thing I changed in the script was the downpayment percent:

Code
 function initFields() {  
document.forms[0].purchase.value = getPrice();
document.forms[0].downpmt.value = parseInt(document.forms[0].purchase.value * .1);


It was * .2

Thank you in advance for any advice you or anyone may have to offer!

Matt


(This post was edited by mw5cents on Apr 5, 2005, 10:56 AM)


Deven
User

Apr 5, 2005, 4:43 PM

Post #28 of 30 (2048 views)
Shortcut
Re: [mw5cents] A Simple Estimated Payment Script. [In reply to] Can't Post

Yeah - I also have my customers filling in the price once they click on the pop-up. I'll try working on passing a variable to it and let you know. I'm right in the middle of coding a new commercial real estate site, so bear with me....Deven


markb2003
User

Apr 18, 2005, 1:00 PM

Post #29 of 30 (2026 views)
Shortcut
Re: [Deven] A Simple Estimated Payment Script. [In reply to] Can't Post

where do I stick this? Do I make it as a link and create a pop-up box and then insert the HTML and script tags into my pop-up? Do I place only the /script tags in the publish_listing.html file? I did this and got a numeric display of the total price of house, not payments and no options. Such a simple thing and I'm getting confused. Thank you. Mark


Deven
User

Apr 18, 2005, 5:51 PM

Post #30 of 30 (2021 views)
Shortcut
Re: [markb2003] A Simple Estimated Payment Script. [In reply to] Can't Post

Hi Markb:

Look at post #8. Download the attachment, open it in your favorite text editor, copy the script, then insert it anywhere you want on your _publish_listing page. It takes the price field and calculates a monthly payment.



An example might be....

Price: $125,000

Estimated monthly payment: <--insert code here-->

Let me know if this doesn't answer your question.

~~~Deven

First page Previous page 1 2 Next page Last page  View All
 
 


Search for (options)
Products
CMS Builder
Article Manager
Realty Manager
Listings Manager
Order Now
Services
Priority Consulting
Support
Online Documentation
Support Forums
Support Homepage
Company Info
12 reasons to choose us!
Meet the team
Monthly newsletter
Contact Us
Toll Free: 1-800-752-0455
Phone: (604) 689-3347
Sales | Support
Conditions of Use | Privacy Policy | Copyright © interactivetools.com 2008
#201 - 2730 Commercial Drive, Vancouver BC Canada V5N 5P4