I've always tried to specify the height and width attributes for img tags in HTML. Not for style reasons, but because the browser then expects the size of the image and can do page layout even before the image has finished downloading. From the HTML spec:
The height and width attributes give
user agents an idea of the size of an
...
Hi, I have a jcycle plugin on a number of divs which are testimonials. Basically I don't want to show the tag in the testimonial viewed in a block on the front page but rather I do want it to show on another page. So I want to add some jquery or another method that strips the img tags for the front page display.
Any ideas how to do th...
What is the best way to link to the icons of websites? Meaning, given a hostname, what src should I put in an <img> tag to link to the 16x16 icon?
I was just doing http://<hostname>/favicon.ico. It seems some .ico files aren't liked by different browsers. Chrome seems to like them all, but Safari, FF and IE all have problems with ...
The simplified version of the problem I am seeing in IE7 can be demonstrated using FireBug Lite.
On a page loaded with jQuery, I open FireBug Lite (via bookmarket) and I enter the following:
image = $('<img src="http://example.com/boofar.jpg" border="12"
width="95" height="95" title="Booya">')[0];
and the result...
I need to define an <img>'s src attribute in CSS. Is there a way to specify this attribute?
...
The thing im trying to do right now is pulling in multiple links from a textarea,
We can pretend that a user inputs c:\pics\img01.jpg and in the next row he'll have the next imglink.
I want to pull those links, I allready have the code for that:
var entered = $('#filedir').val();
var lines = entered.split(/\r\n/);
var opttext = "...
I am trying t o create img captions based on src value match.
JQUERY : What is the best way to extract "Author-ABC" from an img with src value wwww.abcd.com/images/imagename_Author-ABC_.jpg and replace the alt value with this value.
DRUPAL : Is there a way to preprocess this a drupal template function and save the value in img alt attr...
Hey Guys (and Ladies)
I am looking at getting the image name from an image with a src loaded dynamically.
Basically what I am doing is using the Google chat badge on a site to live chatting. And else where on the page, I have an image saying Live Chat:Online or Live Chat:Offline. And I want this to change depending on whether I am avail...
I have an image set by css style to 100x75. When it doesn't load, the alt text loads into the space, but expands the container to beyond 100px width.
How can I prevent this? Either by cutting it off or wrapping it.
...
I've tried some HTML DOM code from several sites, but it isn't working. It isn't adding anything. Does anyone have a working example on this?
this.img = document.createElement("img");
this.img.src = "img/eqp/"+this.apparel+"/"+this.facing+"_idle.png";
src = getElementById("gamediv");
src.appendChild(this.img)
But it isn't adding anyt...
Here's a webpage that does what I'm describing: http://mashable.com/2010/05/13/mobile-tech-journalists/
What's going on with the images? It seems that they get loaded and fade in as you scroll them into view.
Is there a name for this technique? Is it a new optimization technique? Where can I read more about it?
...
If you take the following image:
http://ecx.images-amazon.com/images/I/41uxky7oT8L._SL160_.jpg
place it in an html file with an IMG tag, then resize it to width 160 but do not set the height setting, and are on Firefox, you will see an ugly black line under the image.
For instance:
<img src="http://ecx.images-amazon.com/images/I/41u...
Given the following HTML:
<p>This is text and this is an image <img src="http://www.example.com/image.jpg" />.</p>
Is it possible to make the image render? When using this snippet: mContentText.setText(Html.fromHtml(text));, I get a cyan box with black borders, leading me to believe that a TextView has some idea of what an img tag is.
...
I can't get any images to show up when I'm using IE with these makeshift tabs I made, everything shows up and space is allocated for the image but the image doesn't show up when I change the class. I'm using the css property visiblity to make it work.
function findJournalId(d){
var parent=jQuery(d).parent(); ...
I use loadData method to load some html content into a webview, but when it encounters something like this :
<a href="http://www.anywebsite.fr/">some text</a><img src="http://www.anotherwebsite.fr/thewantedpicture" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" />
I only get this in t...
Basically, I am trying to put a semi-transparent div over an image to serve as a background for text for a slideshow. Unfortunately, the browser seems intent on always rendering the img over the background-image. Is there any way to fix this?
Here is my current CSS for the semi-transparent div:
#slideshow .info
{
height: 80px;
...
Hi,
This function is called when an up/down arrow is clicked to slide hidden div. If the div is hidden, the arrow points down and changes to up when the div is shown. If the div is shown, the arrow points up to hide div and changes to down when the div is closed. I just wanted to know if there was a more efficient way of doing this or...
So I have this php script that output an html table with data about some files (like filename, filesize, etc...)
I have this javascript function that displays the picture when you hover a tag belonging to the class "preview". For example, if a filename is: somePic.jpg, when you hover somePic.jpg in the table, the picture will appear nex...
We are using PD4ML library to convert HTML to PDF. Is there any way with which I can include a image from the internet in my HTML to convert it into PDF.
I am having problem in getting the image into PDF. I tried using base parameter in the PD4ML library but that didn't worked out.
May be I am doing something wrong or PD4ML doesn't suppo...
I have a html table with 3 rows and 1 column. In the top and button row I have images and in the middle row I have div.
Between my rows I see a separation (I see background of my page). I tried to set all padding and margins to zero (for tables, div and images) and I still have this separation. Can anybody, please, help me to solve this...