Altering the browser's interaction with css and the dom - css

I am interested in creating a custom browser with a hacked render engine that reinterprets or automatically assigns certain css vaules no matter what the web site.
A simple example would be...
no matter what website you visit the anything with the img tag is rotated 90 degrees.
I am struggling to find any sort of starting point for this small project...any ideas or suggestions on the css/dom issue?
I plan to build out the GUI in visual basic if that makes any difference.

Since you're using Visual Basic, why not use the WebBrowser control and modify the DOM elements within that control? You can manipulate elements from within your code behind.

Sounds like you want to develop a browser plugin / extension.
Chrome extensions are a good place to start.
If you'd like to actually like to monkey with the render engine behind a browser, check out WebKit (what Safari uses) or Gecko (what Firefox uses).

Related

Find design Problems (html,css)

i have some ASP.NET pages.
pages does not appear in FireFox4 same IE9.
i want to find my HTML or CSS Design problems.
i hared that this is a tool for finding problems.
but i can't use it because my ASP.NET Page contains some usercontrols.
I am looking for a way to find my design problems(tool , tip , etc).
another note is i am using jQuery UI plugins in my site.
One approach would be to use Chrome Developer Tools / Firebug / IE 8 Developer Tools to take a peek at the HTML being generated to look for any glaring errors. It can also help catch some jQuery issue that might be causing you grief.
Outside of that, HTML Tidy is a nice program that could help diagnose some stuff for you as well.
One thing to realize is that every browser renders a page slightly different, despite the attempts to render them in a "universal" manner. If you're really looking for the small differences, you can check out the SuperPreview tool that comes with Microsoft Expression Web

customising asp.net fileupload control

Using the asp.net file upload control is very easy, i'm trying to squeeze it into my site and the dam thing is very ugly!. Can I not change the browse button to an image of my choosing ?
So far i'm failing to achieve this seemingly simple goal. Any ideas on this one ?
Thanks
Unfortunately you can't do much with as it's really down to the browser how it is styled and functions. Just try it in Safari & IE to see the difference.
I have seen sites where people have used overlays to make it look different, kind of giving it a mask.
Here's a more thorough discussion on quirks mode about the problem: Styling an input type="file"

ASP.net site looks completely different on IE, Firefox, and Chrome; why?

I'm doing css for a website. I send the html and css to a guy, he puts it into ASP.net. The problem is that the transfer didn't end well for my code and it needs some fixing. The problem is that when I look at it in Chrome, or Firefox, or IE8, I get three completely different renderings. I spent a good amount of time trying to fix a drop-down menu that is supposed to appear while hovering over a link. The one he had in place from ASP.net worked in IE, kinda worked in Firefox, and was completely broken in Chrome (I haven't tested Safari or Opera.) Just getting it to look basically the same in firefox and chrome was a struggle. The html source is showing me two completely different pages as well.
Does anyone have experience with this? I know nothing of ASP.net, and it seems like the guy is modifying my layout with a wsyiwyg (I found tables used in random places, which I did not put there.) Faced with this, what is my best option? Is this fixable, or am I in over my head?
Many times WYSIWYG programs don't generate code that results in reliable, consistent renderings. However, there are a few things you can do to check your site's consistency.
You can use a program like Adobe BrowserLab (there's a free trial right now) to automatically render your page in multiple browsers side by side
You can use the w3 Validator to make sure that your code is standards compliant. If your code isn't standards compliant, then you will likely have issues across browsers.
Note that you can force asp.net to generate XHTML Transitional- or Strict-compliant code (if that's the standard you choose to implement) via the web.config file. Use the directive
<xhtmlConformance mode="Transitional"/>
if you want to enable this behavior.
Was your code rendering fine in those browsers before you sent it off to the .NET guy? If so, the programmer is doing something to muck up your work. ASP .NET won't change the way your code renders... it's simply the Windows equivalent of PHP (simply put).
I would suggest (if you haven't already) testing your code before hand-off to verify proper rendering. Take some screenshots, and if after sending your code to this developer things break, you can point out that it was working until he started messing with your markup. If that ends up being the case, at least you know it wasn't you. If it was, then we have more work to do. :)
Can you provide any samples?
The html source is showing me two completely different pages as well.
That sounds like your asp.net guy is doing something wrong there. You can use asp.net to do browser-dependant rendering, but it sounds more like his job is to just make the site render what you gave him, and it's usually better to get your html and css right to begin with.

What value has Visual Studios CSS support?

So I'm supposed to be a .Net Developer but have found myself getting stuck with allot of css and html stuff lately. I would now consider myself to be very strong in css and all it's intricacies. With that said I still see any use it any of the Visual Studio support for it outside of the intellisense (when it works).
I want to ask if anyone developers that view themselves strong in css are using any of the Visual Studio 2008 css support features and if so what they are and why they use them over say firebug?
Thanks,
Denis
Hand coded all the way for me.
Firebug is really good for getting to the bottom of wierd browser issues, but generally I have IE, Chrome and Firefox open when I'm coding html & CSS, and I just make sure I hit the refresh button often enough in all three of them to make sure I don't get any nasty suprises after writing a pile of css.
Typically I turn off all of the Visual Studio CSS stuff. It's not exactly well made. Instead I've been using MS Expression to build master pages and manage CSS files. It is light years ahead of VS.
That said, I see firebug as a complimentary product, not really a replacement. I use FireBug and the equivalents in safari, chrome, and IE 8 to see what's going on with the internals of a particular element on a page. I use Expression to edit and maintain the css.

How to embed HTML created by Dreamweaver into an ASP.NET applicaton

I've been asked by a friend, who created a very visually appealing website mostly in Dreamweaver, to add some database backed functionality that I really only know how to do in ASP.NET. The problem is when I load his generated HTML into an ASPX page it renders it quite horribly. I've tried adding a basic .html page to an ASP.NET project but it still looks funky. He's on a Mac and i'm (obviously) using a Windows box. Is there a clean way to take a quite complete (but quite static) website and add ASP.NET functionality to it? Any comments are very much welcome. Thanks!
Just a quick thought.
You state in your comment:
Everything works is just doesn't look near as good as it did in the Safari browser
Where doesn't it look as good as it did in the Safari browser? When served as a page from a webserver (either the built-in cassini server, or IIS) in IE/Firefox, or when you switch to design view in Visual Studio?
Visual Studio has a lot of trouble rendering things correctly - it's really not standards compliant by anyone's definition - VS2010 is apparently much better - for example, try looking at this page: display/box/float/clear test in a browser and in the VS designer - very different.
If you mean in the browser, which browser? Have you tried looking at it Firefox instead? It's possible that if it's been built to look nice in Safari that it will work in Firefox, but there may be issues with the rendering/layouts in IE - this is a fairly well known issue.
If all the stylesheets are being correctly called (check with Firebug for Firefox for example) then there are probably some issues with the CSS that need to be addressed for IE.
ASP.NET does not alter the rendering of standard HTML. So there must be some other issue like a missing stylesheet (either all together or a broken link) or images. Once you have the HTML properly copied over and solve the display issue, you can add in the ASP.NET controls and code you need to make it functional.

Resources