我应该使用< br />在我的标记? [英] Should I be using <br/> in my markup?

查看:70
本文介绍了我应该使用< br />在我的标记?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果我想将某些内容移动到新行,我应该使用< br />,还是

有没有办法在CSS中执行此操作?


我只是在考虑是否可以在CSS中使用它会更好

,否则布局是标记的一部分。


干杯,

Lister

If I want to move something to a new line, should I be using <br/>, or
is there a way of doing it in CSS?

I was just thinking if it was possible in CSS then it would be better
as otherwise the layout is part of the markup.

Cheers,
Lister

推荐答案

lister写道:
lister wrote:

如果我想将某些内容移动到一个新行,我应该使用< br />,或者

有没有办法在CSS中执行此操作?


我只是想在CSS中是否有可能然后它会更好

,否则布局是标记的一部分。
If I want to move something to a new line, should I be using <br/>, or
is there a way of doing it in CSS?

I was just thinking if it was possible in CSS then it would be better
as otherwise the layout is part of the markup.



取决于上下文,很多时候< br(< br / xhtml)使用不当

其中有段落或边距和|或填充应该是

定义。你正在尝试的URL会有所帮助。

-

保重,


Jonathan

-------------------

LITTLE WORKS STUDIO
http://www.tittleWorksStudio.com


取决于上下文,很多时候< br( < br / xhtml)使用不当
Depends on the context, many time <br(<br /xhtml) is improperly used

其中有一个段落或者边距和/或填充应该是

定义的。您正在尝试的URL会有所帮助。
where a paragraph is intended or where margins and|or padding should be
defined. URL to what your are trying would help.



嗯,这是我正在写的东西,所以没有示例页面

呢。在这个特定的例子中,是将一些关于图像的描述性文本移动到图像下方的新行,而不是在它旁边显示

。我很欣赏< brcan被滥用于空白等等,但是

只是想知道它是否在整个NOWdays上都不满意。


感谢您的评论。

Well it''s something I''m writing at the moment, so no example pages
yet. In this particular instance is was to move some descriptive text
about an image to a new line below the image, rather than displayed
next to it. I appreciate <brcan be abused for whitespace etc, but
just wondered whether it was frowned upon altogether nowerdays.

Thanks for your comments.


Scripsit lister:
Scripsit lister:

在这个特定的例子中是移动一些描述性文本

关于图像到图像下方的新行,而不是显示旁边的

In this particular instance is was to move some descriptive text
about an image to a new line below the image, rather than displayed
next to it.



使用< brfor目的没有错,但使用< div> ...< / divfor

描述性文字更好。 < divmarkup意味着之前的换行符和

之后_and_它将其容器转换为一个元素,你可以设置样式。对于

课程,您经常需要使用类属性进行样式设置,例如: < div

class =" caption"> ...< / div> ;.


有关展示图片标题的其他选择,请参阅
http://www.cs.tut。 fi / ~jkorpela / www / captions.html

-

Jukka K. Korpela(Yucca)
http://www.cs.tut.fi/~jkorpela/

Using <brfor the purpose is not wrong, but using <div>...</divfor the
descriptive text is better. The <divmarkup implies line breaks before and
after _and_ it turns its container to an element, which you can style. Of
course, you would often want to use a class attribute for styling, e.g. <div
class="caption">...</div>.

For other alternatives on presenting image captions, see
http://www.cs.tut.fi/~jkorpela/www/captions.html

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/


这篇关于我应该使用&lt; br /&gt;在我的标记?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