html

Why does my CSS tooltip push my other content down?

I have a CSS tooltip, with CSS3 fade in, with z-indexes set to 999. When I hover over the link, the tooltip itself pushes my other content down, it's meant to be above, not inline, although I've used a span and converted it to block.. Here is an example of what I'm going for, how can I stop it from pushing the content down? Thanks. ...

generate/get the Xpath for a selected textnode.

Is it possible to get/generate the XPath, for a text selected in the HTML page. Say,I have opened an html file using a browser,say safari/firefox, now i select some text (using mouse), i want to generate/get the xpath for that. is it possible to get it programatically? how? ...

Ajust table column width to content size

Form (with firebug highlight hover the td): Label column CSS: width: auto; padding: 0; margin: 0; The problem: Why my left columns have that invisible "padding-right"? It's not possible to shrink columns to fit their content? --EDIT-- The problem was the table itself. I defined table with "width: 100%". Removed that and the prob...

letters or numbers only in a password with jquery

Hi, I found this code for alphanumeric check ("Letters, numbers, spaces or underscores") but I want to change so I will be able to write only letters or numbers. Can anyone tell me how to change this code: function(value, element) { return this.optional(element) || /^\w+$/i.test(value);} Thanks! Greg ...

Is it possible to track if some one printed a web page?

I think that's not possible, but I want to make sure. ...

Loading HTML into <div> with jQuery-ajax

Hello everyone, I ran into a bit of trouble while trying to load an external HTML page into a div using jQuery-ajax. I had this div: <div id="content"></div> and wanted to fill it with $("#content").load("include/add.html"); It loads the HTML file perfectly, but inside that add.html is a button that should load add2.html(also using .load...

Controller with unknown number of parameters?

Greetings! I'm doing a Form on ASP.NET MVC 2, in my view I have a TextBox for the name, and two buttons. One of the buttons is for submit, and the other one have a function in JS, that add's another textbox, and a drop down list. In the post controller action method, how do I get all the parameters? Here is the View Code: <body> <...

jquery hide form when selecting login submit button, not just any button

I have a form, if submitted correctly, it hides the form. I added a cancel button, to close the pop-up thickbox window, but when I hit cancel, it hides the form. How do I go about hiding the form if the login button is selected? $(document).ready(function() { $("#login_form").submit(function() { var unameval = $("#username...

how to embed WMV files in my html file

Hi, i have made some demo movies in WMV format that i want to embed in my html page. I've found some code to do that, but one thing annoys me: it shows a black front in stead of a picture of the first frame. And i can ofcourse put some descriptive text around the frames/movies, but it isn;t such a nice sight: all black squares with a pl...

Modify QueryString on PostBack to include an anchor bookmark without breaking subsequent events and without using the PostBackUrl property

Consider the following pseudo-code: // sorts the dataset used by the table void ClickEvent() { } foreach (column in table) { // create new LinkButton var lb = new LinkButton(); // hook sort event lb.Click += ClickEvent; // add LinkButton to table table.Controls.add(lb); } How can I modify the QueryString to...

Can I set text box to readonly when using Html.TextBoxFor?

I have the following tag with a Html.TextBoxFor expression and I want the contents to be read only, is this possible? <%= Html.TextBoxFor(m => Model.Events.Subscribed[i].Action)%> ...

How to change the strike-out / line-through thickness in CSS?

Hi, I'm using the "text-decoration:line-through" in CSS, but I can't seem to find any way to vary the line thickness without inelegant hacks like hr or image overlays. Is there any elegant way to specify the thickness of a line-through? Thanks! ...

Getting the ID of an object when the object is given

I have link that calls a function when clicked: <a href="javascript:spawnMenu(this);" id="link1">Test1</a> To make my function work, I need access to the object so that I can perform jQuery operations like this: alert($(objCaller).offset().left); Since objCaller points to the object and not the object ID, this won't work. I need so...

HTML - Put SELECT tag content into INPUT type = "text"

Hi, I have a form in a webpage where I would like to put the selected item in a drop down list into a testbox. The code I have till now is the following: <form action = ""> <select name = "Cities"> <option value="----">--Select--</option> <option value="roma">Roma</option>...

How should i change the root for mod_rewrite url when i work in localhost

I am working on a site maintainence. It uses mod_rewrite technique. But im new to mod_rewrite. How should i change the url to work correctly in my localhost. here's the code: # Enable mod_rewrite, start rewrite engine Options +FollowSymLinks RewriteEngine on rewritecond %{http_host} ^electricians4u.com.au [nc] rewriterule ^(.*)$ htt...

Iframe no scrollbar?

I cant seem to show the scrollbar in my iframe. I am making a script that will rotate a page 180 degrees and it uses iframes. With this code it showed no scrollbar. <iframe frameborder="0" id="browser" src="http://google.com/"&gt;&lt;/iframe&gt; It loads dynamically(although this is after a button is pressed) but this doesnt change an...

refresh parent window after closing thickbox window

I am using Thickbox 3.1 for a login form, using the iframe version. I want to close the iframe (child) window, then refresh the parent window. This closes the iframe window, but I need to somehow set it to refresh the parent window <a href="#" onclick="self.parent.tb_remove();">Close</a> Any help is appreciated. ...

document.getElementByID - checking whether an element has been found or not

Hi, guys. Here's a sample code, that opens an internet explorer window, navigates to google, and gets some element on the page by its unique id: set ie = CreateObject("InternetExplorer.Application") ie.navigate("www.google.com") ie.visible = true while ie.readystate <> 4 wscript.sleep 100 WEnd set some_object = ie.document.gete...

How do I get a useful value for height and width of a div element using javascript?

I need to be able to store the current height and width of a div at any point in time. Currently I am using div.style.height/width which works fine when the styling is applied inline. The problem is that this returns for example 600px and not 600. Is there a better way to do this? If not, whats the best way to get just the number 60...

How do you manipulate form values based off local input?

I have a form that has a series of check boxes and some line items have a text input next to them that defines quantity of the item. <input type="checkbox" name="measure[][input]" value="<?=$item->id?>"> <input class="item_mult" type="text" name="measure[][input]" /> What is the best way to capture the integer from the input field a...