Display Certain Content For Logged In Users - Please Help!

Discussion in 'Integration' started by grayinternet, May 28, 2008.

  1. grayinternet

    grayinternet New Member

    Joined:
    May 27, 2008
    Messages:
    29
    Hello... I contacted the Sales team and they told me this could be done before I purchased the software. On my website, when the user's are logged in they do not get any advertisements. Below is the code we are using with our current system:

    PHP:
    <? include("checkuser.php"); ?>

    <?
    if($loggedin == 'yes') {
    ?>
    <!--No Ads Are Displayed User Is Logged In-->
    <?
    } else {
    ?>
    <!-- Begin: Ad Code -->
    <script type="text/javascript">
    var Title_Color = 'FFFF66';
    var Text_Color = 'ffffff';
    var Background_Color = '273d54';
    var Border_Color = '000000';
    </script>
    <script src="http://adcomp.com" type="text/javascript"></script>
    <!-- End: Ad Code -->
    <?
    }
    ?>
    As you can see the system first includes checkuser.php. This defines the database that all the users are stored in. Then it checks the user's cookie to see if $loggedin == 'yes'. If so, no ads are displayed. If 'no' then the advertisement is shown.

    There are about 3 of these ads on each page and this function is also called a number of other times to display different content for premium members.

    Please let me know how we can call the same function using aMember.

    Thanks!
  2. grayinternet

    grayinternet New Member

    Joined:
    May 27, 2008
    Messages:
    29
    Nevermind.

    I figured it out.
  3. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    what was the issue? (in case someone else runs into the same problem in the future)

Share This Page