
872 P.2d 721 (1994)
125 Idaho 458
Patrick T. DOYLE and Laurie Howlett-Doyle, Plaintiffs-Respondents,
v.
Tom ORTEGA, Defendant-Appellant.
No. 20502.
Supreme Court of Idaho, Boise, February 1994 Term.
April 20, 1994.
*722 Coffin, Snyder & Matthews, Boise, for defendant-appellant. Steven R. Matthews, argued.
Killen & Kerrick, P.A., McCall, for plaintiffs-respondents. William M. Killen, argued.
JOHNSON, Justice.
This is a real estate contract case. The primary issues presented are whether the parties entered into a contract, and, if so, whether the default clause of the contract precludes the buyers from obtaining specific performance when the seller failed to consummate the sale. We conclude that there is a contract and that the contract precludes the buyers from obtaining specific performance.

I.

THE BACKGROUND AND PRIOR PROCEEDINGS.
Tom Ortega owns real property (the property) which he listed for sale with a realtor for $32,000. Shortly after Ortega listed the property, Patrick Doyle and Laurie Howlett-Doyle (the Doyles) visited the property and decided to purchase it. The Doyles submitted a form real estate purchase and sale agreement and receipt for earnest money (the earnest money agreement) dated March 11, 1991, offering to purchase the property from Ortega for $28,000. The financing terms included $5,600 cash down, with the balance and interest payable in monthly installments of $216.19 and with the remaining balance due in five years.
Ortega rejected the Doyles' offer and discussed a counter-offer with his realtor. Ortega indicated that he would reduce the price to $30,000, with cash at closing of $6,000. Ortega said he would accept the remaining payment terms of the Doyles, except he wanted a monthly payment of $231.61. Ortega also stated that he wanted the earnest money deposited with a Rock Springs, Wyoming bank and, rather than sharing the closing agent's fees and the long term escrow fees as the Doyles had offered, Ortega indicated that he wanted the Doyles to pay these fees. Ortega's realtor made notes of these changes on his copy of the Doyles' offer and prepared a new earnest money agreement (the new earnest money agreement) incorporating some, but not all, of the changes the realtor and Ortega had discussed. Ortega's realtor also omitted a provision of the Doyles' offer indicating that facsimile signatures would be acceptable until originals could be signed.
Ortega's realtor sent a copy of the new earnest money agreement to the Doyles. Before sending Ortega a copy of the new earnest money agreement, the realtor noticed that he had marked the wrong boxes relating to the responsibility for payment of the closing agent's fees and the long-term escrow fees. The realtor made these changes and inserted a line for Ortega's initials approving them.
Upon receipt of their copy of the new earnest money agreement, the Doyles signed and returned it to their realtor. Before signing his copy of the new earnest money agreement, Ortega added a provision that the earnest money be deposited in trust at the Rock Springs National Bank, as he had discussed earlier with his realtor. Ortega returned the signed agreement to his realtor without initialing the changes concerning the payment of fees by the Doyles. Noting the absence of Ortega's initials on these changes, the realtor returned the signed document to Ortega. Ortega not only initialed the document, but also added a provision stating: "Sellers [sic] attorney to draw contract & buyer to approve." None of these changes were contained in the copy of the new earnest money agreement signed and returned by the Doyles.
Upon learning of Ortega's revisions (the revisions), the Doyles' realtor called the Doyles. Patrick Doyle orally agreed to the revisions. The Doyles' realtor then prepared an addendum (the addendum) to the new earnest money agreement in an effort to incorporate all the revisions. In addition to the revisions, the addendum extended the closing date from May 1 to May 22, 1991, and contained a provision that the Rock Springs National Bank, rather than an Idaho bank, handle the long-term escrow. The extension *723 of the closing date was necessary because Ortega did not obtain the requisite septic tank approval from the health department until May 8, 1991. The addendum omitted the requirement that the earnest money be transferred to the Rock Springs National Bank, as requested by Ortega, because the realtors concluded Idaho law required that the earnest money be held in trust in Idaho.
Patrick Doyle signed and returned the addendum to his realtor. Ortega never signed his copy of the addendum and subsequently refused to consummate the sale. The Doyles demanded that Ortega complete the sale, but Ortega refused.
The Doyles sued Ortega for specific performance, alleging that the property was unique and, therefore, damages would not adequately compensate them. Ortega contended that he had not entered into a contract with the Doyles, and that even if there were a contract, the default clause of the new earnest money agreement (the default clause) made it clear that the Doyles' only remedy was the return of their earnest money and reimbursement for their costs. The default clause states:
S. DEFAULT: If Seller executes this agreement, and title to the subject property is marketable and insurable and the Buyer fails, neglects or refuses to comply with the terms of any conditions of sale set forth herein within five (5) days from the date on which said term or condition is to be complied with, then the earnest money, upon written request of the Seller shall be forfeited and the Buyer's interest in the property, if any, shall be terminated. The holder of the earnest money as designated herein shall pay from the earnest money forfeited by the Buyer the cost of title insurance, escrow fees, attorney's fees and any other expenses directly incurred by or on behalf of the Buyer and Seller in connection with this transaction and the remainder shall be apportioned one-half to the Seller and one-half to the Broker holding the earnest money, provided the amount to the Broker does not exceed the agreed commission. The payment by Broker as aforesaid shall not constitute a waiver of any other rights or remedies available to the Seller and/or Broker. Buyer shall be responsible for any and all costs or fees incurred by or on behalf of Buyer. If the Seller, having approved said sale fails to consummate the same as herein agreed, the Earnest Money shall be returned to the Buyer less such charges and other costs or fees incurred or committed for use by or on behalf of the Buyer hereunder and Seller shall pay for the cost of title insurance, escrow and legal fees, if any, and reimburse Buyer for that portion of the Earnest Money expended or committed on behalf of Buyer which cannot be refunded.
Both Ortega and the Doyles moved for partial summary judgment, asking the trial court to determine whether the default clause precludes an action for specific performance. The trial court granted partial summary judgment on this issue in favor of the Doyles, reserving for trial the question of whether the parties had entered into a contract for the sale of the property.
Following a trial, the trial court found that the parties had "reached a meeting of the minds about all essential terms of the sale and purchase of the property and had intended to be contractually bound." In addition, the trial court noted that Ortega had not presented the statute of frauds as a defense because Ortega did not allege it as an affirmative defense and it was not tried by the express or implied consent of the parties. The trial court concluded that there was insufficient evidence to support a finding that the parties intended liquidated damages to be the exclusive remedy of the buyers and granted the Doyles a judgment for specific performance. The trial court also awarded the Doyles attorney fees and costs pursuant to a provision of the new earnest money agreement.

