搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

Learn More

Copy text from address bar (not the URL of the current page)

  • 7 回覆
  • 1 有這個問題
  • 19 次檢視
  • 最近回覆由 jscher2000

more options

Looks like this question was asked twice before with no response:

https://support.mozilla.org/en-US/questions/1354750

https://support.mozilla.org/en-US/questions/1331182

I frequently paste text into the address bar to copy it and paste somewhere else. This is very useful for a variety of reasons (e.g. speed, strips text of formatting) but for some reason a recent Firefox update makes it so if you paste text into the address bar and then copy it, you will actually have copied the current page's URL - not the intended copy.

How do we reverse this unexpected and undesirable behavior?

被選擇的解決方法

Replacing the text like you do is not a good way as this might not work properly.

Does it work if you first clear the location bar with Shift+Delete and then paste the content in the empty location bar or if you selected the pasted text another time with Cmd+A ?

Mac might behave like Linux (macOS is based on Linux) and use a primary and secondary clipboard where selecting works differently.

從原來的回覆中察看解決方案 👍 0

所有回覆 (7)

more options

I suggest you use a text or Word type program. Copy to the text/word, then copy that to where you want to.

有幫助嗎?

more options

FredMcD said

I suggest you use a text or Word type program. Copy to the text/word, then copy that to where you want to.

I appreciate the quick response and suggestion, but this workaround doesn't address the main point. To me this is a bug, not a feature, since a text field like the address bar should work the way all other text fields work. In other words, when you copy and paste text in that field, then you should be copying and pasting the selected text (not some other arbitrarily selected text like the current page's URL).

有幫助嗎?

more options

Are you replacing the URL in the location bar or are you appending the text to the current URL when you paste ?

Are you specifically re-selecting the text once you have pasted it ?

有幫助嗎?

more options

cor-el said

Are you replacing the URL in the location bar or are you appending the text to the current URL when you paste ? Are you specifically re-selecting the text once you have pasted it ?

Here is an example flow:

1. Highlight text in an email and hit cmd+C 2. Select text in address bar and hit cmd+A, then cmd+V (pasting the text from the email over the current address bar text) 3. Hit cmd+A, then cmd+C (highlighting and copying the new address bar text) 4. Going to another application and hitting cmd+V (but then a URL pops up instead of the email text)

So yes, replacing the entire URL in the bar, not appending to it.

I am "specifically re-selecting the text" if selecting it through cmd+A counts.

有幫助嗎?

more options

選擇的解決方法

Replacing the text like you do is not a good way as this might not work properly.

Does it work if you first clear the location bar with Shift+Delete and then paste the content in the empty location bar or if you selected the pasted text another time with Cmd+A ?

Mac might behave like Linux (macOS is based on Linux) and use a primary and secondary clipboard where selecting works differently.

有幫助嗎?

more options

cor-el said

Replacing the text like you do is not a good way as this might not work properly. Does it work if you first clear the location bar with Shift+Delete and then paste the content in the empty location bar or if you selected the pasted text another time with Cmd+A ? Mac might behave like Linux (macOS is based on Linux) and use a primary and secondary clipboard where selecting works differently.

Weird! It seems you are right: If I delete the text before pasting, the copy-paste-copy process works as expected. Thanks for pointing this out, apparently there's some nuance happening here. It's still interesting because this is a practice I've used for years but something must have changed recently in Firefox or Mac OS to make this behave differently.

有幫助嗎?

more options

This also happens on Windows.

If you have extra space on your toolbar, you can add the short search bar to use for this. It is stable between page loads in case you want to keep something there for a while. See: Add the Search bar to your Firefox toolbar.

有幫助嗎?

問個問題

如果您還沒有帳號,您必須先 登入您的帳號 來回覆文章。請 開始一個新問題