Re: Does Macintosh read uppercase?
From: Jim Fitzgerald (JimFitzgerald_at_discussions.microsoft.com)
Date: 02/25/05
- Next message: Tom Pepper Willett: "Re: FAQ"
- Previous message: Zackery: "FAQ"
- In reply to: Jim Carlock: "Re: Does Macintosh read uppercase?"
- Next in thread: Jim Carlock: "Re: Does Macintosh read uppercase?"
- Reply: Jim Carlock: "Re: Does Macintosh read uppercase?"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 25 Feb 2005 07:41:03 -0800
Thanks Jim, This will take a while to digest and implement. I do appreciate
your time and help.
"Jim Carlock" wrote:
> The following code should update textboxes on all browsers that
> support javascript. I've run into problems in the past trying to
> get collections of objects to work...
>
>
> <head>
> <script type="text/javascript"><!-- //Hide from older browsers
> var lngSelectedGood = -1;
> var lngUnitPrice = 0;
> var lngQty = 0;
> var lngTotal = 0;
> function fClearForm(form) {
> form.txtUnitPrice.value = "";
> form.txtQty.value = "";
> form.txtTotalPrice.value = "";
> return;
> }
> function fGoodSelected(form) {
> var strTemp = "Blah!";
> //var coll = document.all.tags("SELECT"); //PROBLEM SOME BROWSERS
> fClearForm(form);
> //strTemp = coll(0).options[lngSelectedGood].text; // this works but not used anymore
> lngSelectedGood = parseInt(form.cmbSelectedGood.selectedIndex);
> //we are opting to to identify by using document.FORMNAME.objectname
> strTemp = document.Calculator.cmbSelectedGood.options[lngSelectedGood].text;
> // if you had a text box to display what was selected...
> form.txtSelectedGood.value = strTemp;
> fCalculate(form);
> }
> function fCalculate(form) {
> // someone types in a number
> lngUnitPrice = parseInt(form.txtUnitPrice.value);
> lngQty = parseInt(form.txtQty.value);
> lngTotal = lngUnitPrice * lngQty;
> return(lngTotal);
> }
> function fUpdateSCTFields(form) {
> //an array holds info loaded up from a database
> form.txtUnitPrice.value = parseInt(Goods[lngSelectedGood][0]);
> form.txtShippingCost.value = parseInt(Goods[lngSelectedGood][1]);
> return;
> }
> --></script>
> </head>
> <body>
> <form name="Calculator">
> <!-- The nice thing about combo boxes/list boxes denoted by
> The first item in the collection of <select> objects is this one...
> -->
> <select name="cmbSelectedGood" tabindex="0" onchange="fGoodSelected(this.form)">
> <option selected>Good #1</option>
> .... more options / asp script to load up from db...
> </select>
> <input type="text" name="txtQty" size="5" value="0"
> tabindex="1" MAXLENGTH="3"
> onchange="fQtyChanged(this.form)" /><br />
> <input type="text" name="txtUnitPrice" size="10" tabindex="12" disabled />
> </form>
>
> If you watch the flow of the code, I have one calculate function,
> and the onchange="" items inside the combo boxes (or
> listboxes) call functions to update disabled txtboxes <input> and
> in the end call the fCalculate(form) function to calculate. I
> shortened most of this code, but passing the form into the
> functions works very well, function0001(this.form).
>
> Also refering to document.FormName.objectName is a great
> easy way to reference the objects. But you'll need to tag each
> object with a name... (name="txtPrice"). The document is the
> global tag in JavaScript used to reference the whole HTML
> document. There is a form declaration (NOTE: the name is
> case sensitive in all browsers when referencing it in JavaScript).
> The Form Name is very important for all javascript code.
>
> I've ran into some problems with javascript collections in the
> past not working on NetScape browsers. That was a couple
> years ago.
>
> Hope that helps.
>
> --
> Jim Carlock
> Post replies to newsgroup.
>
> "Jim Fitzgerald" <JimFitzgerald@discussions.microsoft.com> wrote in message
> news:ADB88886-4A9E-4ABE-86B4-8C5641FF7410@microsoft.com...
> Again, thank you both for working on my problem.
>
> I think i may not have explained it correctly. The problem is not in
> passing the 1st and second forms data to the third form on the next page, but
> rather what happens when the data gets to the peregform.asp page.
>
> The page pe.asp has two forms, Form1 & Form2, which collect the district
> number and club name and pass it on to the third page peregform.asp. Since i
> don't have access to a Mac browser I have to guess at this, but I think that
> part works fine, since it is server-side scripting. At least it works in all
> cases where the Browser security is not set to "High".
>
> The problems on the peregform.asp page are these:
>
> 1. when someone chooses one of the first set of options, the correct amount
> for that option does not appear in the window. It should be either $250.00,
> or $240.00, or $190.00, depending on whether you pick the 1st, 2nd, or 3rd
> option. Additionally, if the 1st option is not chosen, then all of the
> fields in the President-Elects section should be disabled, but that is not
> being done on Mac browsers.
>
> The same is true of the second set of options. The amount does not show in
> the window here either. It should be $0.00 if the spouse is not registering,
> or is registering seperately, and it should be $190.0 if the spouse is being
> registered.
>
> If the spouse is not being registered, the fields that collect his or her
> name and club information are supposed to be disabled. Again this is not
> being done on the MAcs.
>
> The club and district number do not appear in the database on the Macs either.
>
> Finally the Total registration which is derived from option 1 & 2 is not
> being calculated at all.
>
> In some netscape browsers the district and club appear correctly on the
> form, but do not get posted to the database.
>
> Would you please fill out the forms and submit them usine IE. and then do
> the same thing with OSX and submit it.
>
> You can then look at the results at:
> http://www.rotary5830.org/Registrations/Bill/Reports/AllByDate.asp
>
> Thanks again,
>
> "Murray" wrote:
>
> > Using OSX (Panther), I was able to successfully navigate to the third form
> > with FF1/Safari 1.2.4/IE5.2x.
> >
> > The only thing I saw was a secure form alert from IE5 each time I selected
> > something from the first two forms.
> >
> > Seems to work OK for me.
> >
> > --
> > Murray
> > ============
> >
> > "Jim Fitzgerald" <JimFitzgerald@discussions.microsoft.com> wrote in message
> > news:7C7B6026-243C-407F-A140-11731403B2CE@microsoft.com...
> > > Murray:
> > > I have the web pages on a web server now, so you can look at them through
> > > any browser. You can't hurt it.
> > >
> > > Here is what you should do. Open this page. The page has two forms one one
> > > page. It loads pre-existing district numbers and club names, and then
> > > redirects that information to a third form on a seperate page, which
> > > should
> > > open automatically. It will in IE, so you will want to run it in IE to see
> > > how the scripts are supposed to run.
> > > http://www.rotary5830.org/Registrations/2005/pe.asp
> > >
> > > Most of the problems show up on the third (last) form.
> > >
> > > Thanks for any help you can give. This is so frustrating because it works
> > > so well on 95% of the registrations.
> > >
> > >
> > > "Murray" wrote:
> > >
> > >> > Macs seem to be reading the fields ok and most web Bots, but the
> > >> > javascript
> > >> > calculations and validations it seems to ignore. I am guessing that I
> > >> > will
> > >> > have to rename the fields and their references in the javascript to all
> > >> > lowercase and underscores.
> > >>
> > >> I doubt that is the problem. I think it's much more likely that the
> > >> scripting itself is overlooking something "Macintoshy".
> > >>
> > >> While I am not much of a scripter, others here are - you wanna post the
> > >> code, or a link to the page? If the latter, then I can examine it "in
> > >> Macinto" so to speak....
> > >>
> > >> --
> > >> Murray
> > >> ============
> > >>
> > >> "Jim Fitzgerald" <JimFitzgerald@discussions.microsoft.com> wrote in
> > >> message
> > >> news:A6EB17E4-F81F-4066-9B5D-A0243D2050F7@microsoft.com...
> > >> > Thanks Murry:
> > >> >
> > >> > I appreciate your taking the time to reply.
> > >> >
> > >> > Macs seem to be reading the fields ok and most web Bots, but the
> > >> > javascript
> > >> > calculations and validations it seems to ignore. I am guessing that I
> > >> > will
> > >> > have to rename the fields and their references in the javascript to all
> > >> > lowercase and underscores.
> > >> >
> > >> > Do you think that will solve the problem, or will it take some major
> > >> > changes
> > >> > to make it work? I can make the case-changes but I am not a
> > >> > programmer,
> > >> > but
> > >> > my son, who did the form for me is.
> > >> >
> > >> > "Murray" wrote:
> > >> >
> > >> >> Errr -
> > >> >>
> > >> >> Yes. No.
> > >> >>
> > >> >> --
> > >> >> Murray
> > >> >> ============
> > >> >>
> > >> >> "Jim Fitzgerald" <JimFitzgerald@discussions.microsoft.com> wrote in
> > >> >> message
> > >> >> news:C7B5B0EC-0B84-4719-845D-6E34A42A20BF@microsoft.com...
> > >> >> > Does Macintosh read upper and lower case scripts? I have a form
> > >> >> > that
> > >> >> > uses
> > >> >> > JavaScript to manipulate several fields. The field names are mixed
> > >> >> > upper
> > >> >> > and
> > >> >> > lowercase.
> > >> >> >
> > >> >> > Could that cause a Mac to ignore the scripts?
> > >> >>
> > >> >>
> > >> >>
> > >>
> > >>
> > >>
> >
> >
> >
>
>
>
- Next message: Tom Pepper Willett: "Re: FAQ"
- Previous message: Zackery: "FAQ"
- In reply to: Jim Carlock: "Re: Does Macintosh read uppercase?"
- Next in thread: Jim Carlock: "Re: Does Macintosh read uppercase?"
- Reply: Jim Carlock: "Re: Does Macintosh read uppercase?"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|