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

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: MOD Implementation
 Changing base member info
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

mtercek
New Member

56 Posts

Posted - 12 January 2005 :  13:36:23  Show Profile
We would like to add a phone ext to the member info. I could probably use the country code field as we do not need that.

Which file would I change to do that?

tribaliztic
Senior Member

Sweden
1532 Posts

Posted - 12 January 2005 :  13:44:45  Show Profile  Visit tribaliztic's Homepage  Send tribaliztic an ICQ Message
inc_profile.asp and pop_profile.asp, if I remember correct you have to edit both.

/Tribaliztic
- www.gotlandrace.se -
Go to Top of Page

mtercek
New Member

56 Posts

Posted - 12 January 2005 :  16:05:52  Show Profile
I was able to change the heading from country to Phone Ext so I am half way there.

Where is the list of countrys kept? I thought it would be in the access .mdb but the list isn't there.

Anyone tell me where I can go edit that list? I will just add all of our possible ext.
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 12 January 2005 :  16:14:01  Show Profile
Look in inc_countrylist.asp


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

mtercek
New Member

56 Posts

Posted - 12 January 2005 :  16:19:07  Show Profile


Yep, there they are. Thanks!
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 12 January 2005 :  16:25:45  Show Profile
You're welcome


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

mtercek
New Member

56 Posts

Posted - 12 January 2005 :  16:29:51  Show Profile
OK, while I am on a roll here...

How could I change this file to allow a user to enter their ext themselves?

Here's one of the current lines for the country file:

Response.Write " <option value=""Afghanistan"">Afghanistan</option>" & vbNewLine & _

I could comment out the current lines and add one that allows entry? Or am I stuck with adding a line for everyone existing phone ext?

TIA

Go to Top of Page

tribaliztic
Senior Member

Sweden
1532 Posts

Posted - 12 January 2005 :  16:49:47  Show Profile  Visit tribaliztic's Homepage  Send tribaliztic an ICQ Message
Remove the part with the options and copy code from another field where the user can enter data. That's how I do most of my coding, stealing snippets of code here and there and putting together to something new =)
It's a great way to learn how the code work anyways..

/Tribaliztic
- www.gotlandrace.se -
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 13 January 2005 :  05:58:49  Show Profile
To elaborate, to replace the country dropdown with a text input, find the following block of code beginning on approximately line 327 (fresh 3.4.04+):
if strCountry = "1" then
	Response.Write	"                    <tr>" & vbNewLine & _
			"                      <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Country: </font></b></td>" & vbNewLine & _
			"                      <td bgColor=""" & strPopUpTableColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
			"                      <select name=""Country"" size=""1"">" & vbNewLine
	if strMode <> "Register" then
		Response.Write("                           <option selected value=""" & rs("M_COUNTRY") & """>" & ChkString(rs("M_COUNTRY"), "display") & "</option>" & vbNewLine)
	else
		Response.Write	"                           <option value=""""></option>" & vbNewLine
	end if
	Response.Write	"                           <option value="""">None</option>" & vbNewLine
%>
	<!--#INCLUDE FILE="inc_countrylist.asp"-->
<%
	Response.Write	"                      </select></font></td>" & vbNewLine & _
			"                    </tr>" & vbNewLine
end if
and replace it with the following:
if strCountry = "1" then
	Response.Write	"                    <tr>" & vbNewLine & _
			"                      <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Country: </font></b></td>" & vbNewLine & _
			"                      <td bgColor=""" & strPopUpTableColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
			"                      <input type=""text"" size=""25"" name=""Country"" value="""
	if strMode <> "Register" then
		Response.Write	ChkString(rs("M_COUNTRY"), "display")
	end if
	Response.Write	""" maxlength=""12"" /></font></td>" & vbNewLine & _
			"                    </tr>" & vbNewLine
end if
You may wish to alter the maxlength attribute of the input (highlighted in blue above) or remove it completely.


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

mtercek
New Member

56 Posts

Posted - 13 January 2005 :  11:27:47  Show Profile
Yes! Awesome! That worked!

thanks very much everyone!

Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 13 January 2005 :  11:48:32  Show Profile
No problem; glad to be of service.


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

cchouse
Starting Member

4 Posts

Posted - 07 February 2005 :  22:33:03  Show Profile
Hi, if I may ask a question about the above, when changing the member info category name, ie from country to phone ext, do you have to change all occurances of the 'country' name in the inc_profile and pop_profile files?

I ask because i can change the displayed name but when i go into the database file the input is not saved.

Thanks for your help!
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 08 February 2005 :  05:36:12  Show Profile
No, it will still be saved to the M_COUNTRY field in the MEMBERS database.

The only thing you may need to change are the labels that read "Country:" in the various files.


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

cchouse
Starting Member

4 Posts

Posted - 08 February 2005 :  17:45:10  Show Profile
Thanks Shaggy but i'm still having a problem with the database saving the result in the country field. To check again, I logged in as an admin and manually updated this 'renamed' field, saved the results, then went back into the member record, and the update was not there. So its not saving it and I'm wondering if its due to the label change? I would not have thought so....thanks again!
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 09 February 2005 :  06:08:21  Show Profile
The value of the name attribute of the input field you're using must be Country for it to work.


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

cchouse
Starting Member

4 Posts

Posted - 09 February 2005 :  13:00:06  Show Profile
Not sure if i understand. What i did was use the occupation field and renamed it 'community name'. the field attribute for occupation should be just text, correct? I have only a limited knowledge of databases but i thought if i didnt change the underlying field, just the text name of that field, it should post normally to the occupation field? I know i'm missing something easy so i apologize for my further questions.
Go to Top of Page
Page: of 2 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.25 seconds. Powered By: Snitz Forums 2000 Version 3.4.07