Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: Flarerahip on May 31, 2020, 10:07:19 PM

Title: profile modify
Post by: Flarerahip on May 31, 2020, 10:07:19 PM
hello, I added some code to Profile-modify.php to add new things to the forum profile page, I got an error.


I added something called test to profile-modify.php
(https://i.hizliresim.com/LGdfRU.png)

then I added it to show what i added to the same file
(https://i.hizliresim.com/WtVSR1.png)

yes, what i want was added to the profile modify section
(https://i.hizliresim.com/DhMM3A.png)

but there is a problem, I get this error when I write and register something
(https://i.hizliresim.com/VVNG1d.png)


note: I showed what I added in the codes in red


Title: Re: profile modify
Post by: Deaks on May 31, 2020, 11:03:25 PM
So what did you add?  Simply remove it for now.

Can I ask what you are trying to do exactly as we may b e better able to assist if we know what your end result is.
Title: Re: profile modify
Post by: Flarerahip on June 01, 2020, 01:15:15 AM
I want to add a 'youtube channel' to the profile switching page, write and save the channel URL, and print it to any page I want in the Forum and put the url in '$ context [' member '] [' youtubechannel '];' I want to print as

I'm bad english, sorry
Title: Re: profile modify
Post by: Arantor on June 01, 2020, 02:12:59 AM
Use the advanced profile fields feature, turn it on in the Core Features page.
Title: Re: profile modify
Post by: Deaks on June 01, 2020, 06:51:10 AM
Yeh I am going to echo' what Arantor said, what you are wishing to do is possible using the Advanced Profile Fields, this is default addition in smf 2.0 line.    Also please dont worry about your English, sometimes we may need you to explain a wee bit more, we will ask questions this is so we can get the full issue and allows us a better chance to help you.
Title: Re: profile modify
Post by: Flarerahip on June 01, 2020, 08:32:12 AM
yes, I did a little research on what you said it is fine but I couldn't do exactly what I wanted, can you show me as a regex with a picture, I want to print this value in any corner of the forum as $context['member']['value added']
Title: Re: profile modify
Post by: Arantor on June 01, 2020, 08:39:56 AM
You can't use $context['member'] everywhere, that only exists in posts and profiles.

Making an icon appear in the profile using the core feature works, that's how I have a GitHub icon in my poster info, you use "icons" placement and use the {INPUT} part to fill in, e,g, you tell it to use the image link and only the part of the url that matches the input gets replaced with {INPUT}

If that isn't going. To work, we're going to need a lot more info like "example the user fills in", what you want the result to show for a user, and exactly where you want to show this (with screenshots)
Title: Re: profile modify
Post by: Flarerahip on June 01, 2020, 08:59:57 AM
Can you tell me in a picture when you are available?
Title: Re: profile modify
Post by: Flarerahip on June 02, 2020, 07:46:42 AM
the problem continues
Title: Re: profile modify
Post by: Deaks on June 02, 2020, 07:49:13 AM
https://wiki.simplemachines.org/smf/How_to_use_Advanced_Profile_Fields

Have a look here it answers how to do it.
Title: Re: profile modify
Post by: Doug Heffernan on June 02, 2020, 08:10:56 AM
Quote from: Flarerahip on June 02, 2020, 07:46:42 AM
the problem continues

What exactly did you add and what are the errors that you are getting? The more details you give us, the better.
Title: Re: profile modify
Post by: Deaks on June 21, 2020, 06:15:10 AM
 Flarerahip, did anything here help?  im marking as solved as its been over 2 weeks since you got back to us, if you still need help please advise what you have tried since.