Title: UL menu php
Last modified: August 21, 2016

---

# UL menu php

 *  [Taro](https://wordpress.org/support/users/sicktb/)
 * (@sicktb)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/ul-menu-php/)
 * Because my menu is not correctly working in IE8 and below i’m trying to add a
   static ul, li based menu. But im not a php pro and i dont know if its possible
   to make a basic menu with the UL class that will look like the normal menu but
   no accordion effect but only opens and basic css.
 * The code must be replaced at the **echo test;**.
 * I tried to find some information on how to display the main pages from the subpages.
   But i can’t find the correct code and i can’t get it to work with the ul code.
 * Let’s say i use the basic codee **wp_list_pages(‘title_li=’);** to view the menu.
   I can’t change the css for the main and submenu items this way.
 * This code works but still gives me a bad layout in IE8 and below:
 *     ```
       wp_nav_menu(array(
                     'menu' => 'main',
                     'container_id' => 'iemenu',
                   ));
       ```
   
 *     ```
       <?php
       function ae_detect_ie()
       {
           if (isset($_SERVER['HTTP_USER_AGENT']) && (strpos($_SERVER['HTTP_USER_AGENT'], 'MSIE') !== false))
               return true;
           else
               return false;
       }
   
       // Use the function and create a condition
       if(preg_match('/msie [2-8]/i',$_SERVER['HTTP_USER_AGENT'])) {
   
          // if IE<=8
   
       echo test;
   
       }else{
   
             wp_nav_menu(array(
                     'menu' => 'main',
                     'container_id' => 'cssmenu',
                     'walker' => new CSS_Menu_Maker_Walker()
                   ));
       }
       ?>
       ```
   

Viewing 1 replies (of 1 total)

 *  Thread Starter [Taro](https://wordpress.org/support/users/sicktb/)
 * (@sicktb)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/ul-menu-php/#post-4620376)
 * test website : [link](http://take.van-gelderop.nl/)
 * At the moment i got this for IE8 and below:
 * wp_nav_menu(array(
    ‘menu’ => ‘main’, ‘container_id’ => ‘iemenu’, ));

Viewing 1 replies (of 1 total)

The topic ‘UL menu php’ is closed to new replies.

## Tags

 * [ie](https://wordpress.org/support/topic-tag/ie/)
 * [Internet Explorer](https://wordpress.org/support/topic-tag/internet-explorer/)
 * [li](https://wordpress.org/support/topic-tag/li/)
 * [menu](https://wordpress.org/support/topic-tag/menu/)
 * [php](https://wordpress.org/support/topic-tag/php/)
 * [ul](https://wordpress.org/support/topic-tag/ul/)

 * 1 reply
 * 1 participant
 * Last reply from: [Taro](https://wordpress.org/support/users/sicktb/)
 * Last activity: [12 years, 3 months ago](https://wordpress.org/support/topic/ul-menu-php/#post-4620376)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
