If/Else Question

Discuss news styles, css code, and other Coranto customizations in here...the possibilities are endless, so have at it!

Moderator: Spunkmeyer

If/Else Question

Postby diogenes2100 » Sat Jan 12, 2008 7:48 pm

I've set up a conditional in one of my templates that isn't working correctly. It's for a Maginot static page.

What I want is if "Field: CustomField_full_story" has any text entered into it, then only that text would be displayed. If "Field: CustomField_full_story" doesn't have any text entered into it, then I want "Field: Text" to be displayed instead.

The problem is when there is text entered for "Field: CustomField_full_story," that text is correctly displayed, but "Field: Text" is also displayed directly below it.

How do I supress "Field: Text" when "Field: CustomField_full_story" is filled in?

Here is the code:

<If: Field: CustomField_full_story><p><Field: CustomField_full_story></p><If: Else><p><Field: Text></p></If>

Once again I'm stumped. Can anyone see what is wrong?
User avatar
diogenes2100
 
Posts: 21
Joined: Mon Mar 14, 2005 6:33 pm
Location: Florida

Postby Dale Ray » Sun Jan 13, 2008 3:35 am

What version of Coranto are you using?
Dale Ray
User avatar
Dale Ray
 
Posts: 1001
Joined: Sun Jan 19, 2003 6:02 pm
Location: NW Indiana

Postby diogenes2100 » Sun Jan 13, 2008 4:37 am

v1.25.1
User avatar
diogenes2100
 
Posts: 21
Joined: Mon Mar 14, 2005 6:33 pm
Location: Florida

Postby diogenes2100 » Sun Jan 13, 2008 6:50 pm

This is solved. If/Else works in styles but not on templates. This forum is amazing. If you dig long enough the answer is usually there.
User avatar
diogenes2100
 
Posts: 21
Joined: Mon Mar 14, 2005 6:33 pm
Location: Florida

Re: If/Else Question

Postby Dale Ray » Sun Jan 13, 2008 7:41 pm

diogenes2100 wrote:I've set up a conditional in one of my templates


That was in your first post and I missed it, sorry. You may want to spend some time reading the Docs Wiki also.
Dale Ray
User avatar
Dale Ray
 
Posts: 1001
Joined: Sun Jan 19, 2003 6:02 pm
Location: NW Indiana

Postby SrNupsen » Mon Jan 14, 2008 6:25 am

Ah... missed the "t" word myself. Well, glad you found out eventually!
-----------------------------------------------------------------------------------------------------
Coranto is free software. I am available for custom work or troubleshooting.

http://www.sundaune.no - transkripsjon, webdesign, nettsider, tekstbyrå
http://www.vagbladet.no - satire, politikk, kultur, sport, nettavis
-----------------------------------------------------------------------------------------------------
SrNupsen
 
Posts: 2229
Joined: Tue Jan 09, 2007 6:46 pm
Location: Nesodden, outside Oslo, Norway


Return to Customization

Who is online

Users browsing this forum: No registered users and 2 guests

cron