There are certain sub-categories which I do not want people to add links to. Accordingly, I will add a field to the categories database called AllowSubmit. It will be a yes/no field, and if no, when someone clicks on Add URL from a sub-category, they will be sent to a page telling them thusly. My question: In add.cgi, how do I call the field from the categories database?
Mar 9, 1999, 3:53 PM
Veteran / Moderator (3108 posts)
Mar 9, 1999, 3:53 PM
Post #2 of 4
Views: 270
I have never seen this question before (maybe others did), so I don't know where the "Gonna Ask This One More Time!" is coming from. If you asked it before, why didn't you just post a follow-up to that message so that we could see that you asked previously. With the recent move in the Gossamer server, messages may have been missed. Demanding an answer, as implied by your subject, isn't the best way to go about getting an answer.
Having said that, have you looked in add.cgi to see how other fields are handled and then tried to use your field in a similar manner? For example:
$in{$db_cols[$db_modified]} = &get_date;
From those two lines, it becomes clear that the fields are contained in the $in variable, indexed by $db_cols using a subscript of the field number, in this case, the $db_modified field.
I hope this is what you are looking for.
[This message has been edited by Bobsie (edited March 09, 1999).]
Having said that, have you looked in add.cgi to see how other fields are handled and then tried to use your field in a similar manner? For example:
Code:
# Set date variable to today's date. $in{$db_cols[$db_modified]} = &get_date;
From those two lines, it becomes clear that the fields are contained in the $in variable, indexed by $db_cols using a subscript of the field number, in this case, the $db_modified field.
I hope this is what you are looking for.
[This message has been edited by Bobsie (edited March 09, 1999).]
Thanks Bobsie:
Sorry if I sounded 'demanding' in my title ... that wasn't my sentiments at all. This message board is an excellent service and I am thankful for all who contribute here ... I have learned tremendous amounts from reading these posts!
My problem is this: My new field which I have in the categories.db, not the links.db. When a visitor wants to add a site, I need to check the hard-coded category against a field in the categories.db. How am I able to load the category fields I need along with the links fields?
[This message has been edited by Lee (edited March 10, 1999).]
Sorry if I sounded 'demanding' in my title ... that wasn't my sentiments at all. This message board is an excellent service and I am thankful for all who contribute here ... I have learned tremendous amounts from reading these posts!
My problem is this: My new field which I have in the categories.db, not the links.db. When a visitor wants to add a site, I need to check the hard-coded category against a field in the categories.db. How am I able to load the category fields I need along with the links fields?
[This message has been edited by Lee (edited March 10, 1999).]

