News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Custom Profile Field Mod

Started by winrules, March 30, 2006, 02:21:25 PM

Previous topic - Next topic

Piwaille

hello...

I wanted to install this mod on RC2 but I failed :
QuoteActions d'installation pour "Custom Profile Mod":
L'installation de ce paquet effectuera les actions suivantes :
   Type    Action    Description
1.    Appliquer la modification    ./Sources/ModSettings.php    Réussite du test
2.    Appliquer la modification    ./Themes/default/Profile.template.php    Échec du test
3.    Appliquer la modification    ./Themes/default/Display.template.php    Réussite du test
4.    Appliquer la modification    ./Themes/default/PersonalMessage.template.php    Réussite du test
5.    Appliquer la modification    ./Themes/default/Register.template.php    Réussite du test
6.    Appliquer la modification    ./Sources/Register.php    Réussite du test

the mod I allready have installed :
QuoteNom du mod     Version     
1.    Ad Managment    1.5    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]
2.    SMF 1.0.7 / 1.1 RC2 Update    1.0    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]
3.    Custom Profile Mod    2.13    [ Appliquer le mod ] [ Lister les fichiers ] [ Effacer ]
4.    MessagePreviewOnHover    1.0    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]
5.    Custom Profile Mod    2.13    [ Appliquer le mod ] [ Lister les fichiers ] [ Effacer ]
6.    CAPTCHA (code verification)    0.1    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]
7.    Lots_o_Smileys    1.0    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]
8.    Skype Name Mod    1.0    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]
9.    Quick Upload    2.1    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]
10.    Googlebot & Spiders Mod    1.0.5    [ Désinstaller ] [ Lister les fichiers ] [ Effacer ]

plus I've made several changes on Display.template.php and Boardindex.template.php...
but I never modified Profile.template.php

I've downloaded the zip file but I can't see why the test fails :(
the only thing I've seen it that the first search find the string on line 1527 when the second one finds the line 244...
Piwaille
le chant du vario est motorisé par SMF 1.1.15

SaikoJosh

#201
Once you tick a checkbox in your profile it's impossible to untick it.

SMF: RC 2
MOD: 2.13

Digital Home Central - Products for the 21st century home (under construction).

Bladenight

I get this message:


Installation Readme
Sorry, but this mod doesn't support your version of SMF.

Package Manager - Install Actions
Install Actions for archive customprofile2-13.zip:
The package you are trying to download or install is either corrupt or not compatible with this version of SMF.


I have this version:


Version Information:
Forum version: SMF 1.0.7
Current SMF version: SMF 1.0.7


With this mods:


Mod Name Version
1. Jack's Phat Calendar Pack 1.0.4 [ Uninstall ]
2. G&S_Sticky 1.1 [ Uninstall ]
3. SMF 1.0.7 / 1.1 RC2 Update 1.0 [ Uninstall ]


Any ideas what the issue is?

winrules

#203
perplexed, when does it give you that error?


john109, fixed :)
you only need to make the changes I posted in the first post of this thread if you are using a custom theme and you want to show the fields in posts.


crazie, just to add on to what perplexed said, the error is probly caused by either the coding changes you made, the gmail mod or the auto sig mod. the data always stays there, with the field id. So actually if you were using "default_options[myfield]" before, if you gave a field in this mod an ID of "myfield" (without quotes) the data would stay there.


piwaille, the skype name mod is probly interferring with this mod.


jcoleuk, confirmed, I will look into it.


Bladenight, sorry but this mod only works with 1.1 RC2, not 1.0.7.


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


daygo140

Two things:

1) Remove a custom field.  I know you can uncheck it and then it doesn't appear but how can I remove the "Enable Custom Profile Field*" entry in the admin section?

2) I checked to show in posts & profile but for some reason it isn't showing in posts.

winrules

Quote from: daygo140 on April 24, 2006, 04:19:04 PM
Two things:

1) Remove a custom field.  I know you can uncheck it and then it doesn't appear but how can I remove the "Enable Custom Profile Field*" entry in the admin section?

2) I checked to show in posts & profile but for some reason it isn't showing in posts.
1: you can't delete fields.
2: if you are using a custom theme you will need to make the modifications to that theme as I said in the first post.


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


daygo140

Quote from: winrules on April 24, 2006, 04:21:39 PM
Quote from: daygo140 on April 24, 2006, 04:19:04 PM
Two things:

1) Remove a custom field.  I know you can uncheck it and then it doesn't appear but how can I remove the "Enable Custom Profile Field*" entry in the admin section?

2) I checked to show in posts & profile but for some reason it isn't showing in posts.
1: you can't delete fields.
2: if you are using a custom theme you will need to make the modifications to that theme as I said in the first post.

OK nice!  Sorry there is so much info on this mod it's very overwhelming! 

I can't delete the fields manually in PHP or anything?

Also since I have your attention, KICK ASS MOD BTW, is there a way to make the custom field's title display bold in your posts in adding to a <BR> or space in between fields??

