porrier Posted July 21, 2012 Share Posted July 21, 2012 Hello all, I've uploaded a new version iOSC3 (http://addons.oscommerce.com/info/7636). See change log below: New Release (v4.0) of iOSC - mobile version of OSCommerce for iPhone and smartphone Changelog v4.0: Cosmetic changes: * Dutch translation * "Mobile" removed from title (mobile/includes/header.php) * Greeting on mobile_index.php is now multilangual * Buy NOW button is now multilangual (mobile_product_info.php + all languages) * Buy NOW button is now multilangual (mobile_product_reviews.php + all languages) * Added Language to header, Home button removed * Non used images removed * Store address added to mobile_contact_us.php (still need some editing) * Confirm password is now multilangual * Button PC Site again added Bugfixes: * BUGFIX: Auto redirect to mobiele home page didn't work (includes/functions/iosc.php) - $targetPage = "mobile_index.php"; changed in $targetPage = "../mobile_index.php"; * BUGFIX: Checkout process goes trough classic site (mobile/includes/configure.php) - define mobile_checkout_process.php added * BUGFIX: After a succes order the customer wasn't redirected to the homepage (mobile_checkout_succes.php) - MOBILE removed from FILENAME_MOBILE_CHECKOUT_SUCCESS * BUGFIX: Link to reviews repaired (mobile/includes/configure.php) - define mobile_product_reviews.php added * BUGFIX: link to product_review_write repaired (mobile/includes/configure.php) - define mobile_product_reviews_write.php added *BUGFIX: PayPal, iDEAL, CC payments, etc didn't work (mobile_checkout_confirmation.php)(thnx to pixclinic) - "echo $payment_modules->process_button();" added (without quotes!!) after "if (is_array($payment_modules->modules)) {" - NOTE: This will save sensitive data on your server. It's up to you to decide wether or not you might want to save creditcard data on your server. There is a contribution that you might want to add to your store that encrypts data via MD5 at: (http://www.oscommerce.com/community/contributions,4359). It is strongly recommended if you use the cc module. *BUGFIX: Auto redirect for smartphones etc edited (thnx to Escaping for the solution, reposted by wflynn) -NOTE: the auto redirect works, but the switch from mobile to classic gives some problems. I'm still working on this one, a great part of ths contribution needs to be rewritten. As a temperory solution you could install Custom HTTP Error Page (http://addons.oscommerce.com/info/933). This way you'll won't lose potential customers. Other: * Rewrote installation.txt To do: * Complete rewrite so the link to the classic site works as it should be * Add a module (specials or whats new) to mobile_index.php * Some editing on the store address in mobile_contact_us.php * (Re)write some other contribs for iOSC (like Purchase Without Account, Points and Rewards and Discount Coupon, etc). Have a look at http://www.cosmeanailart.nl/mobile/ for an example. This is a live shop..... Thanks to the original writers and contributers of this contribution. Your package seems to be incomplete. The installation.txt says: In catalog/includes/header.php ***FIND // check if the 'install' directory exists, and warn of its existence *** ADD BEFORE $mobile_device_url = basename($PHP_SELF) . '?' . tep_get_all_get_params(); require_once('mobile/includes/classes/mobile_redirect.php'); but there is no mobile_redirect.php in mobile/includes/classes . Also the iOSC3 v4.1 Full Package at contributions of osCommerce is a defective zip-archiv Andreas Quote Link to comment Share on other sites More sharing options...
IWAS Posted July 27, 2012 Share Posted July 27, 2012 Why does the latest upload require a password to unzip it or is it just corrupted? Quote Link to comment Share on other sites More sharing options...
bensuba Posted August 4, 2012 Share Posted August 4, 2012 wow. http://www.cosmeanailart.nl looks awesome, i will try this. thanks alot .. Quote My profile Link to comment Share on other sites More sharing options...
bensuba Posted August 4, 2012 Share Posted August 4, 2012 hi I just installed the New Release (v4.1) to my osc first look every thing ok But the product image can not show well, can you help tell where to fix about this problem my website:www.evaland.tw/max/ error code 10006 on my blackberry Quote My profile Link to comment Share on other sites More sharing options...
bensuba Posted August 4, 2012 Share Posted August 4, 2012 Why it is showing same error code 10006 http://www.cosmeanailart.nl/mobile_catalogue.php on my blackberry any solution for this? Quote My profile Link to comment Share on other sites More sharing options...
bensuba Posted August 4, 2012 Share Posted August 4, 2012 Why it is showing same error code 10006 http://www.cosmeanailart.nl/mobile_catalogue.php on my blackberry any solution for this? nevermind i have misstyped lol Quote My profile Link to comment Share on other sites More sharing options...
bensuba Posted August 4, 2012 Share Posted August 4, 2012 Hi, i have installed this and looks great, only 3 things isnt seem right to me header mobile site doesnt seem right redirect to mobile is not working error message when i click 1 of my categories .: deprecated: function ereg() is deprecated in home/content/41/9670941/html/mobile_products.php on line 39 i will try redirect from previous post. Any one know whats wrong with header and deprecated message? my website http://www.tokokristik.com/mobile thanks Quote My profile Link to comment Share on other sites More sharing options...
bensuba Posted August 20, 2012 Share Posted August 20, 2012 Hello all, I've uploaded a new version iOSC3 (http://addons.oscommerce.com/info/7636). See change log below: New Release (v4.0) of iOSC - mobile version of OSCommerce for iPhone and smartphone Changelog v4.0: Cosmetic changes: * Dutch translation * "Mobile" removed from title (mobile/includes/header.php) * Greeting on mobile_index.php is now multilangual * Buy NOW button is now multilangual (mobile_product_info.php + all languages) * Buy NOW button is now multilangual (mobile_product_reviews.php + all languages) * Added Language to header, Home button removed * Non used images removed * Store address added to mobile_contact_us.php (still need some editing) * Confirm password is now multilangual * Button PC Site again added Bugfixes: * BUGFIX: Auto redirect to mobiele home page didn't work (includes/functions/iosc.php) - $targetPage = "mobile_index.php"; changed in $targetPage = "../mobile_index.php"; * BUGFIX: Checkout process goes trough classic site (mobile/includes/configure.php) - define mobile_checkout_process.php added * BUGFIX: After a succes order the customer wasn't redirected to the homepage (mobile_checkout_succes.php) - MOBILE removed from FILENAME_MOBILE_CHECKOUT_SUCCESS * BUGFIX: Link to reviews repaired (mobile/includes/configure.php) - define mobile_product_reviews.php added * BUGFIX: link to product_review_write repaired (mobile/includes/configure.php) - define mobile_product_reviews_write.php added *BUGFIX: PayPal, iDEAL, CC payments, etc didn't work (mobile_checkout_confirmation.php)(thnx to pixclinic) - "echo $payment_modules->process_button();" added (without quotes!!) after "if (is_array($payment_modules->modules)) {" - NOTE: This will save sensitive data on your server. It's up to you to decide wether or not you might want to save creditcard data on your server. There is a contribution that you might want to add to your store that encrypts data via MD5 at: (http://www.oscommerce.com/community/contributions,4359). It is strongly recommended if you use the cc module. *BUGFIX: Auto redirect for smartphones etc edited (thnx to Escaping for the solution, reposted by wflynn) -NOTE: the auto redirect works, but the switch from mobile to classic gives some problems. I'm still working on this one, a great part of ths contribution needs to be rewritten. As a temperory solution you could install Custom HTTP Error Page (http://addons.oscommerce.com/info/933). This way you'll won't lose potential customers. Other: * Rewrote installation.txt To do: * Complete rewrite so the link to the classic site works as it should be * Add a module (specials or whats new) to mobile_index.php * Some editing on the store address in mobile_contact_us.php * (Re)write some other contribs for iOSC (like Purchase Without Account, Points and Rewards and Discount Coupon, etc). Have a look at http://www.cosmeanailart.nl/mobile/ for an example. This is a live shop..... Thanks to the original writers and contributers of this contribution. Sorry, but your shop didnt work normal. it shows error in mobile site as well as in normal site Parse error: syntax error, unexpected T_STRING in /home/h94274/domains/cosmeanailart.nl/public_html/includes/languages/english/create_account.php on line 18 Quote My profile Link to comment Share on other sites More sharing options...
danicer Posted August 21, 2012 Share Posted August 21, 2012 In version 4, i think that in version 3 was OK, when send the confirmartion email do not use the filenames EMAIL_SEPARATOR EMAIL_TEXT_ORDER_NUMBER EMAIL_TEXT_INVOICE_URL Thanks Quote Link to comment Share on other sites More sharing options...
reflex-ocasion Posted September 13, 2012 Share Posted September 13, 2012 Unfortunately I have to uninstall and install another contribution distinct contribution. Within 24 hours I received over 1.200 emails of error because of google. I put here three examples: Sitio web: http://www.mysite.com Codigo de error: 404 - No encontrada Fecha y hora de la incidencia: 13/09/2012 21:56:43 URL solicitada: http://www.mysite.com/mobile_shop_by_price.php?osCsid=sa0r6696ob0fjk5k6l45tpjs80&range=3&osCsid=sa0r6696ob0fjk5k6l45tpjs80&language= IP del usuario: 66.249.72.66 Navegador del usuario: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html) Referencia: Sitio web: http://www.mysite.com Codigo de error: 404 - No encontrada Fecha y hora de la incidencia: 13/09/2012 21:58:44 URL solicitada: http://www.mysite.com/mobile_ask_a_question.php?products_id=34 IP del usuario: 66.249.72.90 Navegador del usuario: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html) Referencia: Sitio web: http://www.mysite.es Codigo de error: 404 - No encontrada Fecha y hora de la incidencia: 13/09/2012 21:41:52 URL solicitada: http://www.mysite.es/mobile_reviews.php IP del usuario: 66.249.72.54 Navegador del usuario: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html) Referencia: Google is looking for three files that do not exist: mobile_shop_by_price.php, mobile_ask_a_question.php and mobile_reviews.php The first and the second may be because I have installed these contributions, but what about the third mistake? I have tried everything to prevent further searching those files that do not exist, but nothing works, google insists on looking for them. I can not allow my hosting account lockout me because of this contribution, sorry, every mistake is an email that I receive and I should have jumped antispam alarms When these problems are resolved erroneous indexing by google'll install this fantastic contibución, but until then... Quote Link to comment Share on other sites More sharing options...
twindaddy Posted September 15, 2012 Share Posted September 15, 2012 (edited) Hello, i installed this contri in my oscommerce webshop 2.3.3 When i go with my mobile phone (blackberry) to my site www.dekammieshop.nl/shop is does not redirect to the mobile version. Then when i wan't to login in the mobile shop i get the following error: Warning: session_regenerate_id() [function.session-regenerate-id]: Cannot regenerate session id - headers already sent in /xxxxxx/shop/includes/functions/sessions.php on line 179 Warning: Cannot modify header information - headers already sent by (output started at xxxxxx/public_html/shop/mobile/includes/application_top.php:7) in xxxxx/shop/includes/functions/general.php on line 49 the warning lines also showup when i tried to pay articles when they are in the basket. Please can someone help me with this Thank you. with kind regards Twindaddy Edited September 15, 2012 by twindaddy Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted September 17, 2012 Share Posted September 17, 2012 (edited) Unfortunately I have to uninstall and install another contribution distinct contribution. Within 24 hours I received over 1.200 emails of error because of google. I put here three examples: Sitio web: http://www.mysite.com Codigo de error: 404 - No encontrada Fecha y hora de la incidencia: 13/09/2012 21:56:43 URL solicitada: http://www.mysite.com/mobile_shop_by_price.php?osCsid=sa0r6696ob0fjk5k6l45tpjs80&range=3&osCsid=sa0r6696ob0fjk5k6l45tpjs80&language= IP del usuario: 66.249.72.66 Navegador del usuario: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html) Referencia: Sitio web: http://www.mysite.com Codigo de error: 404 - No encontrada Fecha y hora de la incidencia: 13/09/2012 21:58:44 URL solicitada: http://www.mysite.com/mobile_ask_a_question.php?products_id=34 IP del usuario: 66.249.72.90 Navegador del usuario: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html) Referencia: Sitio web: http://www.mysite.es Codigo de error: 404 - No encontrada Fecha y hora de la incidencia: 13/09/2012 21:41:52 URL solicitada: http://www.mysite.es/mobile_reviews.php IP del usuario: 66.249.72.54 Navegador del usuario: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html) Referencia: Google is looking for three files that do not exist: mobile_shop_by_price.php, mobile_ask_a_question.php and mobile_reviews.php The first and the second may be because I have installed these contributions, but what about the third mistake? I have tried everything to prevent further searching those files that do not exist, but nothing works, google insists on looking for them. I can not allow my hosting account lockout me because of this contribution, sorry, every mistake is an email that I receive and I should have jumped antispam alarms When these problems are resolved erroneous indexing by google'll install this fantastic contibución, but until then... Hello, For the first 2 files you should add the following to the redirect code you copied to catalog/includes/application_top.php: find: if ($url_basename == 'recently_viewed.php') { $mobile_site = str_replace('recently_viewed.php', 'mobile_index.php', $_SERVER['REQUEST_URI']); } add below this: if ($url_basename == 'shop_by_price.php') { $mobile_site = str_replace('shop_by_price.php', 'mobile_catalogue.php', $_SERVER['REQUEST_URI']); } if ($url_basename == 'ask_a_question.php') { $mobile_site = str_replace('ask_a_question.php', 'mobile_contact_us.php', $_SERVER['REQUEST_URI']); } As you said you have these 2 contributions installed which have no correspondence in the mobile version. So now from the page "shop_by_price" will be redirected to "mobile_catalogue" and from "ask_a_question" will be redirected to "mobile_contact_us". For the third error "mobile_reviews.php" it seems you made a mistake copying the name of the file or you have the name changed in your shop. The original filename is: "product_reviews.php", not "reviews.php". So the redirect searches for a file called "mobile_reviews.php" instead of "mobile_product_reviews.php". 3 solutions: 1. change the filename of "reviews.php" to "product_reviews.php" (don't forget to correct it in "includes/filenames.php" too). OR 2. change the filename of "mobile_product_reviews.php" to "mobile_reviews.php" (don't forget to correct it in "mobile/includes/configure.php" too). OR 3. add this in includes/application_top.php at the same place where you added it for the first 2 pages. if ($url_basename == 'reviews.php') { $mobile_site = str_replace('reviews.php', 'mobile_product_reviews.php', $_SERVER['REQUEST_URI']); } Hope this helps raiwa Edited September 17, 2012 by raiwa Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
breakbred101 Posted September 17, 2012 Share Posted September 17, 2012 So I have installed the contribution, and i have added a few pages that don't orginally come with OSC, (how_it_works.php, promotions.php). I eventually managed to implement these pages, but my text links won't redirect to the mobile site, instead they redirect to the non mobile site. I've been ttrying to figure this out for days, and im all out of existing combinations it seems. Basically, (originaly) i've got <p>Some text ........ <sub>[b]<a href="conditions.php#Sameday>(see Terms & Conditions)</a>[/b]</sub></p> in my original document. Some of these links will hit anchor points in the existing pages mobile version, there is one that redirects to create_account and others that redirect to anchor points in other mobile pages. The version i have installed is the newly realeased iOSC3 5.0, there was a couple simple fixes i made, but nothing that messed with any redirects or what not. Included in the documentation is this below, which I thought i could manipulate to do what I needed it to, but to no avail... Note: This function is not used in the base installation of IOSC 5.0 It is useful for example if you wants to use text links to certain categories or products in the 'TEXT_MAIN' in 'index.php' or other personalized text. and you don't wants to duplicate this text in 'TEXT_WELCOME' of the mobile language files. This allows to use different links for a mobile session and a classic session. See the example in my live shop: www.sarplataygemas.com. the code snippet I use in TEXT_MAIN in the language file of index.php is: 'We handcraft our jewelry with <a href="' . ((mobile_session() == 'mobile_index.php') ? FILENAME_CATALOG . '?cPath=61' : FILENAME_DEFAULT . '?cPath=61&redirectCancelled=true') . '"><u>sterlingsilver findings</u></a> and...' any help would be greatly appreciated. Thanks Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted September 19, 2012 Share Posted September 19, 2012 So I have installed the contribution, and i have added a few pages that don't orginally come with OSC, (how_it_works.php, promotions.php). I eventually managed to implement these pages, but my text links won't redirect to the mobile site, instead they redirect to the non mobile site. I've been ttrying to figure this out for days, and im all out of existing combinations it seems. Basically, (originaly) i've got <p>Some text ........ <sub>[b]<a href="conditions.php#Sameday>(see Terms & Conditions)</a>[/b]</sub></p> in my original document. Some of these links will hit anchor points in the existing pages mobile version, there is one that redirects to create_account and others that redirect to anchor points in other mobile pages. The version i have installed is the newly realeased iOSC3 5.0, there was a couple simple fixes i made, but nothing that messed with any redirects or what not. Included in the documentation is this below, which I thought i could manipulate to do what I needed it to, but to no avail... Note: This function is not used in the base installation of IOSC 5.0 It is useful for example if you wants to use text links to certain categories or products in the 'TEXT_MAIN' in 'index.php' or other personalized text. and you don't wants to duplicate this text in 'TEXT_WELCOME' of the mobile language files. This allows to use different links for a mobile session and a classic session. See the example in my live shop: www.sarplataygemas.com. the code snippet I use in TEXT_MAIN in the language file of index.php is: 'We handcraft our jewelry with <a href="' . ((mobile_session() == 'mobile_index.php') ? FILENAME_CATALOG . '?cPath=61' : FILENAME_DEFAULT . '?cPath=61&redirectCancelled=true') . '"><u>sterlingsilver findings</u></a> and...' any help would be greatly appreciated. Thanks Hello, try this: <p>Some text ........ <sub>[b]<a href="' . ((mobile_session() == 'mobile_"the_mobile_page_where_your_link_is_placed".php') ? FILENAME_MOBILE_CONDITIONS . '#Sameday' : FILENAME_CONDITIONS . '#Sameday') . '">(see terms and conditions)</a>[/b]</sub></p> change: mobile_"the_mobile_page_where_your_link_is_placed".php to the name of the Mobile file where your link is placed. hope this helps Rainer Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
breakbred101 Posted September 20, 2012 Share Posted September 20, 2012 Hello, try this: <p>Some text ........ <sub>[b]<a href="' . ((mobile_session() == 'mobile_"the_mobile_page_where_your_link_is_placed".php') ? FILENAME_MOBILE_CONDITIONS . '#Sameday' : FILENAME_CONDITIONS . '#Sameday') . '">(see terms and conditions)</a>[/b]</sub></p> change: mobile_"the_mobile_page_where_your_link_is_placed".php to the name of the Mobile file where your link is placed. hope this helps Rainer That worked out, thanks rainer. Quote Link to comment Share on other sites More sharing options...
breakbred101 Posted September 20, 2012 Share Posted September 20, 2012 I use paypal express checkout to process my payments but the oringial ext/includes/modules/payment/express.php is not coded to redirect mobile users back to mobile_checkout_confirmation. I believe an if else statement can fix this, the code below is close to what i need to implement but i cant figure out where to put it, or even if it is gonna work without throwing syntax errors, i could use a little guidance. if ($ref string) == mobile_checkout_process.php then { tep_redirect(tep_mobile_link(FILENAME_MOBILE_CHECKOUT_CONFIRMATION, '', 'SSL')); }else{ tep_redirect(tep_href_link(FILENAME_CHECKOUT_CONFIRMATION, '',, 'SSL')); } It's my understanding the placement of this code above, should be simple with the redirect. But being as theres an else clause pertaining to errors I cant figure it out. ... ... if (!tep_session_is_registered('payment')) tep_session_register('payment'); $payment = $paypal_express->code; if (!tep_session_is_registered('ppe_token')) tep_session_register('ppe_token'); $ppe_token = $response_array['TOKEN']; if (!tep_session_is_registered('ppe_payerid')) tep_session_register('ppe_payerid'); $ppe_payerid = $response_array['PAYERID']; [color=#FF6600]tep_redirect(tep_href_link(FILENAME_CHECKOUT_CONFIRMATION, '', 'SSL'));[/color] } else { if (!tep_session_is_registered('shipping')) tep_session_register('shipping'); $shipping = false; $sendto = false; if (!tep_session_is_registered('payment')) tep_session_register('payment'); $payment = $paypal_express->code; if (!tep_session_is_registered('ppe_token')) tep_session_register('ppe_token'); $ppe_token = $response_array['TOKEN']; if (!tep_session_is_registered('ppe_payerid')) tep_session_register('ppe_payerid'); $ppe_payerid = $response_array['PAYERID']; [color=#FF6600]tep_redirect(tep_href_link(FILENAME_CHECKOUT_CONFIRMATION, '', 'SSL')); } } else { tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, 'error_message=' . stripslashes($response_array['L_LONGMESSAGE0']), 'SSL')); }[/color] break; $params['METHOD'] = 'SetExpressCheckout'; $params['PAYMENTREQUEST_0_PAYMENTACTION'] = ((MODULE_PAYMENT_PAYPAL_EXPRESS_TRANSACTION_METHOD == 'Sale') ? 'Sale' : 'Authorization'); $params['RETURNURL'] = tep_href_link('ext/modules/payment/paypal/express.php', 'osC_Action=retrieve', 'SSL', true, false); $params['CANCELURL'] = tep_href_link(FILENAME_SHOPPING_CART, '', 'SSL', true, false); $params['PAYMENTREQUEST_0_CURRENCYCODE'] = $order->info['currency']; #AUD, CAD, EUR, GBP, JPY, USD if ($order->content_type == 'virtual') { $params['NOSHIPPING'] = '1'; } $nProd = sizeof($order->products); $subtotal = 0; for ($i = 0; $i < $nProd; ++$i) { $subtotal += $paypal_express->format_raw($order->products[$i]['final_price']) * $order->products[$i]['qty']; } $difst = 0; if ($subtotal != $paypal_express->format_raw($order->info['subtotal'])) { $difst = $paypal_express->format_raw($order->info['subtotal']) - $subtotal; } $order->products[$nProd-1]['final_price'] += $difst; for ($i = 0; $i < $nProd; ++$i) { $params['L_PAYMENTREQUEST_0_NAME' . $i] = $order->products[$i]['name']; $params['L_PAYMENTREQUEST_0_NUMBER' . $i] = $order->products[$i]['model']; #$params['L_PAYMENTREQUEST_0_DESC' . $i] = $order->products[$i]['description']; $params['L_PAYMENTREQUEST_0_AMT' . $i] = $paypal_express->format_raw($order->products[$i]['final_price']); $params['L_PAYMENTREQUEST_0_QTY' . $i] = $order->products[$i]['qty']; } require_once(DIR_WS_CLASSES . 'order_total.php'); $order_total_modules = new order_total; $order_totals = $order_total_modules->process(); $order_details = array(); $order_details['subtotal'] = 0; $order_details['shipping_cost'] = 0; $order_details['tax'] = 0; $order_details['discount'] = 0; $order_details['handling'] = 0; $order_details['total'] = 0; foreach ($order_totals as $order_total) { if ($order_total['code'] == 'ot_subtotal') { $order_details['subtotal'] += $order_total['value']; } elseif ($order_total['code'] == 'ot_shipping') { $order_details['shipping_cost'] += $order_total['value']; } elseif ($order_total['code'] == 'ot_tax') { $order_details['tax'] += $order_total['value']; } elseif ($order_total['code'] == 'ot_total') { $order_details['total'] += $order_total['value']; } elseif ($order_total['code'] == 'ot_redemptions' || $order_total['code'] == 'ot_gv' || $order_total['code'] == 'ot_coupon') { $order_details['discount'] += $order_total['value']; } elseif ($order_total['code'] == 'ot_insurance') { $order_details['handling'] += $order_total['value']; } else { if ($order_total['value'] > 0) { $order_details['handling'] += $order_total['value']; } else { $order_details['discount'] += $order_total['value']; } } } $params['PAYMENTREQUEST_0_ITEMAMT'] = $paypal_express->format_raw($order_details['subtotal']); $params['PAYMENTREQUEST_0_TAXAMT'] = $paypal_express->format_raw($order_details['tax']); $params['PAYMENTREQUEST_0_SHIPPINGAMT'] = $paypal_express->format_raw($order_details['shipping_cost']); $params['PAYMENTREQUEST_0_SHIPDISCAMT'] = $paypal_express->format_raw($order_details['discount']); $params['PAYMENTREQUEST_0_HANDLINGAMT'] = $paypal_express->format_raw($order_details['handling']); $params['PAYMENTREQUEST_0_AMT'] = $paypal_express->format_raw($order_details['total']); $post_string = ''; //print_r($params); //die(); foreach ($params as $key => $value) { $post_string .= $key . '=' . urlencode(trim($value)) . '&'; } $post_string = substr($post_string, 0, -1); $response = $paypal_express->sendTransactionToGateway($api_url, $post_string); $response_array = array(); parse_str($response, $response_array); [color=#FF8C00] if (($response_array['ACK'] == 'Success') || ($response_array['ACK'] == 'SuccessWithWarning')) { tep_redirect($paypal_url . '&token=' . $response_array['TOKEN']); } else { tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, 'error_message=' . stripslashes($response_array['L_LONGMESSAGE0']), 'SSL')); }[/color] break; } [color=#FF9900]tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, '', 'SSL'));[/color] Quote Link to comment Share on other sites More sharing options...
breakbred101 Posted September 21, 2012 Share Posted September 21, 2012 A little more details on the above post... Basically after you get transferred to paypal and process your payment info, when it comes back to my site it's coming back to the pc version of checkout_confirmation. After more looking im not sure if this edit is a checkout_process, checkout_payment or express.php edit. Any help would be great, as I'm one fix away from a complete mobile version. Quote Link to comment Share on other sites More sharing options...
twindaddy Posted September 22, 2012 Share Posted September 22, 2012 Hello, i installed this contri in my oscommerce webshop 2.3.3 When i go with my mobile phone (blackberry) to my site www.dekammieshop.nl/shop is does not redirect to the mobile version. Then when i wan't to login in the mobile shop i get the following error: Warning: session_regenerate_id() [function.session-regenerate-id]: Cannot regenerate session id - headers already sent in /xxxxxx/shop/includes/functions/sessions.php on line 179 Warning: Cannot modify header information - headers already sent by (output started at xxxxxx/public_html/shop/mobile/includes/application_top.php:7) in xxxxx/shop/includes/functions/general.php on line 49 the warning lines also showup when i tried to pay articles when they are in the basket. Please can someone help me with this Thank you. with kind regards Twindaddy Anybody? Quote Link to comment Share on other sites More sharing options...
Guest Posted September 24, 2012 Share Posted September 24, 2012 Wierd problem, I'm using the latest version os IOS and Oscommerce 2.3.3 with php 5.3 www.shoptuin.nl/mobile Once I go to my account. The page goes blank If I go directly to the mobile_login.php I'm able to login but it will not process. After a refresh I see the My account page Does this have something to to with the redirect My hist server uses php 5.3 Quote Link to comment Share on other sites More sharing options...
breakbred101 Posted September 26, 2012 Share Posted September 26, 2012 Anybody? The headers already sent error is because if extra white spaces after the documents closing "?>" tag... So try this, open /xxxxxx/shop/includes/functions/sessions.php scroll to the very bottom of the page and click a few spaces after the closing ?> tag. If that does not work, go through all your mobile_... pages and be sure there is no white spaces after the closing "?>" php tags Quote Link to comment Share on other sites More sharing options...
Guest Posted September 26, 2012 Share Posted September 26, 2012 Wierd problem, I'm using the latest version os IOS and Oscommerce 2.3.3 with php 5.3 www.shoptuin.nl/mobile Once I go to my account. The page goes blank If I go directly to the mobile_login.php I'm able to login but it will not process. After a refresh I see the My account page Does this have something to to with the redirect My hist server uses php 5.3 I took al ook at the code in mobiel_account.php I think it has something to do with <?php require_once('mobile/includes/application_top.php'); if (!tep_session_is_registered('customer_id')) { $navigation->set_snapshot(); tep_redirect(tep_mobile_link(FILENAME_LOGIN, '', 'SSL')); } Either is is not regestering a session or the tep_redirect function is not working I found this in one of the classes I had to change the function split() was decapracated and use explode function redirect() { global $mobile_site; if(isset($mobile_site)) { $path = explode("/" ,$mobile_site); $file = $path[sizeof($path)-1]; } else { $path = explode("/" , $_SERVER['SCRIPT_NAME']); $filename = $path[sizeof($path)-1]; $file = $this->mobileDir . $filename; } $qstring = $_SERVER['QUERY_STRING']; $SSL = ($_SERVER['HTTPS']) ? "SSL" : "NONSSL"; tep_redirect(tep_href_link($file, $qstring, $SSL, false, false)); } } Can somebody please help me with this Quote Link to comment Share on other sites More sharing options...
Guest Posted September 26, 2012 Share Posted September 26, 2012 if I do this then it works <?php require_once('includes/application_top.php'); //require_once('mobile/includes/application_top.php'); if (!tep_session_is_registered('customer_id')) { $navigation->set_snapshot(); //tep_redirect(tep_mobile_link(FILENAME_LOGIN, '', 'SSL')); tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL')); } But then I get errors once logged in. because it does not reconize tep_mobile_link (obvious) Quote Link to comment Share on other sites More sharing options...
Guest Posted September 26, 2012 Share Posted September 26, 2012 has to be in the function once it need to redirect SessionID enabled pages it goed blank (tep_session_is_registered('customer_id')is <?php function tep_mobile_link($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = false) { return tep_href_link($page, $parameters, $connection, $add_session_id,false); } This is the funtion in the normal site for tep_href_link // The HTML href link wrapper function function tep_href_link($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = true) { global $request_type, $session_started, $SID; $page = tep_output_string($page); if (!tep_not_null($page)) { die('</td></tr></table></td></tr></table><br /><br /><font color="#ff0000"><strong>Error!</strong></font><br /><br /><strong>Unable to determine the page link!<br /><br />'); } if ($connection == 'NONSSL') { $link = HTTP_SERVER . DIR_WS_HTTP_CATALOG; } elseif ($connection == 'SSL') { if (ENABLE_SSL == true) { $link = HTTPS_SERVER . DIR_WS_HTTPS_CATALOG; } else { $link = HTTP_SERVER . DIR_WS_HTTP_CATALOG; } } else { die('</td></tr></table></td></tr></table><br /><br /><font color="#ff0000"><strong>Error!</strong></font><br /><br /><strong>Unable to determine connection method on a link!<br /><br />Known methods: NONSSL SSL</strong><br /><br />'); } if (tep_not_null($parameters)) { $link .= $page . '?' . tep_output_string($parameters); $separator = '&'; } else { $link .= $page; $separator = '?'; } while ( (substr($link, -1) == '&') || (substr($link, -1) == '?') ) $link = substr($link, 0, -1); Quote Link to comment Share on other sites More sharing options...
Guest Posted September 29, 2012 Share Posted September 29, 2012 Any one???? This support is nog very active Quote Link to comment Share on other sites More sharing options...
IWAS Posted October 5, 2012 Share Posted October 5, 2012 (edited) if I do this then it works <?php require_once('includes/application_top.php'); //require_once('mobile/includes/application_top.php'); if (!tep_session_is_registered('customer_id')) { $navigation->set_snapshot(); //tep_redirect(tep_mobile_link(FILENAME_LOGIN, '', 'SSL')); tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL')); } But then I get errors once logged in. because it does not reconize tep_mobile_link (obvious) Why don't you require once both the includes/aplication_top and the mobile/includes/aplication_top ? Should work, I tried it on one of my pages and it worked, but I had to eliminate the snapshot line cause it kept crashing when the clients weren't logged in. http://absolutelyscooterparts.net Edited October 5, 2012 by IWAS Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.