[ Index ]
 

Code source de vtiger CRM 5.0.2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/modules/Rss/ -> Rss.js (source)

   1  /*********************************************************************************
   2  ** The contents of this file are subject to the vtiger CRM Public License Version 1.0
   3   * ("License"); You may not use this file except in compliance with the License
   4   * The Original Code is:  vtiger CRM Open Source
   5   * The Initial Developer of the Original Code is vtiger.
   6   * Portions created by vtiger are Copyright (C) vtiger.
   7   * All Rights Reserved.
   8  *
   9   ********************************************************************************/
  10  
  11  function star(id, starred)
  12  {
  13      location.href = "index.php?module=Rss&action=Star&record="+id+"&starred="+starred;
  14  
  15      var elem = document.getElementById("star-"+id);
  16      if(elem.src.indexOf("onstar.gif") != -1) {
  17          elem.src = "{IMAGEPATH}offstar.gif";
  18      }else {
  19          elem.src = "{IMAGEPATH}onstar.gif";
  20      }
  21  }
  22  function getRequest() {
  23          if ( !httpRequest ) {
  24              httpRequest = new XMLHttpRequest();    
  25          }
  26          return httpRequest;
  27      }
  28  function makeRequest(targetUrl) {
  29          var httpRequest = getRequest();
  30          httpRequest.open("GET", targetUrl, false, false, false);
  31          httpRequest.send("");
  32          switch ( httpRequest.status ) {
  33              case 200:
  34                  return httpRequest.responseText;
  35              break;
  36              default:
  37                  alert("Problem accessing url: "+targetUrl+" Code: "+httpRequest.status);
  38                  return null;
  39              break;
  40          }       
  41      }
  42  function verify_data(form) {
  43          var isError = false;
  44          var errorMessage = "";
  45          if (trim(form.rssurl.value) == "") {
  46                  isError = true;
  47                  errorMessage += "\nRSS Feed URL";
  48          }
  49          // Here we decide whether to submit the form.
  50          if (isError == true) {
  51                  alert("Missing required fields:" + errorMessage);
  52                  return false;
  53          }
  54          return true;
  55  }
  56  function display(url,id)
  57  {
  58      document.getElementById('rsstitle').innerHTML = document.getElementById(id).innerHTML;
  59      document.getElementById('mysite').src = url;
  60  }


Généré le : Sun Feb 25 10:22:19 2007 par Balluche grâce à PHPXref 0.7