html中的路径问题
在java.applet中的appletContext中的showDocument(URL url,String target)中的URL是怎么获取呢?我的几个网页在同一个目录下,怎么写这个的URL?----------------解决方案--------------------------------------------------------
getCodeBase
public URL getCodeBase()获得基 URL。这是包含此 applet 的目录的 URL。
返回:
包含此 applet 的目录的基 URL。
另请参见:
getDocumentBase()
[ 本帖最后由 lampeter123 于 2010-6-3 11:38 编辑 ]
----------------解决方案--------------------------------------------------------
恩,是那么回事,可是为什么我第一次使用getCodeBase()是错误的,我用了getDoucumentBase()也是错误的,可是用了getDoucumentBase()后在用getCodeBase()却是正确的,这是为什么呢?
----------------解决方案--------------------------------------------------------