Maintainer information
Last update: 14 July 2024 by Bob Moniot.
This page is not meant to be viewed by visitors, although it can be if they know the URL. Its purpose is to document the less obvious ways this website is set up so that new maintainers can quickly get up to speed.
Contact information:
Some pages have Larry Olsen’s contact information. In order to protect his information from being harvested by bots, the information is cloaked: instead of being HTML content, it is generated by JavaScript. The JS code is site-wide. To maintain it, go to Home - Pages - Website Tools - Code Injection. The code is placed in the Footer area, so it is inserted before the closing </body> tag of every page. That way it will run after the page elements are defined. We place it there rather than putting it in the header and attaching the function to window.onload since that event may be needed for other purposes in some pages. The function fillInMyEmail() inserts the contact information into the innerHTML of a document element (such as <p>) that has id="contactInfoOverlookcenter" when the page loads. Hopefully that id is site-wide unique.
Dynamic forms:
The registration pages for Pegasus, Orion, and Wynnview allow for registration of a second son. There is a radio button or checkbox that allows the visitor to elect to register a second son. It is off initially. If Yes is selected, then additional form fields become visible to provide the second son’s information. The forms for Pegasus and Orion use a pair of radio buttons, while Wynnview uses a checkbox. The basic form field functionality in Squarespace does not allow setting the initial value of “checked” for a radio or checkbox. A JavaScript code element on each form page is used to initialize the radio buttons so that “No” is checked, and the checkbox is unchecked. This is done by a function attached to the window.onload event. I tried to avoid using window.onload by placing the script after the form, even in another section, but this does not work. Another function is attached to the onclick event of the radio button or checkbox, to reveal or hide the second son information boxes according to whether the second son option is selected or not, respectively.
Some hints on image manipulation
The logos for Pegasus and Orion originally had white backgrounds, impeding their use on a colored background, since they are not the same size. Here is how to convert a white background to transparent in GIMP: Use the Select by Color tool (shift-O). Click on any point in the white background. Then use Colors -> Color to Alpha and click on the background. The text is outlined, and the inside gets made transparent too. Use Bucket Fill, fill similar colors, and click inside each letter to fill again with white. Export image as PNG.
PayPal payment button
The Pegasus/Orion and Wynnview payment pages include a PayPal payment button. Pegasus and Orion both use the same payment page. To change the payment amount, use the following procedure:
Log in to PayPal using the overlookhill account. Get credentials from Bob M or Larry O. This uses MFA via a text to Larry’s phone, so you need to coordinate with Larry during the login.
Go to paypal.com/buttons.
View saved buttons.
Open the desired button and edit. Update Saved Button.
Copy Code to clipboard.
Log in to Squarespace.
To update button, go to Pegasus or Wynnview payment page, replace code from <form> to </form> in PayPal block with code from clipboard.
To create a new button, go to the page where it is needed, and add a Code block. Paste code from clipboard into the block. Add explanatory text before or after the <form>…</form> element as desired.
Recollections
The page “Recollections for Men” under the “Programs for Men” main menu item does not need much maintenance. It describes the activity and lists the places where the recollections managed by Overlook are held. It has an embedded calendar where the upcoming recollections appear.
There is no mechanism (AFAIK) in SquareSpace to have repeating events, so you need to create each one manually. To add a recollection event to the calendar, go to “Recollections” under “Not Linked” pages and click on the “>” symbol. This opens a list of upcoming recollection events. Find one at the location for which you want to add another, e.g. Recollection at Overlook. In the panel at left, click on the “…” and select Duplicate. The in the panel at right, Click Edit. Edit the title to remove the word “(copy)” and click on the date below the title to change the date. When you change the date, the ending time will change to 1 hour after the starting time, so you need to fix that. Save the changes. We schedule publication to be right after the recollection 2 months earlier.
Home Page announcement block
This is a text block with the title in Heading 2 and content in Paragraph 2. Size 12 blocks wide, height as needed for content. Background solid light blue.