Author: snoopdave
Date: Sun Mar  1 18:09:45 2015
New Revision: 1663142

URL: http://svn.apache.org/r1663142
Log:
Fix for ROL-2066 Commentors can't leave a comment using URL begins with 
https:// in Gaurav theme

Modified:
    roller/trunk/app/src/main/webapp/themes/gaurav/entry.vm

Modified: roller/trunk/app/src/main/webapp/themes/gaurav/entry.vm
URL: 
http://svn.apache.org/viewvc/roller/trunk/app/src/main/webapp/themes/gaurav/entry.vm?rev=1663142&r1=1663141&r2=1663142&view=diff
==============================================================================
--- roller/trunk/app/src/main/webapp/themes/gaurav/entry.vm (original)
+++ roller/trunk/app/src/main/webapp/themes/gaurav/entry.vm Sun Mar  1 18:09:45 
2015
@@ -180,8 +180,8 @@
                                                }
                
                                                function fixURL(theForm) {
-                                                       if (theForm.url.value 
!= "" &&
-                                                               
theForm.url.value.indexOf("http://";) == -1) { //prepend http://
+                                                       if (theForm.url.value 
!= "" && !/^\S+:\/\//.test(theForm.url.value)) {
+                                // URL has no scheme so prepend http://
                                                                
theForm.url.value = "http://"+theForm.url.value;
                                                        }
                                                        
saveUserInformation(theForm);


Reply via email to