Perlmonks idea: Examine post code (view only)
tphyahoo
created: 2006-01-20 11:10:59
I had a simple idea that might enhance help new users learn perlmonks formatting. Have an "examine post source" link next to every post. This would of course be view only, not edit. But it would enable new users to quickly learn to use "code" and readmore, and the rest of it. Even after a year, there are some forms of markup that slip my mind: eg, how to do open and close angle brackets, and references to the perl documentation. If there was a link to every post, you could learn this a lot faster and organically.

Just thought I'd through that out!

Re: Perlmonks idea: Examine post code (view only)
created: 2006-01-20 11:16:27

There's an "xml" view link above every node.

Re^2: Perlmonks idea: Examine post code (view only)
created: 2006-01-20 11:32:44
But that will report the text with entities already escaped. I think he wants the "source" of each post exactly like the author sees it...
Re: Perlmonks idea: Examine post code (view only)
ww
created: 2006-01-20 11:33:50
re "view xml":
This node contains a random sample of pm formatting

this is code...line 1
and line 2...
and a last line of 'code'

[ inside (non-linking) square_brackers ]:

and inside [id://524496] brackets linking to an op (not selected for relevance)

Now, scroll up to the top of this page and try the xml link
(:<{)
Re^2: Perlmonks idea: Examine post code (view only)
created: 2006-01-20 14:38:37

Thats a bug. Its not clear where from but I intend to find out.

---
$world=~s/war/peace/g

Re^3: Perlmonks idea: Examine post code (view only)
ww
created: 2006-01-20 15:13:14
........erhhhhh

/me seeks mechanic for adjustment of brain.

ABSOLUTELY! Dear, gentle future readers: please note demerphq's wisdom and if you wish to see the xml of the sample stuff above, please view the thread, not the node.

RULE NUMBER 1: Think, rethink, twist ambiguities around in you mind... and THEN, AND ONLY THEN (after after thinking some more) speak!

Re: Perlmonks idea: Examine post code (view only)
created: 2006-01-20 11:41:34

Occasionally I've desired this for a better quoting. Generally I just copy and paste with the mouse. Personally I don't see any particular risk with such a thing in any case, since what gets written in the code source is public in any case - that is: I know about e.g. tags, but they can be revealed anyway. I can live without this feature, but it wouldn't be bad to have it available...

Re: Perlmonks idea: Examine post code (view only)
created: 2006-01-20 13:22:28
i would like this feature, mainly for quoting. if i quote text wich contains tags, i can't copy them.
cool would be a button beside the 'preview' button that inserts the original text into the textarea with 'blockquote' tags around.
Re^2: Perlmonks idea: Examine post code (view only)
created: 2006-01-20 16:21:24

Here’s a tip: in Firefox, you can select something on the page, then pick “View Selection Source” from the contetx menu, and you’ll get a source view window where the bits you selected on the page are also selected. Nice and easy for copying.

Makeshifts last the longest.

Re^3: Perlmonks idea: Examine post code (view only)
created: 2006-01-21 07:11:38
you mean if i view the source of a post with firefox i can see tags like <code> and <spoiler>? how would firefox know about these tags?

if somebody posted:
post-increment <code>$i++</code> is blahblah
i would like to copy & paste exactly this source.

Re^4: Perlmonks idea: Examine post code (view only)
created: 2006-01-21 09:42:15

I didn’t say that. It’s just a way to get marked up text, and even if you have to change one or two tags from raw HTML to their PM equivalents, that’s much less painful than it would be to copy-paste only text and mark it up from scratch. For cases where you’d have to fix up a lot of markup, the extra step of going through the XML displaytype pays off.

Makeshifts last the longest.

Re: Perlmonks idea: Examine post code (view only)
created: 2006-01-22 06:27:59
I had quite some time ago planned to have a displaytype=bare that would do that. Maybe I should get back to it.
Re^2: Perlmonks idea: Examine post code (view only) ('bare')
tye
created: 2006-01-22 12:15:16

'bare' is already assigned and it isn't a displaytype, so let's not overload that term.

Besides, 'bare' doesn't fit well. 'source' would be better. Or 'input' or 'asentered' or 'rawtext'...

Note that whether you get nodelets etc. around this would be separately controlled (by 'style=bare' or not).

- tye        

perlmonks.org content © perlmonks.org and ambrus, Aristotle, blazar, demerphq, tinita, tphyahoo, tye, ww, ysth

prlmnks.org © 2006 edmund von der burg (eccles & toad)

v 0.03