New To Mac-Forums?

Welcome to our community! Join the discussion today by registering your FREE account. If you have any problems with the registration process, please contact us!

Get your questions answered by community gurus Advice and insight from world-class Apple enthusiasts Exclusive access to members-only contests, giveaways and deals

Join today!

 
Start a Discussion
 

Mac-Forums Brief

Subscribe to Mac-Forums Brief to receive special offers from Mac-Forums partners and sponsors

Join the conversation RSS
Web Design and Hosting Creating sites, scripting, and hosting discussions.

very basic web help


Post Reply New Thread Subscribe

 
Thread Tools
gravitate

 
Member Since: Nov 06, 2008
Posts: 120
gravitate can only hope to improve

gravitate is offline
I know on a pc you can write html code in note pad, save it as html document and then open it in a web brouser to see how it looks.

I tried doing this on by writing html code in textedit, saving as an html and then opening it in safari but nothing shows at all or if i save it in other formats then you can see the tags from html code. please help me where I am going wrong. I want to start writing code on my mac
QUOTE Thanks
louishen

 
louishen's Avatar
 
Member Since: Oct 22, 2007
Location: London
Posts: 8,951
louishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant futurelouishen has a brilliant future
Mac Specs: Mac Mini Core i7 2012 | White 2009 MacBook 2 Ghz | 733 Mhz G4 Quicksilver

louishen is offline
Are you saving the file as a text file or leaving it to the defauly RTF dormat

Any way Text Wrangler from bare bones is a better text editor, especuially for html code

Bare Bones Software | TextWrangler

Member of the Month September 2008 & August 2012 | Found advice useful? use the rep system
QUOTE Thanks
gravitate

 
Member Since: Nov 06, 2008
Posts: 120
gravitate can only hope to improve

gravitate is offline
well regardless of what I do now how do I do it so I can see it on safari when I open it?
QUOTE Thanks
kousik

 
kousik's Avatar
 
Member Since: May 04, 2009
Posts: 21
kousik is on a distinguished road
Mac Specs: Model: Macbook; Processor: Intel Core 2 Duo (2.4GHz); RAM: 2GB (DDR3); Video memory: 256MB

kousik is offline
After entering your HTML code in TextEdit, click on "save as" from the "File" menu. Uncheck "Hide extension" at the left bottom left corner and type the name of the desired filename at the top with the ".html" extension (I tried saving the file with UTF-8 encoding, and it worked perfectly).

If safari is not your default browser, then secondary click (command+click) on the file that you just saved and chose "safari" from the "Open with" menu.

System specs: (1) 13" Macbook Aluminum Unibody (OSX 10.5.8, Darwin 9.8.0, Intel Core2 duo 2.4GHz, 2GB 1067MHz DDR3 RAM, NVIDIA GeForce 9400M) (2) Dell Inspiron 6000 (Intel Pentium M 1.8GHz, 2GB DDR2 SDRAM) -- triple booting with Puppy Linux 4.31, Kubuntu 9.10 and Windows XP Home.
QUOTE Thanks
gravitate

 
Member Since: Nov 06, 2008
Posts: 120
gravitate can only hope to improve

gravitate is offline
Quote:
Originally Posted by kousik View Post
After entering your HTML code in TextEdit, click on "save as" from the "File" menu. Uncheck "Hide extension" at the left bottom left corner and type the name of the desired filename at the top with the ".html" extension (I tried saving the file with UTF-8 encoding, and it worked perfectly).

If safari is not your default browser, then secondary click (command+click) on the file that you just saved and chose "safari" from the "Open with" menu.
I tried this and open with safari and it shows all the html tags. I dont understand it.
QUOTE Thanks
kousik

 
kousik's Avatar
 
Member Since: May 04, 2009
Posts: 21
kousik is on a distinguished road
Mac Specs: Model: Macbook; Processor: Intel Core 2 Duo (2.4GHz); RAM: 2GB (DDR3); Video memory: 256MB

kousik is offline
Quote:
Originally Posted by gravitate View Post
I tried this and open with safari and it shows all the html tags. I dont understand it.
Could you post at least a small snippet of your code here?

System specs: (1) 13" Macbook Aluminum Unibody (OSX 10.5.8, Darwin 9.8.0, Intel Core2 duo 2.4GHz, 2GB 1067MHz DDR3 RAM, NVIDIA GeForce 9400M) (2) Dell Inspiron 6000 (Intel Pentium M 1.8GHz, 2GB DDR2 SDRAM) -- triple booting with Puppy Linux 4.31, Kubuntu 9.10 and Windows XP Home.
QUOTE Thanks
gravitate

 
Member Since: Nov 06, 2008
Posts: 120
gravitate can only hope to improve

gravitate is offline
sure I was just doing a very very basic code to see how to get started

<html>
<body>
<h1>
Hello. Does it work this time?
<h1/>
<body/>
<html/>




I keep trying but to no avail
QUOTE Thanks
kousik

 
kousik's Avatar
 
Member Since: May 04, 2009
Posts: 21
kousik is on a distinguished road
Mac Specs: Model: Macbook; Processor: Intel Core 2 Duo (2.4GHz); RAM: 2GB (DDR3); Video memory: 256MB