II.

THERE IS SUBSTANTIAL AND COMPETENT EVIDENCE TO SUPPORT THE TRIAL COURT'S FINDING THAT THE PARTIES REACHED A MEETING OF THE MINDS AND INTENDED TO BE CONTRACTUALLY BOUND.
Ortega asserts that it was clearly erroneous for the trial court to find that the *724 parties entered into an enforceable contract for the sale of the property. We disagree.
We will not disturb the trial court's finding that the parties agreed to the essential terms of a contract, if the finding is supported by substantial evidence. Hoffman v. S V Co., Inc., 102 Idaho 187, 189, 628 P.2d 218, 220 (1981).
The trial court found that "the parties had reached a meeting of the minds about all the essential terms of the sale and purchase of the property and had intended to be contractually bound," and that "the contract between the parties included all the terms contained in the copy of agreement executed by Mr. Ortega except the inconsequential requirement that the earnest money be transferred to a Rock Springs bank." There is substantial and competent evidence to support the trial court's findings.
We do not address the implication, if any, of the statute of frauds. Ortega did not plead the statute as a defense, and, therefore, waived it. I.R.C.P. 8(c).
I.R.C.P. 15(b) provides that where an issue not pleaded is raised by "express or implied consent of the parties" it must be treated as if properly raised. It is within the discretion of the trial court to determine whether the parties consented to the trial of an issue. Lynch v. Cheney, 98 Idaho 238, 241, 561 P.2d 380, 383 (1977). We will overturn the trial court's decision on this question only when the trial court has abused its discretion. Smith v. King, 100 Idaho 331, 335, 597 P.2d 217, 221 (1979).
Applying the test in Sun Valley Shopping Ctr., Inc. v. Idaho Power, 119 Idaho 87, 94, 803 P.2d 993, 1000 (1991), we conclude that the trial court did not abuse its discretion in deciding that the parties did not try the statute of frauds issue by consent.

