
893 So.2d 395 (2003)
VESTA FIRE INSURANCE CORPORATION and Vesta Insurance Corporation
v.
LIBERTY NATIONAL LIFE INSURANCE COMPANY.
Ex parte Vesta Fire Insurance Corporation and Vesta Insurance Corporation.
(In re Liberty National Life Insurance Company
v.
Vesta Fire Insurance Corporation and Vesta Insurance Corporation).
2010773 and 2010894.
Court of Civil Appeals of Alabama.
October 10, 2003.
Rehearing Denied February 13, 2004.
Certiorari Quashed June 11, 2004.
*397 Tom E. Ellis Birmingham, for appellants/petitioners Vesta Fire Insurance *398 Corporation and Vesta Insurance Corporation.
Charles A. Dauphin of Baxley, Dillard, Dauphin & McKnight, Birmingham, for appellee/respondent Liberty National Life Insurance Company.
Alabama Supreme Court 1030808.
MURDOCK, Judge.
Vesta Fire Insurance Corporation and Vesta Insurance Corporation (hereinafter referred to collectively as "Vesta") appeal from the entry of a summary judgment against Vesta and in favor of Liberty National Life Insurance Company ("Liberty National") by the Jefferson Circuit Court on a contract dispute between the parties. Vesta also petitions for a writ of mandamus, requesting relief from an order of the circuit court granting Liberty National's postjudgment discovery motion on the sufficiency of the supersedeas bond.[1] For expediency, the two actions have been consolidated.
In 1993, Liberty National began the process of spinning off its fire insurance company, formerly known as Liberty National Fire Insurance Company, renaming it Vesta Fire Insurance Corporation, and entered into negotiations with Vesta to establish a more arms-length relationship between the organizations. At the time, Liberty National was selling Vesta industrial fire insurance policies through its "agency force." Liberty National wanted to continue making Vesta industrial fire insurance policies available to its customers, while Vesta wanted to continue utilizing Liberty National's agency force and to retain its current industrial fire insurance business. To accomplish those ends, on September 13, 1993, Liberty National and Vesta entered into a "Marketing and Administrative Services Agreement" ("the Agreement"),[2] whereby Liberty National agreed to allow Vesta to use its agency force to sell industrial fire insurance policies and agreed to provide to Vesta administrative services[3] for the policies in return for Vesta's agreement to compensate Liberty National and its agency force. The Agreement contains the following provisions relevant to this case:
"2.03 Premium

"(a) [Liberty National] shall be authorized to receive premiums on business covered herein. After making appropriate deductions, the balance of such premiums shall be paid to [Vesta] within fifteen (15) days after the close of accounting records for each calendar month. Deductions shall be made for services rendered hereunder and expenses incurred by [Liberty National] as follows:
"(1) Commission and other compensation paid to [Liberty National] agents by [Vesta] as agreed upon by [Vesta] and [Liberty National];
"(2) Cost of Administrative Services computed as follows:

*399 "i. 10% of net (after policies not-taken) annualized premiums on new business issued each month; plus
"ii. One-twelfth (1/12) of 5% of the in force annualized premiums at the end of each month; plus
"iii. 7.5% of the premiums paid each month.
"(3) All expenses incurred by [Liberty National] are directly attributable to Industrial Fire Insurance as follows:
"....
"f. Any and all other expenses that are incurred by [Liberty National] and implicitly or explicitly authorized on behalf of [Vesta].
"....
"ARTICLE VI
"TERMINATION OF THE AGREEMENT
"6.01 Either party may at its election terminate this Agreement by giving the other party ninety (90) days advance written notice of such intent to terminate sales under this Agreement.
"6.02 Within thirty (30) days of receipt or mailing of notice pursuant to 6.01, the [Liberty National] field will cease soliciting and submitting applications for Industrial Fire Insurance on behalf of [Vesta]. Applications submitted within this thirty (30) day period shall be processed in accordance with this Agreement.
"6.03 (a) In the event this Agreement is terminated by [Liberty National], [Vesta] has the right to assume the administration of the business in force which shall include but not be limited to the collection of premiums on the business in force at the time of termination of this Agreement, maintenance of all policy records and files, and any other administrative duties that may be required for administration of the business. It shall be the obligation of [Vesta] to calculate commissions and other compensation payable to the field Agency Force of [Liberty National] as provided in paragraph 2.03(a)(1). Such compensation shall be remitted to [Liberty National] with sufficient accompanying documentation to enable [Liberty National] to properly pay its Agency Force. [Vesta] shall also compensate [Liberty National] on the business in force at the time of the termination of this Agreement at the rate of 7.5% of the premium collected for so long as any insurance written by the [Liberty National] Agency Force shall remain in force.