winrules

Quote from: daygo140 on April 24, 2006, 04:45:56 PM
Quote from: winrules on April 24, 2006, 04:21:39 PM
Quote from: daygo140 on April 24, 2006, 04:19:04 PM
Two things:

1) Remove a custom field.  I know you can uncheck it and then it doesn't appear but how can I remove the "Enable Custom Profile Field*" entry in the admin section?

2) I checked to show in posts & profile but for some reason it isn't showing in posts.
1: you can't delete fields.
2: if you are using a custom theme you will need to make the modifications to that theme as I said in the first post.

OK nice!  Sorry there is so much info on this mod it's very overwhelming! 

I can't delete the fields manually in PHP or anything?

Also since I have your attention, KICK ASS MOD BTW, is there a way to make the custom field's title display bold in your posts in adding to a <BR> or space in between fields??
1: you could delete the field in phpmyadmin, but onyl delete the last one.

2: not yet


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


daygo140

Quote from: winrules on April 24, 2006, 04:48:35 PM
Quote from: daygo140 on April 24, 2006, 04:45:56 PM
Quote from: winrules on April 24, 2006, 04:21:39 PM
Quote from: daygo140 on April 24, 2006, 04:19:04 PM
Two things:

1) Remove a custom field.  I know you can uncheck it and then it doesn't appear but how can I remove the "Enable Custom Profile Field*" entry in the admin section?

2) I checked to show in posts & profile but for some reason it isn't showing in posts.
1: you can't delete fields.
2: if you are using a custom theme you will need to make the modifications to that theme as I said in the first post.

OK nice!  Sorry there is so much info on this mod it's very overwhelming! 

I can't delete the fields manually in PHP or anything?

Also since I have your attention, KICK ASS MOD BTW, is there a way to make the custom field's title display bold in your posts in adding to a <BR> or space in between fields??
1: you could delete the field in phpmyadmin, but onyl delete the last one.

2: not yet

I have two extra fields I don't use or have enabled.  So I assume I delete the last two.  But where and what field?

BTW...I GREATLY APPRECIATE your help and support!

winrules

Quote from: daygo140 on April 24, 2006, 04:54:18 PM
Quote from: winrules on April 24, 2006, 04:48:35 PM
Quote from: daygo140 on April 24, 2006, 04:45:56 PM
Quote from: winrules on April 24, 2006, 04:21:39 PM
Quote from: daygo140 on April 24, 2006, 04:19:04 PM
Two things:

1) Remove a custom field.  I know you can uncheck it and then it doesn't appear but how can I remove the "Enable Custom Profile Field*" entry in the admin section?

2) I checked to show in posts & profile but for some reason it isn't showing in posts.
1: you can't delete fields.
2: if you are using a custom theme you will need to make the modifications to that theme as I said in the first post.

OK nice!  Sorry there is so much info on this mod it's very overwhelming! 

I can't delete the fields manually in PHP or anything?

Also since I have your attention, KICK ASS MOD BTW, is there a way to make the custom field's title display bold in your posts in adding to a <BR> or space in between fields??
1: you could delete the field in phpmyadmin, but onyl delete the last one.

2: not yet

I have two extra fields I don't use or have enabled.  So I assume I delete the last two.  But where and what field?

BTW...I GREATLY APPRECIATE your help and support!
you would have to go to phpmyadmin and delete all the entrys in the settings table that have CPx in them, where x is the field number. however its probly more trouble than its worth.


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


daygo140

Quote from: winrules
you would have to go to phpmyadmin and delete all the entrys in the settings table that have CPx in them, where x is the field number. however its probly more trouble than its worth.

worked great!!!

perplexed

Quote from: perplexed on April 23, 2006, 10:36:52 AM
I tried using the CPF registration fields both as 'optional' and as 'forced' and everything works :)
I am only getting one error in the forum log:

http://www.mysite.com/forum/index.php?option=com_smf&amp;Itemid=83&amp;action=register
8: Undefined index: member
File: /home/mysite/public_html/forum/Themes/default/Register.template.php (before sub template - eval?)
Line: 127

This error?  I got it in the log after someone registered

Also since I had to look in the log again... it is full of

8: Undefined index: CP9
File: /home/mysite/public_html/forum/Themes/default/Profile.template.php (forumProfile sub template - eval?)
Line: 1699

for CP9 and CP10 - these are both fields for registration that also show in your profile, and they are selection boxes for selecting browser type, and OS.

CP9 shows in profile as firefox and CP10 as PC unless people change it. I have 4 fields in registration, but only these two are selection boxes and seen by the user. The other two are text fields and only seen by admin.  I wonder if it has something to do with that?




winrules

Quote from: perplexed on April 24, 2006, 05:47:28 PM
Quote from: perplexed on April 23, 2006, 10:36:52 AM
I tried using the CPF registration fields both as 'optional' and as 'forced' and everything works :)
I am only getting one error in the forum log:

