Guest User

Untitled

a guest
Oct 16th, 2013
454
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 1) Open the file: include/library/phpfox/image/helper.class.php
  2.  
  3. Look for:
  4. $sImage .= ' title="' . $aParams['title'] . '"';
  5.  
  6. Replace with:
  7. $sImage .= ' title="' . htmlspecialchars($aParams['title']) . '"';
  8.  
  9. Next, look for:
  10. $sImage .= ' alt="' . $aParams['title'] . '" ';
  11.  
  12. Replace with:
  13. $sImage .= ' alt="' . htmlspecialchars($aParams['title']) . '" ';
  14.  
  15. 2) Now open the file: module/captcha/include/component/ajax/ajax.class.php
  16.  
  17. Look for:
  18.     public function reload()
  19.     {
  20.         $sUrl = Phpfox::getLib('url')->makeUrl('captcha.image', array('id' => md5(rand(100, 1000))));
  21.         $this->call('$("#' . $this->get('sId') . '").attr("src", "' . $sUrl . '"); $("#' . $this->get('sInput') . '").val(""); $("#' . $this->get('sInput') . '").focus(); $("#js_captcha_process").html("");');
  22.     }
  23.  
  24. Replace with:
  25.     public function reload()
  26.     {
  27.         $sUrl = Phpfox::getLib('url')->makeUrl('captcha.image', array('id' => md5(rand(100, 1000))));
  28.         $sId = htmlspecialchars($this->get('sId'));
  29.         $sInput = htmlspecialchars($this->get('sInput'));
  30.         $this->call('$("#' . $sId . '").attr("src", "' . $sUrl . '"); $("#' . $sInput . '").val(""); $("#' . $sInput . '").focus(); $("#js_captcha_process").html("");');
  31.     }
  32.  
  33. 3) For our last edit, open the file: module/share/include/component/ajax/ajax.class.php
  34.  
  35. Look for:
  36.     public function popup()
  37.     {      
  38.         Phpfox::getBlock('share.frame', array(
  39.                 'type' => $this->get('type'),
  40.                 'url' => $this->get('url'),
  41.                 'title' => $this->get('title')
  42.             )
  43.         );
  44.     }
  45.  
  46. Replace with:
  47.     public function popup()
  48.     {      
  49.         Phpfox::getBlock('share.frame', array(
  50.                 'type' => htmlspecialchars($this->get('type')),
  51.                 'url' => $this->get('url'),
  52.                 'title' => htmlspecialchars($this->get('title'))
  53.             )
  54.         );
  55.     }
RAW Paste Data