943,907 Members | Top Members by Rank

Ad:
You are currently viewing page 2 of this multi-page discussion thread; Jump to the first page
Sep 12th, 2009
0

Re: New Format - Code tag options

Yeah, I just tried that in the C++ forum. Tried to post this:


[code][B][/B]./calcAverage 5 8 1 4[/code]

It added the C++ code tags, I would imagine since there's nothing to be bolded. Stick an empty space in between the Bold tags and that has no effect. Stick a printable character in between the Bold tags and it has the effect you mentioned. What if you want nothing bolded, as I did not?

I like it better the old way, where nothing was assumed and language-specific code tags were added only at the poster's option. Gives you more control of the post. Worse, the changes are retroactive. Posts prior to the change have the syntax added where it wasn't intended. I'm seeing it all over the place. Here's one of my old threads, chosen at random, See the bottom part of post 1. Syntax has been added where none was intended, so it doesn't look very good.

http://www.daniweb.com/forums/thread147949.html

Can pre-change posts at least no longer be parsed this way? Check the post date and see if it was pre-change and parse it differently based on that?
The way I found best is by putting a dot between the [b].[/b] tags. So the following is an example of what your code should have looked like:

[code][B].[/B]/calcAverage 5 8 1 4[/code]
Sponsor
Featured Poster
Reputation Points: 410
Solved Threads: 258
Occupation: Genius
cwarn23 is offline Offline
3,004 posts
since Sep 2007
Sep 13th, 2009
0

Re: New Format - Code tag options

Click to Expand / Collapse  Quote originally posted by cwarn23 ...
The way I found best is by putting a dot between the [b].[/b] tags. So the following is an example of what your code should have looked like:

[code][B].[/B]/calcAverage 5 8 1 4[/code]
Yeah, I guess no one will notice a bold dot, so there are workarounds. I think it would be better to go back to the old way where nothing was assumed and you had to make it explicit.

Click to Expand / Collapse  Quote originally posted by John A ...
You can do [code=text] to disable syntax highlighting completely:
text Syntax (Toggle Plain Text)
  1. ./calcAverage 5 8 1 4
Thanks. I hadn't realized this. Good to know.

Click to Expand / Collapse  Quote originally posted by John A ...
They're not even backwards compatible with the old language tags (cplusplus, csharp, etc)
"Old" language tags? I remember about a year ago being told not to use [code=C++] when I was using it, but to use [code=cplusplus] instead. Are we not using [code=cplusplus] anymore? And if so, what are we supposed to use now? C++? CPP? cplusplus still seems to work.

These threads should probably be updated to explain the new rules in detail.

http://www.daniweb.com/forums/misc-explaincode.html
http://www.daniweb.com/forums/announcement8-3.html
Last edited by VernonDozier; Sep 13th, 2009 at 1:46 am.
Featured Poster
Reputation Points: 2614
Solved Threads: 687
Posting Expert
VernonDozier is offline Offline
5,375 posts
since Jan 2008
Sep 13th, 2009
1

Re: New Format - Code tag options

>Are we not using [code=cplusplus] anymore?
Nope. Apparently, now we're supposed to be using the name of the forum (for example, [code=c++], [code=c#], etc.).

>cplusplus still seems to work.
That's the thing. If you specify an "invalid language", the syntax defaults to the language of the forum. Which means that, for example, if I had posted code with the [code=cplusplus] tag in the Java forum (perhaps to illustrate differences in the language), the code will now be highlighted as Java. Which I find completely ridiculous.
Team Colleague
Reputation Points: 2240
Solved Threads: 338
Vampirical Lurker
John A is offline Offline
5,055 posts
since Apr 2006

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in DaniWeb Community Feedback Forum Timeline: Nick Complete
Next Thread in DaniWeb Community Feedback Forum Timeline: Avatar size limits





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC