Jump to content


Photo
- - - - -

PHPurchase and PlatformPro css conflict


  • Please log in to reply
15 replies to this topic

#1 znagle

znagle

    Advanced Member

  • Members
  • PipPipPip
  • 30 posts

Posted 18 February 2011 - 07:36 PM

Can anyone further explain how to fix the settings page issue? I'm running into something very similar. When I go to Platform Pro Settings the Global Options and Template Setup are already expanded and I can't access any of the other sections. I tried renaming the jquery-ui-1.7.1.custom.css file in the PHPurchase plugin folder but didn't notice any effect. Any ideas?

#2 znagle

znagle

    Advanced Member

  • Members
  • PipPipPip
  • 30 posts

Posted 21 February 2011 - 07:36 PM

Is there a way to access the different settings panels when the jquery is broken? I need to change a blog setting but because of the jquery issues, clicking on it changes the page URL to "http://www.ragstock.com/wp-admin/admin.php?page=pagelines#blog_and_posts" but the panel doesn't expand and I'm unable to access the settings.

#3 bryan-hadaway

bryan-hadaway

    Advocate

  • Members
  • PipPipPipPipPip
  • 3697 posts

Posted 21 February 2011 - 11:43 PM

This is a known issue with the plugin: http://getsatisfacti...plugin_conflict Thanks, Bryan

#4 znagle

znagle

    Advanced Member

  • Members
  • PipPipPip
  • 30 posts

Posted 22 February 2011 - 05:28 PM

Thanks Bryan, Unfortunately it doesn't look like they've really resolved the issue. PHPurchase/Cart66 support has been pretty poor in my experience. The funny thing is, PHPurchase and Platform Pro were getting along fine until I upgraded to PHPurchase 2.6.7 from 2.6.5. Is there a way to manually access the different settings panels when the jquery is broken? Thanks for your help. -Zach

#5 cmunns

cmunns

    Advocate

  • Members

  • 6537 posts
  • Country: Country Flag

Posted 22 February 2011 - 05:52 PM

You can edit the plugin code yourself...basically add conditionals to any admin option css or jquery inclusion. It will likely say enqueue script or something like that...you can paste a few block of code if you want help, but please don't paste the whole enchilada

#6 znagle

znagle

    Advanced Member

  • Members
  • PipPipPip
  • 30 posts

Posted 22 February 2011 - 06:45 PM

Here's every instance of "wp_enqueue_script" in the phpurchase.php file. Any hints? ----------------------------------------------------- function PHPurchaseCustomScripts() { $path = WPCURL . '/plugins/phpurchase/js/ajax-setting-form.js'; wp_enqueue_script('ajax-setting-form', $path); // Include jquery-multiselect and jquery-ui wp_enqueue_script('jquery'); wp_enqueue_script('jquery-ui-core'); wp_enqueue_script('jquery-ui-sortable'); $path = WPCURL . '/plugins/phpurchase/js/ui.multiselect.js'; wp_enqueue_script('jquery-multiselect', $path, null, null, true); } add_action('admin_init', 'PHPurchaseCustomScripts'); ---------------------------------------------------- /** * Load the jquery library */ function PHPurchaseLoadJquery() { wp_enqueue_script( 'jquery' ); } add_action('wp_print_scripts', 'PHPurchaseLoadJquery'); ------------------------------------------------------ /** * Load the cart from the session or put a new cart in the session */ function PHPurchaseInitCart() { $setting = new PHPurchaseSetting(); $path = WP_PLUGIN_URL . '/phpurchase/js/phpurchase-library.js'; $forceHttps = $setting->lookupValue('auth_force_ssl'); if($forceHttps == 'yes' || $_SERVER['HTTPS'] == 'on' || $_SERVER['SERVER_PORT'] == 443) { $path = str_replace('http:', 'https:', $path); } wp_enqueue_script('phpurchase-library', $path, array('jquery'), '1.0'); session_start(); if(!isset($_SESSION['PHPurchaseCart'])) { $_SESSION['PHPurchaseCart'] = new PHPurchaseCart(); }

#7 bryan-hadaway

bryan-hadaway

    Advocate

  • Members
  • PipPipPipPipPip
  • 3697 posts

Posted 23 February 2011 - 02:09 AM

Adam may be able to assist. But, if your not liking the plugin, why not a try a more respected, popular plugin: http://wordpress.org.../wp-e-commerce/ I use the premium version successfully with my PlatformPro setup. Thanks, Bryan

#8 znagle

znagle

    Advanced Member

  • Members
  • PipPipPip
  • 30 posts

Posted 23 February 2011 - 04:36 PM

Thanks for the suggestion, Bryan. I'm in the process of evaluating alternatives.

#9 cmunns

cmunns

    Advocate

  • Members

  • 6537 posts
  • Country: Country Flag

Posted 23 February 2011 - 08:52 PM

You'd want to wrap this function: ` function PHPurchaseCustomScripts() { $path = WPCURL . '/plugins/phpurchase/js/ajax-setting-form.js'; wp_enqueue_script('ajax-setting-form', $path); // Include jquery-multiselect and jquery-ui wp_enqueue_script('jquery'); wp_enqueue_script('jquery-ui-core'); wp_enqueue_script('jquery-ui-sortable'); $path = WPCURL . '/plugins/phpurchase/js/ui.multiselect.js'; wp_enqueue_script('jquery-multiselect', $path, null, null, true); } ` using an if statement. ` function PHPurchaseCustomScripts() { if (is_page('PHPurchase'): $path = WPCURL . '/plugins/phpurchase/js/ajax-setting-form.js'; wp_enqueue_script('ajax-setting-form', $path); // Include jquery-multiselect and jquery-ui wp_enqueue_script('jquery'); wp_enqueue_script('jquery-ui-core'); wp_enqueue_script('jquery-ui-sortable'); $path = WPCURL . '/plugins/phpurchase/js/ui.multiselect.js'; wp_enqueue_script('jquery-multiselect', $path, null, null, true); endif; } ` To know the correct page name for the conditional open up any phpurchase admin page and look in the URL to see what they have it named...

#10 znagle

znagle

    Advanced Member

  • Members
  • PipPipPip
  • 30 posts

Posted 24 February 2011 - 04:30 PM

Thanks Adam! It turns out upgrading to Platform Pro 1.2.3 fixed it. Thanks for the code though, that might come in handy in the future.