<$BlogRSDURL$>
Interchange 5.0 hacks
Friday, October 27, 2006
  mod_interchange installation and configuration:

Check in your Admin UI --> admin/env_vars.html in your SERVER SOFTWARE variable what mods you have installed with your server, in my case:

'SERVER_SOFTWARE' => 'Apache/1.3.37 (Unix) mod_interchange/1.34 mod_perl/1.28 PHP/4.4.4 mod_ssl/2.8.28 OpenSSL/0.9.7e-p1'

As you can see I already have mod_interchange installed as a DSO object with Apache. Number 4 below details installation.

1. Install the latest version. As of 10/27/06 mod_interchange 1.34 comes with interchange 5.5.0. NOT. Check CVS nightly for the latest version.

2. Uninstall any olde version that might reside in your interchange (IC) directory, in my FreeBSD it's in /usr/local/interchange/src/mod_interchange/*.

3. Fetch into your IC directory, then Make, Make Install. You may want to uncomment the "install" line in the Makefile.

4. Read REAME file installed with mod_interchange files.

5. With my existing Apache install I decided that building the module as a DSO was the best route.

6. I added the two lines to my httpd.conf file:

LoadModule interchange_module /wherever/lib/apache/mod_interchange.so
AddModule mod_interchange.c

7. You then add the added the following within my VirtualHost directive:

snip, snip...


<Location /psychology_books>
SetHandler interchange-handler
InterchangeServer  /usr/local/interchange/etc/socket
DropRequestList /default.ida /x.ida /cmd.exe /root.exe
OrdinaryFileList /thethink /images /interchange-5 /css
</Location>

</VirtualHost>

8. Add the following to interchange.cfg:

#========================================================================#

SocketPerms 0660

# Set up individual catalogs here.

#Catalog store /var/lib/interchange/store /cgi-bin/store
Catalog thethink /usr/home/thethink/catalogs/thethink /psychology_books

9. Open and save variable.txt file for that particular catalog and adding the shop name to the CGI_URL, i.e. CGI_URL /psychology_books/ Directories and Path

10. Then do this:

1. Stop interchange -
/usr/local/interchange/bin/interchange -stop

2. Change the group and mode of the *directory* -

chgrp www /usr/local/interchange/etc/

chmod 2770 /usr/local/interchange/etc/

3. Restart interchange -
/usr/local/interchange/bin/restart 
Friday, January 06, 2006
  Create drop down menus:

1. Add variables directory and MENU_VRIABLES (4 files* below) within /usr/home/marbex/catalogs/marbex/variables. These are used within the individual pages/templates to load essential scripyt, i.e. _COMMON_MENU_ etc.



COMMON_MENU

[menu name="[scratch menu_bar]"
menu-type=flyout
use-file=1
anchor_down=1
entities=description
exclude_on=exclude_on
items=depends_on
js_prefix=top_
flyout_class=submenu
flyout_style="border: 1px solid #dddddd; padding: 4px; padding-left: 1px"
submenu_image_right="[var IMAGE_DIR]/sm_right.gif"
inactive=inactive
indicator_class="menu_class=name"
indicator_page=page
link_class=submenu
nbsp=name
logged_in=member
]
[menu-header]



[/menu-header]
{MV_LEVEL:}



{/MV_LEVEL:}
[/menu]





LINE_MENU

[if !scratch line_menu]
[tmpn line_menu]catalog/line[/tmpn]
[/if]

[menu
name="[scratch line_menu]"
full_interpolate=page
localize="name,description"
]
{MV_LAST_ROW:} {/MV_LAST_ROW:}{MV_LAST_ROW?} {/MV_LAST_ROW?}

[menu-footer]
[if session admin]

[/if]
[/menu-footer]
[/menu]

{NAME} -[L]edit[/L]



PAGE_INIT

