gpt4 book ai didi

javascript - 发布到 MySpace 的链接不起作用

转载 作者:行者123 更新时间:2023-11-28 09:01:17 25 4
gpt4 key购买 nike

我在发布到 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 发布内容呢?

最佳答案

试试这个网址 http://mashable.com/2008/02/13/post-to-myspace/

这是来自他们的网站:

Actual Url: http://www.myspace.com/Modules/PostTo/Pages/?t=MySpace%20Post%20To%20Feature%20Example&c=%3Cp%3EHTML%20content%20to%20post%20goes%20here%20%3Ci%3E(e.g.%20text%2C%20images%2C%20objects%2C%20etc.)%3C%2Fi%3E%3C%2Fp%3E&u=http%3A%2F%2Fwww.myspace.com&l=3

“不要删除任何参数(T、C、U、L)——每个参数都是必需的。但是,您不需要在任何字段中添加内容;它们可以留空。”

关于javascript - 发布到 MySpace 的链接不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17697347/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com