This is a discussion on "Code for "<"" within the Web Page Design section. This forum, and the thread "Code for "<" are both part of the Design Your Website category.
|
|
|
|
|
![]() |
||
Code for "<"
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#21
|
|||
|
|||
|
One word - Validation
Once you learn to code by hand (in Windows Notepad if necessary) and not rely solely on WYSIWYG drag-and-drop web-building applications, you'll realise the depth of skill in professional web development and the reasons why your suggested fix is inappropriate. If your happy just pottering around creating amateur websites then your solution might be considered workable. |
|
#22
|
|||
|
|||
|
One word- Notepad....
By the way, most of my coding is hand done, no offense, but I am not stupid. haha. If you want to know why my websites usually look really cartoony, mainly cuase I am a NewB to software and stuff. But I know my coding pretty well, I don't know all of it by anymeans. Thats why I am here ASKING. Its a beautiful thing really. But yeah I agree, notepad is the way to go, and just for your information D3mon, Blockquotes work on all browsers!! so do <div> tags, and if you can't see them then you've done something to your browser, I have checked Opera, Netscape, Mozilla, IE, and Navigator, all of these work correctly. Netscape is 10-15 pixels off, but usually the whole thing is.... thats another story for another time. Cheers! But one more time, let me reiterte this point. I NEVER said it was the BEST way to go. I said it WAS a way to make it APPEAR normal. No offense, but either none of yall read anything, or you British people are weird. Let me explain this point of view by an American. If I say my way works, and it is a way of doing this, than you say, NO its not the best way!!!! well.. heres what I analyze of this... 1. Your a weirdo and dont understand American English, cause in American it means it works, but there are other ways. 2. Your a dumb person who just can't get anything anyways. 3. You dont read posts, except for the previous one, which can cause problems. So.. what are ya??? P.S.- IM a 2!!! |
|
#23
|
|||
|
|||
|
Oh yeah OK. I'm a dumb British wierdo. But it sounds like you've got problems of your own if you can't take advice.
|
|
#24
|
|||
|
|||
|
|
|
#25
|
|||
|
|||
|
<sigh>Here we go again!</sigh>
u2o |
|
#26
|
|||
|
|||
|
Stepping back... A final word if that is ever possible?
When you are coding HTML, if you ever use a < or a > character you should always use the correct HTML code, this also goes for any non alphanumeric characters. Example: < this will work on it's own, but as soon as you do a > the whole sentence will be processed and rendered as... nothing. i.e.,
What could happen is: The browser processes the page, it intercepts a < and now starts looking for a terminating >, but one don't exist! So, it carry on looking but hits the end of the document with the final </body> tag. Your page shows everything up to th < character - There has been an error in the HTML code. This is why we should use HTML codes. In a nutshell, Use HTML codes, they don't get processed. - It's your webpage, they are your audience, it's your risk and your reputation. u2o |
|
#27
|
|||
|
|||
|
I'm slightly confused u2orange...
What was the point of using <blockquote> in your example? As far as I can see all it does is indent code? Does it actually do anything else? It certainly doesn't allow you to view < in the browser... The only way to do that is, as we have already established to use the html code thingy :razz: |
|
#28
|
|||
|
|||
|
The reason he used Blockquote is cause that is what I have always used instead of HTML code symbols (whatever they are called, I dont know, haha). Try a blockquote and put a < in it. It will show up. But what U2Orange pointed out, that if you close the tag in the quotes F.E.- <hello world how are you> then nothing will show up at all, but if you dont close it then you will see this in your browser. - <hello world how are you . Nicely pointed out U2, makes a lot of sense and I actually learned something. Thanks for the full explanation.
|
|
#29
|
|||
|
|||
|
Yes, but if you put a < in then you don't NEED blockquotes at all... it'll do it by itself...
|
|
#30
|
|||
|
|||
|
<blockquote> had nothing to do with it, it was only used in the example, but as I can see, it may have caused confusion. I was just trying to point out that you should not use < as a character, and should always use &lt;
Sorry for the confusion Glad you learned something kulegamr u2o |
|
#31
|
|||
|
|||
|
<blockquote id="quote"><font size="1" face="geneva, verdana, arial" id="quote">quote:<hr height="1" noshade id="quote">Originally posted by kulegamr
The reason he used Blockquote is cause that is what I have always used instead of HTML code symbols (whatever they are called, I dont know, haha). Try a blockquote and put a < in it. It will show up. But what U2Orange pointed out, that if you close the tag in the quotes F.E.- <hello world how are you> then nothing will show up at all, but if you dont close it then you will see this in your browser. - <hello world how are you . Nicely pointed out U2, makes a lot of sense and I actually learned something. Thanks for the full explanation. <hr height="1" noshade id="quote"></blockquote id="quote"></font id="quote"> Ok Kulegamr, you say you're here to learn stuff, so listen. I'll do this one more time. Doing blockquote and pre tags is doing NOTHING in regards to the format of the less-than and greater-than signs. In your example page that you linked to, if you remove the blockquote and pre tags, then it'll display exactly the same text (obviously in a different format) - but it'll still show the < and > the same. The blockquote and pre tags have NOTHING to do with how these tags are displayed. However there are occasions when just doing < and > signs isn't sufficient. This occurs when you have text between a less-than and more-than sign. <like this> <and like> <this> <also <like this>. If you paste that in to your example page - in a blockquote or pre tag if you so choose - you'll notice that it doesn't display. To get it to display, you need to replace these tags with & lt; and & gt; Infact, note that in the source of this page, all of the < and > have been converted. If you are writing server-side code that deals with user input (like on this site), on most occasions you should ensure the text is encoded for the reasons stated above. Phew. Are we all in agreement now? |
|
#32
|
|||
|
|||
|
You've actually put it quite nicely, but whether or not Kulegamr will understand is another matter entirely.
|
|
#33
|
|||
|
|||
|
OHHHHHHHH..... AHHHHHHH... I get it now.. He he. Wow, I never knew that it would do that before. That is completely new to me. So the tags I used dont do anything, I just thought they did... Wow, how dumb am I? <yall can answer if you want too>
So, blockquote and pre, dont do anything outside of change the layout/font of the text? |
|
#34
|
|||
|
|||
|
Precisely! Re-read the thread and you'll see why we were so confused with you!
|
![]() |
| Tags |
| code |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| code help please | lcsaeteurn | JavaScript Forum | 1 | Apr 30th, 2008 02:06 |
| code behind code doesnt work | skat | ASP.NET Forum | 4 | Feb 18th, 2008 10:05 |
| live search code and styleswitcher code | hebel | JavaScript Forum | 0 | May 12th, 2007 06:16 |
| Can somebody give me the code to hide the source code? | renren | JavaScript Forum | 7 | Mar 7th, 2006 12:27 |