This forum has been archived. All content is frozen. Please use KDE Discuss instead.

KMail - opening webpage links in email messages

Tags: solved, solved solved, solved solved, solved
(comma "," separated)
MariaN
Registered Member
Posts
15
Karma
0
OS
Hello,

I tried to do some browsing on this but perhaps didn't manage to use the proper search terms.

A small but annoying problem:

I've KDE 4.3 stable, with KMail 1.12.0 and, obviously, Konqueror 4.3. I'm trying to get URLs included in emails to open in Konqueror by left-clicking the links. Instead, it seems that the page is downloaded into cache and then this file with the page code is opened, instead of the website itself. The same happens if I right-click the URL and select 'open URL'.

Anyone can help me with this? Thanks.
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
Can you please ensure that the association for "html" is set correctly in Konqueror > Settings > Configure Konqueror > File Management > File Associations. Search for "text/html". Ensure that Konqueror is at the top of the associations list, and under Embedding that "KHTML (khtml)" is at the top.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
MariaN
Registered Member
Posts
15
Karma
0
OS
Yes, those are all in order. Otherwise, under Embedding, for 'Left click action', "use settings for 'text' group" is selected, and so is the 'ask whether to save to disk instead' checkbox. The setting for the text group is 'show file in separate viewer.
User avatar
anda_skoa
KDE Developer
Posts
783
Karma
4
OS
If KDE decides to download something when processing an URL, the most likely cause is that the command associated with the MIME type (or for the web browser settings) does not contain %u or %U as one of it parameters.

For example the one configured here for text/html is
Code: Select all
kfmclient openURL %u text/html

(This should actually be the default)

This parameter basically has two functions: first, it tells KDE where to put the URL when invoking the application and second, that the application can actually handle URLs itself.

%u means "can handle a single URL"
%U means "can handle a list of URLs"

If neither is specified, KDE assumes it needs to provide a safe fallback, i.e. download to a temporary file and pass that filename.

Cheers,
_


anda_skoa, proud to be a member of KDE forums since 2008-Oct.
MariaN
Registered Member
Posts
15
Karma
0
OS
Yes, the default command line is there. I also tried changing the %u to %U but no effect.

Investigating further, I notice it varies on different websites. In all cases, the link is downloaded to cache and opened from there in Konqueror.

-With some links, the pages are opened correctly (text, pictures etc). If I click further links on the pages, they open normally as URL addresses.

-With some links (for instance this KDE forum website link in the email notification of forum reply), the page is opened but all text is not properly encoded, images are not loaded and if I try to click further links, I get "file or folder does not exist"

-With some links, only the page with the code is opened, and before that, I get the message: "The file /var/tmp/kdecache-ELWisty/krun/14456.0.showthread.php was opened with UTF-8 encoding but contained invalid characters. It is set to read-only mode, as saving might destroy its content. Either reopen the file with the correct encoding chosen or enable the read-write mode again in the menu to be able to edit it."

I am running KDE 4.3 on Fedora 11, if that might have any bearing on the issue (some Fedora-specific issue).
vikram
Registered Member
Posts
18
Karma
0
OS
I am using KDE 4.3.4 on Arch Linux and have the same issue. Also when viewing a page that ends with .php Konqueror displays the source html of the page instead of rendering it.

Is it possible to configure Kmail or Konqueror to open the page directly instead of downloading to cache ?

thanks
Vikram


vikram, proud to be a member of KDE forums since 2008-Nov.
User avatar
anda_skoa
KDE Developer
Posts
783
Karma
4
OS
vikram wrote:Is it possible to configure Kmail or Konqueror to open the page directly instead of downloading to cache ?


Sure, that's actually the default (you can check with a new user account to see if the current problem is system wide or just for your current account).

What setting do you have in Systemsettings -> Standard Components -> Web Browser?
What setting do you have in Systemsettings -> Advanced Tab -> Fileassociations for text/html?

Cheers,
_


anda_skoa, proud to be a member of KDE forums since 2008-Oct.
vikram
Registered Member
Posts
18
Karma
0
OS
anda_skoa wrote:
What setting do you have in Systemsettings -> Standard Components -> Web Browser?


Systemsettings -> Personal -> Default applications
konqbrowser
anda_skoa wrote:What setting do you have in Systemsettings -> Advanced Tab -> Fileassociations for text/html?

Systemsettings -> Advanced User Settings -> File Associations:
Konqueror

These were default settings - I didnt change anything.


vikram, proud to be a member of KDE forums since 2008-Nov.
User avatar
anda_skoa
KDE Developer
Posts
783
Karma
4
OS
Maybe your distribution changed the defaults.
Usually the default for the first setting is to not have a specific browser but open http links in the application suitable for the linked to file type.

Can you try to switch to that setting?

Cheers,
_


anda_skoa, proud to be a member of KDE forums since 2008-Oct.
vikram
Registered Member
Posts
18
Karma
0
OS
anda_skoa wrote:Maybe your distribution changed the defaults.
Usually the default for the first setting is to not have a specific browser but open http links in the application suitable for the linked to file type.

Can you try to switch to that setting?

Cheers,
_


That worked thanks Anda !


vikram, proud to be a member of KDE forums since 2008-Nov.
mathias-t
Registered Member
Posts
1
Karma
0
OS
Having the above described problem i googled this page and it helped me where to look and change values to rectify the problem.

I just found out, that in my
. Systemsettings -> Standard Components -> Web Browser
there was only written:
firefox
Now i changed this to:
. /urs/bin/firefox
without any %u or anything else and now it works as it should:

clicking on a link within an email in kmail (or any other application or anywhere else in kde) it will open a new tab in firefox and opens the webpage from their real url.

Thanks to everyone for having discussed the problem on this page!


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Sogou [Bot]