What is vldPersonals?

vldPersonals is a very easy to use dating/social software. It allows you to create a fully functioning & modern dating website in a matter of minutes. If You think it's too complicated - check vldPersonals!
Know more about how You can become a dating website owner

What is vldCrowd?

vldCrowd.com is the biggest unofficial community of vldPersonals owners. It is a place to share ideas and thoughts about Your dating website. It is a place to answer questions and receive answers.
Do You own a vldPersonals license? Don't hesitate and join!

Connect Today

Community members help each other to take their dating websites to the next level. Can You make your vldPersonals website better? Join and find out...

Connect With More Than 500 Dating Website Owners! Sign Up Today

Extension Members

Extension Members

Extension Members

This is probably the most important and popular extension for vldPersonals. It allows you to show your members anywhere on your website. You can sort members by type, popularity, gender, etc

Usually, on almost any dating website on the homepage you can see a list of new members or popular. Well, this extension allows you to do just that.

A very basic example will look like this:

{members:limit=10,photos=1,cache_time=0,cache_name="new"}

This will show 10 latest members with photos.

Now, it is important to mention that this extension has two parts:
1. Extension file itself ext.members.php. You can find it in includes/ext folder.
2. Template file for this extension ext.members.tpl. You can find it in your template folder.

If you open ext.members.tpl with your editor you will see that this default template shows image of a member and his/her username. An image and a username are both linked to a member's profile page. Well, that's the beautiful part. You can create your own template for that.

Let's have a look at the list of options which you can use with this extension.

  • limit Limit number of members to show: limit="10"
  • photos Show all members or members with profile photo only: photos=1
  • online Show members online: online=1
  • groups Show members from these groups only: groups="2|5" Find group id in your control panel: Settings->Member Groups.
  • featured Show featured members only: featured=1. You can feature particular members in your control panel by clicking a star symbol: Members->Manage members.
  • albums Show members who have albums: albums=1
  • videos Show members who have videos: videos=1
  • adult Show members who have pictures marked as adult: adult=1
  • music Show members who have music files: music=1
  • blogs Show members who have blogs: blogs=1
  • events Show members who have events created: events=1
  • profile_* Filter by any profile field value: profile_gender1=1. You can find fields and their labels in Settings->Custom Fields. More about this option.
  • dist Use with usa zip addon. Means distance from particular zip code: profile_uszip=611,dist=100. Thus it will show all members who live in the area of 100 miles from a city with a zip code of 611.
  • template Use this option if you want to use your own template: template="mymembers.tpl". Using template with members extension.
  • orderby You can order results by: group_id, member_id, joindate, lastvisit, totalvisits, totalviews, totalfriends, ratings, username, random, etc: orderby="joindate" You can find more in vld_members table. Use key as an option: orderby="totalscore"
  • orderdir Order direction asc or desc: orderdir="desc"
  • cache_name Name of the cache file: cache_name="extra_menu"
  • cache_time Time in minutes. Cache file to refresh every X minutes: cache_time="10"

As you can see there are plenty of options to play with. Below you may find more information about ordering, profile fields and templates.

Some additional notes about caching. Do not ignore this option. First of all it can reduce the amount of requests to your database. This can be quite helpful if you have a high traffic website. Second, use your creativity. Limit amount of members to one. Set cache time to one hour, for example. And you have a member of the hour. Use custom template and put this extension in your sidebar. Useful, isn't it? If you have several member extension one one page and you cache results - give them different cache names.

Using Profile Fields for Filtering Members.

As we all know each member has a particular set of fields, assigned to him/her: city, age, marital status, height, hair, etc You can change this set of fields in control panel Settings -> Custom fields. Every field has a label. For example, "I am" field has "gender1" label.

What you can do with members extension is to filter your members by almost any profile field and its value. For example, having this option in your extension call profile_gender1=1 will show men only. profile_gender1=2 will show women only. Very useful feature indeed.

You can filter your members by: age, city, gender1(I am), gender2(Looking for), country, city, bodytype, smoking, drinking, hair, eyes, etc You can find all fields in vld_members_data_members table.

{members:limit=10,photos=1,profile_gender1=2, profile_city="Toronto", profile_eyes=2,profile_drinking=2}

This code will show 10 socially drinking women from Toronto with blue eyes. (If you have any members like these in your database)

Please, not, that for drop down fields like "eyes" in this example you need to use value id, which you can see in control panel. Thus profile_drinking=2 actually means Socially. For text fields, like city, you need to use exact value - "Toronto" in this case.

This is a great opportunity for landing pages which show particular type of members. It is also great for articles where you can show you members in the side or below, etc. Filter your members by gender, city, country, habits, etc. Just be creative and have fun experimenting.

Creating custom template for Members extension.

ext.members.tpl is a default template for this extension. Let's open it and have a look. First of all when you will make your template you need to wrap all your code in

<!-- IF ext members -->
your code
<!-- ENDIF -->

This will prevent possible errors if extension is not installed or there are no results in your query.

Second. There two parts in the template:
1. Your code outside the loop.
2. Your code inside the loop.

<!-- IF ext members -->
code outside: static titles, texts, links etc
<!-- BEGIN ext_members -->
code for the loop
<!-- END ext_members -->
code outside: static titles, texts, links etc
<!-- ENDIF -->

The loop is basically what extension does. If you have your limit set to 10, the loop will go 10 times and will print your loop code 1 time for each member and it will stop when it will print the code 10 times. This is a very common thing for programming languages. Let's have a look at this simple example.

<!-- IF ext members -->
<h1>Our new members</h1>
<ul>
<!-- BEGIN ext_members -->
<li><a href="{top.virtual_path}{member_profile_link}"> {member_username} </a></li>
<!-- END ext_members -->
<ul>
<p>This is some additional text.</p>
<!-- ENDIF -->

This will generate a simple list of usernames and each username is linking to a profile page of this member. As you can see we use some variables like
{member_username} and {top.virtual_path}{member_profile_link}. Every time a loop gores through the code these variables will be replaced with their values for this particular member.

Again, if you open ext.members.tpl, which is a default template, you will see that the loop contains image of a member and a username both linking to profile.

But of course you can use many other variables in your templates. You can use almost any profile field value. For example, {profile_field_country_value}. This will show country for this member.

You may find plenty of variables here http://www.vldpersonals.com/docs/customization/templates/template_filenames/member_profile.tpl

Here is another example

<!-- IF ext members -->
<h1>Our new members</h1>
<ul>
<!-- BEGIN ext_members -->
<li> <a href="{top.virtual_path}{member_profile_link}"> {member_username} </a><br> {profile_field_gender1_value} from {profile_field_country_value}, {profile_field_age_value_years} </li>
<!-- END ext_members -->
<ul>
<p>This is some additional text.</p>
<!-- ENDIF -->

For each member this will show something like this:

Alexander
Man from Norway, 28

Of course, all this work will require some knowledge of HTML/CSS so you can create custom templates for this extension. As a final note I would like to add a couple of thoughts for you to consider.

1. Use more variables in your templates, mix them, utilize them. For example, you can check if your member is a man or a women. Depending on the answer you can show ten new women in the sidebar or 10 new men. Or even better you can check who your member is looking for and show what he/she wants. Here is a simple code for a woman looking for man and vise versa.

<!-- IF session.profile_gender2 == "Man" -->
{members:limit=10,photos=1,profile_gender1=1}
<!-- ELSE -->
{members:limit=10,photos=1,profile_gender1=2}
<!-- ENDIF -->

2. You can find a huge list of variables here http://www.vldpersonals.com/docs/customization/templates.

As you can see this extension has a huge potential. Have fun experimenting.
Cheers