User Name
Password
AppleNova Forums » Programmer's Nook »

Back to Mac from PC, HTML/PHP Editing Options?


Register Members List Calendar Search FAQ Posting Guidelines
Back to Mac from PC, HTML/PHP Editing Options?
Thread Tools
Mr Ten
Member
 
Join Date: Oct 2005
 
2005-12-01, 05:39

I used to use Notepad on PC to program php and html, now using text edit.

In various instances (ie: e-marketing items), when special characters are pasted into TextEdit (extended hyphens, smart "quotation" marks and apostrophes) and then uploaded to a server, they can appear to be either errors / gray blocks, or disappear all together. Also, you can't view the source of the file online (on a PC that is).

What's recommended as far as an editor that can help clean this up and ensure that everyone is seeing things properly? I did a 2 second glance and saw Mozilla suite and TacoHTML, didn't get them yet. I also have CS2 Premium so I have GoLive, if that helps. Please advise.

Thanks for you help!

...running new osx on a dual-core 2ghz ( not a quad whore )
  quote
Brad
Selfish Heathen
 
Join Date: May 2004
Location: Zone of Pain
 
2005-12-01, 05:46

Quote:
Originally Posted by Mr Ten
special characters ... (extended hyphens, smart "quotation" marks and apostrophes) ... can appear to be either errors / gray blocks, or disappear all together.
BAD! *smack*

The Absolute Minimum Every Software Developer Absolutely, Positively Must Know About Unicode and Character Sets (No Excuses!)

W3C's HTML Document Representation
  quote
AsLan^
Not a tame lion...
 
Join Date: May 2004
Location: Narnia
 
2005-12-01, 06:38

Textwrangler might have the features you are looking for (something about converting to ASCII). I don't know enough about web publishing to comment on the rightness or wrongness of using proper codepages and I usually just go with the flow.

It seems to me that the preferred editors are jEdit and Textwrangler.
  quote
Brad
Selfish Heathen
 
Join Date: May 2004
Location: Zone of Pain
 
2005-12-01, 06:49

I think AsLan^ needs to read that bold link too.
  quote
AsLan^
Not a tame lion...
 
Join Date: May 2004
Location: Narnia
 
2005-12-01, 06:58

Quote:
Originally Posted by Brad
I think AsLan^ needs to read that bold link too.
I did ! (before posting even)

It was a very engaging article but at the end it seemed the author was saying make sure your html has encoding tags and if you are creating an app that parses text, be sure to remember that these days not all text is ascii.

I've had problems editing a text document in textedit, cutting and pasting it into a shell only to find that it's no longer "plaintext" anymore. Which is a little irritating.

EDIT: I just tried to replicate my previous experience with textedit and couldn't so I guess I've got the circumstances wrong. But I remember I did have a problem cutting and pasting with textedit once.
  quote
Brad
Selfish Heathen
 
Join Date: May 2004
Location: Zone of Pain
 
2005-12-01, 07:22

Quote:
Originally Posted by AsLan^
I've had problems editing a text document in textedit, cutting and pasting it into a shell only to find that it's no longer "plaintext" anymore. Which is a little irritating.
Then you forgot this little tidbit:
Quote:
Originally Posted by AsLan^
be sure to remember that these days not all text is ascii.


That applies everywhere, not just in web browsers. What's special about web pages is that you can explicitly define the character set after it has started to load by the browser. Other applications that accept outside input either use only a default encoding (bad!), try a "best guess" (like some web browsers), or allow the end user to define the character set.

The Terminal app? Yup, it allows you to choose the character set encoding. If it matches the character set of the text you copied from TextEdit, it should paste just fine. Otherwise, what TextEdit thinks is an "A" Terminal might, for instance, think is a "Ł" or a "ȉ" or a "Þ" or some other entity.
Attached Images
File Type: png Picture 1.png (32.8 KB, 5 views)

The quality of this board depends on the quality of the posts. The only way to guarantee thoughtful, informative discussion is to write thoughtful, informative posts. AppleNova is not a real-time chat forum. You have time to compose messages and edit them before and after posting.
  quote
AsLan^
Not a tame lion...
 
Join Date: May 2004
Location: Narnia
 
2005-12-01, 07:57

I hadn't realized that terminal had an encoding setting!

BTW I was able to replicate the problem I had before but I really don't know if it's encoding related because all the character should be in the 32-128 character set.

Not that this requires any troubleshooting or anything because I was just cutting a song out of a webpage to use as example text for some project I was working on.


  quote
ast3r3x
25 chars of wasted space.
 
Join Date: May 2004
Send a message via AIM to ast3r3x  
2005-12-01, 08:08

I guess this really requires proper HTML, but John Gruber from daringfireball.net has an addition to BBEdit that helps with quotation and such.

I'm referring to SmartyPants by the way.

Edit: I guess it also requires BBEdit
  quote
drewprops
Space Pirate
 
