Bug 52019

Summary: "open link" doesn't open https urls
Product: kword Reporter: Uri Shohet <ushohet>
Component: generalAssignee: Thomas Zander <zander>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: 1.5 or before   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:

Description Uri Shohet 2002-12-17 13:11:40 UTC
Version:           1.2post (using KDE 3.1.9)
Compiler:          gcc version 3.2 20020903 (Red Hat Linux 8.0 3.2-7)
OS:          Linux (i686) release 2.4.18-18.8.0

I have an RTF file with several URL links. 

Right click->Open Link on an http URL opens konqueror and everything is fine. Same action on https URL gives an error box: "https://server/page.html is not a valid link".

Thanks

Uri Shohet
Comment 1 David Faure 2002-12-18 01:00:21 UTC
Subject: koffice/lib/kotext

CVS commit by faure: 

Accept any valid URL in "open link" (e.g. https:// wasn't handled)
CCMAIL: 52019-done@bugs.kde.org


  M +3 -4      kotextview.cc   1.103


--- koffice/lib/kotext/kotextview.cc  #1.102:1.103
@@ -1090,8 +1090,7 @@ void KoTextView::slotToolActivated( cons
 void KoTextView::openLink()
 {
-    if(m_refLink.find("http://")!=-1 || m_refLink.find("mailto:")!=-1
-       || m_refLink.find("ftp://")!=-1 || m_refLink.find("file:")!=-1
-       || m_refLink.find("news:")!=-1)
-        (void) new KRun( m_refLink );
+    KURL url( m_refLink );
+    if( url.isValid() )
+        (void) new KRun( url );
     else
         KMessageBox::sorry(0L,i18n("%1 is not a valid link.").arg(m_refLink));