我在发布到 MySpace 链接时遇到问题。使用 PDF 教程,我创建了一个简单的页面:
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script type="text/javascript">
function GetThis(T, C, U, L)
{
var targetUrl = 'http://www.myspace.com/index.cfm?fuseaction=postto&' + 't=' + encodeURIComponent(T)
+ '&c=' + encodeURIComponent(C) + '&u=' + encodeURIComponent(U) + '&l=' + L;
window.open(targetUrl);
}
</script>
</head>
<body>
<a href="javascript:GetThis('An Important News Article Title',' ', 'http://www.newssite.com/article.php?id=123',
'3')">
<img src="http://cms.myspacecdn.com/cms/post_myspace_icon.gif" border="0" alt="Post to MySpace!" />
Share on MySpace get method!
</a>
<form id="myspacepostto" method="post" action="http://www.myspace.com/index.cfm?fuseaction=postto"
target="_blank">
<input type="hidden" name="t" value="An Important News Article Title" />
<input type="hidden" name="c" value="" />
<input type="hidden" name="u" value="http://www.newssite.com/article.php?id=123" />
<input type="hidden" name="l" value="3" />
<a href="#" onclick="document.getElementById('myspacepostto').submit();return false;">
<img src="http://cms.myspacecdn.com/cms/post_myspace_icon.gif" border="0" alt="Post to MySpace!" />
Share on MySpace post method!
</a>
</form>
</body>
</html>
有一个简单的链接和形式的例子。但是当我使用表单链接时,请求时间太长,MySpace 没有响应。如果我使用简单链接将内容发布到 MySpace,那么我会得到一个 404 错误页面。那么如何将内容发布到 MySpace?