html

how to find buttons with specified text inside using jquery?

I have this code structure , and i want to search for span that has text "Refund Offline" and then add the class hide_button to the parent tag " button". basically I want to hide the button that has "Refund Offline" text. <button class="scalable save submit-button" type="button" id="id_b5295d98b1d6eb3012e2dfd801ede120"> <span>Refund O...

How to render a printable image from a SWF

I'm working on a project at the moment where the client uses an off-the-shelf Flash library to display data against a map. It's a SWF that we feed some XML data and it renders it in various ways, such as a map of the UK with each county represented with a different colour depending on the data we feed it. As it's an off the shelf, we on...

Can Lucene return several search results from a single indexed file?

I am using Lucene to index and search a small number of large documents. Using the demo from the Lucene site I have indexed the documents and am able to search them. However, the search result is not particularly useful as it points to the file of the document. With very large documents this isn't particularly useful. I am wondering if ...

Is it possible to take a crawled html file, and get information about how a browser would render it?

Examples of stuff I'd like to do: - process javascript and produce new DOM - be able to provide information about DOM objects as rendered (e.g. position, size) Edit: My main concern is if a page contains a large, central flash object (typically a movie or game). ...

How to apply css property using javascript?

I have the following structure of the code, if the height of UL exceed 270px, then i want to add the css property overflow-y:scroll; or else as it is. <ul class="tabs"> <li>Content</li> <li>Content</li> <li>Content</li> </ul> ...

How to print code on html

I want to display code characters on an html page. But no matter what i try it always renders html characters. Pre or code doesnt work. How can I do this? ...

How to make when we tick on checkbox and another input will fill up automatically

Form by example. $fullname = 'John Travolta'; <input type="text" name="fullname" /> <input name="same" type="checkbox" /> Tick if same name When we tick on the checkbox the input fullname will insert automatically by data from $fullname How to do that by javascript, jquery or etc ? ...

issue opening htm files with internal link from command line

Hello all, I'm trying to open a help file from within my java application. I am able to do so using the line: Runtime.getRuntime().exec(new String[] {strPath, strUrl} ); where strPath is the path to IEXPLORE.EXE and strURL is my help file path. However, when I pass a help file with an internal link that contains a space (such as "c:....

How to adjust height of a DIV with respect to other DIV ?

I am building a website for my school project. It have various nested DIVs. However the size of DIVs are different according to content. I want to make all the DIVs of variable height so that all get the height of the longest one. You can view my page here http://www.risingfaizabad.com/demo/ Please help me. ...

I want to reduce the spacing in my asp.net webform

i want to reduce the spacing inside my web page: The problem is the buttons below "back" and "next" is not visible without scrolling down I have posted the code below: <asp:View runat="server" ID="view_1"> <asp:ScriptManager ID="scrMgr" runat="server"> </asp:ScriptManager> <h1 class="bl...

PHP filter string input, cut off all newlines, 1 chars.

I'm writing in PHP! There's a user string input, and I want to cut off all newlines,1 chars that are more than 1 in a row (avoid <br /><br />...). example: I am a SPaMmEr! would become: I am a SPaMmEr! or I am a . . . . SPaMmEr! likewise ...

Focus input field with JQuery without selecting current value text

$("#myinputfield").focus(); Doing that on an input field with it's value already set causes the current value to be selected. How can I focus the field without selecting the text? ...

How to delete a file whenever user leaves page?

I have a form with action set to a php-file (verify.php). In the form, I have made a pretty nice picture upload section. After submitting the form, the verify.php is opened to verify the form filled in by the user. The form values are all placed inside another form on the verify.php page. Only the image is uploaded to a folder on the se...

find top and last element inside a scrollable div

I have a scrollable div with a fixed height. While scrolling I need to get the element at the top of the visible viewport and the one at the bottom of the viewport. I can get the position of the scrollbar using scrollTop, however I am not sure how to get the element. Update: Formatted question for clarity. ...

Is there a way to create and render asp controls to a html string in the code-behind?

How would you create a new DropDownList (or any asp server control) and then render the html to a string in C#? ...

Templates or similar for JavaScript programs in the browser

I've done a lot of server-side HTML programming and used a number of different template languages for producing (X)HTML. This part is very clear to me. But what I'm wondering a bit about is how do people use this in client-side JavaScript programs? I mean, obviously there can be template languages written for JavaScript that work inside...

Best practice for HTML escaping user-supplied data with PHP (and ZF)

Note: I'm using Zend Framework, but I think most of this applies to PHP coding in general. I'm trying to choose a strategy for writing views scripts, possibly with the help of a templating engine. Motivations: clarity and security. I'm just not happy with writing .phtml scripts. This syntax is awfully verbose to do the most often needed...

Strange problem with border collase and border left/right.

Hi all, I have some strange problem with table in Firefox. What I want to create is to create a grid and think border. Here is the mock up (thanks inkscape). Here is my code: <style> .mytable { border-collapse: collapse; } .mytd { width : 1.3em; border : 1px solid black; padding : 0px; margin : 0px; text-al...

Regex behaving differently in IE6/IE7

My HTML is something like this : <select> <option>ABC (123)</option> <option>XYZ (789)</option> </select> What I'm trying to do is: using JQuery and a regex, I replace the "(" with <span>( here's my JQuery line: $(this).html($(this).html().replace(/\(/g,"<span>(")); It's working as intended in Firefox, chrome and safari, ...

How can I make my text stay in side of my JQuery slider

Hi, I have tried everything as far as widths and margins. The problem is I have a background image and when I use a width that makes the text stay inside the slider during scroll, it cuts off my image. That being said, I have everything set to what I want, except the text issue: here is the CSS: #wrapper { width: 550px; margin:0...