Skip Navigation

[Resolved] Best way to make a photographer's directory

This thread is resolved. Here is a description of the problem and solution.

Problem:
Create user and Edit user fields with CRED form.

Solution:
CRED now support both feature:
1) Create user,
2) Edit user fields

I suggest you try this:
1) Create some custom user fields you need with Types plugin:
https://toolset.com/documentation/user-guides/user-fields/

2) You can use WordPress build-in register form or Create a CRED form for user register in your website:
https://toolset.com/documentation/user-guides/cred-user-forms/

3) in above document, section "Email notifications", there you can send an email with login credentials

4) You can let the user edit their custom user fields in wordpress build-in user profile page, or use CRED to let them edit in front-end.

Relevant Documentation:
https://toolset.com/documentation/user-guides/user-fields/
https://toolset.com/documentation/user-guides/cred-user-forms/

This support ticket is created 8 years, 4 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 31 replies, has 2 voices.

Last updated by Paulo Ramalho 8 years, 1 month ago.

Assisted by: Luo Yang.

Author
Posts
#356918

Hi.
I'm making a photographer's directory site. The photographer, once accepted by the administrator will receive a login and password. With these credentials he, or she, will have a user profile with a list of custom forms to fill. Therefore, he will have a personal page profile page and his name on a list profiles page.

My questions are:
- What is the best practice to do that?

My first attempt was create user forms with CRED, but reading here https://toolset.com/forums/topic/custom-post-types-or-user-fields/ I saw that is not the best option. Besides, I can't query these user fields on my theme.

Reading here https://toolset.com/forums/topic/staff-directory-using-views-types-and-cred/ I saw a solution that says I have to create CRED forms to insert the information and a hook to create a new user automatically.

In fact, I'm a little confused about that.
By other hand the user, must upload his own photo gallery. Is it possible with Toolset?
Thanks for your help.

Paulo

#357023

Dear Paulo,

The threads you mentioned above are little outdated, CRED now support both feature:
1) Create user,
2) Edit user fields

I suggest you try this:
1) Create some custom user fields you need with Types plugin:
https://toolset.com/documentation/user-guides/user-fields/

2) You can use WordPress build-in register form or Create a CRED form for user register in your website:
https://toolset.com/documentation/user-guides/cred-user-forms/

3) in above document, section "Email notifications", there you can send an email with login credentials

4) You can let the user edit their custom user fields in wordpress build-in user profile page, or use CRED to let them edit in front-end.

Hope it help

#357758

Hi Luoy.
Thanks for your assistance. Yes, I know the threads where old ones and I was trying to figure out the best practice to do this. I will try the way you suggest, it seems to be the good way.
My only concern is how to make the photo gallery with custom user fields on Types. Any tips about that?
However, I ask you please if you can let this thread open until I have the system done. I'm designing the theme right now. In a couple of days, I close it by myself if everything is all right. Ok?

Thanks again.

#357940

You can create some custom image fields to User Profiles, see the document:
https://toolset.com/documentation/user-guides/user-fields/
screenshot:
hidden link
There is a option for you to create image fields, if you need each user be able to upload multiple images, you can setup it as multiple instance field. see our document:
Repeating Fields
https://toolset.com/documentation/user-guides/repeating-fields/

You can keep this thread open status, or create new thread when your live webiste is ready.

#358173
help-toolset.jpg

Hi Luoy.
I will try the upload multimages tip and try to find some plugin that makes a gallery with the post attachments. Or in this case, user attachments. I hope I can find some.

Well, I've made everything with Toolset.
- create the user fields using TYPES
- I used CRED for display editable profile forms for each user
- I used ACCESS to allow only the author edit and see his own profile
- I used VIEWS to make a kind of "archive" page, displaying the users (I could have done this by my own template)

My problem right now is how to create a link to go to a kind of "single user page". The page that display the full profile of the photographer. I send you an image to illustrate what I need.

Thanks.

#358383

You can simply create a wordpress page, use Views shortcode [wpv-current-user] to display the information of current user.
https://toolset.com/documentation/views-shortcodes/#wpv-current-user

To display other custom user fields of current user, please try another shortcode [wpv-user]:
https://toolset.com/documentation/views-shortcodes/#wpv-user

For example:
[wpv-user field="wpcf-custom-user-field" id="[wpv-current-user info="id"]"]

