Giter Site home page Giter Site logo

erichgoldman / add-url-to-window-title Goto Github PK

View Code? Open in Web Editor NEW
74.0 7.0 13.0 116 KB

A Firefox addon which will put the web page address (URL) into the window's title. Useful for customizing KeePass's auto-type

License: GNU General Public License v3.0

JavaScript 70.73% HTML 29.27%
keepass addon chrome-addon firefox-addon firefox-extension chrome-extension auto-type

add-url-to-window-title's People

Contributors

christoph-b avatar erichgoldman avatar jo-shi avatar justoff avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

add-url-to-window-title's Issues

Synology Photostation crashs with activatet plugin

I can not open my Photostation in Firefox with activated plugin. Everytime the loading of the site stops, and I got an script error. The script doesn't answer. Only if add-url-to-window-title is deactivated the site loads without errors.

fehler_add_url_to_title

Add-On does not activate in pop-up window for self-contained logon at my.yahoo.com

Migrated from Issue #2:

The Yahoo pop-up login dialog generated via the my.yahoo.com sign-in has the same problem. However if the URL of the pop-up is pasted into the Firefox URL address bar the URL-in-Title works fine.

Replication visit: https://my.yahoo.com/ and click "Sign In" at top right.

yahoo-screen-shot-1

yahoo-screen-shot-2


Diagnosis

Note that the URL bar is grayed out. It does not seem to load the add-on at all. The event is not attached. When running a debug with dev tools no breakpoints are triggered when the pop-up window is loaded. Perhaps Firefox treats restricted/locked down windows differently and they are not accessible by the normal tabs api.

Note, that if you visit https://login.yahoo.com/ in a regular tab/window then the add-on is activated. Some further research will be done.

not working at all

FF 90.0.1 (64-bit) on FreeBSD.
No effect at all after plugin installation. Restarting FF does not change anything.
Any ideas?

Russian Translation

{
"manifestDescription": {
"message":"Добавляет полный URL или доменное имя текущей страницы в заголовок окна. Что позволяет сторонним приложениям (например KeePass) идентифицировать текущую открытую страницу."
,"description":"Description in the manifest file"
}

,"optionsSectionHeader": {
"message":"Настройки AU2WT"
,"description":"In extension options, the main header"
}

,"optionsShowFullUrlHeader": {
"message":"Что должно отображаться в заголовке окна?"
,"description":"In extension options, header for showFullUrl setting"
}
,"optionsShowFullUrlText": {
"message":"Отображать URL целиком?"
,"description":"In extension options, text next to checkbox for showFullUrl setting"
}
,"optionsShowFullUrlHelp": {
"message":"При установленном флажке - URL отображается целиком; При снятом - отображается только доменное имя."
,"description":"In extension options, helper text for showFullUrl setting"
}

,"optionsSeparatorStringHeader": {
"message":"Строка-разделитель"
,"description":"In extension options, header for separatorString setting"
}
,"optionsSeparatorStringHelp": {
"message":"Строка символов, которые будут разделять оригинальный заголовок и URL-адрес (например 'Заголовок - URL' или 'Заголовок :: URL')"
,"description":"In extension options, helper text for separatorString setting"
}

,"optionsShowFieldAttributesHeader": {
"message":"Отображение атрибутов полей ввода текста"
,"description":"In extension options, header for showFieldAttributes setting"
}
,"optionsShowFieldAttributesText": {
"message":"Показывать атрибуты поля при установленном в нём курсоре ввода текста?"
,"description":"In extension options, text next to checkbox for showFieldAttributes setting"
}
,"optionsShowFieldAttributesHelp": {
"message":"При установленном флажке – атрибуты 'name' и 'id' <input /> полей будут добавляться к заголовку окна когда в них установлен курсор ввода текста. Это может пригодиться, когда KeePass недостаточно одного URL страницы для корректной работы авто-заполнения. Это также может пригодиться при двухэтапной аутентификации. Вы просто создаёте команду авто-заполнения для конкретного поля, а затем настраиваете авто-заполнение на работу с URL и конкретным полем, в котором сейчас находится курсор ввода текста."
,"description":"In extension options, helper text for showFieldAttributes setting"
}

,"optionsSaveButtonText": {
"message":"Сохранить настройки"
,"description":"In Options Popup - Text which is shown on the save button"
}
,"optionsSavedHeader": {
"message":"Настройки сохранены"
,"description":"In Options Popup - Header for green div that is shown after clicking save button, to confirm saving happened"
}
,"optionsSavedMessage": {
"message":"Чтобы увидеть изменения, вам может потребоваться обновить вкладки."
,"description":"In Options Popup - Text that is shown after clicking save button, to confirm saving happened"
}
,"optionsDonateLinkText": {
"message":"Поддержать автора $2.22"
,"description":"In Options Popup - Link that leads to donation page"
}
,"optionsHelpLinkText": {
"message":"Помощь & ЧаВо"
,"description":"In Options Popup - Link that leads to help page"
}

}

Saving settings to storage (i.e. ~/.mozilla/firefox/profile/browser-extension-data/)

Other extensions save their settings to storage, and then it’s easy to keep those settings in dotfiles.

However I don’t see a directory for add-url-to-window-title in there:

% ls -l ~/.mozilla/firefox/profile.default/browser-extension-data 
total 16
drwx------ 2 m users 4096 Feb 18 05:09 [email protected]
drwx------ 2 m users 4096 Feb 19 01:23 [email protected]
drwx------ 2 m users 4096 Feb 19 01:34 [email protected]
drwx------ 2 m users 4096 Feb 19 01:23 [email protected]

%

It would be super-cool to be able to keep your settings in dotfiles, too. =)

Window/Tab title not updated properly

Hello, Erich! Thank you for this great extension!

On many websites I have noticed that with this extension enabled, the window title many times is not updated properly. For example:

  • Visit: https://addons.mozilla.org/en-US/firefox/
  • Title: Add-ons for Firefox - addons.mozilla.org/ - Firefox
  • Click on "Adblock Plus" at the "Most Popular" sidebar
  • Title: Add-ons for Firefox - addons.mozilla.org/ - Firefox

Now disable the extension:

This is just a harmless example. But sometimes I search for something on my search engine, for example "Firefox 41", and then use the search engine's own form to query for another unrelated word (eg. "Chocolate Ice Cream"), but the title remains the old, so after switching tabs, when I want to find the tab with the search for "Chocolate Ice Cream", I have to look for the tab named "Firefox 41".

Thank you for your attention!

Unicode Issue

The URL seems to get html escaped when added to the title bar.

For eg. go to url: https://www.candyjapan.com/口

And see the title!

It displays for me as : 口 | https://www.candyjapan.com/%E5%8F%A3 - Mozilla Firefox

I've set | as the separator.

Field attributes do not show at: https://wwws.mint.com/login.event

Separated from Issue #2 to focus just on the Mint self-contained logon page.

If you visit Mint.com and click the "Log In" link it will reveal an input form. The add-on works on this form. However, if you click the "Login In" button to submit the form and the fields are blank or on an error you are sent to a stand alone logon page at https://wwws.mint.com/login.event

Before reaching "login.event" you are first redirected from: https://wwws.mint.com/loginJumper.event

On https://wwws.mint.com/login.event if you have enabled "Show the field attributes when a text input field has focus?" selecting and input field will not add the form fields attributes to the title.

URL Title contains characters that are not compatible with KeePass target window regular expressions

KeePass Target Windows support regular expressions. The field attribute strings that add-url-to-window-title add, contains the left bracket character "[" that is special character in regular expressions and must be escaped in a regular expression.

Would it be possible to change the posted attribute strings so that they are compatible with regular expressions; or add an option that either strips, or substitutes alternate characters that are not special characters used in regular expressions?

Note: I prefer to use the special regular expression character '|' (without the quotes) as my separator sting so I would hope that if an option to strip special characters out of the posted Title were implemented, it would not apply to the separator string.

Window/Tab title not updated with JavaScript causing Speculative Parsing

Hey,
just another example with the title not updating. I use Firefox 45.0.1.
If i disable JS on www.mv-werneck.de everything is fine. If it is enabled, the window title will not update when clicking through the navigation (look for menu point "Verein", where you can toggle visibility somewhere in the content).

There is a little script that uses document.write() to write the open tag of an div-element, but doesn't close it. It is closed later in another <script></script> section. I think this is done to make the content in the div-element also appear if you disable JS.
The unclosed element causes Speculative Parsing in Firefox to fail, so it needs to be parsed again. That might be the reason for that bug?
I hope it helps a bit.

