You are here:  » Using CMS top level + Price Tapestry sub folder

Support Forum



Using CMS top level + Price Tapestry sub folder

Submitted by npaitken on Thu, 2008-09-25 14:51 in

Hi David,

I currently have Price Tapestry in top level with Wordpress in a sub-folder. I previously asked some questions relating to RSS feeds here http://www.pricetapestry.com/node/2194

However, now that I'm beginning to produce content for the site I'd like to explore other ways to manage content & navigation - as it's all a bit of a hack right now. In particular, I'd like to explore the idea of using a more versatile CMS like Joomla in top level with Price Tapestry in a sub folder but want to keep the integration relatively simple, as I no php/cms expert!

So I'm thinking if I can replicate the something similar to the current layout without too much fuss it might be worhtwhile doing.

replicating current layout
--------------------------
Homepage - Is it possible to bring something like 'featured products' to the Joomla homepage. That is, have Product snippets (Title, description, image, from £price info, more information LINK) - that would be very handy.

Sidebar Navigation - At the moment I have hard coded category links which go hard-coded category pages. On these pages there's a list of hard coded links like (mysite.co.uk/search.php?q=red+widgets). Preseumably, I could just replicate this in Joomla.

Search results - So if a search is done, you'd be in Price Tapestry right? So I'd just have to make sure Joomla Template / Price Tapestry Template match up right?

Product page - again, you'd be in Price Tapestry right? So I'd just have to make sure Joomla Template / Price Tapestry Template match up right?

Product mapping - Will my current product mapping be affected in any way?

Sitemaps - This would be a bit messy as I've already submitted to Google and been indexed. But presumably I'd just use a Joomla sitemap + PT sitemap as resubmit.

new things I'd like to do
-------------------------
Buyer Guides - Is it possible to embed 'product snippets' (Title, description, image, from £price info, more information LINK) in Joomla pages? This would be a very common thing I'd to do for all sorts of content pages - buyer guides, top 10 lists, etc.

At the end of the day I'm just trying to weigh-up work involved versus benefits.

Many thanks,
Neil

Submitted by support on Thu, 2008-09-25 16:41

Hi Neil,

Yes! This has come up very recently, and I just posted a couple of scripts and example code for doing just that - showing search (product) and price comparison results externally. See the following thread for more info:

http://www.pricetapestry.com/node/2289

Cheers,
David.

Submitted by npaitken on Mon, 2008-09-29 20:40

Hi David,

Thanks for getting back to me. I've decided to go head and use CMS in top level and PT in subfolder. Is it a difficult job to move an existing PT install from top level to subfolder?

Is there a list of things I need to amend/update? e.g:
config.php
database
category mapping
product mapping
hard coded links to change
etc

Best regards,
Neil

Submitted by support on Tue, 2008-09-30 07:38

Hello Neil,

It shouldn't be too hard; nothing in the script or database is hard coded with regards to the directory. You would need to change:

config.php
$config_baseHREF = "/newfolder/";

.htaccess (if useing)
RewriteBase /newfolder/

...and that should be it; other than any hard coded links in your own customisations in the /html/ directory - particularly images or any other style sheets etc...

Cheers,
David.

Submitted by npaitken on Tue, 2008-09-30 15:25

Hi David,

At the end of the day, what code should my .htaccess have and where should the file be located?

My original .htaccess file was located in top folder along with PT and looked like this:

Options -MultiViews
RewriteEngine On
RewriteBase /
RewriteRule ^product/(.*).html$ products.php?q=$1&rewrite=1&%{QUERY_STRING} [L]
RewriteRule ^review/(.*).html$ reviews.php?q=$1&rewrite=1&%{QUERY_STRING} [L]
RewriteRule ^merchant/$ merchants.php
RewriteRule ^merchant/(.*)/$ search.php?q=merchant:$1:&rewrite=1%{QUERY_STRING} [L]
RewriteRule ^merchant/(.*)/(.*).html$ search.php?q=merchant:$1:&page=$2&rewrite=1%{QUERY_STRING} [L]
RewriteRule ^category/$ categories.php
RewriteRule ^category/(.*)/$ search.php?q=category:$1:&rewrite=1%{QUERY_STRING} [L]
RewriteRule ^category/(.*)/(.*).html$ search.php?q=category:$1:&page=$2&rewrite=1%{QUERY_STRING} [L]
RewriteRule ^brand/$ brands.php
RewriteRule ^brand/(.*)/$ search.php?q=brand:$1:&rewrite=1%{QUERY_STRING} [L]
RewriteRule ^brand/(.*)/(.*).html$ search.php?q=brand:$1:&page=$2&rewrite=1%{QUERY_STRING} [L]

I've now done a clean Wordpress install in top level and a new .htaccess has been created and looks like this:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

Should I create 1 file in top level with all the above code? or two files, one in top level with wordpress code, and 1 in subfolder with PT code?

Many thanks,
Neil

Submitted by support on Wed, 2008-10-01 08:57

Hello Neil,

It's best to keep them separate - so move Price Tapestry's .htaccess down into the sub-directory, and then edit RewriteBase as required; for example:

RewriteBase /shopping/

Cheers,
David.