#358514

Hi Luoy.
To display the full profile, with all my Types custom user fields, I prefer hard code my theme with Types shortcodes. Actually I already have it done. But I know I can make it with Views too.

- I already have the Types custom user fields
- I have two Views, one called "Photographers List" (the image I send you) and it's working. I have another called "Single Photographer" and this must be the full profile page.

The problem here is: I do not want to show only the current user, I need two things: a photographers list (I already have it) and, inside every list, a link to the full profile of respective photographer. This must be open to everyone see it. The only private area is for editing this information, but this I already have with ACCESS and CRED.

It's like a blog with a list of excerpts with links to the single post page. Instead of posts I have users.

Thanks.
Paulo

#358752
1.jpg

Dear Paulo,

You can try this:
Setup the user profile link, pass user ID as URL parameter to a target page, in the target page create a view to list users, filter with user ID = the URL parameter, see below screeshot: 1.jpg

#359191

Hi Luoy.
Yes, I follow your idea, I thinks this is perfect but I really do not know how to pass user ID as URL parameter to a target page. And where to put the link? I try some links inside the Views but it doesn't work.

Sorry mi questions, but I always work with TYPES custom posts, it's the first time I use customs users pages.

#359312

Hi again.
I set a WordPress instalation with the unfinished theme I am creating. You can access it.
Please, foremost use the header to see the behavior that I think, as you were a photographer, ok?

hidden link
The site is on spanish, so on the header you have the red box link ACCESO FOTÓGRAFOS = photographer's access.

Your credentials are:
user - toolset
pass - ****

Once you are logedin you can see on the header the link MI PERFIL = my profile.
Till there everything is alright. And you can access the wp-admin.php too.

On the main navigation, please access FOTÓGRAFOS (photographers) hidden link this is the page I list every people.
Here is the page that I need the link to the "single photographer's page" with pagination.

I use to work very well with TYPES and custom post types, but it's the very first time I work with users and the full Toolset.

Thanks again. Any help will be fully appreciated.

Paulo

#359370

Thanks for the details, I have modified your post to hide the password, please do not post the credentials publicly.

And I did below modification in your test site:
1) modify the view "Single Fotógrafo",
hidden link
section "Selección de contenido", choose "Usuarios" and "Fotografos", add a filter:
Elegir usuarios con el id determinado por el parámetro de URL "users-filter" y con el rol "fotografos"
p.ej. susitio/pagina-con-esta-view/?users-filter=1

2) modify the view "Lista Fotografos":
section "Plantillas para esta view":
modify the codes as below:

  <div class="Foto"> <a href="[wpv-post-url id="58"]?users-filter=[wpv-user field="ID"]">[types usermeta="foto" size="thumbnail"][/types]</a> </div>
  <div class="Marca"> <a href="[wpv-post-url id="58"]?users-filter=[wpv-user field="ID"]">[types usermeta="marca"][/types]</a> </div>

Please test again, check if it is what you need

#359702

Hi Luoy.
Great, it's work like a charm, thanks. Definitely I have to much to learn about the power of TOOLSET. Right now I'm looking for how to change the "?users-filter=" paramenter to the name of the user on the URL, it's for SEO porpouses. I think I need add_query_arg() but again I never work with that. I'm looking on the TOOLSET documentation but I can deny I'm little confusing about how to work with query filters yet.

This is what I wish to get.
hidden link
to
hidden link

Anyway, thank you VERY much for the solution and if you have some idea to the url problem it will be fully apreciated.

Paulo

#360042

It is not possible within Toolset, you will need create a custom rewrite rule, see wordpress document:
https://codex.wordpress.org/Rewrite_API/add_rewrite_rule
add_rewrite_rule
add_rewrite_rule() allows you to specify additional rewrite rules for WordPress. It is most commonly used in conjunction with add_rewrite_tag() (which allows WordPress to recognize custom post/get variables).

Hope it help

#363639

Hi Luoy.
I have mi site almost done and just realise that is not posible to do parametric searchs with the custom user fields I have.
https://toolset.com/forums/topic/parametric-search-view-with-post-author-selection/

Am i correct?

#363640

My client needs searching for user fields and a google map like this image. My idea was use a views parametric search with a views google maps integration. Just like this uploaded image.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.