I have a working dbman set up and i wanted to have default and registered users to be able to add to the database..but i wanted to block a few fields when ever the did thier search on the database..ie email,address,phone number etc..how can i do this..thanks for any info
If you only want the admin to see these fields, then use the following codes:
if ($per_admin) {
print qq|$rec{'FieldName'}|;
}
print qq|
If you want people who add records to see these fields, then replace $per_admin with $per_add. Also, replace FieldName with the name of your fields that you want the admin or others to see.
Regards,
------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
----------------------
Code:
|; if ($per_admin) {
print qq|$rec{'FieldName'}|;
}
print qq|
If you want people who add records to see these fields, then replace $per_admin with $per_add. Also, replace FieldName with the name of your fields that you want the admin or others to see.
Regards,
------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
----------------------
Jan 3, 2000, 2:29 PM
Novice (7 posts)
Jan 3, 2000, 2:29 PM
Post #3 of 6
Views: 2333
Eliot thanks for helping me with this..
What im have is 16 fields in the dbman
I have used the configurator and generated the 2 following files
http://www.adoptionseekers.com/default.txt
http://www.adoptionseekers.com/html.txt
when i use the configurator i get the missing bracket error...Reason: Missing right bracket at ./html.pl line 1458, at end of line
syntax error at ./html.pl line 1458, at EOF
I can plainly see that the problem is in these few lines in the sub html_record...It seems to be putting an extra { at the end of the lines...
print qq| |;
if ($rec{'Your State'}) {
print qq| |;
if ($per_admin) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Your State:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Your State'}</Font></TD></TR>
|;
}
.......................................
if ($rec{'Your State'}) {
you can see at the end of the line it has an extra { with no closing bracket..im not sure what to do with it..remove it or add another ..its confusing me..
it also appears here as well....
print qq| |;
if ($rec{'Phone Number'}) {
print qq| |;
if ($per_admin) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Phone Number:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Phone Number'}</Font></TD></TR>
|;
}
when i did this on the configurator it was admin only but not required...What im trying to accomplish is that all required fields are to filled out but registered users but only i can see the submitted info that i have marked per admin
can you help me with this please?
thanks again..
carl
[This message has been edited by chorton (edited January 03, 2000).]
What im have is 16 fields in the dbman
I have used the configurator and generated the 2 following files
http://www.adoptionseekers.com/default.txt
http://www.adoptionseekers.com/html.txt
when i use the configurator i get the missing bracket error...Reason: Missing right bracket at ./html.pl line 1458, at end of line
syntax error at ./html.pl line 1458, at EOF
I can plainly see that the problem is in these few lines in the sub html_record...It seems to be putting an extra { at the end of the lines...
print qq| |;
if ($rec{'Your State'}) {
print qq| |;
if ($per_admin) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Your State:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Your State'}</Font></TD></TR>
|;
}
.......................................
if ($rec{'Your State'}) {
you can see at the end of the line it has an extra { with no closing bracket..im not sure what to do with it..remove it or add another ..its confusing me..
it also appears here as well....
print qq| |;
if ($rec{'Phone Number'}) {
print qq| |;
if ($per_admin) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Phone Number:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Phone Number'}</Font></TD></TR>
|;
}
when i did this on the configurator it was admin only but not required...What im trying to accomplish is that all required fields are to filled out but registered users but only i can see the submitted info that i have marked per admin
can you help me with this please?
thanks again..
carl
[This message has been edited by chorton (edited January 03, 2000).]
I would recommend NOT using the configurator to make adjustments to your HTML codes in the html.pl file!
These codes are ALL screwed up:
if ($rec{'Phone Number'}) {
print qq| |;
if ($per_admin) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Phone Number:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Phone Number'}</Font></TD></TR>
|;
}
THEY should be the following:
if ($per_admin) {
if ($rec{'Phone Number'}) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Phone Number:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Phone Number'}</Font></TD></TR>
|;
}
}
Regards,
------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
----------------------
These codes are ALL screwed up:
Code:
print qq| |; if ($rec{'Phone Number'}) {
print qq| |;
if ($per_admin) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Phone Number:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Phone Number'}</Font></TD></TR>
|;
}
THEY should be the following:
Code:
|; if ($per_admin) {
if ($rec{'Phone Number'}) {
print qq|
<TR><TD ALIGN="Right" VALIGN="TOP" WIDTH="20%"><$font_color>Phone Number:</FONT></TD>
<TD WIDTH="80%"> <$font>$rec{'Phone Number'}</Font></TD></TR>
|;
}
}
Regards,
------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
----------------------
Good.
Regards,
------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
----------------------
Regards,
------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
----------------------