"(b) In the event this Agreement is terminated by [Vesta], business in force and administered by [Liberty National] pursuant to this Agreement will continue following the notice of termination, in accordance with the policy contract provisions. [Liberty National] shall continue to provide such administrative services as required by this Agreement for so long as any insurance written pursuant to this Agreement remains in force. For as long as [Liberty National] continues to provide the services required by this Agreement [Liberty National] will continue to be compensated according to paragraph 2.03(a).
"....
"6.07 Upon termination of this Agreement the following shall apply:
"(a) Subject to the terms of this Agreement and the provisions of the underlying policies of insurance, the business issued hereunder shall remain with [Vesta] and [Vesta] shall continue to insure and service such business. All hardcopy records that pertain to the business of [Vesta] shall *400 become the property of [Vesta] and shall be returned to [Vesta] as it directs. [Liberty National] shall provide [Vesta] with all computer records relevant to the Industrial Fire Insurance business. However, [Liberty National] shall have the right, during normal business hours, to inspect and copy such records as it may reasonably request. Any inspection or reproduction made pursuant to the terms of this paragraph shall be at the sole expense of [Liberty National].
"(b) [Vesta] shall continue to pay [Liberty National] compensations as specified in this Agreement and reimburse [Liberty National] for expenses incurred and for commissions paid to agents pursuant to the provisions of this Agreement. Such payments shall continue for so long as [Liberty National] services the Industrial Fire Insurance business covered herein."
(Emphasis added.)
The parties performed their respective obligations under the Agreement without incident until March 28, 1995. On that date, Liberty National sent Vesta written notification that in 30 days it would cease taking applications for Vesta industrial fire insurance policies, but that it would continue to provide administrative services for policies already "in force" in accordance with the Agreement. Under §§ 6.01 and 6.02 of the Agreement, this notice set into motion the process of terminating the Agreement. Under § 6.03(a), termination by Liberty National gave Vesta the right to assume the administration of the business in force, and, on August 27, 1996, Vesta sent Liberty National written notification of its intent to assume control of the administrative functions associated with its policies.
The parties admit that the conversion process was cumbersome and slow, and, as a result, Vesta's assumption of control of the administration of the policies was not completed until September 1998. From April 1995 through September 1998, Liberty National continued to receive 7.5% of the premiums collected each month, plus one-twelfth of 5% of the in-force annualized premiums at the end of each month, and the commissions on in-force policies for its agency force, in accordance with § 2.03(a)(2) of the Agreement. In October 1998, after Vesta assumed all administrative duties concerning the Vesta industrial fire insurance policies in force, Vesta ceased paying Liberty National 7.5% of the premiums collected each month. Vesta continued to pay Liberty National agents their commissions until April 1999, after which it ceased that remuneration as well.
On March 5, 1997, Jim Hattaway, an examiner with the Alabama Department of Insurance ("the Department"), wrote Vesta a letter indicating concerns that the Department had regarding Vesta's payment of fees and commissions to Liberty National pursuant to the Agreement. The Department's concerns were based on § 27-7-4, Ala.Code 1975, which provides that no agent is permitted to accept insurance payments for policies that the agent is not licensed to sell and the fact that Liberty National did not have a license to sell property and casualty insurance. Vesta claimed before the trial court that the Department had threatened it with massive fines if it did not cease paying Liberty National agents commissions under the Agreement.
On June 23, 1999, Liberty National sued Vesta, alleging breach of the terms of the Agreement, requesting compensatory damages for Vesta's failure to continue paying Liberty National 7.5% of the premiums Vesta had collected on in-force policies since it had assumed administrative *401 duties over those policies, and seeking $24,000 in expenses incurred by Liberty National in assisting Vesta in the transition of the administration of the policies from Liberty National to Vesta. Vesta answered the complaint, denying all material allegations and requesting a jury trial.
On June 29, 2001, Liberty National moved for a summary judgment pursuant to Rule 56, Ala. R. Civ. P., attaching deposition excerpts and other materials as exhibits to its motion. On August 20, 2001, Vesta filed its response in opposition to the motion for a summary judgment and filed a cross-motion for a summary judgment, also attaching exhibits to its motion. Supplemental briefs and additional evidence were filed by the parties, and the trial court held a hearing on the matter on November 2, 2001.
Following the hearing, Liberty National filed a motion for leave to amend its complaint to include a declaratory-judgment count, seeking a declaration as to whether Vesta had an obligation to pay to Liberty National commissions that Liberty National alleged were due to its agents who had sold Vesta industrial fire insurance policies that were still in force. Vesta filed a response to Liberty National's motion to amend its complaint on November 15, 2001, pointing out that an action had been filed in the Tuscaloosa Circuit Court against Liberty National by one or more of its agents demanding payment for those same commissions; Vesta claimed that if the motion for leave to amend was granted, it would potentially be subject to multiple actions for the same damages in separate courts. On November 19, 2001, the trial court granted Liberty National's motion for leave to amend its complaint to add the declaratory-judgment count.
Subsequently, on November 30, 2001, Liberty National moved for a summary judgment on its amended complaint. On December 14, 2001, Vesta filed a response that included a cross-motion for a summary judgment. On January 7, 2001, Vesta filed an amendment to its response, asking the trial court to dismiss the amended complaint or, in the alternative, to compel joinder of the Liberty National agents who purported to be a class in the action pending in the Tuscaloosa Circuit Court against Vesta on the issue of the commissions. In addition, Vesta requested that the trial court add the Department as an indispensable party to the declaratory-judgment count.
On March 7, 2002, the Jefferson Circuit Court entered a summary judgment in favor of Liberty National and against Vesta. It denied all other pending motions, all of which had been filed by Vesta. Vesta appealed.
Along with its notice of appeal, Vesta filed a supersedeas bond ("the bond") in the amount of approximately $30,000. On May 1, 2002, Liberty National filed an objection to the amount of the bond and moved the trial court to allow it to conduct postjudgment discovery pursuant to Rule 27(b), Ala. R. Civ. P., to determine the proper amount of the bond. In its discovery request, Liberty National sought to have Vesta
"[p]roduce documents which show the amount of premium collected from October 1, 1998 to the time of [Vesta's] response to these Requests for Production on any Vesta industrial fire insurance written by the [Liberty National] Agency Force."
On May 8, 2002, the trial court granted Liberty National's Rule 27(b) motion. The trial court denied Vesta's motion to reconsider that decision on May 17, 2002. Concurrent with the trial court's denial of Vesta's motion to reconsider, the Jefferson County circuit clerk denied approval of Vesta's supersedeas bond. Vesta then *402 filed an application to stay execution of the judgment with the trial court. On May 23, 2002, the trial court denied Vesta's motion. Vesta appealed the denial of the stay, and, on June 18, 2002, this court granted Vesta's motion to stay the execution of the judgment until June 28, 2002, the date on which the trial court had set a hearing on the discovery issue and the stay request. On June 28, 2002, the trial court held the hearing, again denied Vesta's requested relief, and ordered Vesta to produce the discovery material requested within 15 days. On July 3, 2002, Vesta filed a motion to extend the stay of execution of the judgment pending a determination of the appeal filed with this court. This court denied that motion on July 23, 2002.
Vesta appealed the trial court's order granting the post-discovery motion filed by Liberty National on June 10, 2002. Liberty National filed a motion to dismiss the appeal, but this court, on July 16, 2002, denied that motion, and ordered that the appeal be treated as a petition for a writ of mandamus.

