【发布时间】:2015-10-26 05:41:49
【问题描述】:
在this 页面上,同一行上有两个“此处”链接,第二个无效。
我的 css 可以在 here 找到。我不确定为什么它与“标题”div 有什么不同,因为标题 div 中的链接即使在同一行上也能正常工作。
有问题的具体代码发布在下面。
CSS
#body {
line-height:1.5em;
width:700px;
margin:auto;
overflow-x: hidden;
padding:12.5px;
color:#4e443c;
font-size:16px;
font-family:"Courier";
text-align:left;
}
HTML
<div id="body">
<h3>Logger</h3>
Logger is a java library that allows you to log to a log file easily. <a href="Logger.jar">Download</a> <span> the .jar file and then add it to your build path.
For Eclipse instructions see <a href="http://stackoverflow.com/a/2727723">here</a>.
For command-line instructions see <a href="http://stackoverflow.com/a/2096298">here</a>.
Then add the code <i>Logger log = new Logger();</i> to your class to initialize the logger and then you can use either <i>log.log(String);</i> or <i>log.logAndPrint(String);</i> to print to the log.
The <i>logAndPrint</i> method prints to the console as well as the log file while the <i>log</i> method only prints to the file.
Below is an example driver program. <br>
<script src="http://gist-it.appspot.com/https://github.com/dummycode/Logger/blob/master/Example.java?footer=0">
</script>
<a href="/p">Back</a>
</div>
我尝试了不同的方法,例如 display:inline-block 或使用 span 标记,但其中大部分都弄乱了我的页面格式。
谁能帮帮我?
【问题讨论】:
-
请在您的问题下方查看我的回答。