---
title: "加入到收藏夹中"
author: "tomEnjoy"
date: "2009-11-24T15:39:27Z"
tags: []
slug: "untitled"
draft: false
lastmod: "2009-11-24T15:39:27Z"
id: 524546
url: "https://tomenjoy.iteye.com/blog/524546"
---

```js
function add2Favorite(){	
 try{
  if (window.sidebar) { 
    window.sidebar.addPanel(document.title,location.href,""); 
  } else if( document.all ) {
    window.external.AddFavorite( location.href,document.title);
  }
 }catch(e){}
}
```