Vesta's Appeal
"In reviewing the disposition of a motion for a summary judgment, we use the same standard used by the trial court in determining whether the evidence before it made out a genuine issue of material fact and whether the movant was entitled to a judgment as a matter of law. Bussey v. John Deere Co., 531 So.2d 860, 862 (Ala.1988). When the movant makes a prima facie showing that there is no genuine issue of material fact, the burden then shifts to the nonmovant to present `substantial evidence' creating such an issue. Bass v. SouthTrust Bank of Baldwin County, 538 So.2d 794, 797-98 (Ala.1989). Evidence is `substantial' if it is of `such weight and quality that fair-minded persons in the exercise of impartial judgment can reasonably infer the existence of the fact sought to be proved.' West v. Founders Life Assurance Co. of Florida, 547 So.2d 870, 871 (Ala.1989). Our review is subject to the caveat that we must review the record in a light most favorable to the nonmovant and must resolve all reasonable doubts against the movant. Hanners v. Balfour Guthrie, Inc., 564 So.2d 412, 413 (Ala.1990)."
Ex parte Harris, 837 So.2d 283, 286 (Ala.2002).
Vesta contends, as it did before the trial court, that it is no longer required to pay Liberty National a percentage of the premiums collected on fire insurance policies still in force or to pay Liberty National agents commissions on those policies because Liberty National has ceased servicing the policies. Vesta relies on § 6.07(b) of the Agreement, which states: "[Vesta] shall continue to pay [Liberty National] compensations as specified in this Agreement and reimburse [Liberty National] for expenses incurred and for commissions paid to agents pursuant to the provisions of this agreement. Such payments shall continue for so long as [Liberty National] services the Industrial Fire Insurance business covered herein." (Emphasis added.)
In contrast, Liberty National maintains, as it did before the trial court, that Vesta owes it 7.5% of the premiums collected each month, as provided in § 2.03(a)(2)(iii) of the Agreement and that Vesta owes Liberty National agents commissions pursuant to § 2.03(a)(1). Liberty National relies upon § 6.03(a), which states, in pertinent part:
"In the event this agreement is terminated by [Liberty National]... [i]t shall be the obligation of [Vesta] to calculate commissions and other compensation payable to the field Agency Force of [Liberty National] as provided in paragraph *403 2.03(a)(1).... [Vesta] shall also compensate [Liberty National] on the business in force at the time of the termination of this Agreement at the rate of 7.5% of the premium collected for so long as any insurance written by the [Liberty National] Agency Force shall remain in force."
(Emphasis added.)
The trial court determined that § 6.03(a) and § 6.07(b) of the Agreement are inconsistent with one another, thus rendering the Agreement ambiguous. After evaluating the Agreement as a whole, the trial court concluded that the two provisions could not be reconciled, and it employed a rule of construction known as the "former over latter" rule, which dictates that "if there exists inconsistency between two clauses of a contract which cannot be reconciled, the inconsistency must be resolved in favor of the prior clause, unless an intention to thereafter qualify is plainly expressed." City of Fairhope v. Town of Daphne, 282 Ala. 51, 58, 208 So.2d 917, 924 (1968). See, e.g., Irwin v. Baggett, 231 Ala. 324, 326, 164 So. 745, 746 (1935); City of Fairhope v. Town of Daphne, 282 Ala. 51, 58, 208 So.2d 917, 924 (1968). Applying the "former over latter" rule, the trial court determined that § 6.03(a) governs over § 6.07(b) and, therefore, that Vesta is contractually obligated to pay Liberty National 7.5% of premiums collected on in-force industrial fire insurance policies written by Liberty National agents and to pay commissions on those policies for as long as those policies remain in force.
Vesta takes issue with the trial court's method of resolving the conflict, arguing that because there is an ambiguity between §§ 6.03(a) and 6.07(b), that ambiguity must be resolved by a jury, not by the trial court. Vesta contends that Alabama law dictates that an ambiguity in a contract precludes a trial court from entering a summary judgment on a breach-of-contract claim and that the issue must be resolved by a jury. Among other cases, Vesta cites McDonald v. U.S. Die Casting & Development Co., 585 So.2d 853 (Ala.1991), in support of its position:
"If the terms within a contract are plain and unambiguous, the construction of the contract and its legal effect become questions of law for the court and, when appropriate, may be decided by a summary judgment. Dill v. Blakeney, 568 So.2d 774 (Ala.1990). However, if the terms within the contract are ambiguous in any respect, the determination of the true meaning of the contract is a question of fact to be resolved by a jury. Id. The question whether a contract is ambiguous is a question of law for the courts. Id."
McDonald, 585 So.2d at 855.
Vesta neglects a step in the contractual-interpretation process in making its argument. "It is axiomatic that the question whether a contract is ambiguous is for the trial court." Mann v. GTE Mobilnet of Birmingham, Inc., 730 So.2d 150, 154 (Ala.1999). The trial court found that the language in §§ 6.03(a) and 6.07(b) create an ambiguity in the Agreement, and Vesta does not challenge that finding.
However, Vesta contends that once a determination of ambiguity has been made, a summary judgment cannot be granted and the case must be submitted to the jury. While some cases, such as McDonald, supra, and Ex parte Harris, 837 So.2d 283, 290 (Ala.2002) ("once a court determines that an instrument is ambiguous or uncertain in any respect, it becomes a question for the factfinder to determine the true meaning of the contract"), appear to indicate that this is the rule, other cases provide a more detailed explanation of the method to be employed by a court in interpreting a contract. Alfa *404 Life Ins. Corp. v. Johnson, 822 So.2d 400 (Ala.2001), provides a thorough explanation of the steps to be employed by the trial court:
"When a trial court is found with a contract issue, it is important for the trial court to determine as soon as practicable the `threshold issue' whether the contract is ambiguous. If the trial court determines that there is no ambiguity, it must '"determine the force and effect of the terms of the contract as a matter of law."' Cherokee Farms, Inc. [v. Fireman's Fund Ins. Co.], 526 So.2d [871], 873 [(Ala.1988)], quoting Wigington v. Hill-Soberg Co., 396 So.2d 97, 98 (Ala.1981). However, if the trial court finds the contract to be ambiguous, it `must employ established rules of contract construction to resolve the ambiguity.' Voyager Life Ins. Co. v. Whitson, 703 So.2d 944, 948 (Ala.1997). If the application of such rules is not sufficient to resolve the ambiguity, factual issues arise:
"`If one must go beyond the four corners of the agreement in construing an ambiguous agreement, the surrounding circumstances, including the practical construction put on the language of the agreement by the parties to the agreement, are controlling in resolving the ambiguity.'
"Id. at 949. Where factual issues arise, the resolution of the ambiguity becomes a task for the jury. McDonald v. U.S. Die Casting & Dev. Co., 585 So.2d 853 (Ala.1991)."
822 So.2d at 404-05 (emphasis added). In short, a court is to evaluate the contract on its face and apply rules of contract construction in an effort to resolve ambiguities before submitting the case to a jury. See, e.g., Boykin v. Bank of Mobile, 72 Ala. 262, 269 (1882); Lutz v. Van Heynigen Brokerage Co., 199 Ala. 620, 629, 75 So. 284, 288 (1917); Air Conditioning Eng'rs v. Small, 259 Ala. 171, 176, 65 So.2d 698, 703 (1953).
In this case, the trial court explicitly looked "only at the four corners of the contract and appl[ied] these rules of construction" to reach its decision. As Johnson, supra, makes clear, when the rules of contract construction are sufficient to resolve the ambiguity, the trial court must rule on that basis, without resorting to parol evidence and submitting the case to the jury. Consequently, Vesta is in error in arguing that the trial court was required to submit the case to a jury once it determined that §§ 6.03(a) and 6.07(b) rendered the Agreement ambiguous.
We turn now to the merits of the trial court's analysis. Though recent Alabama authorities citing the "former over latter" rule exist, see, e.g., Voyager Life Ins. Co. v. Whitson, 703 So.2d 944, 949 (Ala.1997) ("[a]ny inconsistencies between clauses or conditions that cannot be reconciled must be resolved in favor of the first clause"), Vesta argues that because the rule is arbitrary, it is not to be used often. Several general authorities agree.
"This rule is one of last resort, ... and is applied only where no other acceptable means of disposing of the repugnant clauses can be found. It gives effect to the first clause merely by reason of the priority of its position and not by reason of any other consideration. Consequently, if there is, as a matter of ascertainment and construction of the intent of the parties as disclosed by the instrument as a whole, any sufficient reason for giving one of the repugnant clauses preference to the other, the rule is shown to be inapplicable."
17A Am.Jur.2d, Contracts § 394 (1991) (emphasis added; footnotes omitted). See, e.g., 11 Richard A. Lord, Williston on Contracts § 32 (4th ed. 1999) ("Because of *405 the arbitrary and artificial quality of this rule of interpretation, it is not universally followed and will only be accepted as a rule of last resort."). Alabama courts have also held that this rule "should never be resorted to until all efforts to reconcile the conflicting parts [have] failed." Petty v. Boothe, 19 Ala. 633, 640 (1851).
However, even if the "former over latter" rule should not have been used by the trial court, we conclude that the trial court's judgment is due to be affirmed. "It is well settled under Alabama law that the words of a contract are to be given their ordinary meaning and that the intention of the parties is to be derived, if possible, from the provisions of the contract itself." BoWing Office Sys., Inc. v. Johnson, 744 So.2d 915, 918 (Ala.Civ.App.1999). "[T]erms should be construed in pari materia and a construction adopted which gives effect to all the terms used." Federal Land Bank of New Orleans v. Terra Res., Inc., 373 So.2d 314, 320 (Ala.1979). As noted, courts must use "all efforts to reconcile" contractual provisions. Petty, 19 Ala. at 640. "Inconsistent parts in a contract are to be reconciled, if susceptible of reconciliation...." Sullivan, Long & Hagerty v. Southern Elec. Generating Co., 667 So.2d 722, 725 (Ala.1995). We conclude that §§ 6.03(a) and 6.07(b), when considered along with associated contractual provisions, reasonably may be read as not being in conflict with one another.
Section 6.03(a), by its terms, describes exactly the factual situation in this case. That section is triggered by termination initiated by Liberty National. Liberty National terminated the Agreement in accordance with §§ 6.01 and 6.02 by giving Vesta written notice on March 28, 1995, that it would cease selling Vesta industrial fire insurance policies in 30 days and by carrying through on that notice by ceasing to take new applications 32 days later.[4] Upon such termination, "[Vesta] has the right to assume the administration of the business in force which shall include but not be limited to the collection of premiums on the business in force at the time of termination of this Agreement...." § 6.03(a). Vesta did elect to assume the administration of the business in force, and it sent written notice to Liberty National of its intent to do so on August 27, 1996.
After the termination of sales by Liberty National and the assumption of the administrative services by Vesta, § 6.03(a) provides that Vesta has the obligation "to calculate commissions ... payable to the field Agency Force of [Liberty National] as provided in paragraph 2.03(a)(1)." Thus, even after Vesta has assumed all administrative-service responsibility for *406 the insurance policies in force, under § 6.03(a) Vesta still had the obligation to pay commissions to Liberty National agents as provided in § 2.03(a)(1). Vesta also retains continuing obligations to Liberty National under the last sentence of § 6.03(a): "[Vesta] shall also compensate [Liberty National] on the business in force at the time of the termination of this Agreement at the rate of 7.5% of the premium collected for so long as any insurance written by the [Liberty National] Agency Force shall remain in force." The result is that it is Vesta's responsibility to pay commissions as agreed upon in § 2.03(a)(1) to Liberty National agents and to pay Liberty National 7.5% of the premiums collected on in-force policies written by Liberty National agents so long as the policies remain in force.
Section 6.07(b) describes a different factual situation than the one before us in this case. Section § 6.07 states that "[u]pon termination of this Agreement [subsections (a) and (b)] shall apply...." Section 6.01 states that the Agreement is terminated by giving written notice of "intent to terminate sales under this Agreement." (Emphasis added.) Consequently, as soon as Liberty National gave Vesta written notice of its intent to stop selling the industrial fire insurance policies, the Agreement in principal part was terminated. Section 6.03(a) specifically became effective in this case not only because Liberty National initiated termination, but also because Vesta elected to exercise its "right to assume the administration of the business in force...." § 6.03(a). (Emphasis added.) By the terms of § 6.03(a), Vesta had the right to assume administrative-service responsibilities, but it did not have the duty to do so, even though the principal Agreement between the parties had been terminated by the terms of § 6.01 upon Liberty National's written notice of its intent to stop selling the insurance policies.
Indeed, Vesta did not elect to assume administrative-service responsibilities until over a year after Liberty National stopped selling Vesta insurance policies; Vesta did not actually assume such responsibilities until three and one-half years after the termination date. Vesta continued to pay Liberty National 7.5% of the premiums collected each month, plus 1/12 of 5% of the in-force annualized premiums at the end of each month, and it continued to pay commissions to Liberty National agents on policies in force during that three and one-half year period.[5]
Vesta made the latter payments because it was operating under the rubric of § 6.07(b), which provided that "[Vesta] shall continue to pay [Liberty National] compensations as specified in this Agreement and reimburse [Liberty National] for expenses incurred and for commissions paid to agents pursuant to the provisions of this Agreement. Such payments shall continue for as long as [Liberty National] services the Industrial Fire Insurance business covered herein." Under § 6.07(b), Vesta was required to pay Liberty National the "compensations specified in the Agreement," meaning all of the compensation specified in § 2.03(a)(2), which is why it paid Liberty National the 1/12 of 5% of the in-force annualized premiums at the end of each month[6] in addition to paying Liberty National 7.5% of the premiums collected each month. Section 6.07(b) also required Vesta to "reimburse [Liberty National] for expenses incurred" because Liberty National continued to provide service on the policies in force.
*407 In contrast to the circumstances covered by § 6.07(b), once Vesta began providing administrative services for its policies, it was not required to pay 1/12 of 5% of the in-force annualized premiums at the end of each month under § 6.03(a) because that section does not require Vesta to pay all "compensations specified in the Agreement," but rather just the 7.5% of the premiums collected each month. Likewise, § 6.03(a) does not require Vesta to "reimburse [Liberty National] for expenses incurred" because, unlike the circumstances covered by § 6.07(b), Vesta has assumed administrative-service responsibilities for the in-force policies; therefore, there are no expenses incurred by Liberty National for Vesta to reimburse.
In short, §§ 6.03(a) and 6.07(b) describe different scenarios when the Agreement is terminated, the former for when Vesta assumes administrative-service responsibilities for policies in force and the latter for when it does not.[7] Under § 6.07(b), Vesta had to continue to make "[s]uch payments," i.e., all of the compensation listed in § 2.03(a)(2) as well as the commissions as agreed upon under § 2.03(a)(1), "for so long as [Liberty National] service[d] the Industrial Fire Insurance business covered" in the Agreement. As soon as Vesta assumed administrative-service responsibilities for the in-force policies, however, the scheme of compensation provided for in § 6.03(a) started to apply, which required Vesta to pay Liberty National only commissions on policies in force that were written by Liberty National agency-force personnel and 7.5% of the premiums collected each month "for so long as [such policies] remain in force."
Based on the foregoing reading of the Agreement, we conclude that the trial court correctly determined that § 6.03(a) controls the current business relationship between Vesta and Liberty National. We further conclude that even if §§ 6.03(a) and 6.07(b) are inconsistent, we would reconcile them in the above-described manner, without resorting to the "former over latter" rule or to extrinsic evidence. Although the trial court employed a different rationale than the one employed by this court, "we will affirm a properly entered summary judgment regardless of the reason stated by the trial court." Green v. Ingram, 794 So.2d 1070, 1072 (Ala.2001). Thus, Vesta's objections on this issue do not warrant reversal of the entry of the summary judgment in favor of Liberty National.
In addition to its disagreement with the trial court's use of the "former over latter" rule to reconcile the language of § 6.03(a) and § 6.07(b) in the Agreement, Vesta contends *408 that the trial court erred to reversal in this case for several other reasons.
Vesta spends a considerable portion of its brief to this court arguing that the trial court incorrectly entered the summary judgment because, it contends, there are issues of fact in dispute that required the trial court to submit the case to a jury for its determination on those issues. Vesta contends that a jury should have been allowed to evaluate those disputed facts and their impact on a proper contractual interpretation. However, only two findings of fact listed by the trial court in its judgment are directly contradicted by Vesta in its brief to this court. The first is the trial court's finding that Liberty National gave proper written notice of termination of the Agreement. Vesta contends that Liberty National did not give 90 days notice of its intent to terminate the Agreement. We find no merit to this claim.[8]
The second finding that Vesta disagrees with is the trial court's finding that "[Liberty National] incurred the [conversion] expense at Vesta's implicit if not explicit authority." It was on the basis of this finding that the trial court awarded Liberty National $24,000 to cover expenses Liberty National claimed it had incurred during the conversion of administrative services from Liberty National to Vesta. Vesta contends that this finding was in error because, it says, Vesta presented substantial evidence that the parties had agreed that such conversion expenses would be paid for by Liberty National, not Vesta. In support of that contention, Vesta cites the deposition testimony of two Liberty National executives discussing the contents of a "Document of Understanding" circulated between the parties sometime after August 27, 1996; according to Vesta, that document outlines the parties' responsibilities during the conversion process. A portion of that document allegedly reflected the parties' understanding that conversion costs incurred by each party would be that party's responsibility. Based on that document, which was submitted into evidence, and the testimony of the Liberty National executives concerning that document, Vesta argues that whether it is responsible for reimbursing Liberty National for conversion expenses is a fact in dispute that warrants a jury determination.
However, as explained above, the trial court based its findings on undisputed facts and the four corners of the Agreement, not on extrinsic evidence. Section 2.03(3)(f) of the Agreement states that "[a]ny and all other expenses" that are not specifically listed in § 2.03 "that are incurred by [Liberty National] and implicitly or explicitly authorized on behalf of [Vesta]" are to be paid by Vesta. By Vesta's own admission, it expressly authorized the conversion of administrative services for in-force policies from Liberty National to Vesta. Therefore, the trial court's finding of fact in this regard is not legitimately in dispute when extrinsic evidence is excluded from consideration.
Because both of the trial court's findings of fact that Vesta takes issue with are not legitimately in dispute, we conclude that the trial court did not commit error by refusing to deny summary judgment on the ground that there are genuine issues of material fact.
Vesta also argues that a jury should have been given the opportunity to consider the entire Agreement to determine what the intentions of the parties were concerning the Agreement. Vesta lists several parts of the Agreement that it says raise the possibility that a jury would *409 have interpreted the Agreement differently than did the trial court. However, that argument ignores the fact that the trial court considered the Agreement as a whole in reaching its conclusion about the Agreement's meaning. Moreover, we also have evaluated the Agreement as a whole in light of Vesta's argument, and we also find Vesta's argument to be without merit. Again, as we stated above, a question regarding the meaning of the contract will be submitted to a jury only after the trial court has determined that there is an ambiguity in the contract and that it is unable to resolve the ambiguity through regular rules of contract construction on the basis of the four corners of the document. Johnson, supra. For the reasons explained above, we conclude that the Agreement was not ambiguous or inconsistent, and, therefore, the trial court did not err by not submitting the case to a jury.
Vesta also points to a litany of extrinsic evidence presented by the parties that it says should have been used in resolving the alleged ambiguity in the Agreement. Vesta contends that because extrinsic evidence was submitted, the trial court was bound to consider that evidence in attempting to resolve the ambiguity in the Agreement. Again, Vesta misunderstands the process by which courts interpret contracts.
"It is the province of the court to construe written instruments, and declare their legal effect. But, when the legal operation and effect of an instrument depends, not only on the meaning and construction of its words, but upon collateral facts in pais, and extrinsic evidence, the inference of facts to be drawn from the evidence should be submitted to the jury."
Boykin v. Bank of Mobile, 72 Ala. 262, 269 (1882). Both the trial court and this court have determined the meaning of the Agreement at issue without the need to resort to extrinsic evidence. The mere fact that extrinsic evidence was submitted does not mean that a trial court must consider that evidence when construing the meaning of a contract, if it concludes that the meaning is ascertainable by applying the rules of contract construction and by looking only at the four corners of the contract. See, e.g., Johnson, supra; Whitson, 703 So.2d at 949 ("If one must go beyond the four corners of the agreement in construing an ambiguous agreement, the surrounding circumstances ... are controlling in resolving the ambiguity." (Emphasis added.)).
Vesta also contends that it was error for the trial court to deny its Rule 19, Ala. R. Civ. P., motion for joinder in this case of the plaintiffs in the action filed in Tuscaloosa Circuit Court ("the Tuscaloosa action"). Vesta argues that the Tuscaloosa action was filed by Liberty National agents against Vesta seeking the same commissions that were the subject of Liberty National's declaratory-judgment count in this case. Vesta argues that failure to join those plaintiffs subjects it "to a substantial risk of incurring double, multiple, or otherwise inconsistent obligations by reason of the claimed interest." Rule 19(a), Ala. R. Civ. P. Specifically, Vesta claims that if the plaintiffs in the Tuscaloosa action are not joined in this action, it possibly could have to pay both Liberty National and Liberty National's agents the commissions on the in-force insurance policies.
The trial court ruled that Vesta would not be subject to double, multiple, or inconsistent obligations without joinder of the plaintiffs in the Tuscaloosa action because, it reasoned, Vesta could raise the defense of accord and satisfaction in the Tuscaloosa action once it paid Liberty National the commissions due under the *410 Agreement. The defense of accord and satisfaction has applicability only where there is "an agreement to accept in extinction of an obligation something different from or less than that to which the person agreeing to accept is claiming or entitled," § 8-1-20, Ala.Code 1975, and "[a]cceptance of the consideration of [the] accord extinguishes the obligation...." § 8-1-22, Ala.Code 1975. Vesta correctly points out that there was no evidence before the trial court indicating that there had been or would be an agreement by the plaintiffs in the Tuscaloosa action to accept payment to Liberty National as an extinguishment of their claimed debt. Consequently, the defense of accord and satisfaction would not be available to Vesta in the Tuscaloosa action.
However, the defense of payment would be available to Vesta in the Tuscaloosa action. Section 6.03(a) of the Agreement requires payment of the commissions to Liberty National so that Liberty National can pay its agents, stating that Vesta is obligated "to calculate commissions and other compensation payable to the field Agency Force of [Liberty National].... Such compensation shall be remitted to [Liberty National] with sufficient accompanying documentation to enable [Liberty National] to properly pay its Agency Force." (Emphasis added.) The trial court's order directing Vesta to pay Liberty National the commissions is no different than the arrangement between the parties before Vesta ceased remitting payment for the commissions  Vesta paid Liberty National, which in turn paid its agency force their commissions. Thus, the trial court's entry of the summary judgment on the declaratory-judgment claim concerning the Liberty National agents' commissions will not subject Vesta to double, multiple, or inconsistent obligations because, in the Tuscaloosa action, Vesta has the defense of payment. Consequently, the plaintiffs in the Tuscaloosa action are not indispensable parties under Rule 19, Ala. R. Civ. P., and the trial court did not err in refusing to grant Vesta's motion for joinder of the plaintiffs in the Tuscaloosa action.
Vesta also contends that the trial court erred in denying its Rule 19, Ala. R. Civ. P., motion for joinder of the Department as an indispensable party because, it says, substantial evidence was presented that the Department intended to fine Vesta up to $232 million for violations of § 27-7-4, Ala.Code 1975, in connection with paying the commissions to Liberty National agents. Vesta contends that the failure to join the Department as an indispensable party potentially subjects it to multiple, double, or inconsistent obligations concerning the commission payments.
As we stated earlier, an examiner for the Department wrote Vesta a letter on March 5, 1997, expressing concern that Vesta may be violating § 27-7-4 by paying Liberty National the commissions. The letter indicated that if such concerns were not addressed, it was possible that Vesta could face a fine of up to $232 million. Vesta claimed before the trial court that if it made the commission payments it would be violating an agreement it made with the Department not to do so, and, thus, Vesta argued, a declaration that Vesta had to make such payments would subject it to inconsistent obligations. However, Vesta never entered into the record any evidence of an agreement between the Department and itself regarding commission payments. Thus, there is no indication of an obligation other than that in the Agreement at issue requiring Vesta to pay Liberty National the commissions on policies in force. Without evidence of an inconsistent obligation, we cannot hold the trial court in error for failing to find that the Department is an indispensable party.
*411 In a related argument, Vesta contends that it does not have to pay the commissions to Liberty National because, it argues, such payments violate § 27-7-4. Section 27-7-4(a) stated, in pertinent part, that "[a]ny insurer accepting business directly from a person not licensed to transact such business and not appointed by such insurer shall be liable to a fine up to three times the premium received from such unlicensed person."[9] Vesta argues that the trial court's order requires it to make payments that render the Agreement illegal, which is an impermissible contractual obligation.
The trial court observed that Vesta had been paying the commissions in question from at least September 1993 through September 1998; in fact, Vesta paid the commissions even after the Department expressed its concerns to Vesta about the payments to Liberty National. There was no question that Vesta had received a significant benefit from its Agreement with Liberty National. As a result, the trial court concluded, Vesta is estopped from claiming illegality under § 27-7-4 as a reason for not having to pay the commissions at this point. Citing Ex parte Rice, 258 Ala. 132, 137, 61 So.2d 7, 10 (1952), the trial court concluded that "[a] party who receives the benefit of a contract cannot subsequently defeat its obligations under the contract by claiming illegality unless the performance injures the public or is detrimental to the public." Vesta does not dispute the trial court's finding of estoppel on appeal, thus its ruling on this issue is due to be affirmed.
For the foregoing reasons, and because we will affirm a properly entered summary judgment for any reason, Green, supra, we affirm the trial court's entry of the summary judgment in favor of Liberty National and against Vesta.

