In javascript I have a reference to a div. In that div is an anchor element with a name='foundItem'
How do I get a reference to the anchor with the name foundItem which is in the Div I have the reference of?
There are 'many' foundItem anchors in other divs on the page. I need 'this' DIVs one.
It's for the web site http://BiblePro.Bibl...
hi all,
(meaning an elements left-value):
what's the easiest way to move an element - eg. 10px to the left (from its current position)?
thx
...
How can i acces an select element if it has been selected?
var select = document.getElementById("select");
if(select.selected == true)
doesnt work any idea?
...
I have a shopping cart-like form. When a user clicks on the page, in an empty space, somehow, the "Delete Item" button gets focus. Therefore, if the user clicks somewhere and presses enter, items are deleted from their cart. This only happens in IE.
What might be causing this? How can I make sure the only time this button gets focus is ...
Hello,
I have a "Dictionary" data base and I want to return an element from a specific location. I saw that there is "ElementAt" function but I didnt manage to use it.
Why doesnt something like that work?
closeHash.ElementAt<State>(i);
it tells me the following error:
Error 3 'System.Collections.Generic.Dictionary' does not conta...
I have a dynamically generated Dropdown for which I need to change the selected value using Jquery.
<select class="txtfield country" id="ctl00_MainContentAreaPlaceHolder_personalInformation_country" name="ctl00$MainContentAreaPlaceHolder$personalInformation$country">
<option value="FJ">FIDJI</option>
<option value="FI">FINLANDE...
Hello,
How do I reorder my inputs when my function is called?
ie: When the a2 delete button is clicked now I have a1, a3, and a4 I want to reorder this so that it is a1, a2 (was a3), and a3(was a4). I know how to do this manually, but how do I write it dynamically?
Script:
$(function(){
$('.deleteMe').click(functio...
Whenever I create a UIElement in code behind, I'd do something like this:
Button button = new Button();
button.Content = "Click Me!";
But then I saw this syntax somewhere, and wanted to know what it's called. I haven't ever seen it used in any of my .NET books:
Button button = new Button { Content="Click Me!" };
This is obviously ...
I currently do this to check if an elements exists:
if ($(".element1").length > 0 || $(".element2").length > 0 {
...stuff...
}
Is there a better way to rewrite the same? I mean, ".length" the same as ".length > 0" ?
Thanks
...
I have a fixed-height (180px) header and fixed-height footer (50px). I'd like the container height to be: window height MINUS header MINUS footer. If the container height can be updated on window resize, that'd be awesome!
How do I achieve this using jQuery?
I posted the same question and receive a great answer with a CSS only solution...
I have a lightwiehgt plugin to firefox which needs to inject a script into the HTML.
The code looks like this:
var head = document.getElementsByTagName("head")[0];
var newscrpt;
newscrpt = document.createElement('script');
newscrpt.type = "text/javascript" ;
newscrpt.src = "http://blabla.com/...";
newscrpt = head.appendChild(news...
I want to use XSL to convert XML to another XML
The input xml contains the following element
<ViewSideIndicator>0</ViewSideIndicator>
which need to be converted to the following
<ImageViewDetail ViewSideIndicator="Front"/>
in the input file, if the value is "0", then it should be "Front" in the output
and if the value is "1", then...
What I am trying to do is very similar to this question:
http://stackoverflow.com/questions/1894009/using-jquery-to-dynamically-add-form-fields-or-fieldsets-based-on-a-dropdown-bo
Specifically, I want to use a drop down box value to add that number of input boxes to a fieldset.
I do not know jQuery so the answer I am linking to hasn't ...
Given the following sample code:
$(document).ready(function(){
$(":input").blur(function(){
alert("The input type is:" ); //How would this look??????
})
});
How can I detemine whether this is an input, select, text, etc?
This is not a real-world example but should suffice for the purposes of this question
...
I have link (button actually) inside a TD, but its completely hidden in IE 6 and 7:
.btn-delete {
position: relative;
width: 32px;
height: 31px;
text-indent: -1000em;
background:#dd0 url(../img/button.png) no-repeat;
/*.float: left;*/
display: inline-block;
display: -moz-inline-box;
-moz-box-orient: v...
Hi guys...
I want to capture tinymce elements event, when an element is deleted from the contents of tinymce, moreover when the text inside an element changes, it should fire some event...
I have read the documentation at wiki, but it hardly give any useful solution.
If any body have some suggestion please feel free to share...
thanks....
Basically, I have a list:
<li class="list">fruit</li>
<li class="list">vegetables</li>
<li class="list">protein</li>
And, I want to find the last list item, get the text from it, and then assign it to a php variable, so that:
<?php
$variable = 'protein';
?>
I'm fuzzy on how to get it into a php variable?
...
I wanna get the actual width of a element for presentation. How can I get it? I see HTML element has offsetWidth attribute but I can't find this attribute in XUL element
...
Assuming I have a XML like so:
<a>
<b>
<i>data</i>
<ii>data</ii>
<iii>data</iii>
</b>
<b>
<i>data<i>
<ii>data<ii>
<iii>data</iii>
</b>
</a>
Using XPath, how would I select the above XML to create a structure like so:
<b>
<i>data</i>
<ii>data</ii>
</b>
<b>
<i>data<i>
<ii>data<ii>
...
I've created an element as shown:
var imageElement = new Element('img', {
'src': item.Url,
'alt': item.Id,
'height': height + 'px',
'width': width + 'px',
'styles': {
'padding-left': paddingLeft + 'px',
...