ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Commenting out Code in EE Templates?

May 19, 2008 9:42pm

Subscribe [8]
  • #1 / May 19, 2008 9:42pm

    StR@ng3r

    12 posts

    Is it possible to comment out EE Tags in EE templates?

    Let’s say for example I have an {embed=embeds/gu_mod_articles}tag. Is it possible to comment it out instead of deleting it?

  • #2 / May 19, 2008 9:45pm

    PXLated

    1800 posts

    Sure, just use the standard html comment code. <!—&—>

    Edi-Add: I believe there is a plugin also but I don’t seem to have a bookmark for it. The plugin removes all commented code from the source so it’s not even visible.

  • #3 / May 19, 2008 10:09pm

    stinhambo

    1268 posts

    What about using {!—instead of <!—

    This removes any trace of it in the source.

    I just cut and paste into the notes section to make the code easier to read. I can just cut and paste back in later!

  • #4 / May 19, 2008 10:13pm

    StR@ng3r

    12 posts

    thanks a lot, that helped.

  • #5 / May 19, 2008 10:16pm

    PXLated

    1800 posts

    Really-Cool
    Edit-Add: I have to may closer attention to the little things in the change logs :-(

  • #6 / May 20, 2008 1:47am

    Ingmar

    29245 posts

    Yes, since EE 1.4.2 (May 2006) we now have EE style comments 😊 Glad you found it.

  • #7 / Jan 02, 2009 1:57pm

    Todd D.

    460 posts

    I just cut and paste into the notes section to make the code easier to read…

    Out of curiosity, how does cutting and pasting into the notes section make the code easier to read? Is there a plug-in or something that will color code that area?

    The reason I ask, is sometimes looking at a large template… I wish there was an easier way to read the code. Line numbers and color coding would be awesome!

  • #8 / Jan 02, 2009 4:19pm

    grrramps

    2219 posts

    The reason I ask, is sometimes looking at a large template… I wish there was an easier way to read the code. Line numbers and color coding would be awesome!

    I don’t know how this would be done, but it would be WONDERFUL. Every template field should have line numbers and configurable color coding.

    And configurable buttons similar to the HTML buttons in EE.

  • #9 / Jan 02, 2009 8:50pm

    Joobs

    362 posts

    a text editor based template editor would be amazing.  You can of course save the templates as seperate files and edit them in your own editor but this is a bit more time consuming to make edits etc.

    A javascript solution to make the template editor might cause a few problems.  Can you get browser plugins that achieve the same effect?

  • #10 / Jan 05, 2009 2:41am

    asozzi

    262 posts

    You can use the firefox extension ItsAllText or use the javascript solution that I like to called EditArea.
    For EditArea you will need the plugin here (mind the small change needed explained down in post#14) and the javascript plugin found here.

    If you think of it….somebody probably already made it.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases