Support » Plugins » AWPCP

  • Been trying to work with the author but he seems busy as there have been no replies. So let’s try other WP experts 🙂

    Within the plugin is some individual ad-layout code that you can modify. This is the stock code showing:

    <div id="showad"><div class="adtitle">$ad_title</div><br /><div class="adinfo">$featureimg<label>Contact Information</label><br /><a href="$quers/$codecontact">Contact $adcontact_name</a>$adcontactphone $location</div>$aditemprice $awpcpextrafields $showadsense1<div class="adinfo"><label>More Information</label><br />$addetails</div>$showadsense2 <div class="fixfloat"></div><div id="displayimagethumbswrapper"><div id="displayimagethumbs"><ul>$awpcpshowadotherimages</ul></div></div><div class="fixfloat"></div>$awpcpadviews $showadsense3</div>

    I want to hide the contact information from non-registered users and so far have come up with this:

    <div id="showad"><div class="adtitle">$ad_title</div><br /><div class="adinfo">$featureimg<label>Contact Information</label><br />
    <?php
    if ( is_user_logged_in() ) {
        echo '<a href="$quers/$codecontact">Contact $adcontact_name</a>$adcontactphone $location';
    } else {
        echo 'Welcome, visitor! Register as a member to see this seller's information!';
    };
    ?>
    $aditemprice $awpcpextrafields $showadsense1<div class="adinfo"><label>More Information</label><br />$addetails</div>$showadsense2 <div class="fixfloat"></div><div id="displayimagethumbswrapper"><div id="displayimagethumbs"><ul>$awpcpshowadotherimages</ul></div></div><div class="fixfloat"></div>$awpcpadviews $showadsense3</div>

    The problem is that it seems that the php code is partially being ignored. The modified code above will show the contact information to someone logged in but it also shows the ‘second half’ of the php code.

    Here’s what the page output looks like(text).

    Contact dragondon
    Phone: 9055555555
    Location : hamilton, ontarion canada'; } else { echo 'Welcome, visitor! Register as a member to see this seller's information!'; }; ?>

    I recently added the Exec-PHP to see if I can force the code to be properly executed but this seems to have little/no effect at all.

    Any suggestions?

  • The topic ‘AWPCP’ is closed to new replies.