The bug is also still present for me with the sites mentioned in #6 and #7.
Best greets
Stonecrusher

/edit: Console in firefox suggests this. It's made for the webmaster, but still may be useful.

adding the account alias / ID of the AWS signin page would allow KeePassXC Auto-type to pick the correct AWS credentials automatically

Background

I would like to configure a KeePassXC entry auto-type to look for a window title that includes the Account Alias / ID to which the user is trying to sign-in. This account Alias / ID is present when you go to, for example https://myaccountalias.signin.aws.amazon.com/console

Proposed Solution

Add the Account Alias field value to the title (or make the title include a configurable set of page elements)

image

Enabling this would allow me to auto-type for the correct account alias without having to scan the list of ALL auto-type enabled AWS entries. This can save a lot of time if I have many distinct AWS credentials, across many AWS accounts.

Problem

I don't know how to add a specific element of the page in the title, and this is not configurable.

Switching between AWS accounts is a common enough use case that I think it would make both this extension, and KeePassXC, more useful to more people.

LastPass has no solution for this. My move away from it was rather seamless thanks to this extension, except for the AWS signin page use case.

Problems with https://webmail.strato.com

Hi eric,
big thanks for your work! I use your extension every day and it helps me a lot.
I have problems with the above website https://webmail.strato.com
If you open the page the URL will be shown in the Title bar for a very short period of time and then overwritten. If you then go into Add-On settings and uncheck/check the "Show full URL?" option the URL will be correctly added by your Add-On but the original Windows title dissappears.
Would be great if you could take a look.

P.S: I use
Firefox ESR 45.3.0
Add-On v.1.01.1

Full URL mode should show the protocol

