Gelbooru

Notice: We are now selling NEW Gelbooru Merch~! Domestic shipping is free on all orders! Do you have an artist tag on Gelbooru? Let us know so we can properly credit you!

Ticket Information - ID: #304


ID:Category:SeverityReproducibilityDate SubmittedUpdated By:
0000304Bug Reportingnormalalways11/25/09 02:20AMlozertuser
Reporterdrako
Assigned to:lozertuser
Resolution:Resolved
View StatusPublic
Version:0.1.10
Target Version:0.1.11
Summary:Remove Favorites returns to page=1
Description:When removing a favorite from a page other than 1, it returns to page 1. (javascript bug)

Possible Solutions:
AJAX jQuery removal of <span class="thumb">? or make it not visible.

Additional Info:jQuery:::

$(".thumb > a:last").click(function() {
var pid = $(".thumb > a:first").attr('id');
$.get({
url: "index.php",
data: { page : 'favorites', s : 'delete', id : pid }
});
$(this).parent().hide();
return false;
});

Remove the "onclick" jscript from the "remove" button, and use the script above in a conjunction with jQuery.

www.jQuery.com


Alternative
adjust the php, to return to that page by including the &pid=<pageid> in the onClick document.page=""

This alternative will require more maintenance when the favorite page is updated. (IE, adding favorite folders, searchable favorites, etc.)
lozertuser replied at 2009-12-04 04:17:47
Done for 0.1.11. In SVN in dev folder.