Search Results

Search found 11623 results on 465 pages for 'css positioning'.

Page 92/465 | < Previous Page | 88 89 90 91 92 93 94 95 96 97 98 99  | Next Page >

  • Use CSS selectors to collect HTML elements from a streaming parser (e.g. SAX stream)

    - by Jakub Narebski
    How to parse CSS (CSS3) selector and use it (in jQuery-like way) to collect HTML elements not from DOM (from tree structure), but from stream (e.g. SAX), i.e. using sequential access parser? Are there CSS selectors that need access to DOM (Wikipedia SAX page says that XPath selectors "need to be able to access any node at any time in the parsed XML tree")? I am most inetersted in implementing selector combinators, e.g. 'A B' descendant selector. I prefer solutions describing algorithm, or in Perl.

    Read the article

  • JQuery.ready is too late: How do I apply CSS Values with JQuery before Rendering?

    - by viatropos
    I want to be able to apply opacity to some elements to make them invisible only if javascript is enabled. I don't want to use display:none because I want the layout to act as if they're in the DOM, so setting opacity to 0 is perfect. I want to be able to set this initial value using Javascript, using JQuery, so I don't have to mess with browser differences on the opacity (and many other) attributes. But if I set opacity to 0 like so: $(document).ready(function() { $("#header").css("opacity", 0); $("#header").animate({opacity:1}, 500); }); ...half the time it's already visible on the screen, so it appears and disappears. How do I set these css values using JQuery before they ever can render?

    Read the article

  • Which free HTML/CSS IDE has best readable code formatting ?

    - by jitendra
    Which free HTML/CSS IDE has best readable code formatting for XHTML and CSS ? in one click or from keyboard shortcut? I don't want to give more time to proper indention, tab ec, want to select whole code and give good-looking formatting. I need easliy scanable Code formatting and syntax highlighting. and missing things (if anything is not proper) should show error. I know many online tool to do this but don't want to go everytime to online tool. Edit; I need free Windows tool (portable would be better)

    Read the article

  • What are the design patterns for HTML and CSS ?

    - by IHawk
    I know that is a very embracing question, but I have just started with Ruby on Rails, and still have a long way with CSS and HTML. There are lots of books about CSS and HTML patterns, but I would like to know what is really applied to actual webpages. For example, what's the best way of doing a simple webpage with a lateral menu, a logo on the top, and some text below? Ok, it seems stupid, but there's lot of ways of doing that, or not ? So, how can I learn this patterns and what are the real patterns ? Would appreciate suggestions of books, articles, etc.

    Read the article

  • Is there any tool which can rearrange the css based on same type selector?

    - by metal-gear-solid
    I've big css where selector for same things are on different place. Is there any tool which can rearrange the css based on same type selector? This is just example. #main h2 { font-size: 2em; } #sidebar h3 { font-size: 2em; } #main h1 { font-size: 3em; } #sidebar h4 { font-size: 1.6em; } #main #box h2 { font-size: 2em; } #sidebar ul li { font-size: 1em; } it should arranged like this #main h1 { font-size: 3em; } #main h2 { font-size: 2em; } #main #box h2 { font-size: 2em; } #sidebar h3 { font-size: 2em; } #sidebar h4 { font-size: 1.6em; } #sidebar ul li { font-size: 1em; } if parent selector is same then all should be at same place.

    Read the article

  • How to use these ruby based CSS stylsheet frameworks languages?

    - by metal-gear-solid
    I read about many CSS related languages and tools which need ruby. What is the purpose of these languages and tool how these can save time and improve our CSS coding. What is the role in ruby language in these languages and tool. Will i have to install and learn ruby language to use these languages and tool. will i need ruby installed on webserver where website will be hosted. I'm talking abut these languages http://lesscss.org/ http://sass-lang.com/ http://compass-style.org/ some mentioned here: http://www.ruby-toolbox.com/categories/css_frameworks.html I'm on Windows XP PC , How can i use these Ruby based languages and which is preferred? I don't know ruby language.

    Read the article

  • When is it a good idea to use the CSS display property?

    - by allyourcode
    I think I first learned of this property when I thought "I should put this list of items in a ul, but I want it to be laid out horizontally. I wonder if I can do that with CSS?" When I googled this, I found a couple of sites suggesting that I create a CSS rule that would change the value of the display property of the li elements to inline. I've also seen the suggestion that a div (or other block element) be given display: table-cell in order to force the vertical align property to work. These techniques seem kind of hacky. Does that make sense? This might not be a good analogy, but it seems like trying to ride a car as if it were a motorcycle. Yeah, I could replace the steering wheel with handle bars, wear a helmet, and remove all the passenger seating, but how the heck is a car going to drive on two wheels??

    Read the article

  • Regular Expression to get the size value of a CSS property?

    - by thiesdiggity
    I wrote a regular expression to get the size from a CSS property: /(([+-]?\d*\.?\d+(\s)*(px|em|ex|pt|in|pc|mm|cm)?)|thin|medium|thick)(\s|;|$)/i but for some reason its not working as intended. For example, when I run the following: preg_match_all('/(([+-]?\d*\.?\d+(\s)*(px|em|ex|pt|in|pc|mm|cm)?)|thin|medium|thick)(\s|;|$)/i', "border-bottom:1px solid #99999;", $matches); It outputs: 1px 99999; But I only want the 1px value returned. I understand why its returning the above but can't seem to figure out how to only return the size and not the color value. I tried using the following negative lookbehind but it's not working either: /(((?<!#\d{3}|#\d{6})[+-]?\d*\.?\d+(\s)*(px|em|ex|pt|in|pc|mm|cm)?)|thin|medium|thick)(\s|;|$)/i I want to use preg_match_all for those CSS properties that can have multiple size values (i.e. margin). Anyone have any ideas how to get this regex to return only the size values? Thanks for your help!

    Read the article

  • CSS - Why am I not able to set height and width of <a href> elements?

    - by Kenny Bones
    Hi, I'm trying to create css buttons by using the following html markup: <a href="access.php" class="css_button_red">Forgot password</a> But it ends up being not bigger than the text in the middle. Even though I've set the class's height and width. You can preview the problem here btw, www.matkalenderen.no Notice the first button, that's a form button and it's using it's own class. At first I tried to use the same class on the css button as well and the same problem appeared, so I tried to separate them into their own classes. In case there was some kind of crash. But it didn't matter anyway. What am I missing here?

    Read the article

  • What is CSS? what should be the shortest and appropriate answer of this question? [closed]

    - by metal-gear-solid
    What is CSS? what should be the shortest and appropriate answer of this question? How simple we can explain , What is CSS ,just in words? mine answer is this Stands for "Cascading Style Sheet." Cascading style sheets are used to format the layout of Web pages. They can be used to define text styles, table sizes, and other aspects of Web pages that previously could only be defined in a page's HTML. Is it ok or it can be more perfect or shorten?

    Read the article

  • jquery.position() isn't working correctly.

    - by devzero
    I'm working on a menu system where I want a ul to show as a dropdown when the users does a mouseOver on li in another ul. I thought I'd use position to set the position of the dropdown (so it actually looks like a menu). What I want is the dropdown's top left corner to start at the same place as the bottom left corner of the wrapping listitem. Unfortunately the positioning fails in several different ways: In Firefox it seems like the dropdown's are offset with approximately -100 25 pixels the first item in the list has a different offset on the left side compared to the other items The offset in IE is not the same as in FF Doing the positioning repeatedly in explorer results in different positions each time. I've created a test page where you can see the effects: http://test.evju.biz/test/test_position.html

    Read the article

  • CSS Question - Any way to set (eg. a font-size) to a group of styles, by linking the style to anothe

    - by Joe
    .small_fonts{ font-size:10px; } .fonts_blue{ color:blue; } .fonts_red{ color:red; } .fonts_green{ color:green; } Any way to apply "small_fonts" to each of the "fonts_blue, _red, _green" w/o doing this: .fonts_blue, fonts_red, fonts_green { font-size:10px; } I am just trying to update my css to be more organized. I realised I don't need to define the font-size for each of the "small" fonts. When adding the class btw... I know you can do this: class="small_fonts fonts_blue" ~ however I'm talking about combining within the css stylesheet

    Read the article

  • How would I get an img element to render under a background-image in CSS.

    - by Nat Ryall
    Basically, I am trying to put a semi-transparent div over an image to serve as a background for text for a slideshow. Unfortunately, the browser seems intent on always rendering the img over the background-image. Is there any way to fix this? Here is my current CSS for the semi-transparent div: #slideshow .info { height: 80px; margin-top: -80px; background: url(../../images/slideshow-info-pixel.png) repeat; } ... with slideshow-info-pixel.png being a single pixel, 50% opacity, PNG 24. I have so far tried z-index and the CSS must be compatible with IE6.

    Read the article

  • How can I rotate images and text every few seconds using CSS?

    - by Infinity
    In a part of my website I would like to insert some images and a text under each image and I want that the images and texts rotate every few seconds. Is it possible to do using only CSS? I have googled but I have only found solutions using Java Script or Flash or so. It is also possible using CSS3 @keyframes. But the problem is that IE and Opera do not support it. I'm looking for a pure CSS solution which is also compatible.

    Read the article

  • Is it practical to build a web site using strict XHTML and relying on CSS 100% for visual style?

    - by Micah
    I tend to take the academic approach all too often and adhere to strict principles in my development when the reality is that I could have finished the project sooner had I been a little less cautious. I'm looking to find the right amount of practicality. I want to take the "Zen" approach to designing a site which (in my words) says "Use HTML strictly for content structure, and let the CSS magic do the rest". How practical is this in reality? One of the issues I run into is that I want to develop (make functional) the site first, then come back in and design it later. I know structure-wise how I want the site to flow, but I haven't even begun playing with the CSS layout, graphics, or any of the other designy stuff. What is the right approach here?

    Read the article

  • Letter spacing issue with 'overlapping' character

    - by Wesz-T
    I'm having some trouble with a font I found on Google Web Fonts. As you can see in the image posted below, the capital V in 'Versus' overlaps with the 'e' when i'm using Firefox. Though when i'm using Chrome (or IE) it does not overlap and leaves me with an ugly space between the two characters. Is there any way to fix this and make it look like the one in Firefox? Or should I start looking for another font? My HTML: <html> <head> <meta charset="utf-8"> <title>Versus</title> <link rel="stylesheet" type="text/css" href="css/reset.css" /> <link rel="stylesheet" type="text/css" href="css/style.css" /> <link href='http://fonts.googleapis.com/css?family=Marck+Script' rel='stylesheet' type='text/css'> </head> <body> <div> <h1>Versus</h1> </div> </body> My CSS: h1 { font-family: 'Marck Script', cursive; font-size: 100px; color:#444; text-align:center; padding:0 50px; text-shadow: 2px 2px 3px #777; } Thanks in advance!

    Read the article

  • 10 Useful CSS Tips And Tutorials

    - by Jyoti
    CSS is a technology that web designers use everyday, but yet it is something that most struggle with as well. Whether it’s keeping stylesheets for large sites manageable or creating image effects that are cross browser compatible, there are plenty of things to cause frustration. This article is an attempt to provide you with a [...]

    Read the article

  • Improving CSS With .LESS

    Improve your CSS skills using .LESS, a free, open-source port of Ruby's LESS library. LESS (and .LESS, by extension) is a parser that allows web developers to create style sheets using new and improved language features, including variables, operations, mix-ins, and nested rules.

    Read the article

  • New Bundling and Minification Support (ASP.NET 4.5 Series)

    - by ScottGu
    This is the sixth in a series of blog posts I'm doing on ASP.NET 4.5. The next release of .NET and Visual Studio include a ton of great new features and capabilities.  With ASP.NET 4.5 you'll see a bunch of really nice improvements with both Web Forms and MVC - as well as in the core ASP.NET base foundation that both are built upon. Today’s post covers some of the work we are doing to add built-in support for bundling and minification into ASP.NET - which makes it easy to improve the performance of applications.  This feature can be used by all ASP.NET applications, including both ASP.NET MVC and ASP.NET Web Forms solutions. Basics of Bundling and Minification As more and more people use mobile devices to surf the web, it is becoming increasingly important that the websites and apps we build perform well with them. We’ve all tried loading sites on our smartphones – only to eventually give up in frustration as it loads slowly over a slow cellular network.  If your site/app loads slowly like that, you are likely losing potential customers because of bad performance.  Even with powerful desktop machines, the load time of your site and perceived performance can make an enormous customer perception. Most websites today are made up of multiple JavaScript and CSS files to separate the concerns and keep the code base tight. While this is a good practice from a coding point of view, it often has some unfortunate consequences for the overall performance of the website.  Multiple JavaScript and CSS files require multiple HTTP requests from a browser – which in turn can slow down the performance load time.  Simple Example Below I’ve opened a local website in IE9 and recorded the network traffic using IE’s built-in F12 developer tools. As shown below, the website consists of 5 CSS and 4 JavaScript files which the browser has to download. Each file is currently requested separately by the browser and returned by the server, and the process can take a significant amount of time proportional to the number of files in question. Bundling ASP.NET is adding a feature that makes it easy to “bundle” or “combine” multiple CSS and JavaScript files into fewer HTTP requests. This causes the browser to request a lot fewer files and in turn reduces the time it takes to fetch them.   Below is an updated version of the above sample that takes advantage of this new bundling functionality (making only one request for the JavaScript and one request for the CSS): The browser now has to send fewer requests to the server. The content of the individual files have been bundled/combined into the same response, but the content of the files remains the same - so the overall file size is exactly the same as before the bundling.   But notice how even on a local dev machine (where the network latency between the browser and server is minimal), the act of bundling the CSS and JavaScript files together still manages to reduce the overall page load time by almost 20%.  Over a slow network the performance improvement would be even better. Minification The next release of ASP.NET is also adding a new feature that makes it easy to reduce or “minify” the download size of the content as well.  This is a process that removes whitespace, comments and other unneeded characters from both CSS and JavaScript. The result is smaller files, which will download and load in a browser faster.  The graph below shows the performance gain we are seeing when both bundling and minification are used together: Even on my local dev box (where the network latency is minimal), we now have a 40% performance improvement from where we originally started.  On slow networks (and especially with international customers), the gains would be even more significant. Using Bundling and Minification inside ASP.NET The upcoming release of ASP.NET makes it really easy to take advantage of bundling and minification within projects and see performance gains like in the scenario above. The way it does this allows you to avoid having to run custom tools as part of your build process –  instead ASP.NET has added runtime support to perform the bundling/minification for you dynamically (caching the results to make sure perf is great).  This enables a really clean development experience and makes it super easy to start to take advantage of these new features. Let’s assume that we have a simple project that has 4 JavaScript files and 6 CSS files: Bundling and Minifying the .css files Let’s say you wanted to reference all of the stylesheets in the “Styles” folder above on a page.  Today you’d have to add multiple CSS references to get all of them – which would translate into 6 separate HTTP requests: The new bundling/minification feature now allows you to instead bundle and minify all of the .css files in the Styles folder – simply by sending a URL request to the folder (in this case “styles”) with an appended “/css” path after it.  For example:    This will cause ASP.NET to scan the directory, bundle and minify the .css files within it, and send back a single HTTP response with all of the CSS content to the browser.  You don’t need to run any tools or pre-processor to get this behavior.  This enables you to cleanly separate your CSS into separate logical .css files and maintain a very clean development experience – while not taking a performance hit at runtime for doing so.  The Visual Studio designer will also honor the new bundling/minification logic as well – so you’ll still get a WYSWIYG designer experience inside VS as well. Bundling and Minifying the JavaScript files Like the CSS approach above, if we wanted to bundle and minify all of our JavaScript into a single response we could send a URL request to the folder (in this case “scripts”) with an appended “/js” path after it:   This will cause ASP.NET to scan the directory, bundle and minify the .js files within it, and send back a single HTTP response with all of the JavaScript content to the browser.  Again – no custom tools or builds steps were required in order to get this behavior.  And it works with all browsers. Ordering of Files within a Bundle By default, when files are bundled by ASP.NET they are sorted alphabetically first, just like they are shown in Solution Explorer. Then they are automatically shifted around so that known libraries and their custom extensions such as jQuery, MooTools and Dojo are loaded before anything else. So the default order for the merged bundling of the Scripts folder as shown above will be: Jquery-1.6.2.js Jquery-ui.js Jquery.tools.js a.js By default, CSS files are also sorted alphabetically and then shifted around so that reset.css and normalize.css (if they are there) will go before any other file. So the default sorting of the bundling of the Styles folder as shown above will be: reset.css content.css forms.css globals.css menu.css styles.css The sorting is fully customizable, though, and can easily be changed to accommodate most use cases and any common naming pattern you prefer.  The goal with the out of the box experience, though, is to have smart defaults that you can just use and be successful with. Any number of directories/sub-directories supported In the example above we just had a single “Scripts” and “Styles” folder for our application.  This works for some application types (e.g. single page applications).  Often, though, you’ll want to have multiple CSS/JS bundles within your application – for example: a “common” bundle that has core JS and CSS files that all pages use, and then page specific or section specific files that are not used globally. You can use the bundling/minification support across any number of directories or sub-directories in your project – this makes it easy to structure your code so as to maximize the bunding/minification benefits.  Each directory by default can be accessed as a separate URL addressable bundle.  Bundling/Minification Extensibility ASP.NET’s bundling and minification support is built with extensibility in mind and every part of the process can be extended or replaced. Custom Rules In addition to enabling the out of the box - directory-based - bundling approach, ASP.NET also supports the ability to register custom bundles using a new programmatic API we are exposing.  The below code demonstrates how you can register a “customscript” bundle using code within an application’s Global.asax class.  The API allows you to add/remove/filter files that go into the bundle on a very granular level:     The above custom bundle can then be referenced anywhere within the application using the below <script> reference:     Custom Processing You can also override the default CSS and JavaScript bundles to support your own custom processing of the bundled files (for example: custom minification rules, support for Saas, LESS or Coffeescript syntax, etc). In the example below we are indicating that we want to replace the built-in minification transforms with a custom MyJsTransform and MyCssTransform class. They both subclass the CSS and JavaScript minifier respectively and can add extra functionality:     The end result of this extensibility is that you can plug-into the bundling/minification logic at a deep level and do some pretty cool things with it. 2 Minute Video of Bundling and Minification in Action Mads Kristensen has a great 90 second video that shows off using the new Bundling and Minification feature.  You can watch the 90 second video here. Summary The new bundling and minification support within the next release of ASP.NET will make it easier to build fast web applications.  It is really easy to use, and doesn’t require major changes to your existing dev workflow.  It is also supports a rich extensibility API that enables you to customize it however you want. You can easily take advantage of this new support within ASP.NET MVC, ASP.NET Web Forms and ASP.NET Web Pages based applications. Hope this helps, Scott P.S. In addition to blogging, I use Twitter to-do quick posts and share links. My Twitter handle is: @scottgu

    Read the article

  • Guidance for a C# developer to become better UI developer

    - by Pankaj Upadhyay
    I am a C# developer and had developed simple websites in regular asp.net(with asp.net controls) and a wpf application. Nowadays, I am trying myself in Asp.net MVC3 and been exposed to the HTML with Razor view Engine. To be honest, I am not too good or I should awful at my knowledge of HTML and CSS. Therefore, I keep posting questions now and then on SO for very simple tasks. This has made me very tired of the this Q&A development process. So, now i am thinking of learning the basics of HTML, CSS and maybe some Javascript. Therefore i would request you to guide me to become an efficient enough developer for these technologies. Something that won't take much time and get me up and running fast.

    Read the article

< Previous Page | 88 89 90 91 92 93 94 95 96 97 98 99  | Next Page >