[Vtigercrm-commits] [vtiger-commits] r10750 - /vtigercrm/branches/5.0.3/Smarty/templates/Rss.tpl

vtigercrm-commits at vtiger.fosslabs.com vtigercrm-commits at vtiger.fosslabs.com
Fri Apr 20 13:04:26 EDT 2007


Author: richie
Date: Fri Apr 20 11:04:21 2007
New Revision: 10750

Log:
* Fixed the issue in alert message of RSS, Fixed #3588

Modified:
    vtigercrm/branches/5.0.3/Smarty/templates/Rss.tpl

Modified: vtigercrm/branches/5.0.3/Smarty/templates/Rss.tpl
==============================================================================
--- vtigercrm/branches/5.0.3/Smarty/templates/Rss.tpl (original)
+++ vtigercrm/branches/5.0.3/Smarty/templates/Rss.tpl Fri Apr 20 11:04:21 2007
@@ -73,7 +73,9 @@
                                         $("status").style.display="none";
 					if(isNaN(parseInt(response.responseText)))
         				{
-				                alert(response.responseText);
+				               var rrt = response.responseText;
+						$("temp_alert").innerHTML = rrt;
+						removeHTMLTags();	
 				                $('rssurl').value = '';
 					}
 					else
@@ -92,11 +94,12 @@
 
 <!-- Contents -->
 {include file="Buttons_List1.tpl"}
+<div id="temp_alert" style="display:none"></div>
 <table border=0 cellspacing=0 cellpadding=0 width=98% align=center>
 <tr>
 	<td valign=top align=right width=8><img src="{$IMAGE_PATH}showPanelTopLeft.gif"></td>
 	<td class="showPanelBg" valign="top" width="100%" align=center >	
-
+		
 			<!-- RSS Reader UI Starts here--><br>
 				<table width="100%"  border="0" cellspacing="0" cellpadding="5" class="mailClient mailClientBg">
 				<tr>
@@ -228,4 +231,17 @@
                         {rdelim}
                 );
 {rdelim}
+
+
+function removeHTMLTags()
+{ldelim}
+ 	if(document.getElementById && document.getElementById("temp_alert"))
+	{ldelim}
+ 		var strInputCode = document.getElementById("temp_alert").innerHTML;
+ 		var strTagStrippedText = strInputCode.replace(/<\/?[^>]+(>|$)/g, "");
+ 		alert("Output Message:\n" + strTagStrippedText);	
+ 	{rdelim}	
+{rdelim}
+
+
 </script>





More information about the vtigercrm-commits mailing list