I have one array of strings. I need to find all strings starting with a key.
for eg: if there is an array ['apple','ape','open','soap']
when searched with a key 'ap'
i should get 'apple' and 'ape' only and not 'soap'.
This is in javascript.
...
I am a newbie.I have doubt, regarding which js library i should select for my new project, which is a small website with rich user interface.Jquery and prorotype are the two options in my mind.
Will i go with jquery or prototype.
...
Is there any way in javascript to check if web page has been vertically scrolled?
specially for Internet Explorer? I need to get the mouse position in IE but using
jQuery event e.pageY it gives correct value when page is not scrolled but when page is scrolled down then it gives wrong position.
...
Hi,
thanks for looking.
I'm having an issue i cant seem to get the submit function workin.
load login form if needed.
login_box_comment = function(){
$("body").append('<div id="login_form_modal" style="display:none">'+
'<div id="status" align="left">'+
'<center><h1><img src="/ext/login/img/key.png" align="absmiddle"> LOGIN</h1>...
I'm trying to use the jQuery cycle plugin to cycle round different quotes. I would like to have the quotes displayed for different amount of time depending on the length of the quote. To achieve this I get the content mangagement system to output the amount of seconds as a class name such as dur13 would be for 13 seconds.
This is my non...
Hello
I am using following javacript code
$("a.adminlink").click(function(){
$("#bigpopup").fadeIn();
//$("a.activetablink").removeClass("activetablink");
//$("a.tablink[href=" + $(this).attr("href") + "]").addClass("activetablink");
$.get($(this).attr("href"),{},function(response){
$("#tabmenu").html(response.menu);
...
I've three strings.
var ids = "1*2*3";
var Name ="John*Brain*Andy";
var Code ="A12*B32*C38";
I want to create a JavaScript object of it.
...
i am trying to experiment with the tumblr api. i tried
$(function() {
$.getJSON("http://jiewmeng.tumblr.com/api/read/json", function(data) {
$("#postsContainer").append(data);
});
});
but got a 200 OK with empty response in firebug. when i navigate to http://jiewmeng.tumblr.com/api/read/json, i see the data. so i shld be g...
I am using Zend Framework, and to illustrate what is working I added the saveAction() to this post and it works flawlessly. It will animate and change the class as I want. The function upload instead only change the text and ignore the javascript. I can do alerts that works, however jquery is not possible. I get error saying that $ is un...
My question is related to this question. You will have to first read it.
var ids = "1*2*3";
var Name ="John*Brain*Andy";
var Code ="A12*B22*B22";
Now that I have an array of javascript objects. I want to group my objects based on CODE. So there can be duplicate codes in that code string.
As per the above changed strings, I have same ...
Working in Firebug Console, but not from file.
Google Chrome - Uncaught TypeError: Object # has no method 'listAttributes'
Firefox - $(".div4").listAttributes is not a function
<script src='/jquery.js'></script>
<script src='jquery.listAttributes.js'></script>
<div class='div4' style='color:red;'>
</div>
<script>
$(".div4").listAttr...
Does anyone know how I can take a mysql datetime stamp, such as YYYY-MM-DD HH:MM:SS and either parse it or convert it to work in JavaScript's Date() function, such as.. Date('YYYY, MM, DD, HH, MM, SS);
Thank you!
...
I am adding <script type="text/javascript" src="http://somedomain/somescript.js"> to the document head via jQuery. This is the code I use:
$(document).ready(function () {
var s = document.createElement("script");
s.type = "text/javascript";
s.src = (document.location.protocol == "https:" ? "https://ssl" : "http://www") + ...
Hello,
I have dynamic page which takes about 8 seconds to load searched data.
Problem is, all browsers remain on old page for those 8 secs & show dynamic page only after it
loads completely.
What I want is preloder image to be shown to the customers until second page gets load.
How can I achieve this?
Thanks
...
I would like to do this:
Drag a DIV element from a first document that contains an IFRAME
Drop this DIV element into into a second document, inside the IFRAME.
Is there a way to use jQuery UI draggable & droppable to achieve this? or otherwise do this in a cross-browser way, possibly with another JS library?
...
I am trying to write a little snippet that allows a user to go to i.e. navigate to) a new url, based on a user selection in an option select control.
<script type="text/javascript">
/* <[CDATA[ */
jQuery.noConflict();
jQuery(document).ready(function(){
var id = jQuery($this).val();
var url = some_Lookup_func(id);
jQuery("#th...
Hello,
I have a simple carousel to display some images. As you would expect the carousel auto rotates every x seconds.
I currently have a div which I animate the width over the x seconds to show progress. This allows users to see how long they have to wait until the next image is displayed. When a user hovers over the image, the progr...
I need to build a news scroller module for a website in Joomla (http://www.expedicionantioquia.org/idures/index.php) to replace the one made with flash on the right column. I was thinking on doing it with JQuery to allow the tabbed navigation, but i'm a little bit lost, partly because i haven't found a good tutorial about building joomla...
I have a quick question regarding the proper way to access Javascript class member variables from inside of an event handler that class uses. For example:
function Map() {
this.x = 0;
this.y = 0;
$("body").mousemove( function(event) {
this.x = event.pageX; // Is not able to access Map's member variable "x"
...
currently, i am using the following to close a dialog
<button onClick="Boxy.get(this).hideAndUnload(); return false;">Cancel</button>
but i want to do something like
<button class="btnCancel">Cancel</button>
to close the dialog
i tried to use jquery delegate() to close the dialog but it does not work. fyi, i am loading the whole f...