III.

SPECIFIC PERFORMANCE WAS NOT AVAILABLE TO THE DOYLES.
Ortega asserts that the trial court should not have granted specific performance to the Doyles. We agree because the default clause limited the remedy available for Ortega's failure to consummate the sale.
The rules that apply in construing contracts are well established:
The primary objective in construing a contract is to discover the intent of the parties, and in order to effectuate this objective, the contract must be viewed as a whole and considered in its entirety. The primary consideration in interpreting an ambiguous contract is to determine the intent of the parties. The determination of a contract's meaning and legal effect are questions of law to be decided by the court where the contract is clear and unambiguous. However, where a contract is determined to be ambiguous, the interpretation of the document presents a question of fact which focuses upon the intent of the parties. The determination of whether a contract is ambiguous or not is a question of law over which we may exercise free review, and in determining whether a contract is ambiguous, our task is to ascertain whether the contract is reasonably subject to conflicting interpretation.
Bondy v. Levy, 121 Idaho 993, 996-97, 829 P.2d 1342, 1345-46 (1992) (citations omitted).
Applying these rules of construction, we conclude that the default clause is not ambiguous and that it limits the buyer's remedies for the failure of the seller to consummate the sale to those stated in the clause.
The portion of the clause concerning default by the seller states:
If the Seller, having approved said sale fails to consummate the same as herein agreed, the Earnest Money shall be returned to the Buyer less such charges and other costs or fees incurred or committed for use by or on behalf of the Buyer hereunder and Seller shall pay for the cost of title insurance, escrow and legal fees, if any, and reimburse Buyer for that portion of the Earnest Money expended or committed on behalf of Buyer which cannot be refunded.
In distinction, in the event of the buyer's default, the default clause specifically preserves remedies for the seller other than those stated in the clause. Also, the provision *725 requiring the return of the earnest money to the buyer is inconsistent with specific performance.
Viewing the agreement as a whole and considering it in its entirety, we are left with only one reasonable interpretation. In the event of the seller's failure to consummate the sale, the buyer is entitled only to the remedies stated in the default clause.
Although it is not dispositive, we note that in Margaret H. Wayne Trust v. Lipsky, 123 Idaho 253, 846 P.2d 904 (1993), the Court reviewed an earnest money agreement to determine the scope of the seller's remedies upon the buyer's default. The clause at issue contained a liquidated damages remedy for both buyer and seller as well as a reservation of other remedies for both seller and buyer. While the Court found that the reservation of remedies preserved the right to seek specific performance by either party, the Court also stated: "This is not to say, however, that an agreement for the purchase of real property may not be clearly drafted so as to limit the seller's remedy to retaining the earnest money deposit as liquidated damages ..." Id. at 258, 846 P.2d at 909.

IV.

CONCLUSION.
We reverse and remand the case to the trial court with directions to enter judgment for Ortega. The trial court shall include in the judgment an award of reasonable attorney fees both in the trial court and on appeal, as provided for in the agreement between the parties.
We award Ortega costs on appeal.
McDEVITT, C.J., and BISTLINE, TROUT and SILAK, JJ., concur.
