Women Only Forumwhy | Register | Login
Active Topics | Blog | FAQ | Rules
Featured Favorite: Taipei Expat


Support all Forumosa's sponsors | Click here to see all our advertisers



Post new topic Reply to topic
 [ 16 posts ]  Search in topic: Go to page 1, 2  Next
Author Message
Taffy
 Post subject: Appeal to techies - simple program needed!
PostPosted: 08 Feb 2006, 10:58 
Offline
Immune to Breathalizers (jiǔ cèce bù chūlái)
Immune to Breathalizers (jiǔ cèce bù chūlái)
Forumosan avatar

Years of membershipYears of membershipYears of membershipYears of membership
Joined: 20 Oct 2005, 15:11
Posts: 2052
Location: Zhonghe: the Slough of the Orient
Great Britain
I'm hoping someone can help out with this as I have absolutely no knowledge of programming. I need a program (web-based?) to convert Tonally Orthographic Pinyin to tone-marked pinyin and vice-versa. I imagine it wouldn't be very difficult for someone with the relevant skills and I am very happy to provide a list of all the equivalents in both standard Hanyu Pinyin and TOP.

Ex: tā hěn


Top
 Profile E-mail  
 
ironlady
 Post subject:
PostPosted: 08 Feb 2006, 22:31 
Online
Former City Mayor (qiánrèn shìzhǎng)
Former City Mayor (qiánrèn shìzhǎng)

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 13 Nov 2001, 17:01
Posts: 4823
Location: A place where people can't sleep or teach English in McDonald's
He has the download link for this .php script; I've downloaded it, and maybe I can modify it, but it would certainly be faster for someone who actually knew what s/he was doing to do the modifications. It seems to be a simple search and replace going on, and that's something I should be able to handle maybe later this weekend or next week if I get out from under this pile of work.

Anyone?
It's just a matter of controlling the case of the output based on the Hanyu Pinyin tone mark or number (let's go with numbers at present, that's easier).
Heck, we could add a color-coding option while we're at it, if it's for output on a Web page...

