• Drop down without a Submit Button using JavaScript (for pages)

    How can i do this for pages

    <li id="categories"><h2><?php _e('Posts by Category'); ?></h2>
    	<?php wp_dropdown_categories('show_option_none=Select category'); ?>
    
    <script type="text/javascript"><!--
        var dropdown = document.getElementById("cat");
        function onCatChange() {
    		if ( dropdown.options[dropdown.selectedIndex].value > 0 ) {
    			location.href = "<?php echo get_option('home');
    ?>/?cat="+dropdown.options[dropdown.selectedIndex].value;
    		}
        }
        dropdown.onchange = onCatChange;
    --></script>
    </li>
Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter Millen

    (@millen)

    Does anyone know how to do this?

    Thread Starter Millen

    (@millen)

    Is there anyone out there that know how to do this?
    To make a drop down list with no submit button, that contains pages instead of categories.

    Any wordpress expert/guru out there that know how to solve this?

    /Thanks

    Thread Starter Millen

    (@millen)

    Is their anybody out there that knows where i can get help with this at least? I have search everywhere for days now and i can’t find any related information.

    Help would be very much appreciated…

    Thread Starter Millen

    (@millen)

    anyone?

    if someone know, i’m very interested in this tip too ??
    many thanks!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Drop down without a Submit Button using JavaScript (for pages)’ is closed to new replies.