Ok I guess it does three thing =\
________________________________
Alex Boyer
Webmaster
Hobby Products International
70 Icon Street
Foothill Ranch, CA 92610 USA
949 753 1099 x 135
949 753 1098 fax
Latest Option Parts and Bodies!
-----Original Message-----
From: owner-merchant5-users listmgr.miva.com
[mailto:owner-merchant5-users listmgr.miva.com] On Behalf
Of Alex Boyer
Sent: Friday, March 10, 2006 1:33 PM
To: proka prokofievcreative.com; merchant5-users listmgr.miva.com
Subject: RE: [m5u] Using just the MIVA back end for
processing orders
Well ok then if you know PHP here's the function I use. I
send all "Add
to Cart" links through this page. It does two things.
First it pulls part information out of one of our existing
databases and
uses the part name to populate the clickstream analysis
software I'm
using.
Second, typically it opens the ADPR screen of Miva and posts
the product
information to the cart which initiates the generation of
the
htscallerid cookie. This posting method eliminated an error
where
refreshing the page once inside the Miva cart would add
another product.
Finally it redirects the user to the cart with the cookie in
place.
All this happens on the server end so the user never notices
the
transition.
*-----------------------------------------------------------
------*
<?PHP
include('./xxxxx/xxxxx.inc.php');
$action = str_replace("\r\n",
"", $_REQUEST['Action'])
;
$prodCode = str_replace("\r\n",
"",
$_REQUEST['Product_Code']) ;
$qty = str_replace("\r\n", "",
$_REQUEST['Quantity'])
;
$stCode = str_replace("\r\n", "",
$_REQUEST['Store_Code'])
;
$screen = str_replace("\r\n", "",
$_REQUEST['Screen'])
;
$link =
"http:
//www.hpiracing.com/Merchant2/merchant.mvc";
function getPartName($partNo)
{
$sql = "
SELECT
partnumber,
partname
FROM xxxxx
WHERE partnumber = '".$partNo."'
LIMIT 1";
$result = mysql_query($sql);
return $result;
}
$getPart = getPartName($prodCode);
$showPart = mysql_fetch_object($getPart);
// prepend phpOpenTracker
include 'phpOpenTracker.php';
// log access
phpOpenTracker::log(
array(
'document' => 'Added
#'.$showPart->partnumber.' -
'.trim($showPart->partname).' to the basket.'
)
);
function post_it($datastream, $url)
{
$url = preg_replace (" ^http:// i",
"", $url);
$host = substr ($url, 0, strpos($url, "/"));
$uri = strstr ($url, "/");
$reqbody = "";
foreach($datastream as $key=>$val)
{
if (isset($reqbody) AND $reqbody != "")
{
$reqbody .= "&";
}
$reqbody .= $key."=".urlencode($val);
}
$contentlength = strlen($reqbody);
$reqheader = "POST $uri HTTP/1.0\r\n".
"Host: $host\n". "User-Agent:
Buy HPI\r\n".
"Content-Type:
application/x-www-form-urlencoded\r\n".
"Content-Length:
$contentlength\r\n\r\n".
"$reqbody\r\n";
$socket = fsockopen($host, 80, $errno, $errstr);
if (!$socket)
{
$result["errno"] = $errno;
$result["errstr"] = $errstr;
return $result;
}
fputs($socket, $reqheader);
while (!feof($socket))
{
$result[] = fgets($socket, 4096);
}
fclose($socket);
return $result;
}
$data["Action"] = $action;
$data["Product_Code"] = $prodCode;
$data["Quantity"] = $qty;
$data["Store_Code"] = $stCode;
$data["Screen"] = $screen;
$data["Session_ID"] =
$_COOKIE['htscallerid'];
$result = post_it($data, $link);
if (isset($result["errno"]))
{
exit;
}
else
{
header("Location:
".$link."?Screen=".$screen."&Ses
sion_ID=".$_COOKIE['htscallerid']);
}
?>
*-----------------------------------------------------------
---------*
Hope that'll at least get you started in the right
direction.
________________________________
Alex Boyer
Webmaster
Hobby Products International
70 Icon Street
Foothill Ranch, CA 92610 USA
949 753 1099 x 135
949 753 1098 fax
Latest Option Parts and Bodies!
-----Original Message-----
From: proka prokofievcreative.com [mailto:proka prokofievcreative.com]
Sent: Friday, March 10, 2006 1:11 PM
To: Alex Boyer
Subject: RE: [m5u] Using just the MIVA back end for
processing orders
Thanks. No, I've developed my own CMS with php/mysql and
I've got it
the
way I want it. I'll also be developing site nuances not
yet available
in
other CMS, so I don't want to abandon it and start a whole
new learning
curve. It's offered with my hosting package though, so why
not chop
what I
need out of it, and forget the rest.
-Dave
-----Original Message-----
From: owner-merchant5-users listmgr.miva.com
[mailto:owner-merchant5-users listmgr.miva.com] On Behalf
Of Alex Boyer
Sent: Friday, March 10, 2006 3:49 PM
To: webmaster wpcomp.com; proka prokofievcreative.com;
merchant5-users listmgr.miva.com
Subject: RE: [m5u] Using just the MIVA back end for
processing orders
MM5 with MySQL eliminated this issue on our end. I just use
the pricing
information from Miva itself to determine the price in the
rest of the
site. Same with inventory levels.
Vic is right in one sense though. Doing a store this way is
complicated, can be messy and if you don't already have a
site with
product info, it's usually more efficient to do it all with
one system.
________________________________
Alex Boyer
-----Original Message-----
From: owner-merchant5-users listmgr.miva.com
[mailto:owner-merchant5-users listmgr.miva.com] On Behalf
Of WolfPaw
Computers - Miva Lists
Sent: Friday, March 10, 2006 12:45 PM
To: proka prokofievcreative.com; merchant5-users listmgr.miva.com
Subject: RE: [m5u] Using just the MIVA back end for
processing orders
Yes, its very possible.
The question is why? You really take away from the purpose
of the
software
if you do not allow it to do what it was intended -
dynamically create
and
manage your content.
Then you just have to update pricing in two places when you
make changes
-
doubling your efforts.
Vic Vega,
WolfPaw Computers
MIVA Merchant Hosting Specialists
"The leader of the pack in MIVA Hosting"(sm)
MIVA Standard Hosting Partner - OpenUI Premier Partner
FREE MerchantHowTo.com Basic Tutorial Subscription with each
hosting
account!
A $49 value! http://tinyurl.com/48nmu
Ph: (866) WOLFPAW - www.wpcomp.com - sales wpcomp.com
> -----Original Message-----
> From: owner-merchant5-users listmgr.miva.com
> [mailto:owner-merchant5-users listmgr.miva.com] On Behalf
Of
> proka prokofievcreative.com
> Sent: Friday, March 10, 2006 12:54 PM
> To: merchant5-users listmgr.miva.com
> Subject: [m5u] Using just the MIVA back end for
processing orders
>
> Hi,
>
> I hope I'm sending this to the correct address now.
>
> I was wondering if there is a way to just use the back
end of
> the MIVA merchant to handle shopping cart/order
processing by
> linking only the shopping cart functionality on my
existing
> website "add to cart" buttons.
>
> In other words, set up the product db, use my existing
store
> front structure, and link into the MIVA back end
shopping
> cart for each product I have on my site. I don't want
to use
> the MIVA storefront, just the cart.
>
> -Dave Prokowiew
> ____________________________________
> Prokofiev Creative Services
> proka prokofievcreative.com
> ____________________________________
>
>
>
>
> ------------------ MIVA CORPORATION FOOTER
-------------------
> FEATURE REQUESTS: mailto:wishlist miva.com
> TO FIND HELP: mailto:merchant5-users-help listmgr.miva.com
> TO UNSUBSCRIBE - Send mail to:
> mailto:merchant5-users-unsubscribe listmgr.miva.com
> if you need to unsubscribe a different address, send
a message to:
> mailto:ezmlm listmgr.miva.com
> with a subject or message body of
> unsubscribe merchant5-users yourname yourdomain.com
> ---------------- END MIVA CORPORATION FOOTER
-----------------
>
>
------------------ MIVA CORPORATION FOOTER
-------------------
FEATURE REQUESTS: mailto:wishlist miva.com
TO FIND HELP: mailto:merchant5-users-help listmgr.miva.com
TO UNSUBSCRIBE - Send mail to:
mailto:merchant5-users-unsubscribe listmgr.miva.com
if you need to unsubscribe a different address, send a
message to:
mailto:ezmlm listmgr.miva.com
with a subject or message body of
unsubscribe merchant5-users yourname yourdomain.com
---------------- END MIVA CORPORATION FOOTER
-----------------
--------------------------------------------------------
Disclaimer:
This email is confidential and may be privileged or
otherwise protected
by
work product immunity or other legal rules. It is intended
solely for
the
use of the individual to whom it is addressed. If you are
not the
intended
recipient, be advised that you have received this email in
error and
that
any use, disclosure, dissemination, forwarding, printing,
saving or
copying
of any of its contents is strictly prohibited. If you have
received this
in
error please let us know by email reply, then delete this
email from
your
computer system. You may not take any other action in
reliance on this
email.
Any views or opinions presented are solely those of the
author and do
not
necessarily represent those of Hobby Products International,
Inc.
------------------ MIVA CORPORATION FOOTER
-------------------
FEATURE REQUESTS: mailto:wishlist miva.com
TO FIND HELP: mailto:merchant5-users-help listmgr.miva.com
TO UNSUBSCRIBE - Send mail to:
mailto:merchant5-users-unsubscribe listmgr.miva.com
if you need to unsubscribe a different address, send a
message to:
mailto:ezmlm listmgr.miva.com
with a subject or message body of
unsubscribe merchant5-users yourname yourdomain.com
---------------- END MIVA CORPORATION FOOTER
-----------------
------------------ MIVA CORPORATION FOOTER
-------------------
FEATURE REQUESTS: mailto:wishlist miva.com
TO FIND HELP: mailto:merchant5-users-help listmgr.miva.com
TO UNSUBSCRIBE - Send mail to:
mailto:merchant5-users-unsubscribe listmgr.miva.com
if you need to unsubscribe a different address, send a
message to:
mailto:ezmlm listmgr.miva.com
with a subject or message body of
unsubscribe merchant5-users yourname yourdomain.com
---------------- END MIVA CORPORATION FOOTER
-----------------
------------------ MIVA CORPORATION FOOTER
-------------------
FEATURE REQUESTS: mailto:wishlist miva.com
TO FIND HELP: mailto:merchant5-users-help listmgr.miva.com
TO UNSUBSCRIBE - Send mail to:
mailto:merchant5-users-unsubscribe listmgr.miva.com
if you need to unsubscribe a different address, send a
message to:
mailto:ezmlm listmgr.miva.com
with a subject or message body of
unsubscribe merchant5-users yourname yourdomain.com
---------------- END MIVA CORPORATION FOOTER
-----------------
|