When "Show the full URL?" is checked yes, it should include the protocol (https://) per https://github.com/erichgoldman/add-url-to-window-title/blob/web-extension/managetitle.js#L204 by calling document.URL however, this is being clipped.

Fixing this could break some people's auto-type rules if they made their regex already and didn't include the protocol. We could make this option into a drop down multiple choice instead of a boolean. Most likely outcome will be that some users autotypes will break.

Feature Request: Remove Trailing Slash from hostname

It would be great to have a setting that when enabled removes the trailing slash from the hostname so that Window titles look pretty while switching tabs/windows.

While we're at it, removing the "www." part for hostnames will make it even more awesome.

I can help with writing the regexes for that if you'd like 🙏

seems broken with firefox v52.0.2

Hi,
I am a long time user of your addon. Crucial for me with KeePassX under linux.
Unfortunately it seemed to have stopped working since firefox update to v52.0.2
I can't access it's "preferences" anymore (so on about:addons, I select the addon, then click the "Preferences" button, then a page opens but there are no preferences anymore, just the addons description and the "donate" button...).
And most of all: It does not add the url anymore to the window title (no matter which site).

Could you help?

Of course this would be the perfect moment to donate... but the DONATE function is broken :(((
See my bug-report:
https://bugzilla.mozilla.org/show_bug.cgi?id=1354479

Tormen

Printing problem, duplicated URL (other addon involved)

Hello, I have some printing problems from time to time. At last I figured out why, now I'm just missing the how :)

Print Edit 16.4 and
Add URL to Window Title 1.01 disabled
Firefox 44.0.2, Windows 10.

Address bar URL:
https://plex.tv/

Tab name/tooltip/title:
"Plex: Your media on all your devices" (same having all add-ons disabled)

1. Print Edit enabled

1.2 Tab name/tooltip/title:
Plex: "Your media on all your devices"

2. Print Edit print dialog title:
"Plex: Your media on all your devices - Mozilla Firefox" (this string is sent to the printer/print job name, " - Mozilla Firefox" is added to the actual tab name content)

3. Add URL to Window Title 1.01 enabled

3.1 Tab name/tooltip/title:
"Plex: Your media on all your devices - https://plex.tv/"

3.2 Print Edit print dialog title:
"Plex: Your media on all your devices - https://plex.tv/ - https://plex.tv/ - Mozilla Firefox"

When the base title content is very long, the duplicated (when unusually long) URL + " - Mozilla Firefox" makes a printout fail using Print Edit. No error from the printer, the windows print manager/queue just stalls and eventually clears. No options in Print Edit.

Example:

http://www.skatteverket.se/funktioner/kalenderarkiv/2016privat/14mars.5.3810a01c150939e893f14fd.html

end up as

2016 års kalender för privatpersoner | Skatteverket - http://www.skatteverket.se/funktioner/kalenderarkiv/2016privat/14mars.5.3810a01c150939e893f14fd.html - http://www.skatteverket.se/funktioner/kalenderarkiv/2016privat/14mars.5.3810a01c150939e893f14fd.ht

note the 2 last characters of .html and " - Mozilla Firefox" is missing (string len limit?). I can't print this page using Print Edit - but it does work using the basic native (ctrl+p) print dialog.

Solution; disable/don't use/talk to Print Edit?

Well, yes. But..

As expected (according to 2.), print Edit will add " - Mozilla Firefox". That's OK! What I can't figure out is why the URL is duplicated, having Add URL to Window Title 1.01 enabled? Is it all on Print Edit or is your (great) add-on somehow shooting twice? :)

Cheers

Edit: formatting error due to quotes wrecked the underline tag

Not url in HTTP Basic Auth

Hello,

The title of popup for an http auth doesn't contains any url.

For example:
https://auth-demo.aerobatic.io/protected-standard/

On keepass, the window just contains "Authentification requise" (in french version) without any url (therefore, it can't be used for autotype in keepass).

Could you fix that ?

Thanks in advance & congratz for this great extension.

Max

Some sites defeat the addon field attribute posting ability

In my limited testing I have noted two sites that seem able to defeat add-url-to-window-title's
ability to post the field attributes of the field that has the focus. I am posting them in case you have an interest in investigating examples like this.

  • The main login page of MINT https://wwws.mint.com/login.event displays the Window Title:
    "Mint Start Here | wwws.mint.com/ - Mozilla Firefox" without the quotes
  • The security question page only of the multi-page USBank login which appears to be accessible via https://www.usbank.com/index.html (by entering a dummy string as a username) displays the Window Title: "Online Banking | onlinebanking.usbank.com/ - Mozilla Firefox" without the quotes

Window/Tab title not updated on searx.me

As requested on issue #6, this is a way to reproduce the "title not updated" problem on searx.me:

  • Add searx.me to your searchbar:
    1. Install the addon "Add to Search Bar"
    2. Visit: https://searx.me/
    3. Right click in the search field at searx.me and add it to your searchbar.
  • Now do a search from the search bar for "Firefox 41" using searx
  • Title: Firefox 41 - searx - searx.me/ - Firefox
  • From within searx, do a web search from its internal search field for the words "Chocolate Ice Cream"
  • Title: Firefox 41 - searx - searx.me/ - Firefox

If you skip step one and search directly from searx.me, the title will always be: "searx - searx.me/ - Firefox", but it should be "%s - searx - searx.me/ - Firefox" instead!

Firefox 57 support?

Hi,
First of all really nice and helpful extension, any chance to make it works with 57? and any estimation when?

Thank you in advance.

Enable Multiprocess Firefox support (e10s)

Currently, installing add-url-to-window-title addon will disable multiprocess on Firefox Stable (Firefox 50).

Test procedure:

  1. On about:config, created new boolean entry browser.tabs.remote.force-enable=true
  2. Enabled add-url-to-window-title addon and restart

Initial result, things seems to be working correctly:

  1. URL is shown on title bar
  2. Moving to a different tab, the URL part changes as expected
  3. Moving to a different window, the URL are shown correctly for each window
  4. Opening a new tab then opening a site, window title updates correctly
  5. Navigating between pages on different domain works

Tested Platforms:

  • Firefox 50, Linux
  • Nightly 53.0a1, 2016-11-21, Linux, shims enabled

Apostrophes are removed from the original title

The original page title is passed through the sanitizer before being used to compose the new title, which removes, among other things, the ' character. So any page titled like "Ash's Profile" will become something like "Ashs Profile - facespace.biz/".

Apostrophes in the original title should be retained.

How do I add the current account/profile to the title?

This is a little off topic. Reading the code, it looks like I can add "more stuff" to the title by modifying titleFormatter(). I'd like to add the local chrome user (as in https://www.pcworld.com/article/2089364/how-to-create-and-manage-multiple-user-profiles-in-chrome.html) to the title, since it will help me select the right window when tabbing through several browser windows. I can't find the code to extract it, however. Can that information be obtained from the extension api?

Cool extension btw. Thank you.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.