Rectangular co ordinates between two points in javascript
How to get the rectangular co ordinates between two points in javascript as an object? for example foo(10, 20, 30, 40) shold return (10, 40) and (30, 20) ...
How to get the rectangular co ordinates between two points in javascript as an object? for example foo(10, 20, 30, 40) shold return (10, 40) and (30, 20) ...
i m developing site in Joomla, meanwhile i stuck in a problem,please help me in below problem here is my folder structure for component htdocs/Joomla/administrator/component/com_test/test.php,controller.php models/test.php controllers/test.php ...
Hello, I have a peculiar problem. I am loading a JSON file that contains the src, width and height of a number of images. I am trying to load them into the smooth script jquery plugin and have the images scroll automatically. The "viewing area" div can fit three images side by side. When I first load the page, only the first image is ...
I have this markup (simplified): <ul class="targets"> <li><a href="javascript:void(0);" class="info">A</a></li> <li><a href="javascript:void(0);" class="info">B</a></li> <li><a href="javascript:void(0);" class="info">C</a></li> </ul> And this script (simplified): $('.targets').click(function(e) { alert(e.target); // a...
when i use jquery to create an element(a div, for example) in a callback function, it doesn't allow me to manipulate the newly created element outside the callback function, how can I get around this? here is the example: $.get('menu.xml',function(data){ //create a new element with an ID called "#newElement" }) //I can't select the ...
Hi all! Is it possible to load an external site's content using jQuery's Ajax rather than an iFrame? This is what I am trying to achieve, but it would seem there might be some cross domain issues with this? $('#result').load('http://www.google.com'); In flash you can put a cross-domain policy file in the root of the site allow certa...
I am using Visual studio 2008 in Windows 7. After an ajax call, I am building an image markup dynamically and setting it to a div like this. var imageLocation="<%= Url.Action("Show", "Images", new { Id = Model.LoginUser.UserId })%>"; var markup = '<img class="profile-Image" src="' + imageLocation + '"/>'; $('.divImgdisplay').html(mark...
Hey, I have this MVC form with 2 dropdownlist where selection on the first dropdown should update the second one through an AJAX call. Form looks as follows: <%using (Ajax.BeginForm("GetChildren", "Home", null, new AjaxOptions { UpdateTargetId = "result" }, new Dictionary<string, object> { { "id", "someForm" } })) { %> <%= Html.DropDo...
I want to show some events every year. E.g Like birhday, holiaday. which come every year on a specifc date Thanks ...
Hello, I cannot target an element in jQuery. First example which works : $(document).ready(function() { $('#Models').hide(); }); Second example which fails : $(document).ready(function() { $('#Make').bind('change',function() { $('#Models').hide(); }); }); In this case, the ...
Below is the content of my .aspx page and the "jquery-ui-1.7.1.custom.min.js" is in the same location as the .aspx file. When I run the website with debugging, I get the below error. I know I am terribly missing something here. Any clue? Error :- Microsoft JScript runtime error: Object expected When I run without debugging, I get the...
Hi everyone, Can anyone recommend me jQuery date picker whick is not jQuery UI. Thanks a lot. ...
Lets say I have an unordered nested list: <ul> <li>Item a1</li> <li>Item a2</li> <li>Item a3</li> <ul> <li>Item b1</li> <li>Item b2</li> <li>Item b3</li> <ul> <li>Item c1</li> <li>Item c2</li> <li>Item c3</li> ...
Hi , I am using jquery 1.3 version <div id='mainPanel'> <div> <h3>Head #1 <a href="#"><input type="text" value="Type 1"/> </a></h3> <div> <div id="panel_1"> <div class="items"> <div><input type='text' value="0"/></div> <div><input type='text' value="1"/></div> <...
I'd like to reset multiple textareas and input files by specifying them manually, how do I do with jQuery. I used this to clear forms until now: $('.clear').click(function () { $('form#input')[0].reset(); }); ...
Hi there, I'd like to be able to create a type of folding in xhtml textareas using Javascript/jQuery. For example, given the following text: ABC [123] DEF I'd like to have [123] reduce to [] when the cursor is not over it - i.e. for a cursor |: ABC [] DEF| AB|C [] DEF ABC [|123] DEF ABC [12|3] DEF I want the content within the br...
('.menu-nav li').hover( function() { $j(this).addClass("active"); $j(this).find('.ulwrapper').stop(false, true).slideDown(); $j(this).find('.ulwrapper .ulwrapper').stop(false, true).slideUp(); }, function() { $j(this).removeClass("active"); $j(this).find('div').stop...
Question regarding jQuery and User Controls I have a series of User Controls and within each user control is a client side method that validates all required fields are validated. I would like to call theses user control's client side methods from the host page when submitting a form. Does anyone have code to do this or lead me to an e...
I've just tried and more or less given up on sending an array to a jQuery post function, which are then layed out as POST variables. I've read a lot of the similar questions on here, but none seems to quite get it. I tried all I could, closes was the following function sendValue(requestArray, requestAction){ $.post("requests.php", { ...
hey guys, if a "ul" has more than one "li"-element inside of it, somehting should happen, otherwise not! what am I doing wrong? if ( $('#menu ul').length > 1 ) { regards matt ...