Bookmarks can execute Javascript code. This gives you a lot of flexibility.
For example:
// This keyword bookmark jumps to the Recent Changes page on several different Mediawiki websites.
//
// I typically use "recent" as the bookmark's keyword.
// Is this a specific Mediawiki site that we recognize?
if ( /\.wikipedia\.org$|^terraria\.wiki\.gg$|\.mediawiki\.org$/ .test( window.location.hostname )) {
wikiroot = "https://" + window.location.hostname + "/wiki/"
}
if (wikiroot) {
// Navigate to that page.
window.location = wikiroot + "Special:RecentChanges"
}
...
It needs to first minify the code (to remove comments and such) and then add the "javascript:" boilerplate.