Results 1 to 1 of 1

Thread: Allow Parent Category Posting Problem/MOD?

  1. #1
    Thread Starter
    Amateur mdehaan's Avatar
    Join Date
    Sep 2013
    Location
    Netherlands
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Allow Parent Category Posting Problem/MOD?

    classipress-3.3.3

    I want to disallow posting in parent categories and also sub-parent categories.
    I have set "Allow Parent Category Posting" to NO.
    This works for the first level parent categories, but not for the second level parent categories.

    This is what happens when I select a sub-parent categoty.
    Schermafbeelding 2014-09-12 om 10.11.38.png

    And this is how it has to be.
    Schermafbeelding 2014-09-12 om 10.11.15.png

    Can this be fixed by changing something to these lines of code?

    classipres/includes/js/theme-scripts.js
    Line 485 to 496

    // always check if go button should be on or off, jQuery parent is used for traveling backup the category heirarchy
    if ( ( allow_parent_posting === 'yes' && jQuery('#chosenCategory input:first').val() > 0) ) {
    jQuery('#getcat').fadeIn();
    //check for empty category option
    } else if ( whenEmpty && allow_parent_posting === 'whenEmpty' && jQuery('#chosenCategory input:first').val() > 0 ) {
    jQuery('#getcat').fadeIn();
    //if child category exists, is set, and allow_parent_posting not set to "when empty"
    } else if ( jQuery('#' + results_div_id + (level-1)).hasClass('childCategory') && jQuery(dropdown).val() > -1 && allow_parent_posting === 'no' ) {
    jQuery('#getcat').fadeIn();
    } else {
    jQuery('#getcat').fadeOut();
    }

    Thanx in advance!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Samcy Allow Parent Category Posting Problem
    By masglobal in forum Report ClassiPress Bugs
    Replies: 3
    Last Post: August 29th, 2014, 04:44 AM
  2. Exclude parent category from new job posting
    By glozano in forum JobRoller General Discussion
    Replies: 0
    Last Post: July 29th, 2012, 04:41 PM
  3. [SOLVED] Problem with posting adds ( category add number is displayed)
    By dismacoa in forum ClassiPress General Discussion
    Replies: 3
    Last Post: May 8th, 2012, 10:33 AM
  4. Allow Parent Category Posting
    By dydione in forum Report ClassiPress Bugs
    Replies: 3
    Last Post: December 9th, 2011, 08:31 AM
  5. How to disable ad posting into parent category?
    By hafihz in forum ClassiPress General Discussion
    Replies: 2
    Last Post: May 10th, 2011, 06:28 PM