Results 1 to 4 of 4

Thread: jQuery management in Classipress

  1. #1
    Thread Starter
    aquirio's Avatar
    Join Date
    Feb 2013
    Location
    France
    Posts
    61
    Thanks
    6
    Thanked 1 Time in 1 Post

    jQuery management in Classipress

    Hello,

    I know that there were several threads on the subject but I do not find a basic solution to make sure that the jQuery is properly installed in Classipress.

    I have mostly identify 2 recommendations (child them recommanded) :

    1/ Add a function in functions.php

    // jQuery
    add_action('init', 'prefix_init');
    function prefix_init(){
    if(is_admin()){
    wp_enqueue_script('jquery');
    }
    }


    2/ Modify the head section of wrapper.php
    Here is the extract with the addedcode in red:
    <?php if ( is_singular() && get_option('thread_comments') ) wp_enqueue_script('comment-reply'); ?>
    <?php wp_enqueue_script("jquery"); ?>
    <?php wp_head(); ?>
    <script type="text/javascript"
    src="<?php bloginfo("template_url"); ?>/js/yourScript.js"></script>


    As I am not a specialist in php I didn't identify what is the difference between the two methods and I don't know what are the incidence of them on the website functionality.
    Moreover I saw that in Classipress the jQuery files are numerous and in wp-includes/js/jquey folder and not in a wp-content/theme/classipress/js folder as it seems to be usually.

    Your comments are welcome.

  2. #2
    seoagent's Avatar
    Join Date
    Jul 2012
    Location
    Edmonton, AB, Canada
    Posts
    660
    Thanks
    136
    Thanked 86 Times in 74 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    When in doubt: Read, Ask, Do. G+

  3. #3
    Thread Starter
    aquirio's Avatar
    Join Date
    Feb 2013
    Location
    France
    Posts
    61
    Thanks
    6
    Thanked 1 Time in 1 Post
    You must be an AppThemes customer and logged in to view this response. Join today!

  4. #4
    seoagent's Avatar
    Join Date
    Jul 2012
    Location
    Edmonton, AB, Canada
    Posts
    660
    Thanks
    136
    Thanked 86 Times in 74 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    When in doubt: Read, Ask, Do. G+

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Dimitris Old jQuery version if 'Google CDN jQuery' is activated?
    By per4mance in forum Report JobRoller Bugs
    Replies: 2
    Last Post: March 10th, 2013, 04:27 PM
  2. management listings classipress
    By sandro in forum Report ClassiPress Bugs
    Replies: 7
    Last Post: September 4th, 2012, 02:44 PM
  3. Adding jquery scripts to a Classipress child theme
    By ybpress in forum Report ClassiPress Bugs
    Replies: 7
    Last Post: January 31st, 2012, 11:39 AM
  4. How to Distinguish Between Management and Non Management Job Postings
    By bbuster79 in forum JobRoller General Discussion
    Replies: 1
    Last Post: February 26th, 2011, 07:50 PM