Anyone? :(

_________________
Terry (e-mail: ironlady "little mouse" fanyi.com)
Professional Translator & Conference Interpreter and NYS Certified TPRS Chinese teacher
Join us on ChineseToWesterners, a Yahoo groups group of CSL teachers working to modify Chinese language pedagogy to better fit the needs of Western learners
...although his father beat him every day, wishing him to learn the speech of Ts'e, it will be impossible for him [at least using current methods]...-Mencius


Top
 Profile E-mail  
 
ironlady
 Post subject:
PostPosted: 08 Feb 2006, 22:39 
Online
Former City Mayor (qiánrèn shìzhǎng)
Former City Mayor (qiánrèn shìzhǎng)

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 13 Nov 2001, 17:01
Posts: 4823
Location: A place where people can't sleep or teach English in McDonald's
Actually (darn you, now you've got me thinking about how to script this function rather than getting my work done!! :fume: ), it should be easy to write a pinyin-with-tone-numbers to TOP script, becuase .php comes with automatic functions to uppercase the whole string, just the first character, etc.
Give me a couple of days (but, experts, PLEASE feel free to script this faster and better...)

_________________
Terry (e-mail: ironlady "little mouse" fanyi.com)
Professional Translator & Conference Interpreter and NYS Certified TPRS Chinese teacher
Join us on ChineseToWesterners, a Yahoo groups group of CSL teachers working to modify Chinese language pedagogy to better fit the needs of Western learners
...although his father beat him every day, wishing him to learn the speech of Ts'e, it will be impossible for him [at least using current methods]...-Mencius


Top
 Profile E-mail  
 
hypermegaglobal
 Post subject:
PostPosted: 09 Feb 2006, 02:56 
Offline
Scooter Commuter (qí jī chē shàng xià bān)
Scooter Commuter (qí jī chē shàng xià bān)
Forumosan avatar

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 09 Jun 2002, 16:01
Posts: 655
Location: Luxembourg
Is this working correctly: http://www.hypermegaglobal.net/TOP/input.htm ?

_________________
My silly blog * Chinese Romanization Converter


Top
 Profile  
 
ironlady
 Post subject:
PostPosted: 09 Feb 2006, 03:39 
Online
Former City Mayor (qiánrèn shìzhǎng)
Former City Mayor (qiánrèn shìzhǎng)

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 13 Nov 2001, 17:01
Posts: 4823
Location: A place where people can't sleep or teach English in McDonald's
wow!!!!!!

Only two things: the tone number 5 (some people use it for neutral tone) remains after the * is added to denote neutral tone, and the second tone in TOP is last letter capitalized ,all others small (right now it's first small, others cap).

Can you share the source? I'd love to learn just how you did that (and so fast!!!) :D (I'm just learning basic .php for my own and my husband's Web sites, so most of what I do is read, imitate and modify.)

_________________
Terry (e-mail: ironlady "little mouse" fanyi.com)
Professional Translator & Conference Interpreter and NYS Certified TPRS Chinese teacher
Join us on ChineseToWesterners, a Yahoo groups group of CSL teachers working to modify Chinese language pedagogy to better fit the needs of Western learners
...although his father beat him every day, wishing him to learn the speech of Ts'e, it will be impossible for him [at least using current methods]...-Mencius


Top
 Profile E-mail  
 
hypermegaglobal
 Post subject:
PostPosted: 09 Feb 2006, 07:27 
Offline
Scooter Commuter (qí jī chē shàng xià bān)
Scooter Commuter (qí jī chē shàng xià bān)
Forumosan avatar

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 09 Jun 2002, 16:01
Posts: 655
Location: Luxembourg
ironlady wrote:
wow!!!!!!


Thanks! :)

ironlady wrote:
Only two things: the tone number 5 (some people use it for neutral tone) remains after the * is added to denote neutral tone, and the second tone in TOP is last letter capitalized ,all others small (right now it's first small, others cap).


I think I fixed this now.

ironlady wrote:
Can you share the source? I'd love to learn just how you did that (and so fast!!!) :D


Of course! This should be downloadable (is that a word?):
http://www.hypermegaglobal.net/TOP/input.htm.txt
http://www.hypermegaglobal.net/TOP/makeTOP.php.txt

ironlady wrote:
(I'm just learning basic .php for my own and my husband's Web sites, so most of what I do is read, imitate and modify.)


This sounds very efficient, but isn't the best thing about programming that you're free to find your own solution and implement it? I must warn you, once you've seen my apporach, you can't unsee it. It's so terribly simple! ;)

Please have a good look at the very beginning of function NumberedToTOP where I define the arrays. Due to my puny knowledge of Chinese, there might be some mistakes or superfluous entries.

Furthermore, it's probably more user-friendly to have the form call itself (the result of the conversion would be shown on the same page as the input field).

Finally, as an alternative to computing $AllSyllablesAndTones every time the time the function is called, you could also output it in a way that matches PHP's array defining syntax ("ba"=>"ba*","ba1"=>"BA", etc.) and then simply define the array instead of computing it. Then you could tell people you spent a year writing the list of equivalents by hand. ;)

Any questions, don't hesitate to ask.

_________________
My silly blog * Chinese Romanization Converter


Top
 Profile  
 
Taffy
 Post subject:
PostPosted: 09 Feb 2006, 10:51 
Offline
Immune to Breathalizers (jiǔ cèce bù chūlái)
Immune to Breathalizers (jiǔ cèce bù chūlái)
Forumosan avatar

Years of membershipYears of membershipYears of membershipYears of membership
Joined: 20 Oct 2005, 15:11
Posts: 2052
Location: Zhonghe: the Slough of the Orient
Great Britain
HMG, you are a :star:

Thank you, thank you.

As already stated above, I know absolutely nothing about programming in any form. I had a look at the source code and it's all Greek to me. However, in the fields at the beginning, a couple of things could do with being adjusted:

'


Top
 Profile E-mail  
 
ironlady
 Post subject:
PostPosted: 09 Feb 2006, 22:54 
Online
Former City Mayor (qiánrèn shìzhǎng)
Former City Mayor (qiánrèn shìzhǎng)

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 13 Nov 2001, 17:01
Posts: 4823
Location: A place where people can't sleep or teach English in McDonald's
Fabulous!!! :notworthy: :notworthy:

I can't wait to dissect your code and learn about arrays...that's something I haven't yet touched in .php, but probably a very useful thing to know about!

How do you want to handle this -- I can put the script up on my own Web site and give you a credit/link, or do you want to continue to have exclusive hosting rights to this (which will, given the hordes of people who love TOP, undoubtedly drive your traffic through the roof...)?

_________________
Terry (e-mail: ironlady "little mouse" fanyi.com)
Professional Translator & Conference Interpreter and NYS Certified TPRS Chinese teacher
Join us on ChineseToWesterners, a Yahoo groups group of CSL teachers working to modify Chinese language pedagogy to better fit the needs of Western learners
...although his father beat him every day, wishing him to learn the speech of Ts'e, it will be impossible for him [at least using current methods]...-Mencius


Top
 Profile E-mail  
 
hypermegaglobal
 Post subject:
PostPosted: 10 Feb 2006, 00:16 
Offline
Scooter Commuter (qí jī chē shàng xià bān)
Scooter Commuter (qí jī chē shàng xià bān)
Forumosan avatar

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 09 Jun 2002, 16:01
Posts: 655
Location: Luxembourg
Thank you, thank you, so much praise (also by PM), I'm not used to this! :oops: :notworthy: :lol:

Taifeitang, I'll modify the script later, thanks for the corrections and the beer/chocolate/pizza-offer! :)

Ironlady, you can just take the script and put it on your website or link to my site, whatever you want. I'll probably move the script to a more meaningful domain if I find the time this evening.

Anyhow, we still have to integrate the other romanization systems! Any good websites out there with lists of equivalents (sorry, I only know bopomofo myself)?

_________________
My silly blog * Chinese Romanization Converter


Top
 Profile  
 
hypermegaglobal
 Post subject:
PostPosted: 10 Feb 2006, 08:17 
Offline
Scooter Commuter (qí jī chē shàng xià bān)
Scooter Commuter (qí jī chē shàng xià bān)
Forumosan avatar

Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
Joined: 09 Jun 2002, 16:01
Posts: 655
Location: Luxembourg
OK, I uploaded the version with TFT's correction and also found this table:
http://en.wikipedia.org/wiki/Pinyin_table

So, the "initial+final+er combinations" are still missing, right? Or are they only needed for people speaking with Beijing accent? ;)

_________________
My silly blog * Chinese Romanization Converter


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic
 [ 16 posts ]  Search in topic: Go to page 1, 2  Next


Support all Forumosa's sponsors
Click here to see all our advertisers


Who is online

Forumosans browsing this forum: No Forumosans and 2 visitors


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum


I'm looking for someone who speaks between and years old (gender )
Forumosa Friends Login ID:   Password:   Remember login when I visit Forumosa Friends?  

SITE MAP

LIFE


Events Google Calendar
    Kaohsiung and Southern Taiwan
    Taichung and Central Taiwan
    Northern Taiwan ex-Taipei

Parenting
Dating & Relationships
Pets & Other Animals
    Rescues & Adoptions

Cars & Motorcycles
Health and Fitness

Where Can I Find...? (WCIF)
Volunteering in Taiwan

Teaching English in Taiwan
    Seeking Substitute Teachers

Living in Taiwan
    Diskussion auf Deutsch

MOBILE FORUMOSA


MOB.forumosa.com (HTML)
M.forumosa.com (XHTML)
WAP.forumosa.com
TAPATALK RO (iTunes App)

LEISURE


Travel
Technology

Learning Chinese

Sports
    Cycling
    Martial Arts
Fun & Games
YouTube & Other Video Clips

Restaurants, Bars & Clubs
    Kaohsiung
    Taichung
The Food Forum

FORUMOSANS

Find a Forumosan

FORUMOSA SOCIAL

Facebook - be a fan!
Facebook - join the group!
LinkedIn - join our group!
LinkedIn - invite yourself!
Forumosa Friends

OUR TWITTER FEED

DISCUSSION


Women Only Forum read more
To access this forum, you must be a member of the Women's Forum Group. PM the moderator to request access

Business & Money
    Forumosan Business Directory

Culture & History
Religion & Spirituality
Arts & Entertainment

Taiwan Politics (TP)
International Politics (IP)

Open Forum

Greater Forumosa
Where Forumosans who no longer live in Taiwan can compare notes, thoughts and impressinos

UCP- your User Control Panel
where you check PMs, update your profile, make your forum settings

SEARCH

Show search results as topics or posts
Active Topics
Topics with most recent posts

LEGAL


Human Rights
Dual Nationality
    Military Conscription
Visa & Residency Issues

Work
Taxes

Real Estate & Housing
General Legal Matters
    Certification
    Marriage
    Divorce

ABOUT


Feedback Forum
    Taiwanted
    Taiwanease
    Testimonials
The Temporary Forum

Rules

OUR BLOG


Classic Posts
Advertise
Sponsors
Favorites - link exchange

UNIVERSAL CURRENCY CONVERTER
Convert this amount
of this type of currency
into this type of currency.

enter any amount
Contact us if you want to add a currency to the list - admin (at) forumosa (dot) com

scroll down to see more currencies

scroll down to see more currencies

Universal Currency Converter under license from XE.com. Terms of Use
Forumosa Theme By Echo -=Designs By Echo=- © 2007 Echo
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
2,087,877 Views