Question:
what is the tag used in an html document to add pictures and hyperlinks?
anonymous
2009-10-11 03:13:26 UTC
want 2 make a webpage with pics n hyperlinks
Eight answers:
Shinchon
2009-10-11 03:19:10 UTC
You use the tag for images.



For example:





This would load a picture of a cell phone from the directory "images."



Hyperlinks are done with



For example:

Yahoo Answers

This would generate a blue hyperlink that said "Yahoo Answers" and would take you to answers.yahoo.com.



I hope this was helpful.
anonymous
2009-10-11 05:37:27 UTC
Hi Virajmata.



In HTML, images are defined with the tag.



The tag is empty, which means that it contains attributes only and it has no closing tag.



To display an image on a page, you need to use the src attribute. Src stands for "source". The value of the src attribute is the URL of the image you want to display on your page.



The syntax of defining an image:







The URL points to the location where the image is stored. An image named "boat.gif" located in the directory "images" on "www.w3schools.com" has the URL: http://www.w3schools.com/images/boat.gif.



The browser puts the image where the image tag occurs in the document. If you put an image tag between two paragraphs, the browser shows the first paragraph, then the image, and then the second paragraph.



Hyperlinks, Anchors, and Links

In web terms, a hyperlink is a reference (an address) to a resource on the web.



Hyperlinks can point to any resource on the web: an HTML page, an image, a sound file, a movie, etc.



An anchor is a term used to define a hyperlink destination inside a document.



The HTML anchor element , is used to define both hyperlinks and anchors.



We will use the term HTML link when the
element points to a resource, and the term HTML anchor when the elements defines an address inside a document..



An HTML Link



Link syntax:



Link text



The start tag contains attributes about the link.



The element content (Link text) defines the part to be displayed.



Note: The element content doesn't have to be text. You can link from an image or any other HTML element.



The href Attribute



The href attribute defines the link "address".



This element defines a link to W3Schools:



Visit W3Schools!



Regards.
AnnieEsq
2009-10-12 16:35:16 UTC
The others have it right, but here's some more detail.



ADDING AN IMAGE.



To add an image you type and the image name is usually within quotes. Use the full name, including the jpg, png or bmp extension Also most web servers need the name to be all lowercase, that is often the problem if the picture does not show up.



Make sure the image is either in the directory where your page is (then just use the name), or if in another directory on your same domain server, include that (i.e. images/imagename.jpg), or if on another site you need the full URL (http://www.domainname.com/imagename.jpg)



You can also add other controls such as height and width (if you want to make the actual picture smaller or bigger), border=[width of border], align=[left, right, or center] for horizontal alignment, valign=[top, bottom, center] for vertical alignment. The usemap lets you tie an image map to the image, so if people click different areas of the picture they get sent to different places or get different actions, a little more complicated. Here's an example of a more complex img code.







ANCHORS



You can put an anchor XXX around anything you want to link to - an image, a text word, a document on your server, etc. But the anchor has to also contain an "href" call that tells it where to send the visitor when it clicks the anchor word or image.



To put an anchor around an image you type



But in the first you have to add the source page or document. Here's an example of an anchor code with some additional controls:







The href is the page where the link will take the visitor when clicked and it is required. The rest of these are optional. The target is what browser opens; if you put no target it opens in the same window, if you use blank (like above) a new browser window opens and the original stays open as well. The title is what people see when the put their mouse over the link without clicking it.



Lots of online help on this. Search for html images and/or html image anchors or html anchors. And good luck.
anonymous
2016-04-07 08:58:23 UTC
I've had a look at the JavaScript in the URL you provide. It doesn't offer any functionality of linking the displayed image to the full image in a separate window. The script would have to be customised for your requirements - that means some HTML and JavaScript coding.
راشد ندیم
2009-10-11 03:20:14 UTC
for Link:

Link to Page 2



for Pic:

BodyByChocolates
2009-10-11 07:58:07 UTC
really is your answer.



However you can appeal even more to the search engines by adding a title tag to your links. Once the link is created just put the following code within it.



title="this is my title tag"



Be sure that the keywords you are targeting for that page are within your title tag info and voila - friendly search engine bait.



Cheers



The Body By Chocolates Man

WEB: http://BodyByChocolates.com

TWITTER: http://Twitter.com/BodyByChocolate
Kalyan IT World
2009-10-11 07:09:36 UTC
HI,



above said answer were correct if you want exact coding here the code







web development/programming







Please try like this


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...