Vesta's Petition for a Writ of Mandamus
This court has elected to treat Vesta's second appeal as a petition for a writ of mandamus, because it questions a discovery ruling of the trial court.
"Mandamus is the `proper means of review to determine whether a trial court has abused its discretion in ordering discovery, in resolving discovery matters, and in issuing discovery orders so as to prevent an abuse of the discovery process by either party.' Ex parte Mobile Fixture & Equipment Co., 630 So.2d 358, 360 (Ala.1993). Mandamus is an extraordinary remedy requiring a showing that there is: '(1) a clear legal right in the petitioner to the order sought; (2) an imperative duty upon the respondent to perform, accompanied by a refusal to do so; (3) the lack of another adequate remedy; and (4) properly invoked jurisdiction of the court.' Ex parte Edgar, 543 So.2d 682, 684 (Ala.1989)."
Ex parte Compass Bank, 686 So.2d 1135, 1137 (Ala.1996).
Vesta contends that the trial court erred in granting Liberty National's Rule 27(b), Ala. R. Civ. P., motion for postjudgment discovery regarding the amount of the supersedeas bond because, it says, the postjudgment discovery amounts to an impermissible attempt to supplement the evidence concerning the underlying judgment. Whether a trial court is permitted to order discovery concerning the amount of a supersedeas bond is an issue of first impression in Alabama.
Rule 27(b) provides, in pertinent part:
"If an appeal has been taken from a judgment of a court to which these rules *412 apply ..., the court in which the judgment was rendered may allow ... discovery under Rule 34 or Rule 35 for use in the event of further proceedings in such court. In such case the party who desires to ... obtain the discovery may make a motion in the court therefor upon the same notice and service thereof as if the action was pending in the circuit court."
Our Supreme Court has stated:
"Matters concerning discovery pending appeal are within the trial court's discretion. Rule 27(b), Ala. R. Civ. P. `[R]elief under Rule 27 is discretionary with the trial court, and a trial court's ruling on a Rule 27 petition will not be reversed in the absence of an abuse of discretion.' Ex parte Anderson, 644 So.2d 961, 964 (Ala.1994)."
Sharrief v. Gerlach, 798 So.2d 646, 651 (Ala.2001).
As Vesta correctly points out, a trial court is not permitted to allow postjudgment discovery that "goes behind the judgment."
"[A]fter the appeal is taken, the judgment in the court below can not be vacated and set aside, or opened so as to introduce new matter into the record which was not properly a part of the record at the date of the judgment. ... After final judgment and the adjournment of the court, the record, if it speaks the truth, can not be increased or diminished. Such judgment, until it is reversed or new trial granted, is a finality."
Montevallo Coal Mining Co. v. Reynolds, 44 Ala. 252, 254 (1870) (emphasis added). Any postjudgment discovery is limited by the jurisdiction of the trial court after judgment has been rendered. "[T]he general rule is that a trial court is divested of its jurisdiction during a pending appeal," but "a trial court may proceed in matters that are entirely `collateral' to the appeal." Reynolds v. Colonial Bank, 874 So.2d 497, 503 (Ala.2003). "Collateral" matters are those that "d[o] not raise any question going behind the [judgment] appealed from, nor [do they] raise any question decided by that [judgment]." Osborn v. Riley, 331 So.2d 268, 272 (Ala.1976). More broadly speaking, collateral matters "d[o] not involve the `rights and equities' relative to the question on appeal." Colonial Bank, 874 So.2d at 503 (quoting Osborn, 331 So.2d at 272).
Because a trial court loses jurisdiction of an action save for collateral matters after it has issued a final judgment, the areas of inquiry subject to postjudgment discovery are automatically quite limited. The threshold question that must be answered in order to determine whether a party's Rule 27(b) postjudgment motion for discovery is proper is: Does it concern a collateral matter? If it does involve a collateral matter, then "the court and parties are free to proceed notwithstanding the appeal...." Barran v. Roden, 263 Ala. 305, 307, 82 So.2d 398, 399 (1955).
In Osborn, supra, the prevailing party made a motion for an additional supersedeas bond after the judgment in that case had been appealed. The appellant argued that the trial court was without jurisdiction to hear the motion because the judgment in the case had been appealed. The Supreme Court evaluated the issue as follows:
"[T]he Rileys' motion for an additional supersedeas bond is part of a proceeding that is separate and distinct from the [judgment] appealed from. The question presented by the Rileys' motion, that is, whether the original $5,000 supersedeas bond adequately protected the Rileys' interest in the court's order *413 entered in their favor, does not involve the rights and equities relative to the question of whether their deed should have been set aside. The Rileys' motion does not raise any question going behind the [judgment] appealed from, nor does it raise any question decided by that [judgment]. In short, the Rileys' motion presented a question which is clearly collateral to the questions raised by Osborn's appeal of the court order setting aside the deed."
Osborn, 331 So.2d at 272.
Liberty National's motion for postjudgment discovery on the proper amount of the supersedeas bond is similar to the motion at issue in Osborn  it does not involve the rights or equities involved in the direct appeal; rather, it is designed "merely [to] protect[ ] the appellee['s] interest in the trial court's order entered in [its] favor." Colonial Bank, 874 So.2d at 503. As such, the discovery motion involves a collateral matter, not a matter directly implicating the judgment. Consequently, the trial court had jurisdiction to grant the Rule 27(b) motion at issue.
Vesta complains that questions involving the proper amount of the supersedeas bond are directly related to the amount of the judgment awarded. We agree, but we note that that does not mean the discovery request represents an attempt to modify the judgment or to introduce something inappropriate into the record. Rather, the information sought is for the purpose of "mak[ing] the record speak the truth," Montevallo Coal Mining Co., 44 Ala. at 254, which is permissible under Alabama law. Liberty National seeks only to know the amount of the premiums collected since October 1, 1998, in order to determine how much 7.5% of those premiums, which is what the trial court awarded to Liberty National in its judgment, is. That information is properly part of the judgment. Montevallo Coal Mining Co., 44 Ala. at 254. The trial court is not seeking to change the amount of the award in granting Liberty National's postdiscovery motion; rather, it seeks to ensure that Liberty National's interest in the judgment entered in its favor is properly protected by requiring the correct amount for the supersedeas bond. This is a permissible exercise of the trial court's discretion in ruling on a Rule 27(b) motion. Sharrief, supra.
Because we conclude that the trial court was within its discretion in granting Liberty National's Rule 27(b) motion, Vesta does not have a "clear legal right" to have that decision reversed. Accordingly, Vesta's petition for a writ of mandamus is due to be denied.
2010773  AFFIRMED.
2010894  PETITION DENIED.
YATES, P.J., and CRAWLEY and THOMPSON, JJ., concur.
PITTMAN, J., concurs in the result.
NOTES
[1]  On July 16, 2002, this court issued an order stating that Vesta's appeal of the order granting Liberty National's Rule 27(b), Ala. R. Civ. P., motion would be treated as a petition for a writ of mandamus.
[2]  Liberty National has consistently alleged that both Vesta Fire Insurance Corporation and Vesta Insurance Corporation were parties to, and had joint responsibilities under, the Agreement. In its answer, Vesta Insurance Corporation specifically denied that it had contracted with Liberty National or that it was a party to the Agreement.
[3]  Those administrative services included taking and processing insurance applications, collecting premiums, keeping client records, maintaining agency records such as commission accounting, and handling routine customer-service inquiries.
[4]  Section 6.01 states: "Either party may at its election terminate this Agreement by giving the other party ninety (90) days' advance written notice of such intent to terminate sales under this Agreement." (Emphasis added.)

