Hi,
I ran out of ideas how to solve this problem, maybe someone of you
will help me.. Situation goes like this: I have two elements on site
which are siblings, both of them have "onclick" event. On of these
elements has "position: absolute" and is covering the second element.
What I want to achieve, is when user clicks on the absolute positioned
element, "onclick" event fires for both elements. I tried just
everything that camed to my mind, but wihtout result. Anyone got an
idea how to achieve this? Or is it just impossible to make?
Thanks for any help,
Piotr. 3 1421
On Jul 22, 8:45 pm, Piotr K <piotr.korzenie w...@gmail.comw rote:
Hi,
I ran out of ideas how to solve this problem, maybe someone of you
will help me.. Situation goes like this: I have two elements on site
which are siblings, both of them have "onclick" event. On of these
elements has "position: absolute" and is covering the second element.
What I want to achieve, is when user clicks on the absolute positioned
element, "onclick" event fires for both elements. I tried just
Why don't you just call the onclick handler for the overlapped element
from the positioned element's onclick handler?
everything that camed to my mind, but wihtout result. Anyone
got an
idea how to achieve this? Or is it just impossible to make?
I don't understand what you are trying to make.
On Jul 23, 10:45 am, Piotr K <piotr.korzenie w...@gmail.comw rote:
Hi,
I ran out of ideas how to solve this problem, maybe someone of you
will help me.. Situation goes like this: I have two elements on site
which are siblings, both of them have "onclick" event. On of these
elements has "position: absolute" and is covering the second element.
What I want to achieve, is when user clicks on the absolute positioned
element, "onclick" event fires for both elements. I tried just
everything that camed to my mind, but wihtout result. Anyone got an
idea how to achieve this? Or is it just impossible to make?
Not impossible, as David has suggested. Events bubble up or capture
down the DOM tree, the siblings of the element that starts the event
(or that are higher up the DOM tree) will never be involved in either
sequence. At least one major browser doesn't support the capture
phase anyway.
--
Rob
On 23 Lip, 03:57, David Mark <dmark.cins...@ gmail.comwrote:
On Jul 22, 8:45 pm, Piotr K <piotr.korzenie w...@gmail.comw rote:
Hi,
I ran out of ideas how to solve this problem, maybe someone of you
will help me.. Situation goes like this: I have two elements on site
which are siblings, both of them have "onclick" event. On of these
elements has "position: absolute" and is covering the second element.
What I want to achieve, is when user clicks on the absolute positioned
element, "onclick" event fires for both elements. I tried just
Why don't you just call the onclick handler for the overlapped element
from the positioned element's onclick handler?
everything that camed to my mind, but wihtout result. Anyone
got an
idea how to achieve this? Or is it just impossible to make?
I don't understand what you are trying to make.
Well, it was just an example, that absolute positioned element won't
always entirely cover the second element. What I'm making is
drag'n'drop feature with containers where you can drop dragged
elements. Currently I'm checking if element is dragged above container
at global onmousemove event (by checking if mouse position is in
container boundaries), but it isn't too efficient. It would be much
faster and more accurate if mouse events would fire also for elements
under the dragged element. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Paolo Mancini |
last post by:
Hi all,
I have a page with many different elements: <a href="...."> ... </a>,
listboxes, radiobuttons, etc.
Can I use javascript to prevent the user from interacting with the
page? That is: can I intercept, alert the user, and cancel any click
event on the page?
Unfortunately, if the user clicks on a page element, the event bubbles
|
by: john |
last post by:
I1. notice that if you have an onclick event for both the document
and for a particular element, the onclick for the element is called
first and then it bubbles up to the one for the document. Is it
possible to have an onclick event that is at the document level that
is called first? I would like to intercept it there and return false
so that it doesn't bubble down to the element level.
2. On a completely unrelated topic, is it possible...
|
by: Robert Mark Bram |
last post by:
Hi All!
In the code below, I want to add a handler to a *row* (eventually so I can
change the style of a row), but the event is being generated by the TD's it
seems - in Opera and IE. Is there another way to assign a handler, making
sure the event will come from the row and not a TD, or is this simply a box
model issue I cannot work around by assigning new handlers?
Any advice appreciated!
|
by: Mark Szlazak |
last post by:
Apparently there is a textarea onscroll event bubbling bug in Firefox
and Mozilla:
https://bugzilla.mozilla.org/show_bug.cgi?id=229089
I'm trying to check for this bug with the following script and it
*seems* to work. In IE it reports "bubbling" and in Firefox "not
bubbling" but I really have no direct way to confirm the Firefox
results until the bubbling bug is fixed.
|
by: Wee Bubba |
last post by:
the following event handler checks to see if any parent control has
attached to the event 'SearchItemSelect'. i use it for event bubbling
whenever one of my search items has been selected and at the moment i
am calling this from a repeater's ItemCommand event handler:
protected void OnSearchItemSelect(EventArgs e)
{
if (SearchItemSelect != null)
{
SearchItemSelect (this, e);
| |
by: Lars Netzel |
last post by:
I have made a pretty small and simple webCustomerControl that basically just
renders some HTML tables... I want parts of this to be clickable to fire off
a "Click Event" that you can use as a developer, how do I do this?
best regards/
Lars Netzel
|
by: Jonah Olsson |
last post by:
Hello,
I'm trying to build an "add-on" to an already existing custom web user
control. The old control collects some user data and saves it to a database.
The new control should collect some extra info from the user and add it to a
new table in the database.
The old control should not be re-written (at least not now..), so I need a
way of capturing the click event of the Save button in the old control. This
event should trigger a...
|
by: Girish |
last post by:
OK.. phew. Playing with data grids for the past few days has been fun and a
huge learning experience..
My problem. I have a requirement to display a gird with a gird. Within the
embedded grid, theres a requirement to show a drop down menu list (this is a
control I downloaded online) in one of the columns. For the purposes of this
question, Ive implemented the drop down menu as a drop down list instead.
Ive got all this working at this...
|
by: dan_williams |
last post by:
I have the following test web page:-
<html>
<head><title>Test</title>
<script language="Javascript">
<!--
function fnTR() {
alert("TR");
}
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |