how to attribute code from a website? - html

I found a website useful for designing my own site and took parts of the code to modify it for my personal use.I have added my content but parts of the html and css are from this original website.
do I attribute the work by providing a link to the original developer's page ? I've done so under the footer but was wondering if more is required to give proper credit.

You do so in whatever manner the license they gave you to use their code says you should, and you should ask the copyright holder if it is unclear.

Legally? It depends entirely on the license that the original author has decided to publish their work under. There are a multitude of open source licenses each with slightly different attribution and reuse requirements (even Stack Overflow)
Morally? That's entirely up to you. If you're using a substantial amount of code, a callout on the page may be appropriate. Maybe just a comment will do. Or maybe no attribution at all if the license (and your conscience) allows it.

Related

Will there be any problems if in my project, I use other sources like image from regular websites?

As title.
It is the safest if we go for searching free source and just use them, but it is not always the case that we can find the one that we want. If then, what will happen if I just use images from someone's website in my own project?
Images that you find on the web are licensed in one way or another, as a result it is important to understand the terms of that license.
This question goes over what you can do when your license is being infringed upon.
But from the phrasing of your question it sounds as though you are curious about what will happen if you just take images from other websites regardless of the licences on those images. In most cases, it is unlikely that much will happen as the content owner would have to be aware that you're using their licensed product. But that doesn't mean that you should.
If you were using licensed content and the content owner was aware, they have many options available, from requesting that you remove their content all the way to hiring a lawyer to pursue the issue.
I personally do not recommend just using content without knowing what license it is governed by. It is always better to ask permission first. That being said, Here is a link to a flow chart that may help in deciding if you should/can use an image from the web.

Is Viewing HTML Source Code Legal?

For learning purposes I want to view the html source of sites like amazon.com, ebay etc , After learning I want use it in my work, I don't want to copy and paste the html source.
Points to consider:
1. Hiding html source is unprofessional, here
2. Viewing HTML Source is safe for developers, here
3. All working web professionals do it for learning, here
So can i View HTML Source to learn css styles etc ? or should I get permission from website's owner ?
Any help would be great.
Client side code is always accessible publicly, viewing it or using it for learning purpose is absolutely fine. There is nothing illegal to that. However, if you are using the design of the any website or the part of website such as java-script or css, there should be a copyright notes; just read that once before using it. I don't think all java-scripts and css may have the copyright issues and you can also read the website policy before using it.
That depends.
If you live in the USA and circumvent a copyright protection system (however badly implemented) while viewing and using source code you broke the law. There are many other ways to break the law by misusing other peoples websites (like scraping, leaching, mirroring, hacking, etc). Search for "laws you break every day" and you will see how hard it can be to not break the law, but the rule of thumb is be a nice small fish and likely any laws you break people wont care enough to charge you with.
You can read a source, but you shouldn't use it if not allowed. If the source has a license, you should read it to know.
The HTML/CSS/Javascript code is loaded in your browser and you can watch it as many times as you want without any concern.
yup, it is 100% legal to view and use

Reserving space in html markup or adsense ads

Hey so this is really simple question, but for some reason I couldn't find an answer via google. I'm in the process of building a website (many things are still not functioning), but Im now adressing look and feel I would like have space reserved for adds in my php templates. Is it enough to just add a <div class='advertisement'> and use standard css to hold position?
(I know this will work for my purposes) Howver I am woundering if once google crawls my site in future will require less work to have add's displaying.
p.s. I have also readthrough google's guidlines on where add should be placed and hava a differnet look then rest of page Just woundering if I'm missing something.
If you use <div class='advertisement'></div> (with no content between the tags) and set the dimensions of the element in CSS, this is sufficient for reserving space, and Google sees it as empty (as it is) and ignores it, until you put some content there. There is no way, and no need, to inform Google about the future content of the page.
If you wish to insert some dummy content into the element, like “Advertize here” (which is really an ad of a kind) or “Reserved for ads”, that’s OK. It may help you during development and evaluation. Whether they are OK for real pages when launched needs to be considered carefully. But to search engines, that would be just content, and probably not relevant – it does not no much harm, but neither does it help. (We don’t expect people to search for such things, do we?)
#Mr.Alien comment is all I was really loking fir if google does not provide adds for testing... copy and pasted below
#brendanmorrison Keep sample banners with a text Advertise Here

Is there a name for this type of popular footer?

Screenshot of a footer:
I'm unsure if there is a particular name for that kind of footer or if it's a widget for a certain framework. That particular example was taken from buffalonews.com
After I know the name I can refine my searching for implementing it. Thank you for your input.
I believe the name you're looking for is a Site Map Footer. This is common now-a-days to display the contents of the site to the user while also offering crawlers direct links to content pages.
The key here is to display pages that are relevant/important to the user without inundating them so many links they can't figure out where to go.
The part that lists the content of your website is called "sitemap" AFAIK
Looks like a fairly common set of copywrite notices.
There is no standard widget or way to present this, apart from legal requirements (which may vary depending on where the site operates from).
I don't think there is actually a name for this king of footer though I agree it is quite common.
Maybe it is because this "kind" is very subjective and would have to be very specific and most of the times not helpful. (Or maybe because nobody has coined it yet) :)
Look at Brad's answer
If you have wordpress you could see some here for inspiration. In wordpress and the popular CMS you can change the footer for many available ones.

Focussing on Style Sheets and Cross Browser Compatibility

Let me begin this topic by explaining my background experience with web design. I have always been more of a back end programmer, with PHP and SQL and things. However I do have a shallow background with HTML and CSS. The problem is, I don't know it all. What I do know is, when it comes to designing (not back end dirty work) I understand basic CSS properties and I also understand HTML and I can usually throw together a sloppy web page with the two and a couple bazillion DIV tags.
Anyways..
The problem I always have encountered is that when I design a website in a browser such as IE7 (and then it looks perfect on IE7), and then look at it on IE8 or IE6 or Mozilla (etc.) it gets all spacey and ugly and looks totally different than the way it should look on IE7.
Question one:
Basically, what I am asking everyone is what route should I take to learn how to properly build the website? Build as in put it togehter with CSS standards and HTML standards that will make my site look the same on every brwoser. (Not only learning standards but where can I learn to properly write my code?) Where is a strong free resource I can use to learn how to these things?
Question two:
How do I properly code my website? Do I use all external style sheets to make dynamic page design simplistic or do I hard code some things into the DIV tags on each page? What is proper?
Oh, and if anyone has any tutorials on how to properly design a complete layout feel free to throw it in a response somewhere.
Thank you for taking the time to read my questions, and hopefully you will understand what I am trying to get out to everyone. I need to get on the right route of the designing side of web programming so that I will know how to create successful websites in the future.
Thank you,
Sam Pardee
First, I recommend NOT starting with IE as your "development" browser. Start in Firefox, say (which gives you the advantage of tools such as Firebug and the web developer toolbar), and then get it right in IE afterwards.
Second, definitely user external style sheets; it results in much cleaner code and a much simpler way to make style updates. Definitely recommended. Also external CSS files can be cached by the browser, so they won't increase the page download size as users go from page to page in your site or application.
Lastly, start by defining your content using simple HTML, basing the structure on the meaning of the content (often called "semantic" HTML), not on how you want it to look. Use a <ul> tag for something that is a list of items, for example, even if you don't want to display it as a "bullet list" (the default styling for <ul>). Then start adding styles to make it look right. This will result in very clean HTML that can support a variety of formats and layouts (take a look at CSS Zen Garden to see what I mean) and will also help push you towards a layout that reflects the structure of your content, which will be easier to read and comprehend.
In terms of books, you can't go wrong with Eric Meyer. HTML is easy, of course, and I don't recommend doing fancy stuff with HTML, so put your learning effort into CSS (Eric is the CSS guru).
Cross-browser compatibility is always an issue. It's a staple of web development, sadly, and there is no magic bullet. Luckily, the main offender, IE6, is finally starting to fade.
A1.
When starting work on a new site, first take every piece of content that needs to be on the page and paste it into a text file. Then put it in a rational order (thinking "If I had to use a text browser to use this page, how would I want it to be arranged...").
Then start wrapping HTML tags around each piece of content. For each piece, think "What type of information is this?" A heading? h1/h2/etc tags. A paragraph? A quote? A table? p,quote,table. Essentially, use HTML tags that describe what kind of information each piece of content is. When I do this, I pay no attention to how it actually looks in the browser at this point.
Once the content is all marked up, begin writing the CSS. If at all possible, try not to touch the markup during this step. Sometimes that isn't possible, though, and throwing a div or span around some elements is unavoidable. The less meaningless markup, the better.
In my experience, this approach keeps things very clean and tidy, and makes debugging layout issues a lot easier.
A2.
Building the styles into your markup using the "style" attribute is fine for prototyping, but beware, the temptation to leave them there once it works is strong. The best practice is to have all of your styles in external stylesheets. I'm interested to hear any alternative viewpoints.
Some great web standards/CSS resources:
http://www.csszengarden.com/
http://www.alistapart.com/
http://www.thenoodleincident.com/
http://www.quirksmode.org/css/contents.html (useful reference for selector-compatibility)
http://centricle.com/ref/css/filters/ (good reference for css hack compatibility)
http://www.zeldman.com/
http://meyerweb.com/
Hope this helps!
There are TOO many site out there that have really great tutorials for HTML and CSS. They will give you all of the information you are asking for. I would start doing some reading of the great gurus of HTML/CSS:
Simon Collison
Andy Budd
Molly Holschzag
Dan Cederholm
Jason Santa Maria
Eric Meyer
Jeffrey Zeldman
Cameron Moll
Any book or article you can fond from these folks will steer you in the right direction; you can't go wrong!
As for sites that will give you the proper methods/concepts/training for web standards compliant sites:
http://www.w3schools.com/default.asp
http://www.webstandards.org/
http://www.smashingmagazine.com/
http://www.webdesignpractices.com/
http://www.designmeltdown.com/default.aspx
http://www.cameronmoll.com/
http://www.alistapart.com/
http://www.cssnewbie.com/
http://www.css3.com/
http://htmldog.com/
http://css-tricks.com/
http://simplebits.com/
http://www.colly.com/
http://glish.com/css/#tutorials
http://meyerweb.com/
http://jasonsantamaria.com/
The one of the best books I've bought so far to help with HTML and CSS coding PROPERLY is Beginning CSS Web Development by Simon Collison. Great, easy to understand, and not too slow. Great examples to follow along. After that, buy CSS Mastery - Advanced Web Standards Solutions, also by Simon Collison, and Andy Budd and Cameron Moll. This book gets you up to speed with some advanced techniques that you'll see on the many of the web sites right now, some of which were invented by the authors.