how to hide url address in status bar? [duplicate] - javascript

This question already has answers here:
Closed 12 years ago.
Possible Duplicate:
JavaScript: Change browser window status message
When we hover on some link text, the target link is shown in the status bar. How can we hide the link address in the status bar. For example, in following link:
Start Upload

Try this
<a onClick="javascript:$('#fileUpload2').fileUploadStart()" href="javascript:void(0)">Start Upload</a>`
Only javascript:void(0) will show up in the browser window.
James

Related

An icon for a bookmarklet [duplicate]

This question already has answers here:
Adding favicon to javascript Bookmarklet (uses window.open)
(3 answers)
Can I create a bookmarklet button with icon?
(1 answer)
Closed 7 months ago.
I'd like to write a bookmarklet for Chrome. Something like this.
<a href="javascript:void%20function(){var%20a=prompt(%22What%20is%20your%20name%3F%22,%22Your%20Name%22);null!=a%26%26alert(%22Hello%20%22+a)}();">
Oxford Extra
</a>
It works. On a real page one can drag this link to the bookmark panel and drop there.
The problem is that there is no icon.
If it were an ordinary link, the favicon of a site would appear. But in case of this bookmarklet, the Chrome's default icon is selected, which is not good.
How can I give the bookmarklet an icon?

How to hide refferer from a website [duplicate]

This question already has answers here:
Remove http referer
(10 answers)
Closed 6 years ago.
For example I have a website X and I don't want the other site Y, to know my url adress if someone goes to site Y through my website X. How do I do that?
There is noreferrer value for rel attribute:
https://html.spec.whatwg.org/multipage/semantics.html#link-type-noreferrer
https://developer.mozilla.org/en-US/docs/Web/HTML/Link_types
Prevents the browser, when navigating to another page, to send this page name, or any other value, as referrer via the Referer: HTTP header.
(In Firefox, before Firefox 37, this worked only in links found in pages. Links clicked in the UI, like "Open in a new tab" via the contextual menu, ignored this).
Example:
example
There is also a library that tries to support noreferrer on older/non-supportive browsers:
https://github.com/knu/noreferrer

Make the link visible when hovering a non-link element [duplicate]

This question already has answers here:
How to display text in the browser status bar?
(6 answers)
Closed 6 years ago.
You know when you hover a < a> element and the link appears in the bottom left corner of the browser?
Is it possible to do it with another tag?
No. Setting the status bar manually has been disabled in modern browsers for security reasons. A malicious site developer could make the status bar display a different URL than the one they would be taken to on a link.
The Javascript property used to work like this:
window.status = "Status bar text";
This no longer does anything at all by default on any current browser.
No, but you can put an <a> element over/around another element and 'disable' the link (onclick) using javascript to achieve a similar result:
<a href="//Message in the status bar!" onclick="return false">
<div>
This div shows something in the status bar
but is actually surrounded by a disabled link
</div>
</a>

Javascript: Change Url without refreshing the page [duplicate]

This question already has answers here:
How do I modify the URL without reloading the page?
(20 answers)
Closed 8 years ago.
I am in a page with url
https://mysite.com/tst/v1/my-app/var/$%5Btest_new_var%5D.
On click i want to change the url to
https://mysite.com/tst/v1/my-app/" without reloading the page.
How can i do that?
please help,
Thanks.
In newer browsers that support history.pushState you can replace the url without reloading.
Lets say a user browses to http://example.com/ernie.html
window.history.pushState({ foo: "bar" }, "page 2", "bert.html");
Will change the address bar to http://example.com/bert.html, but won't cause the browser to load bert.html or even check that bert.html exists.

Determining what is shown in an iframe [duplicate]

This question already has answers here:
Get current URL from IFRAME
(8 answers)
Closed 9 years ago.
I created a web browser type application using a textbox as an address bar and an iframe as a web content host. Upon entering an address in the textbox, the content in the iframe changes and is working properly. When the client clicks on a link in the iframe, the text in the address bar should change according to the content in the iframe - how can I do this?
For example: To begin with, www.microsoft.com is in the textbox and the corresponding page is in the iframe. If I click on a link such as products, the text box text should change to the page in the iframe.
You can use the onload event on your iframe to know when url has been changed. Then read the src attribute and update your textbox.

Categories