godsent Posted July 2, 2013 Share Posted July 2, 2013 I've been reading about PHP developer interview questions. One of them was to ask person do design a most simple website using HTML code by hand writing. And it was said that if a interviewee writes something like <img src="someimage.gif"> it indicated that you can call next interviewee right now. So despite not being alt and title attributes what is wrong with using images in this way? Quote Link to comment https://forums.phpfreaks.com/topic/279784-why-this-is-wrong/ Share on other sites More sharing options...
Irate Posted July 2, 2013 Share Posted July 2, 2013 Depends. Does the interviewer require XHTML-conform syntax? Another thing, when creating a site, it is a good practice to create a subfolder for images. Quote Link to comment https://forums.phpfreaks.com/topic/279784-why-this-is-wrong/#findComment-1439077 Share on other sites More sharing options...
kicken Posted July 2, 2013 Share Posted July 2, 2013 I think more context surrounding the original claim is needed to determine why they may have said that. If for example, someone made their site design in Photoshop as an image, then just stuck one image tag in a HTML file and called that their design, obviously that is wrong and you shouldn't waste your time on that person. That's a bit of an extreme interpretation though so most likely that is not the issue. There are issues with the HTML being invalid due to missing required attributes, but whether that deserves sending the person on their way or not is up to how much of a stickler for details the interviewer wants to be I guess. A few possible negatives with that tag are 1) ALT is generally required per the HTML spec, and should be used for accessibility purposes (ie, screen-readers, text-only browsers) 2) A TITLE attribute is nice, not necessary though 3) A defined WIDTH and HEIGHT attribute are recommended for quicker page layout, not required though. Quote Link to comment https://forums.phpfreaks.com/topic/279784-why-this-is-wrong/#findComment-1439094 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.