| | |
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?
[code][B].[/B]/calcAverage 5 8 1 4[/code]
Try not to bump 10 year old threads as it can be really annoying.
Like php then read my website at http://syntax.cwarn23.net/
Star-Trek-Atlantis - now that's what I call a movie ^_^
My favourite PC. - MacGyver Fan
Bad english note: dis-iz-2b4u
Like php then read my website at http://syntax.cwarn23.net/
Star-Trek-Atlantis - now that's what I call a movie ^_^
My favourite PC. - MacGyver Fan
Bad english note: dis-iz-2b4u
•
•
Join Date: Jan 2008
Posts: 3,810
Reputation:
Solved Threads: 501
•
•
•
•
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]
•
•
•
•
You can do [code=text] to disable syntax highlighting completely:
text Syntax (Toggle Plain Text)
./calcAverage 5 8 1 4
•
•
•
•
They're not even backwards compatible with the old language tags (cplusplus, csharp, etc)
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.
>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.
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.
"Technological progress is like an axe in the hands of a pathological criminal."
![]() |
Other Threads in the DaniWeb Community Feedback Forum
- Previous Thread: Nick Complete
- Next Thread: Avatar size limits
| Thread Tools | Search this Thread |







