Will Wonka asking you to tell him again what WordPress can't do.

Multisite Post Forker – The Jolly Brancher

I happened to see John Johnston’s tweet earlier today. Essentially the goal was to write a plugin in WordPress multisite that would let the user fork a post/page into their own site where they could then continue to edit etc. @cogdog possible splot/plugin idea https://t.co/pL0HnuIO2L — john johnston (@johnjohnston) April 19, 2019 I had been hassling with a few other projects and felt like a break so I decided to take a swing at making it. I knew I had some of the major concepts worked out as part of the Motherblog Plugin, I’d just need to tweak some things. I managed to get a working plugin together in an hour or so. I’m dabbling off and on with some details but it’s functional. It’s up on github. Demo video is below.

14

Weekly Web Harvest for 2019-04-07

Facebook includes weird messages inside Oculus Touch controllers – Business InsiderFacebook said it accidentally hid bizarre and “inappropriate” messages inside “tens of thousands” of virtual-reality controllers, including “Big Brother is Watching” and “The Masons Were Here.”

12

Making an Index Using Javascript

Working with a faculty member we had a rather long page that was originally written in Google Docs. It had many sections that were (mostly) designated by H tags of various denominations. The goal was to and put it on a website quickly build an index of anchor links. I did not wish to do the index portion by hand. With javascript things like this are relatively pleasant. You can see the whole thing in this codepen but I’ll break it down a bit below. First we can get all the H tags with querySelectorAll. I can console.log(headers) and I’ll see a NodeList of all the headers it found. I tend to work console.log all my variables as I go just to make sure it’s really happening the way I think it is. My next move is to add an id to each of these headers so that we can navigate to them via anchor links. with this forEach loop each header will get an id of header-whatever number we’re on in the loop. Now that I have headers that I can link to as anchor links, I need to build the index and put it somewhere. In this case it was easy for me to add a div to the source manually so I did. That will be where […]

Google Sheets Data Flow

This is a pretty specific thing but the concepts ought to be broadly applicable and interesting for the 3 to 5 people who will end up reading this. It’s a fairly amusing blend of less standard Google Functions and a bit of Google Script to do something fairly decent that had been quite a bit of hassle to do previously. We have Social Work students who are assigned to various supervisor/liaison people. There are a lot of students. We wanted students to be able to submit a form to Google Drive and we’d keep track of all this and show only the relevant data to the various supervisors. Files from Form Setting up a form that requires you to be logged in and accepts files is now very easy in Google Forms. It also remains easy to log that information to a spreadsheet associated with the form. Merging the Data The student email address became the unique ID that would allow us to tie the form submission to the list of students and their programs, liaisons etc. Now we needed a formula to link these two sheets via email. I started with =VLOOKUP but that would have required the student email to be the leftmost column in the data and that would be awkward for other things. After some banging […]

07

Weekly Web Harvest for 2019-03-31

Homemade Low Carb Crunch Protein Bars (Keto, Vegan, Paleo) Lil Nas X – Old Town Road (feat. Billy Ray Cyrus) [Remix] – YouTubeA rare musical inclusion -Lil Nas X and Billy Ray Cyrus remix Morgan Herlocker on Twitter: “Became aware of the first major open scooter feed this morning. 20 minutes in and I am able to pull timestamps for trips going back and forth between a high school and a nearby Planned Parenthood. Working on a disclosure ASAPBecame aware of the first major open scooter feed this morning. 20 minutes in and I am able to pull timestamps for trips going back and forth between a high school and a nearby Planned Parenthood. Working on a disclosure ASAP & will share details as soon as I can safely do so.

A tag cloud of filler text.

Tag Cloud from Gravity Form Entries WP Plugin

Based on a conversation I had on Tuesday there appeared to be a need to generate a tag cloud1 from Gravity Forms responses. I didn’t see any immediate solutions after browsing for plugins. Granted, I could have jerry rigged something by creating posts and doing something weird where I added the words as tags . . . but I’m trying to do things in a more sustainable way lately and I figured this wouldn’t be too tough. I’m going to try to do a decent job of moving through the development process in stages. If you just want to mess with the plugin, it’s on GitHub. Find a Decent Tag Cloud Library I looked around and found wordcloud2.js. It seemed perfect. It has some real flexibility and the hard work has been done for me. I played around with a demo in CodePen. This lets me work out any kinks I might have in the js/html/css side of things before adding any WordPress and PHP complexities. If I don’t force patterns like this, I’ll add enough complexity that figuring out which thing I’m not understanding is much harder. It might take some extra time but it saves me quite a bit more in the long run. Building the Plugin Foundation enqueue the main scripts Following my mantra of slowly adding […]