[calc]
$Variable->{MV_DHTML_BROWSER} = 'MSIE.*[5-9]\..*WindowsMozilla.*GeckoOpera.*[7-9]\.';
$Scratch->{dhtml_browser} =
$Session->{browser} =~ m{$Variable->{MV_DHTML_BROWSER}};
if($Scratch->{members_only} and ! $Session->{logged_in}) {
$Scratch->{mv_successpage} = $Tag->var('MV_PAGE', 1);
$Tag->deliver({ location => $Tag->area('login')});
}
return;
[/calc]


##### BTW, there are more otherTags like above in the 5.3 catalog.cfg to determine whether the user has a DOM-compliant browser #############


THEME_CSS




2. Import the 5.3 tree.txt within the Menu Editor. It contains the menu structure that opens the lower-level menus when you mouse-over the top-level menu links.

The rest is coming...

 
Thursday, November 24, 2005
  How to add your own fields to the ui Edit Item page ic4.8.x.
============================================================

These instructions show you how to add a field to the record editor pages in
the admin ui. This assumes you are adding a field to the 'products' table,
it has already been added in the database, and Interchange is aware of it. remeber to add addt'l columns/field names to corresponding *.txt files within the Products folder, i.e. merchandising.txt.

1) Log in to the admin ui with super user permissions.
2) Go to the Administration section.
3) Click on tables.
4) Click on the Products table icon to edit the table entries.
5) Click on the link 'products' immediately after the 'Select table to edit' heading.

You are now at the mv_metadata settings which define the display of the table data.

6) Add the name of your field to the list named 'Fields to edit'. These are
in the order they will be displayed for editing.
7) Click OK

The field should now appear in the edit item page.

8) Now go to edit an item - your field should be there.
9) Click on the 'meta' link next to the field name. (it there is no 'meta' link you need to set the variable 'UI_META_LINK' to 1 in the Admin Control preference group.
10) set up the label, field type, width etc. and save.

>Hello all:
>
>Basics: IC 5.0.1, MYSQL, FreeBSD 4.7
>
>I'm attempting to add the ability for one item to be within several (3)
>separate Promotions. In doing so, I created two additional fields within the
>merchandising table called featured_2 and featured_3. I'm able to add the
>two additional widgets (for the two new fields) within the "Select for table
>edit: merchandising" UI though I can't find a way to add the two widgets to
>the "Merchandising Editor" UI or the "Promotion: edit item" UI. Any ideas?
>
>Thanks,
>
>David Radovanovic

You'll want to edit the ui_data_fields string which is set on the admin
page(s) for these functions (i.e.: admin/item_feature.html). The admin
pages are located in VENDROOT/lib/UI/pages/admin/ and can be edited there
for a server-wide modification, or the page of concern can be copied to
CATROOT/pages/admin/ for a single-catalog mod. Once the field appears on
the editor form, you can change the meta to use the widget and related
properties you desire.

- Ed L.
 
Thursday, February 10, 2005
  To create a comments/instructions field to checkout page,
i.e. "Please include card with biscotti saying, Love David, etc."
BTW, there is a value gift_note that had been half-heartedly to the report page though I couldn't get it to work properly.

The files you'll need to add the comments/instructions value to:

Four files in /catalog_root/etc/report, mail_receipt, receipt, log_transaction adding:

"Comments: [value comments]" to the mail_receipt, receipt, report

and then adding:

"comments: [value filter=mac name=comments]"

to log_transaction so that it writes to the transaction table (if you want it to write to database):


Depending on the checkout process you use (multi-page or not):

I added this to /catalog_root/include/checkout/shipping_address:



There are a number of other pages that you will want to add "Comments: [value comments]" depending on your customization of IC.

I hope I'm not forgetting anything, though I probably am.





 
Wednesday, February 04, 2004
  Let's start blogging! La, la ,la... 
Keeping track of changes I've made to Interchange shopping carts and their respective ITL scripts and hacks.

ARCHIVES
02/01/2004 - 03/01/2004 / 02/01/2005 - 03/01/2005 / 11/01/2005 - 12/01/2005 / 01/01/2006 - 02/01/2006 / 10/01/2006 - 11/01/2006 /


Powered by Blogger