Join Date: May 2004
Location: Atlanta
 
2005-12-01, 09:47

Only a matter of time before someone lets on about SubEthaEdit. Let's see how long it takes before somebody tells you about that one.

Yep. Let's see.


Edit: Oh wait, it has collaborative features as well?? Hmmmmm....

Steve Jobs ate my cat's watermelon.
Captain Drew on Twitter
  quote
rollercoaster375
Senior Member
 
Join Date: Mar 2005
Location: UIllinois (Champaign, IL)
Send a message via AIM to rollercoaster375 Send a message via MSN to rollercoaster375 Send a message via Yahoo to rollercoaster375 Send a message via Skype™ to rollercoaster375 
2005-12-01, 10:00

1. SubEthaEdit
2. Sumultron
3. TextMate
4. BBEdit
5. Text Wrangler

There are others, but those are the decent ones. (Not including Java Apps)
  quote
Brad
Selfish Heathen
 
Join Date: May 2004
Location: Zone of Pain
 
2005-12-01, 11:17

Since I didn't mention it before, I'll repeat the recommendation of the last two members. I use SubEthaEdit for the overwhelming majority of my coding. AppleNova? Yeah, all the HTML and CSS you see here that I've written or modified was done through SubEthaEdit.

SubEthaEdit is pretty feature-light, but that's why I like it. It's a simple text editor at the core, but it offers line and character numbering, syntax coloring, automatic line indention, bracket/parenthesis matching, and collaborative sharing/editing (although, I've never used this bit).

SubEthaEdit also plays very nicely with the smart FTP/SFTP clients like Transmit and Fugu that allow you to edit the file "directly" on the server. When I click "edit externally" in Transmit, for example, it downloads the file to a hidden temporary directory and opens it in SubEthaEdit. Any time I choose to save it, SubEthaEdit notified Transmit to upload and replace the old copy. I love that.

I don't like editors that try too hard to do my job. I especially hate editors that automatically insert an additional quote or parenthesis or bracket in anticipation of my next move. I already have the well-practiced memory muscle that instinctively taps return a few times, enters a closing parenthesis, and arrows back up, thankyouverymuch.

The quality of this board depends on the quality of the posts. The only way to guarantee thoughtful, informative discussion is to write thoughtful, informative posts. AppleNova is not a real-time chat forum. You have time to compose messages and edit them before and after posting.
  quote
rollercoaster375
Senior Member
 
Join Date: Mar 2005
Location: UIllinois (Champaign, IL)
Send a message via AIM to rollercoaster375 Send a message via MSN to rollercoaster375 Send a message via Yahoo to rollercoaster375 Send a message via Skype™ to rollercoaster375 
2005-12-01, 13:39

Automatic line indentation isn't as nice as it could be in most OS X programs. When working on a windows box, I use Maguma Open Studio. When you hit a close curly bracket the tab level goes down one. Saves quite a large amount of time.

(Side note, I use SubEthaEdit for the majority of my work, although not with the default syntax highlighting)
  quote
Mr Ten
Member
 
Join Date: Oct 2005
 
2005-12-01, 21:00

i hate editors and want something feature light. the syntax coloring, proper character display and line #'s are more than enough, i will try subetha out. thanks for the help, i really could've used it in today's hectic times of preparing 6 email campaigns being sent to 10 different lists!
  quote
Mr Ten
Member
 
Join Date: Oct 2005
 
2005-12-07, 20:29

text wrangler is what i'm using for now.

it cuts / pastes as is.
it straightens smart-quotes and apostrophes
it has the ascii table for me to find/replace items easy.

i thought i saw a table that shows a project outline (maybe another one?)

good for now, nice and simple.

thanks very much.
  quote
Radarbob
Member
 
Join Date: Feb 2005
 
2005-12-18, 17:29

I'm surprised BBEdit has not gotten more mention.

As a programmer's editor, BBEdit is peerless.

I code on PCs for a living and at one point I was bringing in my macintosh to use BBEdit for it's HTML capabilities. I particularly like how it can match html tags. Of course I did not ask permission to do this.
  quote
Posting Rules Navigation
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Post Reply

Forum Jump
Thread Tools
Similar Threads
Thread Thread Starter Forum Replies Last Post
Bring Back Mac OS Classic!!! Randycat99.org Apple Products 4 2019-07-29 22:33
Flash Back: We're Fighting Back For Mac! HOM General Discussion 22 2007-08-07 19:09
Mac mini accessory mania Robo Third-Party Products 9 2005-11-16 19:37
Think Secret opens the MWSF floodgates (iLife, mini Mac, iWork, flash iPod) Frank777 Speculation and Rumors 340 2005-01-11 18:00
From Mac to PC Luca General Discussion 45 2004-10-08 08:23


« Previous Thread | Next Thread »

All times are GMT -5. The time now is 05:02.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004 - 2024, AppleNova