hi All,
I have a problem that i want to access the normaltagCmt elements value:
<div id="random no">
<div id="normaltagdialog">
<table style="width:100%; height:100%" border="2px">
<tr style="width:100%; height:13%" align="left">
<td>
<label> {$LANG.TEXT}</label>
</td>
</tr>
<tr style="width:100%; hei...
I have a button which sets window.location to a php file which generates a feed which is then downloaded. However, as the files vary in size due to what data is put into the feed it can sometimes take a while from the click of the button to the file dialog popping up.
What I would like to be able to do is click the button and display a ...
I have an array:
var locations = ['Afghanistan','Albania','Algeria','New York'];
and a string:
var string = 'I love Afghanistan New York Afghanistan Andorra Andorra Algeria New York';
I want to count the number of times each keyword in the array appears in the string but can't figure out the best way to do that.
...
Most of the Rails books I have touch on script.aculo.us and prototype, but because the Rails framework is so large, they don't spend a lot of time going in depth on the two packages.
I really like Agile Web Development with Rails (3rd Ed.), so I was leaning towards picking up another book from Pragmatic Bookshelf specifically on script....
Here is my HTML
<tr>
<td colspan="2" class="borderBottomCell">
<div class="benefitInfo" style="WIDTH: 99%! important;">
<asp:DropDownList runat="server" ID="ddlbc1" />
<asp:Label runat="server" ID="lblbc1" />
...
JS library like JQuery can be linked directly from other site (e.g. google). Usually I use
<script type="text/javascript" src="/js/jQuery.min.js"></script>
But I can use
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
or similar.
I like to take full control o...
I want to capture the Ctrl-R or F5 shortcut on the browser to prevent it from performing a browser refresh, but instead perform a custom refresh.
I was able to capture Ctrl-R on Safari and FF using:
document.onkeypress = function(e){
if ((e.ctrlKey || e.metaKey) && e.keyCode == 114) // Ctrl-R
e.preventDefault();
}
But that...
I have a big chunk of HTML which is a template for some data added using AJAX. I would like to store the chunk in a variable and then do replacements on tokens in it but I don't want to mess up the formatting of the html to get it into a javascript string. Is there a thing like the
<<END
command in perl which will read everything f...
I'm using a clearsilver variable as a parameter to a javascript function, from an href. Like this:
<a href="javascript:foo('<?cs var: js_escape(bar) ?>');"><span>
This works great, until the cs variable contains quotes.
Anyone have experience with this? Is there some ordering of escaping that will work for this, or do I need to find ...
Hey Folks,
I am entirely new to regex, and am trying to use it to match vales in order to map them to variables (javascript looking at the output in responceText generated from a php script).
At the moment I have this code:
if (xmlhttp.readyState==4)
{
document.getElementById("test").innerHTML=xmlhttp.responseText;
cmake = xmlh...
I am intrigued by IxEdit and its full-javascript approach that should allow to build nice web pages powered by JQuery effects.
I like also the opportunity to use it on many platforms.
But, is it worth a try ?
Is it complete ? Has it compatibility issues ? Are there better alternative tools ?
...
I would like to show thumbnails of external websites that I link to when the user mouses over the links, similar to how snap.com does this. How can I accomplish the same thing?
...
Hello,
My html of form is like this
<form id="form" method="post" action="func.php">
<table> <!--- DATA HERE --> </table>
<input type="submit" value="Submit" id="set" />
</form>
I want to use javascript to post the data, my javascript is like this
$('#set').live('click', function () {
$('.setForm').attr('action', '');
var...
Hi Everyone,
I have no idea what's going on here and was hoping someone could help, I'm sure it's something easy going on that I'm just missing.
I have a function in javascript that has a JQuery post inside of it. I would like to return the results of the post which is just text and put it in a variable. The number is coming back cor...
Ahoy everyone,
I am using this sliding top panel using mootools (for orientation, the code is basically the same).
I want it to appear when the page is loaded, means, index.html is loaded.
I achieved this simply by adding the corresponding javascript to index.html:
<script type="text/javascript">
window.addEvent('domready', functi...
Hi,
is there anyway to stop popping up the warning message in IE when trying to execute javascript?
I want some solution which does not need modifying the settings in the IE manually by the user.
Thanks,
...
I am using the following regex
/[a-zA-Z0-9]+/i.test(value)
If I enter a space in the word, it passes.
I don't see where spaces are aloud in the regex, why is it passing?
...
I have a list of songs, and I want users to be able to filter them by typing into a text field. Here's what I'm doing now:
$("#filter_song_list").keyup(function() {
var filter = new RegExp($(this).val(), "i");
$("ul.song_list a").each(function(){
if (!$(this).text().match(filter)) {
$(this).hide();
} else ...
If an exception is thrown in my web service and I wanted to give the user a more meaningful error message rather than a generic 'an error has occurred when processing your request', what are some possible techniques that can be used to pass the exception message back to the client?
is this something that is acceptably practiced?
...
I have an HTML along the following lines:
<div class="hiddenClass"> // this implies display:none
<span>
<input type="text" id="hiddenInput"/>
</span>
</div>
and a Javascript event (triggered in a "succes" method of an jQuery $.ajax() call ), that needs to make this div visible and then set the focus to the control. Something li...