Search Results

Search found 1146 results on 46 pages for 'divs'.

Page 33/46 | < Previous Page | 29 30 31 32 33 34 35 36 37 38 39 40  | Next Page >

  • Custom GMapTypeControl buttons (Google Maps V2 API)

    - by AndiDog
    A similar question was already asked, but does not have a satisfying answer. I want to change the CSS style for the map type selection buttons (which are actually DIVs that don't have a CSS class). The links in the referenced question show how to subclass controls, but the examples don't seem to work for GMapTypeControl. Tried the following function CustomGMapTypeControl() {} CustomGMapTypeControl.prototype = new GMapTypeControl() CustomGMapTypeControl.prototype.setButtonStyle_ = function(button) { button.style.backgroundColor = "red"; } but the setButtonStyle_ function doesn't even get called. Any solutions for this?

    Read the article

  • scrollTop with jQuery

    - by Narcís
    I want a foot to be at the bottom of the page. But when the user makes the window smaller, the two divs come together, it would be better that begins the scroll and hides the foot. I don't know if I explain? I have the code life here: http://jsfiddle.net/mdAsn/ $(function(){ $(document).scroll(function(){ var topDistance = $('#foot').scrollTop(); if(topDistance >= 420){ $('#foot').css({position: 'absolute',bottom:'10px'}); } else{ $('#foot').css({position: 'absolute',top:'410px'}); } }); })

    Read the article

  • focusout not triggering when clicking on another selector with a click

    - by Sean
    I have 2 divs that each have clicks bound to them. when you click on a div a form is displayed (in another div) that allows you to set properties specific to the div that is clicked. I'm using focusout to save the properties to a data object. everything is working perfectly except when i click on the other div. it seems that the click handler on the other div cancels out the focusout of the form field. Has anyone else experienced this? is so what is the proper way to overcome this?

    Read the article

  • How to get number of elements of a class before a certain element

    - by David Shaikh
    I want to know how many elements of a certain class appear in the DOM before an element that let's say has been clicked on. <html> <div class="a"> </div> <div class="b"> <div class="a"> </div> </div> <button>CLick me!</button> <div class="a"> </div> </html> So in the previous DOM tree if the element to be clicked is the button, and Im looking for divs with class "a" it should return 2, even though in the whole tree there are 3, but "before" the button there are only 2. How could I do that? Thanks

    Read the article

  • how to remove all text nodes and only preserve structure information of a html page with nokogiri

    - by user58948
    I want to remove all text from html page that I load with nokogiri. For example, if a page has the following: <body><script>var x = 10;</script><div>Hello</div><div><h1>Hi</h1></div></body> I want to process it with Nokogiri and return html like the following after stripping the text like so: <body><script>var x = 10;</script><div></div><div><h1></h1></div></body> (THat is, remove the actual h1 text, text between divs, text in p elements etc, but keep the tags. also, dont remove text in the script tags.) How can I do that?

    Read the article

  • Hovering Div Shows a Hidden Div - Prototype

    - by phil
    I have three divs set up in the following way: <div class="outer-div"> <div class="inner1"></div> <div class="inner2" style="display:none;"></div> </div> I have the second inner div hidden via the inline style. What I am trying to accomplish is that when the outer div, or basically any of the content is hovered over then the inner2 would appear. I am unfamilar with Prototype and having a terrible time trying to get my head around it. Missing jQuery but this time around Prototype is totally required. Thanks in advance for any help!!

    Read the article

  • How to display query results in an HTML page

    - by user272899
    When showing data from a mysql table on an php page does it have to be in a table?? What I want to do is display my results in divs. like so: <div class="moviebox rounded"><a href=""> <img src=" $imgurl " /> <form method="get" action=""> <input type="text" name="link" class="link" style="display:none" value="http://us.imdb.com/Title? $imdburl "/> </form> </a></div> And have that repeat for each one of the images in the database. How is this done?? I am fine showing the data in a table but can't seem to get this right

    Read the article

  • jQuery: Toggling an image when toggling a DIV

    - by Wanda
    Hey guys, I'm trying to write some jQuery that will toggle DIVs open and closed, and it's working, but I want an arrow that will change to "down" if the DIV is expanded, and "right" if the DIV is collapsed. What I have so far: $('.toggleHead').click(function() { $('#arrow').attr('src', 'images/icons/down.png'); $(this).next().toggle(); return false; }).next().hide(); Where would I put the other $('#arrow').attr('src', 'images/icons/right.png');? Thanks!

    Read the article

  • jQuery resize event for div children

    - by Frank Michael Kraft
    $("div.content-left > *, div.content-main > *" ).live('resize',function(){alert("Size changed")}); does not work, because the resize event only applies to window resizes. But in my case the divs change size late, because the content is loaded late by an ajax request - or by clicking a panel menu. I definatley need to avoid to register on all individual events of the children (ajax, click), because that can be very many different events and then it is not maintainable.

    Read the article

  • how to not use relative links in html, but everytime starting from the domain.

    - by Andy
    Hi, I'm trying to make a page for use with wordpress and it's almost working, The page I want to use is an HTML page with designated space for it within certain DIVs. I'm encountering the problem of wordpress using the wrong links to kind of everything. I will probably have to change every link to http://www.mydomain.com/sub/folder/image.jpg while there are many links. the page is positioned in a subfolder, there where wordpress is installed on the server. But other pages are positioned in the root, and retrieve all other files directly starting from the domain so writing /sub/folder/image.jpg is enough. Is there a way I could get this to work with html/php files in sub folders as well (so when typing a link like /sub/folder/image.jpg they retrieve http://www.mydomain.com/sub/folder/image.jpg and not http://www.mydomain.com/sub/folder/sub/folder/image.jpg thanks!

    Read the article

  • JQuery if/else statement matching a wildcard css name

    - by Neokoenig
    Hi All, I'm trying to write an if/else statement in jQuery which can change an elements class by matching 'IN' or 'OUT' (in this case). I.e, I have several Divs with class='IN-something' OR class='OUT-something'. The below would work if I new the exact CSS class, but all I'll know is whether it contains 'IN' or 'OUT'. So like this, but works: if ($(jRow).hasClass('IN-*')) {jRow.attr( "class", "OUT-foo" );} else {jRow.attr( "class", "IN-foo");} Ideas? Thanks!

    Read the article

  • Why is my background image not displaying properly in IE7?

    - by JAG2007
    Screenshot of the issue: here Webpage in Question: http://cure.org Offending browser: Internet Explorer 7 You'll notice from the screenshot, or if you view this site in IE7, that the background image is not displaying for the content div (#modal-inner-content). Strangely, the image displays in the other divs where it is used (since it's a sprite, I'm using that same image for #modal-top-border and #modal-btm-border). In all other browsers it displays properly, and even in IE8. I cannot seem to find what CSS rule (or lack thereof) I may be using that IE7 is choking on. NOTE: in order to get the modal screen, just click the link at the very top banner of the page that says "login to your CURE account

    Read the article

  • auto resize text (font size) when resizing window?

    - by Stephen
    Hi, I have been trying(in vain) to build a page whose elements would resize as I changed the window size. I have it working in css for images no problem, but I can't seem to accomplish the same for text, and I am not sure it is even possible in CSS. And I can't seem to find a jquery script that accomplishes this. When a user resizes the window, I essentially want the page to scale dynamically and fluidly, without the user having to invoke page zoom. This works fine on my img divs via css, but not for the text, which stays the same size. any ideas? Thanks!

    Read the article

  • dojo dynamic right click context menu

    - by levy
    There are tons of different dojo right click context menus in a page slowing down the browser. Some divs have context menus while some others don't. So I just can't have a dynamic global context menu and still be able to fallback to the browser's built in menu in some cases, do I? The non lazy instantiation of the dojo context menus just take too much time. How can I make those context menus dynamic? Preferably being created on demand when the user actually right clicks on them.

    Read the article

  • JQuery: loop through elements with more than one css class name that share only the first class name

    - by omaether
    Hello, I'm trying to use JQuery to loop through several div's with more than one class name, that all have the same first css class name and each one has a different second class name, e.g. <div class="maintext blue"> </div> <div class="maintext purple"> </div> <div class="maintext chartreuse"> </div> <div class="maintext puce"> </div> <div class="maintext lime"> </div> In JQuery I have tried $(".mainText").each(function (i) $(".mainText.*").each(function (i) $(".mainText" *).each(function (i) $(".mainText .*").each(function (i) But it will not select any of the divs with class="mainText ..." thanks for considering the question.

    Read the article

  • jQuery selector depending on children

    - by wiradikusuma
    Hi guys, I have an HTML form consisting of some text-inputs. I'm using jqTransform to prettify them. Now I want to add two buttons that will add and remove text-input dynamically. Adding is easy: $('#container').append(''); $('input[name=foo]:last-child').jqTransInputText(); But removing is tricky: $('WHAT-TO-SELECT').remove(); I can't do "input[name=foo]:last-child" since it's already wrapped (some divs) by jqTransform. To put this question in another way: How do I select based on "who has child of type input with 'foo' as its name"?

    Read the article

  • move text from one div to another with javascript or mootools

    - by Ke
    Hi, I have two divs. I would like to move/populate the text from div id one to div id two using an onclick event. I am wondering how to do this? and also whether mootools can be used to accomplish the task or whether simple javascript is only necessary? <div id='one'> <ul> <input type="checkbox" onclick = "my_function()"/> <li>some text 1</li> <input type="checkbox" onclick = "my_function()"/> <li>some text 2</li> </ul> <div> <div id='two'> <div> Cheers in advance for any helps. Bangin my head against a brick wall here, because my javascript skillz are limited! Ke

    Read the article

  • Clarification For Dynamic Height Boxes for CSS

    - by HollerTrain
    I am having the hardest time trying to figure out this (should be) simple css: Website is here: http://mibsoftware.us/fct/index.php I'm simply trying to get my #leftcolumn and #maincolumn to be inside the #content_container, yet whatever I'm doing isn't working at all. I'd like for the #content_container to be a dynamic height since the height of #leftcolumn and #maincolumn change depending on the page you are on. From the framework of my css it should work fine, so I must be missing something in my .css file declaring these divs. Any help would be greatly appreciated, as this will be a great learning experience for me.

    Read the article

  • HTML5 drag & drop: The dragged element content is missing in Webkit browsers.

    - by Cibernox
    I'm trying to implement something similar to a cart where you can drop items from a list. This items (<li> elements) has some elements inside (divs, span, and that stuff). The drag and drop itself works great. But the dragged element's image doesn't show its content in Webkit browsers. My list element has a border an a background color. In Firefox, the image is the whole item. In Webkit browsers, only the dragged element without content. I see the background and border, but without text inside. I tried to make a copy of the element and force it to be the image, but doesn't work. var dt = ev.originalEvent.dataTransfer; dt.setDragImage( $(ev.target).clone()[0], 0, 0); I have a simplified example that exhibit the same behavior: http://jsfiddle.net/ksnJf/1/

    Read the article

  • Methods for breaking up content client-side into multiple "pages"

    - by Tom Genoni
    I have a long HTML text-only article formatted with paragraph tags. What I'd like to do is break this content into N number of divs so that I can create individual pages. So, for instance, on an iPad/iPhone, instead of reading one long page the user could swipe right/left to navigate to pages. My initial javascript attempts have been somewhat convoluted: creating an array of the text, measuring line-heights, device window heights, adding closing/opening paragraph tags and the end/beginning of pages. Thoughts on a good way to approach this? I will not have access to server-side processing, this has to be a client-side solution.

    Read the article

  • JQuery Tabs - HTML not displayed in any other tab except default tab

    - by user346347
    I'm pretty new to jquery, but I have a tab structure working and make a $.getJSON call to retrieve the JSON results from the backend. Now, I have 3 tabs: Tab1, Tab2 and Tab3. All the three tabs have the same divs but different content. The content shows up just fine in the first tab which is shown by default, but on clicking the 2nd tab, I make the same $.getJSON call and retrieve the JSON just fine, the same HTML is being constructed on the fly and set in the DIV within the tab but it is not being displayed... Any pointers??

    Read the article

  • finding the value of radio button with jquery

    - by oo
    i have this code below to show different divs when i choose certain radio buttons: if ($("input[@name='exerciseRB']:checked").val() == 'New') { $("#newExercise").show(); $("#existingExercise").hide(); } else { $("#newExercise").hide(); $("#existingExercise").show(); } at first, i just had two radio buttons (both named exerciseRB and everything works fine. Now, later in my web page i added two new radio buttons (with the name lessonRB). The issue is that once i added these other new radio buttons when i look up this in firebug: $("input[@name='exerciseRB']:checked") i actually get an array back with both the exerciseRB item as well as the lessonRB item. Its almost as if the @name='exerciseRB' is being ignored. any ideas here?

    Read the article

  • Show elements depending on html value of a tag

    - by mike23
    I would like to accomplish the following with jquery : When I click on this link <a href="#">Cars</a> I would like all divs like those <div class="product"> <div class="category">Cars</div> </div> to do something. You get the idea, I have a menu with a list of categories, and a list of products, each containing a div with the category name, and I would like to make them hide/show.

    Read the article

  • CSS float problems, works in IE, doesn't work in Chrome/FF.. I'm probably doing something wrong

    - by user1003916
    I'm not terribly well-versed in CSS.. and don't know all of the major quirks yet. Maybe someone can help me. I've set up an image showing my code, a diagram of my DIVs, and examples of how it looks in IE versus Chrome/FF Can someone direct me to the proper way to go about this? It works fine in IE, but in Chrome and FF, one of the images is escaping its container, and the "content block" as I call it is going underneath the image it's supposed to be next to. Each of the components has a css class despite my diagram saying there's no css.. currently there's just some basic styling for those (padding, text-indent, etc). Thank you

    Read the article

  • how to dynamically (re)position an element according to the bottom of the page using JS / Jquery?

    - by jon
    Hi All, the back story: i have a tab section on a page which when navigated through displays sections (divs) of varying height. the result, is that certain inputs (which are strangely positioned for reasons i can't change) on this page reposition themselves problematically. the proposed solution: as the page height changes, have these problem inputs repositioned according to the page bottom (from which their appropriate distances are always a constant). what i'm thinking is that i need some js that does something like, page height change triggers input position from bottom to = x. there are two inputs if that's at all relevant. :) if only there was css for this (i know there is under normal circumstances, but trust me -- not in this case). thanks for your time & help i've been struggling with this for weeks!

    Read the article

< Previous Page | 29 30 31 32 33 34 35 36 37 38 39 40  | Next Page >