Generated CSS path is giving 404 error
Within the front_end_head() function, $menu->term_id is not giving me the same value as $parentID within the save_config() function.
The end result is I have a stylesheet generated from the plugin as: custom_menu_images_3.css, but in the head of my document it’s looking for: custom_menu_images_6.css?ver=3.1.2
Great plug-in, I’m looking forward to using it regularly.
Same problem here.
In my header there is this link “custom_menu_images_.css?ver=3.1.2” but the css file is “custom_menu_images_4.css”
How are you calling the menu?
Is it registered via functions.php or just called in the theme?
My menu is registered via functions.php:
register_nav_menus( array( 'primary' => __( 'Primary Navigation', 'rek' ), ) );
Then called in my header.php:
$args = array( 'theme_location' => 'primary', 'container' => 'div', 'container_class' => 'menu_header', 'menu_class' => 'menu', 'echo' => true, 'fallback_cb' => 'wp_page_menu', 'depth' => 0, ); wp_nav_menu($args);
[please format code using the code formatting button]
Thanks for your feedback,
Let us check and get back to you.
My code is very simple
add_action( 'init', 'register_my_menus' );
then in header.php:
wp_nav_menu( array('menu' => 'principal' ));
Sorry for the inconviniences, we figured out a better way of doing this.
Comming next week
Great, glad to hear it.
I’ll be looking forward to the next release.
I’ll be sure to let you know.
We will generate a single css file with a unique url and all multiple menus css apended to it.
What do you think? Any better ideas?
Hi Anabelle, I think that’s a good idea.
In my case, I’ll only be using the navigation icons on my primary menu, however if I were using multiple menus with icons I would definitely prefer having all css within one file rather than the plugin making separate requests for each stylesheet.
Two more unrelated items I’ll mention…
1. When adding an icon image the thickbox popup isn’t able to fit the content of the wordpress image uploader/library (see example)
Not a major issue, but slightly annoying. Looks like the thickbox width should be somewhere around 670px to fit everything.
2. Originally when I was trying to get the plugin working I first specified an image URL and then decided to use the library instead. Even after selecting the “From Media Library” radio button, the input for the icon url was kept. I became unclear if that was something I had to manually clear before my library selection would work.
I would either have the url input field cleared when the From Media Library option is selected, or simply add a margin on the bottom of the url input field to keep the two options a bit more separate.
Thanks again for your work on this plugin.
Hey Thanks a lot for yout great feedback,
This will all come in the next version 🙂
We have just released a new version that greatly improves CSS generation and handling for multiple menus.
Works good! On the site I was previously testing the plugin with it saves my menu icons but gives a warning.
Warning: Invalid argument supplied for foreach() in /home4/yyyyy/public_html/xxxxx/wp-content/plugins/custom-menu-images/custom-menu-images.php on line 150
I installed the plugin on another site (fresh install of the plugin) and it didn’t give me the error, so perhaps it’s because I upgraded the plugin vs a fresh install (or maybe it’s just conflicting with another plugin).
I’ll post if I notice any bugs, but it’s working good and my icons are showing up.
- The topic ‘Generated CSS path is giving 404 error’ is closed to new replies.