http://www.mysite.com/forum/index.php?option=com_smf&amp;Itemid=83&amp;action=register
8: Undefined index: member
File: /home/mysite/public_html/forum/Themes/default/Register.template.php (before sub template - eval?)
Line: 127

This error?  I got it in the log after someone registered

Also since I had to look in the log again... it is full of

8: Undefined index: CP9
File: /home/mysite/public_html/forum/Themes/default/Profile.template.php (forumProfile sub template - eval?)
Line: 1699

for CP9 and CP10 - these are both fields for registration that also show in your profile, and they are selection boxes for selecting browser type, and OS.

CP9 shows in profile as firefox and CP10 as PC unless people change it. I have 4 fields in registration, but only these two are selection boxes and seen by the user. The other two are text fields and only seen by admin.  I wonder if it has something to do with that?




did you try recreating the fields?


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


perplexed

yeah I did when I upgraded, I can do it again though and see if it makes any difference- everything seems to work ok though :)

*points to favourite mods in signature*

winrules

Quote from: perplexed on April 24, 2006, 06:21:26 PM
yeah I did when I upgraded, I can do it again though and see if it makes any difference- everything seems to work ok though :)

*points to favourite mods in signature*
would you post what's around lines 1699 in profile.template.php

also I've figured out what's causing the undifiened index:member errors, this wil be fixes shortly.


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


GJ-tje

Hello, here I am again, but I have a question.

Is it possible to give the custom profile fields a max width?
Because now there isn't and it can ****** the profiles up.
See also: http://www.appieskamertjuh.nl/smf/?action=profile;u=67
This occurs on any resolution a user has or can have...

Many thanks in advance!

P.S. Did you think about my suggestion which I told you some time ago?
Furthermore, I really like and appreciate this mod, with this mod, I do not have to modify SMF Profiles myself... :P
"People cannot gain anything without sacrificing something of equal value.
To obtain, something of equal value must be lost.
That is alchemy's first law of Equivalent Exchange."

"People should not be afraid of their Goverments. Goverments should be afraid of their People."

parcley

maybe this has been asked and i missed it...but is there a way to have the index of custom fields (in the admin section) display the name of the field and not "custom field 1"..."2"...etc.


perplexed

#217
Quote from: winrules on April 24, 2006, 06:44:53 PM
Quote from: perplexed on April 24, 2006, 06:21:26 PM
yeah I did when I upgraded, I can do it again though and see if it makes any difference- everything seems to work ok though :)

*points to favourite mods in signature*
would you post what's around lines 1699 in profile.template.php

also I've figured out what's causing the undifiened index:member errors, this wil be fixes shortly.

Hi

here are the few lines around 1699 in profile as requested:


}
if ($modSettings['CP' . $i . '_type']=='select')
{
echo '
<tr>
<td><b>' . $modSettings['CP' . $i . '_name'] . ': </b></td>
<td><select name="default_options[' . $modSettings['CP' . $i . '_id'] . ']">';
$r = 1;
while (isset($modSettings['CP' . $i . '_data' . $r . '']) && !empty($modSettings['CP' . $i . '_data' . $r . '']))
{
echo '

[color=red]xxxxxxxx[/color] <option' , $context['member']['options'][$modSettings['CP' . $i . '_id']] == $modSettings['CP' . $i . '_data' . $r . ''] ? ' selected="selected"' : '' , '>' . $modSettings['CP' . $i . '_data' . $r . ''] . '</option>';
$r++;
}
echo '
</select></td>';
}
if ($modSettings['CP' . $i . '_type']=='check')
{
echo '
<tr>



I have highlighted the start of line 1699 with xxxxxxxxxx

winrules

Quote from: GJ-tje on April 24, 2006, 07:17:26 PM
Hello, here I am again, but I have a question.

Is it possible to give the custom profile fields a max width?
Because now there isn't and it can ****** the profiles up.
See also: http://www.appieskamertjuh.nl/smf/?action=profile;u=67
This occurs on any resolution a user has or can have...

Many thanks in advance!

P.S. Did you think about my suggestion which I told you some time ago?
Furthermore, I really like and appreciate this mod, with this mod, I do not have to modify SMF Profiles myself... :P
do you mean max lenght? I'll consider that.
about the other suggestion, It might be in 2.2 but I'm busy working on another mod right now.


parcley, Good idea, that'll be in 2.2.



perplexed, ok, figured out what's causing that, 2.1.4 will fix that too.


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


perplexed

yeah the max length idea would be good, as the text fields seem to be unlimited? 

I mentioned ages ago now putting a limit on the size of images that can be displayed in profiles, do you remember?  I set up a text area for a 'profile pic' but it doesnt read the image size restrictions set in features and options and displays it full size. (We have limits of 500px x 300px set on the board images.) I've decided not to mention 'images' until we can set the maximum size.


Advertisement: