Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 MOD: Configurable Member Fields
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 4

HuwR
Forum Admin

United Kingdom
20593 Posts

Posted - 02 November 2000 :  05:33:22  Show Profile  Visit HuwR's Homepage
Instructions For Configurable User Fields.

Download the files here


This mod requires animedj's Mod Commander




New Files



Unzip...
admin_user_fields.asp, pop_ufield_table.asp, pop_ufield_record.asp,
member_profile_setup.asp,UserFields.Mod and UserFields.txt

to your forum/mods/ directory



Modified files

If you have NOT modified

admin_config_members.asp
config.asp
pop_profile.asp
inc_profile.asp
register.asp

then unzip them to your forum directory. If you have already made changes to these files,
you will find all the required changes are clearly commented.


Finally add the following functions to the end of inc_functions.asp

'Rem User Field Code #######################################
function DoesUserFieldExist(fMemberID,FUSerFieldID)

fieldSQL = "SELECT * FROM " & strMemberTablePrefix & "MEMBERFIELDS WHERE " & strMemberTablePrefix & "MEMBERFIELDS.USR_FIELD_ID=" & FUSerFieldID
fieldSQL = fieldSQL & " AND " & strMemberTablePrefix & "MEMBERFIELDS.MEMBER_ID=" & fMemberID
set rsGetFields = my_Conn.Execute(fieldSQL)
DoesUserFieldExist = not rsGetFields.EOF
rsGetFields.Close

end function

function getUserFieldValue(fUser_Field_ID,fMemberID)

strSql = "SELECT " & strMemberTablePrefix & "MEMBERFIELDS.USR_VALUE "
strSql = strSql & " FROM " & strMemberTablePrefix & "MEMBERFIELDS "
strSql = strSql & " WHERE " & strMemberTablePrefix & "MEMBERFIELDS.USR_FIELD_ID = " & fUser_Field_ID
strSql = strSql & " AND " & strMemberTablePrefix & "MEMBERFIELDS.MEMBER_ID = " & fMemberID
set rsgetUserFieldValue = my_Conn.Execute(strSql)
if Not rsgetUserFieldValue.EOF then
getUserFieldValue = rsgetUserFieldValue("USR_VALUE")
else
getUserFieldValue = ""
end if

end function
'Rem User Field Code #######################################


Once you have copied all the files, You can turn the extra info On/Off in the Configure Memberdetails section of Admin.
To set up the new field defnitions, execute the admin prog from Mod Commander.


That's all folks...

If you get any problems, please email me.

'Resistance is futile'

Edited by - huwr on 02 November 2000 05:33:55

webshorts
New Member

USA
96 Posts

Posted - 02 November 2000 :  10:43:44  Show Profile  Visit webshorts's Homepage  Send webshorts an ICQ Message
the only problems I ran into were the directories in your mod file included the /mods/ directory, so the URL was parsing incorrectly, your setup page wasn't appearing in the Mod Commander (I think this is a mod commander problem), and your setup file did't add any fields to the database, so after I ran the setup, and then went to the admin portion, I got an EOF error.

Otherwise, it works great <img src=icon_smile.gif border=0 align=middle>

Daniel Short
Chief Designer,
Web Shorts Site Design

Free DHTML at DHTMLShock.com
JavaScript and DHTML forum, powered by Snitz

Edited by - webshorts on 11 January 2001 11:53:34
Go to Top of Page

animedj
Junior Member

USA
190 Posts

Posted - 02 November 2000 :  11:02:37  Show Profile  Visit animedj's Homepage  Send animedj an ICQ Message
hmm, I checked around the file and made some fixes to the mod file. This uses the forum directory as well as the mods directory so that's why it might be a little confussing. I fixed the paths in the zip file so now one has to extract this file to the forums directory with subdirectories enabled.

d/l : http://animedj.com/hacks/UserFields.zip

---
Johann Reyes
http://animedj.com
Go to Top of Page

n/a
deleted

2 Posts

Posted - 02 November 2000 :  14:38:59  Show Profile
yahoo

Go to Top of Page

HuwR
Forum Admin

United Kingdom
20593 Posts

Posted - 02 November 2000 :  15:49:20  Show Profile  Visit HuwR's Homepage
Sorry people,

I did notice the problems last night, but have been ith a client all day so couldn't do anything about it.

<font color=blue>'Resistance is futile'</font id=blue>
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20593 Posts

Posted - 02 November 2000 :  15:53:35  Show Profile  Visit HuwR's Homepage
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
hmm, I checked around the file and made some fixes to the mod file. This uses the forum directory as well as the mods directory so that's why it might be a little confussing. I fixed the paths in the zip file so now one has to extract this file to the forums directory with subdirectories enabled.

d/l : http://animedj.com/hacks/UserFields.zip

---
Johann Reyes
http://animedj.com
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>

Thanks for sorting it animedj.
humbly grateful.
I will chnage the zip file on my site later

<font color=blue>'Resistance is futile'</font id=blue>
Go to Top of Page

ilovemoney
Starting Member

Taiwan
27 Posts

Posted - 02 November 2000 :  22:53:05  Show Profile
Microsoft OLE DB Provider for ODBC Drivers ERROR '80040e10'...

/bbs/member/admin_config_members.asp, LINE85

WHY~~Y___________Y



Go to Top of Page

HuwR
Forum Admin

United Kingdom
20593 Posts

Posted - 03 November 2000 :  03:27:43  Show Profile  Visit HuwR's Homepage
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
Microsoft OLE DB Provider for ODBC Drivers ERROR '80040e10'...

/bbs/member/admin_config_members.asp, LINE85

WHY~~Y___________Y

<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>

Only thing I can think is that either you didn't run the setup script, or it hasn't added the new field to FORUM_CONFIG.

You need to add a field C_INTUSERFIELDS (int) to FORUM_CONFIG

<font color=blue>'Resistance is futile'</font id=blue>
Go to Top of Page

Davio
Development Team Member

Jamaica
12217 Posts

Posted - 16 December 2000 :  01:50:39  Show Profile
I'm getting an error when clicking on the Admin link in the Mod Commander:<pre id=code><font face=courier size=2 id=code>ADODB.Recordset error '800a0bcd'
Either BOF or EOF is True, or the current record has been deleted. Requested operation requires a current record.
/beta/31_sr2/mods/admin_user_fields.asp, line 59</font id=code></pre id=code>
Line 59 is:
rs2.AbsolutePage = iPage

I commented it to see what affect it would have on the mod, but it seems to work ok without it.
Also the new user field doesn't seem to be changing when I'm using the 'Single Input' in think it was. The checkbox. I mean when I got to my profile and check the box and save it, I go back to my profile and it is back to the default.

<center><font color=green>*----*----*----*----*----*----*----*----*
<font size=2>"To Get To Heaven,
It's Who You Know That Counts."</font id=size2>
*----*----*----*----*----*----*----*----*</font id=green></center>
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20593 Posts

Posted - 16 December 2000 :  04:50:18  Show Profile  Visit HuwR's Homepage
Davio,

Can I get back to you on this, I off to visit some friends for the weekend.

<font color=blue>'Resistance is futile'</font id=blue>
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20593 Posts

Posted - 16 December 2000 :  05:15:29  Show Profile  Visit HuwR's Homepage
Davio,

Now you have some user fields, try re-adding the line you commented, it may have just ben an init prob.

Off the top of my head, your problem may be that the SHORTNAME fields are not unique.

<b>USR_SHORTNAME</b>
This is used internally as the forms input name, to retreive the User values.
Try using values like "user_1, user_2" etc, that way it won't clash with any internal names



<font color=blue>'Resistance is futile'</font id=blue>
Go to Top of Page

Davio
Development Team Member

Jamaica
12217 Posts

Posted - 16 December 2000 :  12:16:32  Show Profile
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>Can I get back to you on this, I off to visit some friends for the weekend.<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Sure, no prob. HuwR. Have fun.
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>Off the top of my head, your problem may be that the SHORTNAME fields are not unique.<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
I didn't create any user fields before this. It's the first time I was accessing the admin file for the mod, so there were no user names.

I will try uncommenting the line after creating a user field as you suggested.

<center><font color=green>*----*----*----*----*----*----*----*----*
<font size=2>"To Get To Heaven,
It's Who You Know That Counts."</font id=size2>
*----*----*----*----*----*----*----*----*</font id=green></center>
Go to Top of Page

Indy
Starting Member

17 Posts

Posted - 19 December 2000 :  00:41:06  Show Profile
First, let me say thanks to everyone for the great mods. They just keep getting better.

I downloaded the UserFields mod and installed. It created the table and I was able to insert a custom field via the admin page. For the sake of details, I entered the following information.

LABEL = Units
TYPE = S
SHORTNAME = User_Unit

All this gets entered successfully. I've updated admin_config_members.asp
config.asp
pop_profile.asp
inc_profile.asp
register.asp
per the instructions, but when I go to pop_profile.asp to view my profile information I don't see the custom "Unit" field.

Am I missing something? Maybe I just don't know what this mod is suppose to do. I want to use the mod to add an extra member field to capture what military style unit they want to be a member of. Then I could use this information to select which rank insignia image (a little custom hack of the badge mod I did) to display for the member. i.e. whether they are officers or enlisted, etc.

Any demos on how this is suppose to look and work?

Thanks

Indy
----
Is CHRISTmas a holiday or a HOLYday for you?
Go to Top of Page

bencal
Starting Member

USA
17 Posts

Posted - 28 December 2000 :  13:38:38  Show Profile  Send bencal a Yahoo! Message
I have downloaded and UnZipped the files and changed the config.asp to point back to the Access 97 db. I tried to do the "setup.asp", but get Where do I find the admin prog, "Mod Commander"?

Here's the SETUP.asp results:
The database you are using needs to be upgraded !!


Code : -2147217904


Thanks-



Edited by - bencal on 02 January 2001 18:39:51
Go to Top of Page

frankie
Junior Member

Vatican City
304 Posts

Posted - 28 December 2000 :  16:19:17  Show Profile  Visit frankie's Homepage  Send frankie an AOL message  Send frankie an ICQ Message  Send frankie a Yahoo! Message
HuwR,

Do you know why this mod doesn't post the members entries in the userfields to the MEMBERFIELDS table (that is the Usr_Value cloumn)?!!

Thoughts?!!

Note: When I added the values in the table manually, everything worked, otherwise nothing will show in the profile page after the user enters or modifies any of the added USERFIELDS!

ô¿~
Go to Top of Page

bencal
Starting Member

USA
17 Posts

Posted - 28 December 2000 :  21:12:37  Show Profile  Send bencal a Yahoo! Message
Well, I got the Mods Commander and it installed easily. The changes HuwR suggested were downloaded and istalled as directed. But, now the registration/logon now does not work. Did I miss something?
Go to Top of Page
Page: of 4 Previous Topic Topic Next Topic  
Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.19 seconds. Powered By: Snitz Forums 2000 Version 3.4.07