开发者

Safari 5 Exentsions

I'm trying to teach myself Safari 5 extensions and I'开发者_Python百科m new to web development in general. Looking at the sample code, I see:

<!DOCTYPE HTML>
<script>
...
</script>

I'm just wondering, what language am I looking at? I see functions and code that almost looks C-like. Apple's documentation says it would be helpful to know HTML, javascript, CSS, and HTMl5 but I'm not sure what their samples are written in.


... is used in code examples as a placeholder, to say "insert more code here" - perhaps this is where you are confused? If you point us to the sample you are referring to, that may help to clarify.

If anything else looks unfamiliar - it may be "The Safari Extensions JavaScript API" which may contain some possibly unfamiliar looking JavaScript - from having a quick nose around - there doesn't seem to be any other technologies present.

<script> tags are used to allow inline javascript inside a HTML page - generally - w3schools is a good stop for concise explanations of HTML tags. <script> opens up the area in the page that will be interpreted as javascript code by the browser, while </script> signifies it has ended.

So the ... in this case is simply an indicator of where your custom JavaScript code should be.

The <!DOCTYPE HTML> is a HTML 5 doctype - 'an instruction to the web browser about what version of the markup language the page is written in'


From what I see, it's definitely mixed HTML5 and javascript.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