The Lodge is members-only web design and development videos and live help. Log In or Sign Up.
Can anyone lend a hand?
@TheDoc I got the following
syntax error, unexpected ‘)’
I ended up solving it by doing this:
< ?php foreach($pages->invisible()->slice(1, 1) AS $p): ?>
< ?php echo ($p->isOpen()) ? ‘ active’ : ” ?>
Any reason for the ternary operator?
< ?php if($p->isOpen()) echo ‘ active’ ?>
@BenWalker Thank you!!! I literally just copied it from the foreach statement above it with just a few alterations.
You must be logged in to reply to this topic.
Search for Stuff
Browse the Archives
Get the Newsletter
... or get the RSS feed