我有一段google浑天仪的代码和swfobject.js、tagcloud.swf,想把它嵌进我的php网站,然后读取我的数据库,抽出最热门的标签,点击后通过一个搜索文件search.php来搜索这个标签得到搜索页面。
问题是现在不知道参数怎么设计,请具体解释一下每个参数的含义。
那一堆很长的参数(是urldecode吧?)应该是用php生成之后插进去就可以了了吧?
还有是有这3个东西(代码 + swfobject.js + tagcloud.swf)就可以了吗?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
</head>
<body>
<div id="Tags"></div>
<script src="swfobject.js" type="text/javascript"></script>
<script type="text/javascript">
var rnumber = Math.floor(Math.random()*9999999);
var cloud = new SWFObject("tagcloud.swf?r="+rnumber, "tagcloudflash", "250", "250", "9", "#ffffff");
cloud.addParam("wmode", "transparent");
cloud.addParam("allowScriptAccess", "always");
cloud.addVariable("data", "%3C%3Fxml+version%3D%271.0%27+encoding%3D%27utf-8%27%3F%3E%3Cbillboard%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%27%E5%88%98%E5%BE%B7%E5%8D%8E%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%272012%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%27%E9%98%BF%E5%87%A1%E8%BE%BE%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%27%E7%BE%8E%E5%A5%B3%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%27%E5%B8%85%E5%93%A5%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%27%E4%B9%B0%E6%88%BF%E5%AD%90%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%27%E6%B1%BD%E8%BD%A6%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3Citem+url%3D%27www.google.com.hk%27+query%3D%27%E8%B5%84%E6%BA%90%27+trend%3D%270%27+intro%3D%27%27+url1%3D%27%27%2F%3E%3C%2Fbillboard%3E");
cloud.write("Tags");
</script>
</body>
</html>