Getting The X/Y Position Of A Mark?
Dec 5, 2009
suppose that a web page has a mark "M". For example,when a user open the web page If the mark "M" is printed in the position of height 300px from the top of the browser and width 500px from the left of the browser, I like to get the height value 300px and width value 500px. Let's call them X position and Y position.Can I get the X position and Y position of the mark "M" in javascript just after the mark "M" is printed.
View 22 Replies
ADVERTISEMENT
Nov 23, 2011
i,m trying to make a map who show me as position A and a target adress as point B.I have made it so i can choose adress a and adress b from a dropdown but i want to automaticly load my position as possition A then choose position B from a dropdownlist. How can i do this ?
[Code]....
View 2 Replies
View Related
Jul 23, 2005
I've started testing on Win XP SP2 and it now has something called local machine lockdown activated by default. It means that active content,
such as JavaScript, is prevented from running.
I thought that the solution was simply - to enable the testing of files locally - to just add what M$ calls the "mark of the web". So I added
this line to the tops of my HTML pages:
<!-- saved from url=(0013)about:internet -->
However, the local links in the files, such as to external JavaScript files, do not work because (I believe) the HTML files are now treated as an internet zone and not a local zone file.
Without deactivating the lockdown is there a way to get a bunch of inter-linked files to work locally, or is it just my lack of understanding of what's going on that's at fault?
View 16 Replies
View Related
Nov 7, 2003
I'm listing a query as HTML from a database. I'd like to enable a checkbox at runtime.
That is... When I find a field=1 I want to have it selected. If 0 deselected. Is it possible right with HTML or do I need Javascript? In both cases, how can I do this?
View 3 Replies
View Related
May 3, 2006
which of the following two codes is correct and where is the correct notation standardized:
a) alert("Hello World");
b) alert('Hello World');
View 4 Replies
View Related
Apr 14, 2011
how do I write a quotation mark (") in javascript?
View 2 Replies
View Related
Jul 23, 2005
I'm working on a JSP application, and wish to define a text-field so
that it becomes marked (highligted) when it obtains focus.
I've tried giving the text-field a value when it obtains focus, but
the value is not marked. So if i wish to alter the value, I have to
manually delete the given 'onFocus' value before I set a new value.
<INPUT TYPE=TEXT NAME=test size=30 want this
to be highlighted!'">
I'm missing something to highlight the text-field text in the code
above.
View 1 Replies
View Related
May 15, 2009
I am looking for a plugin for jQuery to mark areas on image and select a friend like you can do it in some social networks to mark your friends on fotos!
View 1 Replies
View Related
Aug 26, 2010
Looking to return true if a question mark (?) exists in a given string.I was thinking of something like the following, but it obviously doesn't work.
alert('/?'.test('my?string'));
View 1 Replies
View Related
Feb 1, 2011
We all know AC_OETags.js.URL like: [URL]How to make flash detection in variable with valu true or false if it is (not) detected to use in PHP applications?
View 5 Replies
View Related
Jul 24, 2010
I have done how to find out co ordinate(x and y axis) of a point on an image where a user clicks. But I need the opposite thing now. I need to mark a point on an image when a user gives suitable x axis and y axis co ordinate as input, how can i do this with java script?
View 2 Replies
View Related
Apr 20, 2010
I am basically trying to enter a name along with a mark and store this in a javascript cookie. From this I want to create the mean and graph for up to 100 results.This is the code:
<html>
<head>
<title>Class Marks Calculator</title>[code]....
I have been working on this for hours and do not understand where I am going wrong.
View 5 Replies
View Related
May 13, 2010
I'm new to javascript and am not sure why this works in firefox and not chrome. I am trying to create a script that keeps an object fixed horizontally while bing positioned absolute vertically. if I replace the toPP variable in document.getElementById('fire').style.top = toPP; with say '50px' it will move the element down 50 pxs, but how I have it currently it doesn't do anything in chrome
<script type="text/javascript" >
window.onscroll = function()
{
if( window.XMLHttpRequest ) {
var x = 0 -document.documentElement.scrollTop;
var toP = String(x);
var toPP = toP + "px";
[Code]...
View 7 Replies
View Related
Jun 26, 2010
disable select until user puts mark in check box. Then enable select.I have two select box's on a page. The first asks what product, the second is based on the first and presents a list of pdf's according to which product the user selected. (yes, multi dimensional)What I have works fine, but now i need to make the user put a check mark in a check box before the First SELECT box becomes enabled/available.So basically, when they agree, they can get the download.Here are my select boxes.
HTML Code:
<form>
<select name="category" style="width:180px"></select>
<select name="site" style="width:180px" onchange="openLink(this.value)"></select>[code]....
(ignore the The 'open' button. It's there in case the default option is what the user wants, so they don't have reselect via the select box.)
1. How do I disable the select boxes by default on page load?
2. How do I detect that the user has put a tick in and the enable the disabled Select box?
View 6 Replies
View Related
Dec 2, 2010
I've a in a simple webpage. When this checkbox is enabled or checked orclicked I need to add some dinamically DOM content. I been playing with this code:
$("#int_code").click(function(){
$(this).after("tetete")
});
It's very simple and works but not like I want. Every time I click the checkbox or mark I get the text "tetete" after #int_code element. This is fine but I want when the checkbox is checked the content is added if is unchecked the content is gone. I have in mind this $("#int_code").is(':checked')
View 15 Replies
View Related
Aug 11, 2009
#navigation li is the parent element, which is positioned relative.The ul element above that is also position relative. I previously tested a click function and was able to confirm I was getting the correct position back, so now I just need to set the CSS property correctly for all of those links.The reason I want to do this is I have a set of links that appear over a photo of a city skyline. When you hover over those items, I want them to be given a background image that is a blurred and lightened version of the same photo so it needs to line up (sort of like the tabs are made of frosted glass).
View 1 Replies
View Related
Feb 18, 2010
I have found nice short tutorial here: Rounded_Corners
It works fine unless I try to move it.
I have added only one DIV over all:
Now I see that my text (white) moved but not background.
How do I properly position the whole DIV of class "roundbox" ?
View 1 Replies
View Related
Jul 31, 2005
I have a HTML file that has a lot of content. In it I have a <div id="d1">somecontent</div> block. Would it be possible for me to know the position of this d1 (absolute or relative) displayed on the page / window if not setting it first ?
View 5 Replies
View Related
Mar 22, 2007
I have a <img> tag in my web page that i use as button.
when user will click on it, i would like to display a hidden <div> just under.
I mean by just under, that next pixel below the <img> should be the top of <div>.
Moreover, the left of <img> should be the left of <div>... like that it will look like aligned.
The challenge is the following one.
my <img> is positioned by CSS file, so it can (but it is not a must) have left and top setup... maybe not.
I did a short test :
if i setup in CSS file the left and top of <img>, a simple click on <img> can not retrieve the left and top of itself.
something like that i did :
function ShowCalendar(id_master)
{
var uleft = document.getElementById(id_master.id).left;
alert("Left : " + uleft);
}
where id_master = id of the <img> as following :
<img id='id_img' class='buttonimg' src='calendar2.gif' ></img>
So how can i solved this issue ?
Moreover, position of this <div> should be in absolute coordinates, to avoid issue in browser Xsing.
View 1 Replies
View Related
Jul 23, 2005
Hey peeps, I'm trying to get a webpage open and start scrolled fully to the bottom. How should I go about this?
View 3 Replies
View Related
Sep 9, 2006
I have some floating divs on my page.
When I click the div I want do display a menu over it, how can I
determine the position of the clicked div on the page?
View 6 Replies
View Related
Jul 20, 2005
I have simple table
<table id = "mytable" ....>
....
</table>
I want to get the left position of the table.
Everything I did getting wrong :
mytable.left doesn't work, neither mytable.style.left,
mytable.getAttribute("left") ...
What is the correct syntax for getting the position of the table element
(and others ...) ?
View 3 Replies
View Related
Apr 3, 2009
I am an html/css/php professional who dabbles a bit in javascript and many other languages. I must say up front however that I absolutely despise javascript. However, it is necessary for the work I do, so I get by. I have been working for roughly 5 hours trying to find a solution to this. What I do doesntwork, even though I believe it should. Here is my problem: I have a 'menu', based inside of a table. There is one particular td, that when clicked, displays a menu of the users online friends. The friends box is in a div.
The td is name 'online' and the friends box is named 'menufriends'. (with id's, of course.) My problem is that I need the friends box to display next to the td. So what when you click the td, it shows up to the right of it instead of below the menu. I have tried all sorts of different methods and cant even get it to change its position.
[Code]...
View 25 Replies
View Related
Jun 28, 2009
Before you immediately give me an answer, let me describe fully what I'm trying to do, as it's not as simple as the title suggests.
I need to get the absolute position of a DIV (top and left properties) relative to the viewport/screen.
I've tried using .offsetTop and .offsetLeft, but these return the top and left properties relative to the DIV's immediate parent element, not the viewport (unless of course the DIV is top-level and not contained in any other DIVs).
So, is there any way to retrieve the absolute position of a DIV relative to the viewport, even if that DIV is nested in other DIVs?
View 1 Replies
View Related
Nov 6, 2009
Is there some possibility to put the horizontal scroll bar of the web browser into the center if the "width" of web page are bigger then the "width" of the web browser screen?
So I don't need to scroll to right if I open the page, but the horizontal scroll bar will be positioned in the center.
That code should do the same think like I when I take the scroll bar and put it in the center position, but this should be happen when I load the page automatically.
View 3 Replies
View Related
Mar 3, 2010
i want the div to be displayed where the mouse was clicked... whats wrong?
<head>
<style type="text/css">
#layer1 {
position:fixed;
[Code]....
View 1 Replies
View Related