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.

ExpressionEngine tag in blog article

April 02, 2008 12:04am

Subscribe [4]
  • #1 / Apr 02, 2008 12:04am

    mogya

    11 posts

    Hi,all.

    How are you doing to write ExpressionEngine Tags in your blog entry?

    Today I wrote some sample code on my blog:

    =========
    BraBraBra….
    You can use {if} method like this:
    {if segment_2 == "category"}
    BraBraBra….
    =========

    When I published this blog article, all contents after this article disappered!

    I guess the reason is this tag is still alive…
    {if segment_2 == "category"}

    Then, how to KILL this tag? How to write sample ExpressionEngien tag code on my blog? Give me good idea!

  • #2 / Apr 02, 2008 12:56am

    Casey Reid

    82 posts

    If I follow what your asking, then one way you can include code in your blog posts is by wrapping them in an html code tag. Usually like this:

    
    
    ...code goes here…
    
    
    
  • #3 / Apr 02, 2008 1:00am

    Arun S.

    792 posts

    I’m also having a little trouble understand what exactly you mean.

    Are you closing the if statement?

    For example:

    {if segment_2 == “category"}  
        
    Content
    
    {/if}

    If you don’t close the if statement, sometimes it will kill the rest of the page.

  • #4 / Apr 02, 2008 1:06am

    Casey Reid

    82 posts

    Just as a follow up, you should be able to also use:

    [ code ]
    ... code here ...
    [/ code ]

    Use no spaces in the code tag though.

  • #5 / Apr 02, 2008 1:35am

    mogya

    11 posts

    Yes that’s I want to know. I got working by [ code][ /code]!

    but

     seems not working.
    
    for example, paste this code on your blog entry.
    
    <blockquote>This is first line.
    <pre><code>{ if segment_2 == "category" }
    

    This is second line.

    On my site, I can’t see “This is second line.” and after that.

    Anyway I’m fine to using [ code][ /code]. Thank you for helping!

  • #6 / Apr 02, 2008 10:37am

    mogya

    11 posts

    BTW, where can I found more imformation about this [ code][ /code]?

  • #7 / Apr 02, 2008 10:44am

    Ingmar

    29245 posts

  • #8 / Apr 02, 2008 8:54pm

    mogya

    11 posts

    Thanks!

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

ExpressionEngine News!

#eecms, #events, #releases