Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 MediaWiki,但我无法使用 tag <script></script>。
<script></script>
有一种方法可以按类获取 url (location.href) 吗?
比如我把代码location.href放在js文件中,在我放的页面中:
<div class="someclass"></div>
并出现网址?
有很多“变量”可用,这应该打印当前 URL(没有任何脚本):
<div>{{canonicalurl:{{FULLPAGENAME}}}}</div>
http://www.mediawiki.org/wiki/Help:Magic_words