Erlang Mailing Lists

Author Message

<  Yaws mailing list  ~  Sorry to be so picky...

LRP
Posted: Tue Jun 01, 2010 4:34 am Reply with quote
Joined: 08 Oct 2008 Posts: 8 Location: Boston, MA.
Hello,

Very small point, but I suggest yet another documentation fix...

At the bottom of page 11 of the Yaws documentation *.pdf, we find the line:

{html, io_lib:format("You say that you’re running ~p",

I would urge escaping the single quote as follows:

{html, io_lib:format("You say that you\’re running ~p",

Newbies like me need to learn good practice.

All the best (and thanks for providing Yaws and its documentation),

LRP


______________________________________

AUTHOR OF:

- Freein' Pancho - freeinpancho.com
- Aya Takeo on the web - ayatakeo.com
- Aya Takeo Vol. I - vol1.ayatakeo.com

_______________________________________



------------------------------------------------------------------------------

_______________________________________________
Erlyaws-list mailing list
Erlyaws-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/erlyaws-list

Post received from mailinglist
View user's profile Send private message
Guest
Posted: Tue Jun 01, 2010 8:56 am Reply with quote
Guest
On 06/01/2010 06:33 AM, lloyd@paisite.com wrote:
> Hello,
>
> Very small point, but I suggest yet another documentation fix...
>
> At the bottom of page 11 of the Yaws documentation *.pdf, we find the line:
>
> {html, io_lib:format("You say that you’re running ~p",
>
> I would urge escaping the single quote as follows:
>
> {html, io_lib:format("You say that you\’re running ~p",


I don't see the point, why quote when it's not required. Actually,
it's wrong to quote here.

Eshell V5.7.5 (abort with ^G)
1> "a'a".
"a'a"
2> "a\'a".
"a'a"
3>



/klacke

------------------------------------------------------------------------------

_______________________________________________
Erlyaws-list mailing list
Erlyaws-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/erlyaws-list

Post received from mailinglist
Guest
Posted: Tue Jun 01, 2010 2:17 pm Reply with quote
Guest
On 06/01/2010 03:35 PM, lloyd@paisite.com wrote:
> Hello,
>
>> I don't see the point, why quote when it's not required. Actually,
>> it's wrong to quote here.
>
>> Eshell V5.7.5 (abort with ^G)
>> 1> "a'a".
>> "a'a"
>> 2> "a\'a".
>> "a'a"
>> 3>
>
> Here is what I see if I run the code as presented in the documentation:
>
> You say that you’re running "Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.0.1Cool Gecko/2010021719 Firefox/3.0.6 (Debian-3.0.6-3)"
>
> When I escape the single quote, the string displays correctly.
>
> But if escaping is wrong, and the single quote displays garbage, what is right?
>
> I wouldn't have raised the issue if the string had displayed correctly.
>

Hmm, there is something else at play here. Single tick, doesn't have to be quoted
in HTML, there is nothing special about that char. And

<erl>
out(_A) ->
{html, "ab'cd"}.

</erl>

and

<erl>
out(_A) ->
{html, "ab\'cd"}.

</erl>


Produces exactly the same output, and display fine in the browser. Fishy !!

/klacke

------------------------------------------------------------------------------

_______________________________________________
Erlyaws-list mailing list
Erlyaws-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/erlyaws-list

Post received from mailinglist
Guest
Posted: Tue Jun 01, 2010 2:33 pm Reply with quote
Guest
2010/6/1 Claes Wikstr
Guest
Posted: Tue Jun 01, 2010 3:01 pm Reply with quote
Guest
On 06/01/2010 04:32 PM, Steve Vinoski wrote:

> I believe what Lloyd is seeing is just an artifact of copying and
> pasting from the PDF, where what visually looks like a single quote is
> actually this mess of characters:
>
> \342 \200 \231

Ahh, clever you.

/klacke

------------------------------------------------------------------------------

_______________________________________________
Erlyaws-list mailing list
Erlyaws-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/erlyaws-list
Post received from mailinglist

Display posts from previous:  

All times are GMT
Page 1 of 1
This forum is locked: you cannot post, reply to, or edit topics.

Jump to:  

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
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum