vBadvanced Forums  
Go Back   vBadvanced Forums > vBadvanced Products > vBadvanced Links Directory > vBa Links Directory v1.0 Support > "How Do I..." Questions

Reply
 
Thread Tools Display Modes
  #1  
Old 11-20-2004, 12:49 PM
Lionel Lionel is offline
Senior Member
 
Join Date: Jan 2004
Location: Miami
Posts: 1,040
Default make field not required per category

I'd like to use one category as a yellow page.
I already used the hack to make url not required.
I made some custom fields for first and last names
Can I make those 2 custom fields required only on a specific category?
Reply With Quote
  #2  
Old 11-20-2004, 12:57 PM
Brian's Avatar
Brian Brian is offline
Administrator
 
Join Date: Jan 2004
Location: Georgia, USA
Posts: 34,240
Default Re: make field not required per category

In your addlink.php file look for this code:
PHP Code:
$thisfield 'field' $field
Right above it add this:
PHP Code:
        if (in_array($field, array(A,B,C)) AND !in_array($_POST['catid'], array(X,Y,Z)))
        {
            continue;
        } 
Replace A,B,C there with the fieldids and X,Y,Z with the catid(s) that those fields should be required in. I haven't tested this, but it should work fine.
Reply With Quote
  #3  
Old 01-12-2005, 09:49 PM
lee wilde's Avatar
lee wilde lee wilde is offline
Meow
 
Join Date: Jun 2004
Location: Perth, Australia
Posts: 47
Default Re: make field not required per category

This is cool.

Can I now make fields which are not required in a certain category, not visible in the "ADV_LINKS_ADD_EDIT" template?
Reply With Quote
  #4  
Old 01-13-2005, 10:38 AM
Brian's Avatar
Brian Brian is offline
Administrator
 
Join Date: Jan 2004
Location: Georgia, USA
Posts: 34,240
Default Re: make field not required per category

Not really since your users will pick the category on that page.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
More than one category. kittymother "How Do I..." Questions 6 05-03-2008 01:42 AM
Make URL field not required DougM "How Do I..." Questions 17 11-25-2005 01:45 PM
Make a category for a specific group attroll "How Do I..." Questions 2 10-17-2004 11:19 PM
Feature Request: Make "User" field editable to Mods ataraxia Feedback & Suggestions 1 10-06-2004 12:53 PM


All times are GMT -4. The time now is 09:35 AM.

Forums Powered by vBulletin, Copyright ©2000-2009, Jelsoft Enterprises Ltd.
Please note that vBadvanced is in no way affiliated with Jelsoft Enterprises Ltd, nor will Jelsoft be able to provide any support for our products.