Different functions available in different websites

I see this topic as more a design question than anything.

If you wanted certain actions to be available/visible in certain web sites only, how would you do it?

My take is to:

  1. Have a macro group for each domain / webpage.
  2. Parse the URL - on what trigger? - to get the domain name.
  3. Pop up the appropriate macro group palette for each case.

Is this about right?

I would think the trigger would have to be an appropriate hot key. Maybe the Caps Lock hyperkey.

Thoughts?

Example: “GitHub New Issue” macro Is only appropriate when on the repository’s page(S).

I do this with macro groups, but I don't use triggers or URLs. I just set the group's activation criteria to include a unique word common to the site:

This shows a palette and activates the macros automatically whenever I visit that site, and deactivates them when I leave or switch tabs.

1 Like

Ah! I wasn’t aware of that trigger. However, doesn’t that put the palette up as soon as the title matches? I might not want that. And title might not be the key. (URL is obtainable via Cmd+L, Cmd+C in Firefox.)

Would switching from Firefox to Safari help? (I might but right now HTML5 Canvas behaviour is better for me in Firefox.)

You can always set the palette to a hotkey if you want to choose when it's displayed. As for browsers, this method should work just as well with Firefox as Safari or Chrome, but if you'd rather define macros by URL than title, I would recommend one of the latter, as you can then just use the %FrontBrowserURL% token to acquire the URL programmatically, which is much faster and more robust than going through the clipboard. For the URL method, you could do something like this:

1 Like

I also have a pallet for certain urls in safari. I have solved it with 2 gglick contributions: The one is here

I can't find the other one at the moment.

I have 2 macro groups:

The first one contains the trigger



In the second one then the palette with the special macros

2 Likes