Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^15: Making Perl Monks a better place for newbies (and others)

by pryrt (Abbot)
on Feb 05, 2020 at 18:19 UTC ( [id://11112443]=note: print w/replies, xml ) Need Help??


in reply to Re^14: Making Perl Monks a better place for newbies (and others)
in thread Making Perl Monks a better place for newbies (and others)

I know for a fact that these newline characters ... are being stripped.

No you don't. You just don't understand HTML.

This paragraph has ten newlines between the parentheses: ( ). But it doesn't render that way. It looks like a single space between the parentheses, like ( ).

HTML is newline agnostic -- or rather, it collapses 1 or more newlines into a single space when rendered. It's not perlmonks that strips the newlines; it's the rendering engine of your browser, in accordance with HTML specifications. If you disbelieve me, view source on my reply, which shows the newlines still exist in the raw HTML. (edit: Perlmonks doesn't strip them out; it send them to your browser, and your browser's rendering engine does the whitespace collapsing./edit) The same works on every HTML page on the internet; it's something I've known since I started hand-coding HTML in college in 1993. It's not something new.

PerlMonks is not content with p but also requires slash p surrounding each paragraph. This all becomes rediculous when posting from a mobile device, where these characters are unavailable. ... Sometimes I miss one or the other p and the whole post has to be fixed in preview. The implementation does not seem consistent, so I use br.

Yes, the HTML spec requires both opening and closing tags for the paragraph, as in <p>...</p>. And the perlmonks preview highlights when you miss one of them. But if you create the post with the missing </p> anyway, it will still render reasonably. For example, I will intentionally forget the closing p in this paragraph...

This paragraph starts with a new <p>, even though the previous paragraph didn't properly close with </p>. And it still renders. Perlmonks was just doing you the favor of showing your malformed HTML before you post; it's up to you whether to listen or not.

I agree that it would be nice if Perlmonks didn't require entry in HTML. (I tried the wikisyntax thingy some time ago, but I am a lot more used to markdown than wiki nowadays, and I'd really prefer if the input engine were Markdown-that-accepts-raw-html-when-I-want-control; but I don't have the skillset to make either a free nodelet hack, or join pmdev and dig into the source code and implement it, so I choose not to complain -- in open source, if I'm not willing or able to do it myself, I don't feel justified in complaining loudly.)

Replies are listed 'Best First'.
Re^16: Making Perl Monks a better place for newbies (and others)
by PerlGuy(Tom) (Acolyte) on Feb 05, 2020 at 20:09 UTC
    "If you disbelieve me, view source on my reply, which shows the newlines still exist in the raw HTML."

    I've been posting from a tablet or phone, most days, which don't have "view source", but, on my computer now, I see, you are absolutely right!

    I certainly understand html ignores "return" or newline and other white space, I just never in a million years would have suspected that PerlMonks lets that pass through. I've never before encountered any forum software that did not do SOMETHING with the newline, either strip, or replace.

    But I would think that would make fixing the problem that much easier.

    Or not much more, if any more, difficult.

    Tom
      I just never in a million years would have suspected that PurlMonks lets that pass through. I've never before encountered any forum software that did not do SOMETHING with the newline, either strip, or replace.

      You know, for someone who's been a member here for over ten years, it sure seems like you've never read Markup in the Monastery or Writeup Formatting Tips.

        links for both displayed literally every time a user posts or replies...

        A reply falls below the community's threshold of quality. You may see it by logging in.
        > member here for over ten years,

        On a side note: do we monitor big amounts of failed login attempts?

        Like someone trying to take over an old account which hasn't been posting for ten years?

        Cheers Rolf
        (addicted to the Perl Programming Language :)
        Wikisyntax for the Monastery FootballPerl is like chess, only without the dice

      fixing the problem

      It's not a problem; it just means you have to write your posts in html.

        " ...it just means you have to write your posts in html."

        That's exactly the point. I'm often on the go and post to forums from an Android device, (tablet or phone) which are anything but html/code friendly. This is not a problem on any other forum, anywhere else on the internet. As someone stated years ago, in this or another thread on the subject. New users, even Perl programmers, may not be versed in HTML.

        It can be argued that they should be. But even so, who really prefers to type seven or eight characters of html for every paragraph break regardless of how versed they may be in html?

        Angle brackets and forward slash are not on a typical mobile device keyboard. That is, in part, an issue with Android I suppose, but should PerlMonks require new users to download a special keyboard app for their phones just to post here?

        The thread is about how to make the place easier to use for newbies(and others). Requiring that everyone use HTML does not seem very newbie friendly.

        Tom
          A reply falls below the community's threshold of quality. You may see it by logging in.
A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11112443]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2024-04-23 16:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found