Incorporate WordPress with Interspire Shopping Cart

March 30, 2009

in Interspire,WordPress

I’m going to elaborate on this further (and about Interspire in general), but for those of you who want to make WordPress functions available throughout your shopping cart, here’s how:

Before the closing ?> in the init.php file, add the following code:
require(realpath(ISC_BASE_PATH).'/blog-directory/wp-blog-header.php');, where /blog-directory/ is your WP installation. If you installed it in the root directory, then you’d simply need require(realpath(ISC_BASE_PATH).'/wp-blog-header.php');
(see Update below).

Update: There is a bug that happens when the include is placed at the bottom of init.php; instead, add require(realpath(ISC_BASE_PATH).'/wp-blog-header.php'); on the line below require_once(dirname(__FILE__).'/lib/init.php'); (line 3).

Voila! That simple. Any questions?

Interspire + WordPress Update:

I don’t know if it’s because WordPress has been updated, or if it’s because Interspire has been, but there is a function conflict going on between the two softwares. Unfortunately, you need to replace your WordPress installation’s wp-includes/formatting.php file to have if(!function_exists()) for every function.

Here’s the file:

  formatting.php (91.7 KiB, 212 hits)

Interspire + WordPress Update 2:

So, after searching Interspire Shopping Cart for each function in formatting.php, I found there are only two conflicting functions:

  • convert_chars()
  • stripslashes_deep()

If you wrap these functions found in /wp-includes/formatting.php in function_exists, everything works just dandy.

A very, vitally important note:

After some frustrating hours trying to figure out why adding products to the cart wasn’t working, I discovered that the WordPress function wp_unregister_GLOBALS() was screwing up the works. I also found another article with the same problem, and the solution: turn off register globals. You need to update your php.ini file with register_globals Off. You can also search Google for more info on how to do that.

Share and Enjoy:
  • Print
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • StumbleUpon
  • Technorati
  • Twitter

Related posts:

  1. Recover your password from Interspire Shopping Cart
  2. Add ‘Customers Also Purchased’ to the Cart Page on Interspire Shopping Cart
  3. Interspire Shopping Cart — Add a Brands Drop-Down Menu
  4. Generate CSS Body Classes in Interspire Shopping Cart
  5. How to Add an `Edit Product` Link for Interspire Shopping Cart

17 comments… read them below or add one

Mitch May 21, 2009 at 10:07 pm

I have a real estate website using Interspire Shopping Cart, and was just reading your WordPress real estate site article with the view to ditch interspire. I never thought of combining them – great idea. Thanks for the post!!

Reply

Bruno Goyanna June 5, 2009 at 2:05 pm

I have a working Interspire Shop Cart I wonder what the advantage and if you have a model working with this technique your

Thanks

Reply

TheFresh June 12, 2009 at 8:21 pm

I installed WordPress; I added your code; now what? How do I apply WordPress to my Interspire Shopping Cart?

Reply

Joe January 15, 2010 at 10:30 pm

Could you explain this a little more clearly?  I have a couple of questions.  1. There isn’t a ?> in the init.php file.   2.  When I added this at the end of the page, it made my homepage turn blank. 

I guess… what is the expected outcome when doing this?  And where exactly should this go?  I’m not sure I completely understand what this would accomplish, but I’m very interested in finding out. 

Thanks! 

Reply

Zack Katz January 19, 2010 at 3:52 pm

I wrote this tutorial for a previous version of Interspire Shopping Cart. I am working on a newer version of Interspire right now, and I’ll post a revised update on how to incorporate the two.

The goal is simply to have the WordPress database and functions available in the Interspire framework, so that if I wanted to, I could find related posts to a specific product, for example.

Reply

Sid January 26, 2010 at 2:56 am

Any updates on how to pull this off with the new version of Interspire’s Cart?
 
//sid

Reply

Tommy January 29, 2010 at 7:04 am

Any update for the latest ISC Zack  ? And more information on how to use it ?

Thanks

Reply

Zack Katz February 19, 2010 at 6:02 am

Hi Joe,
I found out that the page turned blank because of a PHP function conflict. Check out the updated post above.

Reply

Mike February 5, 2010 at 1:18 pm

Would be interested in this too…haven’t bought interspire cart yet, but probably would if there was an easy way to incorporate it into WP.

Reply

Danno March 10, 2010 at 2:55 am

Cool info Zack. I am currently using both I have http://shop.dura-mounts.com running wordpress and http://www.dura-mounts.com running interspire. I am going to use your technique. Thanks. By the way people. What Zack is saying is that you will be able to call and use funtions and the database from wordpress to use in Interspire, but you still need some programming knowledge to implement it.

Reply

Zack Katz March 10, 2010 at 4:06 am

Yes, that’s exactly what I would have tried to say :-)

Reply

VId April 23, 2010 at 10:11 am

I have one question. How do I send email to all customer?

Reply

Justus Rowe May 1, 2010 at 8:42 pm

It’s still unclear what value this has. I mean, what functions would you want/need to use from wordpress with interspire and how would one do this? Related posts, ok but how? Like say you implement this and it’s working. How then would you use these functions with the cart? This article is like giving someone a forklift and not teaching them how to use it.
I’m just asking again for the people who really don’t understand where you are going with this.  I use wordpress and Interspire together without doing anything special. I use Interspire’s RSS capabilities to pull in all blog articles (or ones related to products only) and I use wordpress’s RSS capability to pull in any products from Interpsire via an RSS feed.  I really wish Interspire had a real blog feature that pinged when you submit an article. WordPress is really nothing special other than ease of use and pinging IMHO.

Reply

irfan ahmed May 7, 2010 at 3:25 pm

thank you
 
irfan

Reply

Shopping Cart June 23, 2010 at 10:31 am

how can we finish the conflict between these two softwares, without replacing WordPress installation’s

Reply

Zack Katz June 24, 2010 at 8:19 pm

Unfortunately, there’s no easy way to do this. It will throw a fatal error every time. The reason I used @include instead of include is to prevent any errors from messing up the shop. However, other than that, I found no easy solution.

Reply

ThomasNelson August 9, 2010 at 5:03 am

This is a great post.

i am just now beginning to create all of my pages am I definitely looking to integrate a WordPress Blog in the same fashion you are but would like them both sync and look seamless as a customer goes through the site.

Reply

Leave a Comment

Previous post:

Next post: