Fixing percent sign when posting code.
Hi,
This has been mentioned several times now but I'll bring it up again since it's still a big problem.
When posting code between code tags and including binary numbers like ADCON=101011 the forum tends to remove the percent sign and some of the digits. It doesn't happen all the time:
Code:
ADCON=%101011 'same as above
but it sure does happen a lot - for example here, here and here (and that's just the last couple days) but, for example, NOT in this post.
What is going on? This issue really needs to be looked into IMHO.
/Henrik.
EDIT: Look it happend to me in this post. The thing is that at first it was fine, then I went into EDIT the post and after "reposting" it i was messed up.
Re: Fixing percent sign when posting code.
Henrik, I edit your post and placed the missing sign.
How?
Simply by clicking the first A/A button on the edit window (Switch Editor to Source Mode).
Ioannis
Re: Fixing percent sign when posting code.
Hi,
Yes, it can be fixed by editing, editing and editing, switching between different modes and more editing - there really should be no need to.
And, even if you went in and added the % sign in my previous post there's still an issue with the lost digits.
Can the editors then be set to default to the correct mode? It seems that when first making the post it defaults to the one where % works (because at first it WAS there) but when editing posts it defaults to the one where % does not work (because after I edited my post it was gone).
People come here for help, they post their code for other members to look at and the forum messes it up. It gets hard for people to help. IMHO this is a real issue which has a bad impact on the usability of the forum.
/Henrik.
EDIT: Oh, look at my original post. Now the % sign and leading digits are gone from the text as well, not only the code window. It's just a mess this....
Re: Fixing percent sign when posting code.
Well, the default is WYSIWYG, and as I understand it this should show the % sign. So it is not very much what I see...
This is Lesters job and not moderators thing to mess.
Uers just have to remember click on the A/A button prior to write the message.
Ioannis
Re: Fixing percent sign when posting code.
Testing:
The above was written in the WYSIWYG editor which, at least for me, is the default editor when making a new post.
EDIT:
That showed up OK. Now I pressed Edit post, the editor looks different but the A/A button says Switch to Source mode so I guess I'm still in WYSIWYG mode.
EDIT2: And that messed it up.
2 Attachment(s)
Re: Fixing percent sign when posting code.
This is WYSIWYG mode:
Attachment 6529
And this is Source mode:
Attachment 6528
When the second is selected, the percentage sign is shown.
Ioannis
Re: Fixing percent sign when posting code.
At the top-right of the page, click on Settings.
In the My Settings section on the left, go to General Settings.
Scroll down to the "Miscellaneous Options".
For the "Message Editor Interface:" select the Standard Editor.
At the bottom of the page, click Save Changes.
Your default editor will now be "Source mode".
This could be made the forum default, but it would only apply to new users when they first join.
Each existing user will have to change the setting themself.
Depending on the forum permissions, this may not be available for everyone.
Please report if it is, or is not available to you.
Re: Fixing percent sign when posting code.
Thanks Darrel, it works fine.
Ioannis
Re: Fixing percent sign when posting code.
Thanks Darrel!
Just did that, now let's see what happensEDIT: The above looked fine when first posted. Now I'm editing the message, it still looks OK in the editor.
EDIT2: And after the edit it still seems to be OK. Lets hope everyone here sees this and make the change to their profile because more and more "messed up" code gets posted.
/Henrik.
Re: Fixing percent sign when posting code.
If required, i can set ALL users to default to the standard editor.
just let me know, if that's the group decision.
Re: Fixing percent sign when posting code.
Thanks Lester!
I'm just one member but I think it's a good idea doing that.
/Henrik.
Re: Fixing percent sign when posting code.
I vote to make it the default
Re: Fixing percent sign when posting code.
Also vote to make it default!
Re: Fixing percent sign when posting code.
Before I vote, what are the cons?
Ioannis
Re: Fixing percent sign when posting code.
Quote:
Originally Posted by
Ioannis
Before I vote, what are the cons?
Ioannis
The only con I see, is that the code posts won't be as neat, and will lose some formatting. But I think that sure beats losing content, like the first 2 msb after each % sign.
I think it all started when we had a wish for neat code ...... http://www.picbasic.co.uk/forum/showthread.php?t=15475
If we default all users to the standard editor, people that really loved the wysiwyg editor could still select it, making it a win/win.
Re: Fixing percent sign when posting code.
Test for code appearance
Code:
label:
for i=1to 10
k=k+1
next i
With a little more effort (selecting Courier New) I think code looks OK.
Ioannis
1 Attachment(s)
Re: Fixing percent sign when posting code.
Due to popular demand, Lester has changed everyone's settings to use the standard editor as default. The wysiwyg editor ("what you see is what you get" .... well almost!) can still be selected by those that want it.
The wysiwyg editor was cutting off the first two bits after each %. I think there were a couple of other odities as well. If you still with to use the wysiwyg editor, it is still available. Just click on settings, select general settings, and mark the box for the editor of your choice. If you want to keep the standard editor, of course, you don't have to do anything.
Attachment 6533
Re: Fixing percent sign when posting code.
It seems that the WYSIWYG setting has no affect.
The "Quick Reply" editor is always "Source Mode", and there's no button to switch to WYSIWYG.
But if you click the "Go Advanced" button, the editor is still in Source Mode, but there's a button for WYSIWYG.
It doesn't seem to matter which way the setting is.
Well, except for the "Basic Editor".
You don't want to select the Basic Editor.
So all in all, it works for me. :cool:
Re: Fixing percent sign when posting code.
Oops, I guess you're right. Currently you don't really get a choice, it just looks like you do.