kousik is offline
There is a weird (?) thing about opening a file with ".html" extension using TextEdit --- it opens up as an HTML document (you're in a kind of WYSIWYG mode), but you really want to open it as a plain text in order to able to edit it using your own HTML tags. Here's a workaround:

1. Open TextEdit
2. Insert the above HTML code that you just posted
3. Go to format on the menubar and select "Make plain text"
4. Then save the file as "filename.html" using "Save as" option under "File".
5. Open "filename.html" with Safari.

I'm very sure that the problem you're seeing is because you're editing in HTML mode. So before entering your code make sure you are in the plain text mode. Let me know if it works. Good luck!

System specs: (1) 13" Macbook Aluminum Unibody (OSX 10.5.8, Darwin 9.8.0, Intel Core2 duo 2.4GHz, 2GB 1067MHz DDR3 RAM, NVIDIA GeForce 9400M) (2) Dell Inspiron 6000 (Intel Pentium M 1.8GHz, 2GB DDR2 SDRAM) -- triple booting with Puppy Linux 4.31, Kubuntu 9.10 and Windows XP Home.
QUOTE Thanks
JGruber

 
Member Since: Aug 20, 2005
Location: Redlands, CA
Posts: 739
JGruber has a spectacular aura about
Mac Specs: Macbook Pro 15" 2ghz/2GB/250gb/SD - White Macbook 2.16ghz/2.5GB/250GB/SD

JGruber is offline
Quote:
Originally Posted by gravitate View Post
sure I was just doing a very very basic code to see how to get started

<html>
<body>
<h1>
Hello. Does it work this time?
<h1/>
<body/>
<html/>




I keep trying but to no avail
Your coding is wrong to start with... here is how it should look.
PHP Code:
<html>
<
head>
</
head>
<
body>
<
h1>
HelloDoes it work this time?
</
h1>
</
body>
</
html
You have your "/" on the wrong side.
QUOTE Thanks
Aptmunich

 
Aptmunich's Avatar
 
Member Since: Mar 09, 2004
Location: Munich
Posts: 9,073
Aptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant future
Mac Specs: Aluminium Macbook 2.4 Ghz 4GB RAM, SSD 24" Samsung Display, iPhone 4, iPad 2

Aptmunich is offline
First: Stop using TextEdit (as others have said)

Next, this is the key if you must use TextEdit:
Quote:
3. Go to format on the menubar and select "Make plain text"
QUOTE Thanks
gravitate

 
Member Since: Nov 06, 2008
Posts: 120
gravitate can only hope to improve

gravitate is offline
Quote:
Originally Posted by kousik View Post
There is a weird (?) thing about opening a file with ".html" extension using TextEdit --- it opens up as an HTML document (you're in a kind of WYSIWYG mode), but you really want to open it as a plain text in order to able to edit it using your own HTML tags. Here's a workaround:

1. Open TextEdit
2. Insert the above HTML code that you just posted
3. Go to format on the menubar and select "Make plain text"
4. Then save the file as "filename.html" using "Save as" option under "File".
5. Open "filename.html" with Safari.

I'm very sure that the problem you're seeing is because you're editing in HTML mode. So before entering your code make sure you are in the plain text mode. Let me know if it works. Good luck!

sweet worked like a charm I am now going to try build a forum from scratch. bit stuck with the php at the moment though lol
QUOTE Thanks
JGruber

 
Member Since: Aug 20, 2005
Location: Redlands, CA
Posts: 739
JGruber has a spectacular aura about
Mac Specs: Macbook Pro 15" 2ghz/2GB/250gb/SD - White Macbook 2.16ghz/2.5GB/250GB/SD

JGruber is offline
Quote:
Originally Posted by gravitate View Post
sweet worked like a charm I am now going to try build a forum from scratch. bit stuck with the php at the moment though lol
That's a bit much isn't it? Not saying it couldn't be done, but that's a lot of PHP/mySQL coding.
QUOTE Thanks
gravitate

 
Member Since: Nov 06, 2008
Posts: 120
gravitate can only hope to improve

gravitate is offline
ya it is a lot but hey its my goal eventually as a project

hey I saved the tags and text in textedit AND OPENED IT IN SAFARI WHICH WAS GREAT BUT THEN WHEN I OPEN IT IN text edit it doesnt show the tags i.e. opens it as a web page. what is going on?
QUOTE Thanks
Aptmunich

 
Aptmunich's Avatar
 
Member Since: Mar 09, 2004
Location: Munich
Posts: 9,073
Aptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant future
Mac Specs: Aluminium Macbook 2.4 Ghz 4GB RAM, SSD 24" Samsung Display, iPhone 4, iPad 2

Aptmunich is offline
Quote:
Originally Posted by gravitate View Post
ya it is a lot but hey its my goal eventually as a project

hey I saved the tags and text in textedit AND OPENED IT IN SAFARI WHICH WAS GREAT BUT THEN WHEN I OPEN IT IN text edit it doesnt show the tags i.e. opens it as a web page. what is going on?
You probably need to switch to plain text mode again.

But seriously, stop using textedit for that type of work. Get one of the free programming text editors made for that type of work.
QUOTE Thanks
miles01110

 
Member Since: Mar 11, 2009
Posts: 469
miles01110 will become famous soon enough

miles01110 is offline
Quote:
Originally Posted by Aptmunich View Post
But seriously, stop using textedit for that type of work. Get one of the free programming text editors made for that type of work.
Like TextWrangler.
QUOTE Thanks

Post Reply New Thread Subscribe


« PHP experts anyone? | Pictures in HTML? »
Thread Tools

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread
Thread Starter
Forum
Replies
Last Post
Web Browsers novicew OS X - Apps and Games 80 04-10-2010 12:02 PM

All times are GMT -4. The time now is 10:03 PM.

Powered by vBulletin
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
X

Welcome to Mac-Forums.com

Create your username to jump into the discussion!

New members like you have made this community the ultimate source for your Mac since 2003!


(4 digit year)

Already a member?