The following will make maintaining bookmarks on Danbooru easier, as it removes the trailing search parameters thereby leaving a clean URL to bookmark. Use the Bookmarklet if it's only needed occasionally, or the Userscript if it's to be used all the time. (ref forum #136183)
Note: Unfortunately, DText doesn't allow one to create a link out of the above, so the bookmarklet will have to be set manually.
Userscript
// ==UserScript==
// @name Danbooru Post URLs
// @version 2.0
// @match *://*.donmai.us/*
// @exclude /^https?://\w+\.donmai\.us/.*\.(xml|json|atom)(\?|$)/
// @grant none
// @run-at document-end
// @description Remove trailing search parameters from image links on the post search page.
// ==/UserScript==
$(".post-preview a").each((i,entry)=>{
entry.href = entry.pathname;
});
Edit:
(2019-10-04)
Added exclude line for XML/JSON
Added version number
(2021-01-25)
Made the script active on the entire site
Changed the run time
Used the instance variation of each
Is this still current? This is the last piece of functionality I was using BetterBetterBooru for, but today's update seems to have broken BBB for good and this script doesn't seem to do anything for me.
Is this still current? This is the last piece of functionality I was using BetterBetterBooru for, but today's update seems to have broken BBB for good and this script doesn't seem to do anything for me.
It still works for me, on both Chrome and Firefox.
I've been voting a lot more since the voting system changed, and I wanted a more efficient way to do it. So based off of suggestions in topic #19990 I made this userscript to add hotkeys for voting.
I have upvote set to shift-W and downvote set to shift-S, the idea being that you can scroll through your search using A and D, voting as you go with your hand on WASD. But you can easily set the hotkeys to whatever you want by changing "shift+w" to the relevant key.
I use Search Artist Commentary for finding and manually translating identical commentaries, it's a great tool for me, but I'd like to be able to set a text (the translation) somewhere to add in the post's translated commentary field while tag scripting with commentary -commentary request -check commentary in the same page.
I developed a userscript a while back that I shared on Discord, which adds an is_deleted checkbox input when editing an artist. This can help save time if editing and deleting an artist at the same time, otherwise the actions of editing and deleting must be done separately.
Userscript
// ==UserScript==
// @name ArtistInputs
// @version 1.0
// @description Add additional inputs to the artist edit form.
// @match *://*.donmai.us/artists/*/edit
// @exclude /^https?://\w+\.donmai\.us/.*\.(xml|json|atom)(\?|$)/
// @run-at document-end
// @grant none
// ==/UserScript==
const IS_DELETED_INPUT = `
<div class="input boolean optional artist_is_deleted field_with_hint">
<input name="artist[is_deleted]" type="hidden" value="0">
<input class="boolean optional" type="checkbox" value="1" name="artist[is_deleted]" id="artist_is_deleted">
<label class="boolean optional" for="artist_is_deleted">Deleted</label>
<span class="hint">Check to mark this artist as deleted.</span>
</div>`;
if (document.body.dataset.action === 'edit') {
$('.artist_url_string').after(IS_DELETED_INPUT);
$('#artist_is_deleted').prop('checked', JSON.parse(document.body.dataset.artistIsDeleted));
}
I use Search Artist Commentary for finding and manually translating identical commentaries, it's a great tool for me, but I'd like to be able to set a text (the translation) somewhere to add in the post's translated commentary field while tag scripting with commentary -commentary request -check commentary in the same page.
Simple stuff I wrote - copying other's code as I don't know javascript nor any programming language - to help with my shenanigans. It works when viewing a post, I don't know how to make something that works on the page I wanted months ago, but it doesn't matter much. As simple as it is, I'm sharing it because it helps mass translating titles like character names and the untitled ones from Pixiv, and other people might take interest and do better things with artist's commentaries. 6 was just a random easy key I chose.
// ==UserScript==
// @name EditTranslatedtitle
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Adds text to the artist's commentary "translated title" field, adds commentary and removes commentary_request after pressing a key.
// @author Individual
// @match https://*.donmai.us/posts/*
// @grant none
// ==/UserScript==
function doc_keyUp(e) {
if (e.key === "6") {
document.getElementById("artist_commentary_translated_title").value = "Untitled";
if (document.getElementById("artist_commentary_add_commentary_tag")) {
document.getElementById("artist_commentary_add_commentary_tag").click();};
if (document.getElementById("artist_commentary_remove_commentary_request_tag")) {
document.getElementById("artist_commentary_remove_commentary_request_tag").click();};
document.getElementsByClassName("ui-button ui-corner-all ui-widget")[8].click();
}
}
document.addEventListener("keyup", doc_keyUp, false);
Increase score of the name if it is found as prefix in other names.
Reduce score of the garbage names.
Garbage detector rules:
Names with common suffixes (events, seeking jobs/comms, sns junk).
Names staring or ending with emoji.
After garbage detection and scoring is done, rebuild name list based on the score from highest to lowest (if score for two names is the same - use alphabetic order).
A slightly personal way to discover and explore tags on danbooru. Buttons (top right corner) that append 'order:favcount age:..6month -animated' or 'order:score age:..6month -animated' to current tags. It wouldn't work unless you have a high-tier account because of the tags limit. But you can always modify the script and personalize it (remove -animated for example). https://raw.githubusercontent.com/ImoutoChan/iqdb-autoselect/master/danbooru-recent-top-posts.js
As an alternative to this, if you're just interested in highlighting which posts you have already favorited, you can instead use a custom CSS. For example, the CSS on forum #132077 will dim out favorited posts unless you hover over them.
As an alternative to this, if you're just interested in highlighting which posts you have already favorited, you can instead use a custom CSS. For example, the CSS on forum #132077 will dim out favorited posts unless you hover over them.
The HTML attribute used by that custom CSS has been removed. →forum #178506
The HTML attribute used by that custom CSS has been removed. →forum #178506
Oh, right. It still works for me, so I had forgotten that. I added that back in with my DisplayPostInfo userscript (topic #15926). To enable it, the post_favorites_enabled has to be checked underneath the userscript settings (User Settings >> Userscript Menus >> DisplayPostInfo >> Information Settings). Once set, it does nothing more than add the data-is-favorited attribute back to the post, so that the user can customize things however they want with their custom CSS.
I have some questions about scripting (Js) on the website, is anyone knowledgeable about that? Specifically Image Board Enhancer greasyfork userscript. I've made some modifications that seems to work almost perfectly in chrome, but when I switch to firefox, the addon doesnt work at all. My changes are here, i would love if someone who knows Js better could take a look at why it might work in Chrome but not Firefox. <3 thanks