4images Modifications / Modifikationen > Mods & Plugins (Releases & Support)

[Mod] Make "Images Per Page" a jump menu

(1/3) > >>

Chris:
This modifies the HTML form that allows the user to set the number of images to display per page.  It makes it behave the same way as the category dropdown list.

When the user selects a category from the category_dropdown_form.html, the choice is made without having to click a "Go" button.  This mod makes the setperpage_dropdown_form.html behave the same way.  The user will not have to click a "Go" button.

Open includes/page_header.php.

--- Code: ---
//-----------------------------------------------------
//--- Set Perpage Dropdown ----------------------------
//-----------------------------------------------------
// Original 4images code
// $setperpage_dropdown = "\n<select name=\"setperpage\" class=\"setperpageselect\">\n";

// Make this a jumpbox
$setperpage_dropdown = "\n<select name=\"setperpage\" onchange=\"if (this.options[this.selectedIndex].value != 0){ forms['imagesperpage'].submit() }\" class=\"setperpageselect\">\n";
--- End code ---

Jasondavis:
i tried this and nothing happens, when I click go it still works normal way, but just picking a # nothing happens

V@no:
it wont work, untill u either delete whole button from /setperpage_dropdown_form.html template =>
--- Code: ---<INPUT type="submit" value="{lang_go}" class="button" name="submit" />
--- End code ---
or delete
--- Quote ---name="submit"
--- End quote ---
from that button.  :wink:

pietg:
Is it also possible to make it just a list instead of a jumpbox?

Piet

V@no:
by default setperpage_dropdown is just a list.

Navigation

[0] Message Index

[#] Next page

Go to full version