*

Fabio Massaro

  • *****
  • 302 posts
Hello I wanted to ask if someone or from mbtheme if you can help me
I just want that on the ad there is only the name and not the name and surname .. I attach image

*

MB Themes

Re: Hello I wanted to ask if someone or from mbtheme if you can help me
« Reply #1 on: January 17, 2022, 11:37:09 AM »
@Fabio
This can be bit tuff as osclass stores name, not first name and last name.
You could try this function to get first name from name:
Code: [Select]
function osc_first_name_from_name($name) {
  $parts = explode(' ', $name);
  return $parts[0];
}
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Fabio Massaro

  • *****
  • 302 posts
Re: Hello I wanted to ask if someone or from mbtheme if you can help me
« Reply #2 on: January 18, 2022, 08:57:23 PM »
yes which folder should I insert on item.php or from another folder

*

MB Themes

Re: Hello I wanted to ask if someone or from mbtheme if you can help me
« Reply #3 on: January 19, 2022, 10:13:01 AM »
@Fabio
You will put function to functions.php and then use user name as parameter for this function.
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Fabio Massaro

  • *****
  • 302 posts
Re: Hello I wanted to ask if someone or from mbtheme if you can help me
« Reply #4 on: January 23, 2022, 02:08:12 PM »
tried it doesn't work

*

cartagena68

  • ***
  • 71 posts
Re: Hello I wanted to ask if someone or from mbtheme if you can help me
« Reply #5 on: January 23, 2022, 02:32:25 PM »
Devi mettere la funzione in function.php e poi richiamarla in item.php, o item-sidebar.php dipendendo dal tema, al posto di osc_item_contact_name()
Rimarrebbe così

osc_first_name_from_name(osc_item_contact_name())

Se ho capito bene