WeBWorK Problems

Apostrophes in student answers

Apostrophes in student answers

by Paul Pearson -
Number of replies: 2
Hi all,

A webwork user recently emailed me with a problem about apostrophes in student answers on iPads:

Our students use iPads ... when they try and enter an answer like y', the iPad changes the font within WW to read some sort of special character and then WW doesn't recognize what was entered as y' or y'', etc. It seems to happen most with apostrophes. Have you had this experience, and do you know a workaround? I assume it's something with the font on the iPad ...

I replied:

The html character code for a standard single quote (which is a small vertical bar) is ' whereas a right single quotation mark (which looks like a comma) is ’ My best guess is that when the student types an apostrophe on their iPad, they're really typing a right single quotation mark. When this right single quotation mark gets sent to the webwork server, webwork does not recognize it as a standard single quote because it doesn't have the character code for a standard single quote.

I had a student from China who was entering answers into webwork using a non-standard character set on her laptop computer, and the webwork server was not able to understand her answers because it was using the standard character set. She was able to change a setting on her laptop so that it used a standard character set and then everything worked fine. I would imagine that a similar solution would work here, but I don't use iPads at all so I don't have any device specific advice to give.

I have a couple of questions for the forum:

1. (Client side, device specific solution) Is there a setting on the iPad that will change the character code from ’ to ' whenever a student types an apostrophe on their iPad? In other words, is there an iPad setting where the character set or the character mapping can be changed to solve this problem?

2. (Server side solution) Is there a webwork server solution to this problem that would take a student answer such as ’ and translate it into ' before the answer checker gets applied? This could either be a global solution (applied to all webwork problems) or a local solution (e.g., a custom answer checker in each problem that uses an apostrophe as part of the answer) or a locally applied solution (e.g., an answer checker flag translate_smart_quotes => 1).

Thanks in advance!

Paul Pearson
In reply to Paul Pearson

Re: Apostrophes in student answers

by Paul Pearson -
Update from the person who reported the problem to me:

I assumed it was something like that - I dug into it a bit more ... it looks like the best option for a fix at the moment is to go into your device's keyboard settings and turn off the iPad's "Smart punctuation" feature.

Settings -> General -> Keyboard -> turn off "Smart Punctuation."

But it's unfortunate it's an all or nothing sort of thing - there doesn't appear to be a way to just enter a vertical single quote versus a "smart" quote as iOS calls it - you either have to turn it ON or OFF for ALL apps. I think you could remap the key, perhaps, but same deal - it'd be remapped for EVERY app.

In reply to Paul Pearson

Re: Apostrophes in student answers

by Davide Cervone -
If you press and hold the ' key, you should get a menu above it that lets you select from the various smart and non-smart apostrophes. I was able to enter standard single quotes that way without turning off smart quotes everywhere.