What does the html bindpoint attribute do?

偶尔善良 提交于 2020-01-25 07:16:48

问题


I'm currently making a facebook application and while investigating the (X)HTML source code for a message thread page to see if it was possible to link to specific messages within threads (apparently it's not), I encountered an HTML attribute that I cannot seem to find any information about. Some span elements on the page had a 'bindpoint' attribute that was set to various values (presumably element IDs). Here is an excerpt from the page source (I replaced some private info with Xs)

<div class="GBThreadMessageRow_Info">
  <span class="GBThreadMessageRow_AuthorLink_Wrapper" bindpoint="authorLinkWrapper">
    <a href="http://www.facebook.com/profile.php?id=XXXXXXXXX" class="GBThreadMessageRow_AuthorLink">XXXXXXXX</a>
  </span>
  <span class="GBThreadMessageRow_Date">
    April 8, 2010 at 10:13pm
  </span>
  <span bindpoint="branchLinkWrapper" class="GBThreadMessageRow_BranchLink"><a href="/ajax/messaging/composer.php?thread=XXXXX&amp;msg_id=XXXXX&amp;id=XXXXXX" rel="dialog-post">Reply</a></span>
  <span bindpoint="reportLinkWrapper" class="GBThreadMessageRow_ReportLink"> • <a href="/ajax/report.php?content_type=9&amp;cid=XXXXX&amp;rid=XXXXX&amp;cid2=XXXX&amp;cid3=X&amp;h=XXXXX" rel="dialog" class="action">Report</a></span>
</div>

I have never seen this attribute before and any information about it would be useful/helpful/interesting. Thanks!


回答1:


As was said in the comments, it has to be something they're doing in the javascript code.

Facebook uses an interesting technique to import their javascript files dynamically (basically they seem to write out script tags in the javascript, when necessary), and it's not quite as simple as just pressing ctrl-F through the first file you find.

So, in conclusion, the bindpoint attribute is something internal to the Facebook eco-system, and not standard HTML. From the name, I assume it has something to do with which events (clicks, mouseovers, etc.) should be binded to the element in question, which is signified by a variable name give in the bindpoint attribute. Or maybe it has to do with which element the element in question should be 'binded' to, like the for attribute for a label. Anyway, this is pure speculation.



来源:https://stackoverflow.com/questions/4607582/what-does-the-html-bindpoint-attribute-do

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!