=== Pearspark Forms ===
Contributors: pearspark
Tags: school, admissions, application form, enrollment, private school
Requires at least: 6.2
Tested up to: 6.8
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Put your school's Pearspark application and interest forms on any page with a block or a shortcode.

== Description ==

Pearspark is school software for small private schools, microschools, hybrid schools and homeschool co-ops. This plugin puts the two public forms a Pearspark school already has onto its own WordPress site:

* **The application form** — the questions your school wrote in Pearspark, with your application fee if you charge one. A submitted application lands on your admissions list.
* **The interest form** — a one-minute "tell me more" form for families who are not ready to apply. Inquiries land on the same list, marked as not yet applied.

The forms take the colors, font and corner style you set in Pearspark, sit on a transparent background so your page shows through, and grow to fit their content. Nothing a family types passes through your WordPress site: the form is a Pearspark page shown inside a frame, and it posts to Pearspark.

**Add a form with the block.** In the editor, add the *Pearspark form* block and choose the application or the interest form. The editor shows the real form.

**Or with a shortcode**, anywhere shortcodes work — the Classic editor, Elementor, Divi, WPBakery, a text widget:

* `[pearspark_apply]`
* `[pearspark_interest]`

Both accept `school="your-school"` to show a different school than the one in Settings, `min_height="600"` for the space held before the form loads, `powered_by="no"` to hide the credit line on that one form, and `title="…"` for the frame's accessible title.

You need a Pearspark account for your school (there is a free trial at pearspark.com). The plugin does nothing without one.

== Installation ==

1. In WordPress, go to Plugins → Add New Plugin → Upload Plugin, choose the zip, then Install Now and Activate.
2. Go to Settings → Pearspark and paste your school's application link from Pearspark (Admissions → Website embed), or just its last part — for example `maple-grove` from `https://pearspark.com/apply/maple-grove`. Save. The page confirms which school it found and whether each form is open.
3. Edit any page, add the *Pearspark form* block (or paste `[pearspark_apply]`), and publish.

== Frequently Asked Questions ==

= Where do the applications go? =

To your Pearspark admissions list, the same place they go from the form on pearspark.com. WordPress never stores them.

= Can I change how the form looks? =

Yes, in Pearspark: Settings → Branding for the colors, and Admissions → Website embed for the font, corners and background. Every page that shows the form updates.

= The form says applications are closed. =

That is your Pearspark setting. In Pearspark, open Admissions and switch applications on. The interest form has its own switch under Website embed.

= Does it work on WordPress.com? =

On WordPress.com, uploading a plugin needs the Business plan or higher. On other WordPress.com plans, use a Custom HTML block with the snippet from pearspark.com/integrations/wordpress instead — same form, no plugin.

= Does the plugin contact any outside service? =

Only when an administrator opens Settings → Pearspark: the plugin asks pearspark.com whether the saved link is a school and which of its forms are open, so the page can say "Connected to Maple Grove Academy". The request carries the link you saved and this site's address; the answer is cached for five minutes. Visitors' browsers load the form itself from pearspark.com, exactly as they would any embedded page. See https://pearspark.com/legal/privacy.

== External services ==

This plugin connects to Pearspark (https://pearspark.com), the service whose forms it displays.

* **What is sent and when:** when an administrator views Settings → Pearspark, the plugin requests `https://pearspark.com/api/embed/school/<your-school-slug>` and sends this site's URL as the user agent. Visitors' browsers load `https://pearspark.com/embed/apply/<slug>` or `/embed/interest/<slug>` inside a frame, and the form posts what a family types to Pearspark.
* **Terms:** https://pearspark.com/legal/terms
* **Privacy:** https://pearspark.com/legal/privacy

== Changelog ==

= 1.0.0 =
* First release: the Pearspark form block, the `[pearspark_apply]` and `[pearspark_interest]` shortcodes, Settings → Pearspark with a connection check, and the optional credit line.
