Use custom designed javascript function to word press button - events

I have a site designed in word press. My problem is that I have Call a Javascript / Jquery function when the user click the WP BUTTON. Presently only open a new page facility is available. i have to add custom designed events of Onfocus, Onclick etc events in wp press.

Related

Delphi - How to programmatically make a modal dialog react like an event similar clicking on the background form

In our application, a modal dialog is shown that the user needs to confirm/close before other interaction is possible/allowed. This dialog is a self-implemented form, so can be adjusted to our needs.
An external event (in our case: a scan from a manual barcode scanner) provides input for the application. When the dialog is in front of the application, I would like to inform the user the scan/input is not processed. An idea is to simulate the behaviour that happens when clicking the form in the background of the modal dialog. By default, Windows then lets the dialog borders 'flash' and a sound is heard ('bonk' sound as described here: Delphi - How do you generate an event when a user clicks outside modal dialog?).
My question is:
Is it possible to programmatically simulate that behaviour, in order
to let user know the dialog has to be closed first?
Additional question: is this proper UI handling or should the dialog itself display an additional info text (e.g. as a footer text) instead of just 'flash'. I like to avoid displaying another modal dialog on top of the first one; to me that not seem best practice as well.
Thank you for any feedback/solution.
Use the FlashWindow or FlashWindowEx functions to achieve this.

Windows. C#. XBox360 Controller prevent default Guide Button popup panel and show my own

I want to use XBox360 Controller in my app. I can get user input with SlimDx.dll. But I cant catch 'XboxButton' or 'GuideButton' pressed. I want catch it to prevent showing default panel (see screenshot) and show my own panel with my controls. Is it possible?

Detect user clicked on specific button on mini browser (window phone)

Im on development of window phone application,
Scenario:
Mini browser opening a page(for example google.com)
Google.com has a button called 'Search'
If User clicked button 'Search'
Redirect to an redirect.xaml
Else
Do nothing
Here is my scenario, how can I actually detect the User clicked the button and only they can proceed to the next page? Is that I have to use javascript in this situation? because if on web, this is technique which I will use.
Webbrowser control downloads we content and you have to parse the content or to handle the js actions. Thats the way to do it.

Upload dialog in Chrome and Firefox on Mac doesn't disable mouseout event for the page element

My task is to implement a file upload form in a popup sub-menu panel. I am using XmlHttpRequest, so it's important to keep that popup opened until I receive an event status that file loading completed/failed. Onmouseover and onmouseout events are used to show/hide the popup.
On "hide" the popup panel is detached from the DOM, and cannot be used anymore as a listener for XHR events.
When I click form's "Browse" button, a system dialog window is opened above the browser. In IE, Chrome and Firefox in Windows the system dialog disables events handling by page. Which means if you move a mouse cursor out of the dialog window on one of the page element, the page won't do anything like reacting on mouseOver/mouseOut events. Unfortunately, in case with Chrome/Firefox on Mac (Safari is OK) the page elements do react on mouse over/out. And my popup menu becomes closed (due to mouseOut event handler for the popup) -> XHR response is not managed properly.
Assuming having an upload form in a popup is a must, what are the possible ways of keeping that panel/form visible while system Upload File dialog window is up? Probably a Mac specific solution.
Sample code can be seen here http://jsfiddle.net/xqvXG/
Solved this by freezing popup panel and covering the whole page with transparent div ('glass').
In case if user chooses file(s) and upload starts, I remove the glass and unfreeze the popup using the XHR function readyStateChangeHandler (or may do that in handler of load event).
If user clicks Cancel in system dialog window or closes it with "X" button - no events passed to the page and 'glass' remains on screen. Then any click on the 'glass' causes its removal and unfreezing (or simple hiding) the popup menu.
'Glass' is required to make a single one-click point (panel) for unfreezing the popup in case if Cancel/Close were pressed.
I wouldn't say this is a perfect solution (sometimes required extra action), but very close to what I was looking for.

drag and drop - vb.net

I am implementing Drag & Drop in windows application. I have
Main Form (Has a toolbar with Search, Open, Print etc) - MdiContainer
On Search - Open a child - Search form.
Drag and Drop a file to a Grid on this search form.
In DragDrop event of the Grid - Call a Modal form.
I am having trouble here.
When i drag and drop a file on to a selected record in the grid, i am able to call a modal form in Grid_DragDrop event. But this modal form blocks everything until it is closed instead of just blocking access to the application. Also when i move this modal form around, i see trail of form moving and it does not go away until i close the form.
I am able to call the same modal form on a button click and able to move it around. No trail of form and it refreshes fine. It only blocks the application and not the desktop.
I am clueless about why this is happening only when i call modal form in DragDrop event?
Showing modal forms from DragDrop event is REALLY bad idea. Basically you make your app go haywire because it cannot do what windows require of it during DragDrop (including redrawing both DragDrop source (desktop?) and target).
Use DragDrop event ONLY to register what is being dropped and then process it afterwards.

Resources