5
Contributors
12
Replies
70
Views
4 Years
Discussion Span
Last Post by ~s.o.s~
Featured Replies
  • 1
    ~s.o.s~ 2,560   4 Years Ago

    [This snippet](http://www.daniweb.com/software-development/cpp/code/274075/all-permutations-non-recursive) without headers doesn't seem to have this problem. There is one more possiblity which I missed the first time: the OP might have actually posted the HTML escaped code snippet. I have posted a comment on that snippet thread; let's see what he has to say. Read More

  • 1
    Dani 1,638   4 Years Ago

    I have a bit of a headache and have been in and out of bed all day, so it's hard for me to concentrate on a code investigation right now :( With the particular code snippet being discussed here, the poster accidentally put the description in the code snippet place … Read More

0

The problem I believe is that special characters like < and > don't require conversion to their HTML entity counterpart when placed inside a pre since the rendering engine just "literally" evaluates them as opposed to recognizing the sequence and rendering it as the corresponding special char. Daniweb code snippet handling code seems to be converting the special chars to HTML entities which is not really required.

0

Other code snippnets render OK the only difference is the OP of that link I posted didn't include the standard #iostream headers.

1

This snippet without headers doesn't seem to have this problem. There is one more possiblity which I missed the first time: the OP might have actually posted the HTML escaped code snippet. I have posted a comment on that snippet thread; let's see what he has to say.

0

Could be... although that was three years ago so the new DW parsing engine might not have affected that.

That being said, it might be doing something funky if he is copying and pasting code from another app.

0

. . . There is one more possiblity which I missed the first time: the OP might have actually posted the HTML escaped code snippet. I have posted a comment on that snippet thread; let's see what he has to say.

Hi, "~s.o.s~".

I replied to you in that thread. And added another comment.

Also, yes, I did copy and paste from another app. I did a copy and paste from the Visual Studio 2012 IDE to a plaintext document (TextPad) to strip out all formatting. Then I did a copy and paste from TextPad to the Code Snippet window. But I don't think that is the issue. I follow this routine for almost all my writing--copying from a plaintext editor to ensure no weird behaviour--and it has worked out fine so far. And my other code snippet, for the Matrix Multiplication Program, appears just fine.

I guess we'll have to wait for some feedback from Dani, to know what may have happened.

Edited by DavidB

1

I have a bit of a headache and have been in and out of bed all day, so it's hard for me to concentrate on a code investigation right now :(

With the particular code snippet being discussed here, the poster accidentally put the description in the code snippet place and the code snippet in the description place. I reversed the two and must have / might have screwed something up in doing so.

Votes + Comments
finger-of-blame.jpg :)
0

What are the options for fixing it?
Should I re-post the original code in another post, same thread?
Could we delete the entire thread and I will create a brand-new one?
Do Mods have the capability to edit the code? Perhaps I could be made a Mod for one hour and then I could correct the code myself; it shouldn't take long.

0

If you can post the entire code once again in your code snippet thread, I can update your original post.

0

@David: I just tried posting your new snippet in the original post but it still doesn't work.

@Dani, this is something to look into. You can reproduce this by trying to update David's original code snippet based on his latest post.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.