Osclass forums

Support forums => General help => 3.6.x => Topic started by: Dublay on February 18, 2016, 04:46:59 pm

Title: Show username instead of real name
Post by: Dublay on February 18, 2016, 04:46:59 pm
Hi,

is it possible to display the username instead of the real name on item page if has been filled by the user? This is important for privacy purposes - not everybody want's his real name posted to his ad.

Thanks in advance!
Title: Re: Show username instead of real name
Post by: teseo on February 18, 2016, 07:12:51 pm
Hi,

What theme are you using?

Regards
Title: Re: Show username instead of real name
Post by: Dublay on February 18, 2016, 07:15:33 pm
Hi,

it's the glider theme.
Title: Re: Show username instead of real name
Post by: teseo on February 18, 2016, 07:56:48 pm
Sorry, don't know that theme. :( Better ask to its developers.

Regards
Title: Re: Show username instead of real name
Post by: Dublay on February 18, 2016, 08:07:28 pm
Ok, I'll try that.

But besided of that theme - is there a variable to show up the username of an item, like oc_posted_by(); or something else?
Title: Re: Show username instead of real name
Post by: teseo on February 18, 2016, 08:15:45 pm
On bender this is the equivalent:

Code: [Select]
                <p class="name"><?php _e('Name''bender'?>: <a href="<?php echo osc_user_public_profile_urlosc_item_user_id() ); ?>" ><?php echo osc_item_contact_name(); ?></a></p>
As you can see, it's not the user's Name or Username what is used directly, but the Name specified when the ad was posted: osc_item_contact_name()

You could just change that for osc_user_username() if only registered users can post ads on your site.

Regards
Title: Re: Show username instead of real name
Post by: Dublay on February 18, 2016, 09:17:15 pm
Ok, I'll try that tomorrow - maybe this will do the trick.
But maybe this is interesting for further versions of osclass, as there are many sites people don't want to get their real name posted. Thanks for your help!