Last post Feb 01, 2010 08:08 PM by VictorJuri
Jun 10, 2009 06:41 PM|radion_auto|LINK
Hi there, basically im having some problems with the annoying generated styles that .net puts in when using controls with the css friendly component. It seems to auto generate a load of css styles and put them in a webresource.axd file. the content of these
is playing havoc with my css.
I dont really want it to generate any css for me, i cant write it myself, but ill be damned if i can find where it is disabled!
Anyone able to tell me how i can strip out all of the formatting .net puts into the menu?
Jun 11, 2009 02:03 AM|cgeers|LINK
If you are using the CSS Friendly Adapters than you should have the CSSFriendlyAdapters.browser file present in the App_Browsers directory.
Open this file and comment out the following line to disable the CSS Friendly Adapters for the ASP.NET Menu control.
Using this file you can choose to which controls the CSS Friendly Adapters are applied.
Jun 11, 2009 02:56 AM|radion_auto|LINK
Thanks for the reply, but that is not really the behavior i am after. I still want the html layed out css-style (with UL and LI's instead of dirty tables) i just dont want all the css stylesheet markup auto generating, any ideas?
Jun 11, 2009 12:48 PM|radion_auto|LINK
Is there a way to do this without having to recompile the CSS friendly component? i can't actually do this as my visual studio does not allow me to load C# projects for some reason, and there is no VB version that i could find..
Jun 11, 2009 06:34 PM|radion_auto|LINK
Could somone please tell me how i get rid of these annoying auto generated styles? .net is putting a "height:1% !important;" on A tags inside my menu, this totally messes up IE6 compatibility and i cant seem to get rid of it!
This has sadly halted my progress with the site for several hours now, what a waste for such a silly problem :(
Jun 15, 2009 06:37 AM|radion_auto|LINK
Anymore ideas on this? i am still banging my head against a brick wall trying to get my page to display in IE6!
Aug 24, 2009 04:56 PM|moogleii|LINK
Radion, what version are you using? I'm running into the same problem with IE6 and menus, even after I overrode all the built-in styling with my own (verified with firebug). I'm on build 24242. I was under the impression 1.0 could give you pure css-friendly
html without built-in styling?
From what i see in the code, for 24242 anyway, it looks like it'll take a rebuild. Actually, after i thought about it some more, it looks like if you apply your own !important property to all your own css, taking care to override everything the built in
css does, you should be able to style it exactly as you want. It worked for me.
I've got to say, I kind of disagree with the bundling of the CSS. I apologize if I'm making some short-sighted assumptions since I've only given the project a cursory glance, but it seems like it would be more powerful and flexible to keep the CSS in a separate
file that users can use, rather than integrating it into a built-in axd resource. From a styling point of view, if I'm building something from the ground up, I'd rather have blank, css-friendly html, rather than something pre-styled.
Aug 27, 2009 12:22 PM|sprockincat|LINK
From there you can just modify the MenuAdapter to not register the scripts. I had to do some modifications to change/add some CSS class names as well.
Superfish is working great for me. I'm not that great with CSS and the Superfish styles were much easier for me to modify than the CSSFriendly styles were.
Feb 01, 2010 08:08 PM|VictorJuri|LINK
This is certainly a pain to have to fight the styles compiled into the dll. I solved this problem very quickly as follows.
The bottom line is that the css is compiled into the dll. This is a mistake if you ask me. Its hard to get your menu to position itself exactly as intenede if you have to fight existing css. Some basic Css is required so the rendered html acts like a menu,
but I think it could be trimed down a bit. This is the reason why the give us the whole project. Its really fast and easy once you figure it out.
Hope this helps someone.