Fog Creek Software
Discussion Board

Knowledge Base
Terry's Tips
Darren's Tips

I think I found a bug in script compiler...

While editing a new site, I came across a small problem...

{$ .headline $}
{$ if nonblank .author $}
  By: {$ .author $}
{$ if nonblank .sidebar $}
  {$ .sidebar $}
{$ endif $}
{$ .body $}
{$ if nonblank .headline $}
  {$ .about $}
{$ endif $}

I took out the HTML tags, but they aren't necessary for this example... Notice that the "IF" next to .author doesn't have a matching "ENDIF"...

When building the site, CD happily parsed the code without complaint. I didn't notice the problem until later when I was working with a different template and it created a page that  had only half of it's data. Since it didn't have an author in the article, it stopped right after the headline.

David Metzener
Tuesday, September 2, 2003

Thanks! We'll check into it.

Joel Spolsky
Tuesday, September 2, 2003

*  Recent Topics

*  Fog Creek Home