Premium members seeing partner sites?

  • Bogey
  • Bogey
  • Genius
  • User avatar
  • Joined: Jul 14, 2005
  • Posts: 8212
  • Loc: USA
  • Status: Offline

Post June 10th, 2008, 10:39 pm

neksus wrote:
Just add a check box to the profile...display yes/no and use an if statement.

Why an if statement? I use something like the following for this type of stuff...
PHP Code: [ Select ]
$affiliates = (($show == true) ? $row['affiliates']; : '');
 
echo $affiliates;
 
  1. $affiliates = (($show == true) ? $row['affiliates']; : '');
  2.  
  3. echo $affiliates;
  4.  

Well, anyway, I use that to show the images for forums and don't know if it'll work for this. Just a though...
"Bring forth therefore fruits meet for repentance:" Matthew 3:8
  • Anonymous
  • Bot
  • No Avatar
  • Joined: 25 Feb 2008
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post June 10th, 2008, 10:39 pm

  • spork
  • Brewmaster
  • Silver Member
  • User avatar
  • Joined: Sep 22, 2003
  • Posts: 6134
  • Loc: Seattle, WA
  • Status: Offline

Post June 11th, 2008, 6:46 am

Not sure why this old topic was bumped but I can't resist fixing/improving that line of PHP:

PHP Code: [ Select ]
$affiliates = $show ? $row['affiliates'] : '';
The Beer Monocle. Classy.
  • Bogey
  • Bogey
  • Genius
  • User avatar
  • Joined: Jul 14, 2005
  • Posts: 8212
  • Loc: USA
  • Status: Offline

Post June 11th, 2008, 9:38 am

spork wrote:
Not sure why this old topic was bumped but I can't resist fixing/improving that line of PHP:

PHP Code: [ Select ]
$affiliates = $show ? $row['affiliates'] : '';

I was bored yesterday :roll:
"Bring forth therefore fruits meet for repentance:" Matthew 3:8

Post Information

  • Total Posts in this topic: 18 posts
  • Users browsing this forum: No registered users and 15 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 2011 Unmelted, LLC. Ozzu® is a registered trademark of Unmelted, LLC.