Section 6.02 states: "Within thirty (30) days of receipt or mailing of notice pursuant to 6.01, the [Liberty National] field will cease soliciting and submitting applications for Industrial Fire Insurance on behalf of [Vesta]."
In an alternative argument, Vesta contends that Liberty National did not give 90 days written notice of termination because it stopped selling the insurance policies only 32 days after it sent notice to Vesta, and, thus, Vesta argues, the provisions of § 6.03(a) do not apply in this case. We find this argument to be without merit; § 6.01 requires notice of intent to terminate sales of insurance policies, which is exactly what Liberty National stated it intended to do in its notice of termination, and, 32 days later, that is what it did. The notice appears to comply with the terms of the Agreement, and, indeed, Vesta made no complaint at the time notice was given that it was inadequate. In fact, Vesta allowed Liberty National to continue servicing the insurance policies without making any sales for over a year before the parties reached their mutual agreement stating that Vesta would assume all administrative services over the policies.
[5]  The trial court found that Vesta actually continued to pay commissions through May 1999.
[6]  Section 2.03(a)(2)(ii).
[7]  Support for the fact that different sections of the Agreement describe different stages of termination is found also in § 6.03(b), which provides that if the Agreement "is terminated by [Vesta], business in force and administered by [Liberty National] pursuant to this Agreement will continue following the notice of termination in accordance with the policy contract provisions." (Emphasis added.) Had Vesta been the first to terminate the Agreement notifying Liberty National that it wished for Liberty National to cease selling its policies, Liberty National would have continued to administer the policies in force. In that scenario, Vesta would have been obligated to continue to compensate Liberty National "according to paragraph 2.03(a)" "[f]or as long as [Liberty National] continues to provide services required by this Agreement." In other words, just as was the case under the terms of § 6.07(b), under the terms of § 6.03(b) Vesta would have been required to reimburse Liberty National for all compensation referenced in 2.03(a), including expenses and 1/12 of 5% of the in-force annualized premiums at the end of each month, for as long as Liberty National continued to provide services, but only because Liberty National would have continued to provide such services for the in-force policies.
[8]  See discussion in note 4, infra.
[9]  Section 27-7-4 was amended effective January 1, 2002. The language quoted above is the language of the statute before the amendment.
