Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contribution] iOSC - mobile version of OSC on your iPhone


bumbarash

Recommended Posts

it is asif you type http://www.yoursite.com/mobile_index.php in your browserbar

if you run your site from a subdirectory, you need to change it to '../mobile_index.php' to get to the correct place.

think that answers your question ... now mine:

At least that is what I have done, but then it still doesn't show the mobile pages. When I put the files in the top level directory on my site, it starts working as long as I have seo urls disabled ...

 

anyone done the extra work for seo urls ?

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

in includes/classes/seo.class.php I have added an extra check to see if urls begin with mobile, if so, the seo url is not generated, but stock function is called.

 

These are now the first couple of lines:

	function href_link($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true){
	$this->start($this->timestamp);
	$this->performance['NUMBER_URLS_GENERATED']++;
	if ( !in_array($page, $this->attributes['SEO_PAGES']) || $this->attributes['SEO_ENABLED'] == 'false' 
		|| 	(substr($page, 0, 6) == 'mobile') ) {
		return $this->stock_href_link($page, $parameters, $connection, $add_session_id);
	}

 

Secondly, for what it's worth, i also made the following changes so that called urls from the mobile pages are keeping on the mobile version and not switching to the PC version.

 

in mobile/includes/functions/general.php

 

1) renamed the tep_mobile_link function to tep_mobile_link1

2) renamed the tep_mobile_link2 function to tep_mobile_link

3) modified tep_mobile_link to prepend mobile to the page, when it is not yet present

 

first couple of lines with the actual results pasted below

<?php
 function tep_mobile_link1($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = false) {
return tep_href_link($page, $parameters, $connection, $add_session_id,false);  	
 }

function tep_mobile_link($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = false) {
   global $request_type, $session_started, $SID;
 	$module = substr($page,0,-4);

//  	$page = FILENAME_MOBILE;
//  	$parameters = 'module=' . $module . '&' . $parameters;
   if (substr($page, 0, 6) !== 'mobile' ) {
 	  $page = 'mobile_' . $page;
}

 

please let me know if I misunderstood how it is supposed to function, but this does seem to work for me. Hope this helps ...

 

Carine

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

if you choose to show the shopping cart upon addition to cart, the PC shopping cart shows, not the mobile version.

 

Not sure if this can be solved by correcting this in mobile/application_top, or if the real application_top.php needs to be enhanced to make the distinction ... that will be for another day, now it is time to sleep :)

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

if you choose to show the shopping cart upon addition to cart, the PC shopping cart shows, not the mobile version.

 

Not sure if this can be solved by correcting this in mobile/application_top, or if the real application_top.php needs to be enhanced to make the distinction ... that will be for another day, now it is time to sleep :)

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

I've tried adding the code to application_top.php but it never redirects.

 

I can goto mysite.com/mobile_index.php and everything is perfect.

 

are there any other ways to force a redirect for mobiles ?

 

thanks!!!!

Link to comment
Share on other sites

I've tried adding the code to application_top.php but it never redirects.

/quote]

Please be precise where you added what and with what clients you have tested.

I personally don't see any other way to do that ...

 

Carine

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

I put the following before the last ?> in mysite/includes/application_top.php:

 

   define(DIR_MOBILE_CLASSES , 'mobile/includes/classes/');   
  require(DIR_MOBILE_CLASSES . 'mobile_redirect.php');   
  $mobileRedirect = new mobileRedirect;

 

My mysite/mobile/mysite/includes/classes/mobile_redirect.php has the following

 

<?php
 class mobileRedirect {
 	var $redirected;
 	var $mobileDir = "mobile_";

   function mobileRedirect() {
   	$this->redirected = $this->needRedirect();
   	if($this->redirected)
   		$this->redirect();
   }

function needRedirect() {
if($this->isCancelled()) return false;
if(strpos($_SERVER['SCRIPT_NAME'],$this->mobileDir . $this->mobileFile) > 0) return false;
if(tep_browser_detect('iPhone') || tep_browser_detect('iPod')) return 'iPhone';
if(tep_browser_detect('IEMobile')) return 'iPhone';
if(tep_browser_detect('HTC')) return 'iPhone';
if(tep_browser_detect('Blackberry')) return 'Blackberry';
if(tep_browser_detect('Nokia')) return 'Nokia';
if(tep_browser_detect('SonyEricsson')) return 'SonyEricsson';
if(tep_browser_detect('Opera Mobi')) return 'iPhone';
if(tep_browser_detect('Opera Mini')) return 'iPhone';
if(tep_browser_detect('MAUI_WAP_Browser')) return 'GenericWAP';
if(tep_browser_detect('alcatel')) return('alcatel'); // Alcatel Browser (PDA/Phone browser)
if(tep_browser_detect('lg-')) return('lg-'); // LG (PDA/Phone browser)
if(tep_browser_detect('ericsson')) return('ericsson'); // Ericsson Browser (PDA/Phone browser)
if(tep_browser_detect('mot-')) return('mot-'); // Motorola Browser (PDA/Phone browser)
if(tep_browser_detect('panasonic')) return('panasonic'); // Panasonic Browser (PDA/Phone browser)
if(tep_browser_detect('philips')) return('philips'); // Philips Browser (PDA/Phone browser)
if(tep_browser_detect('sagem')) return('sagem'); // Sagem (PDA/Phone browser)
if(tep_browser_detect('samsung')) return('samsung'); // Samsung (PDA/Phone browser)
if(tep_browser_detect('sie-')) return('sie-'); // SIE (PDA/Phone browser)
if(tep_browser_detect('sec-')) return('sec-'); // Sony/Ericsson (PDA/Phone browser)
if(tep_browser_detect('sonyericsson')) return('sonyericsson'); // Sony/Ericsson Browser (PDA/Phone browser)
if(tep_browser_detect('mmef')) return('mmef'); // Microsoft Mobile Explorer (PDA/Phone browser)
if(tep_browser_detect('mspie')) return('mspie'); // MS Pocket Internet Explorer (PDA/Phone browser)
if(tep_browser_detect('wapalizer')) return('wapalizer'); // WAPalizer (PDA/Phone browser)
if(tep_browser_detect('Opera Mobile')) return('Opera Mobile'); // WAPalizer (PDA/Phone browser)
if(tep_browser_detect('wapsilon')) return('wapsilon'); // WAPsilon (PDA/Phone browser)
if(tep_browser_detect('webcollage')) return('webcollage'); // WebCollage (PDA/Phone browser)
if(tep_browser_detect('up.')) return('up.'); // UP.Browser (PDA/Phone browser)
if(tep_browser_detect('docomo')) return('docomo'); // I-Mode phone (PDA/Phone browser)
if(tep_browser_detect('portalmmm')) return('portalmmm'); // I-Mode phone (PDA/Phone browser)
return false;
} 

   function isCancelled() {
   	if (tep_session_is_registered('redirectCancelled')) 
   		return true;
   	if(isset($_GET['redirectCancelled']) && $_GET['redirectCancelled'] == 'true') {
   		tep_session_register('redirectCancelled');
   		return true;
   	}
   	return false;
   }

   function redirect() {
   	$path = split("/" , $_SERVER['SCRIPT_NAME']);
   	$filename = $path[sizeof($path)-1];
   	$file = $this->mobileDir . $filename;
   	$qstring = $_SERVER['QUERY_STRING'];
   	$SSL = ($_SERVER['HTTPS']) ? "SSL" : "NONSSL";
   	if (file_exists($file))
   		tep_redirect(tep_href_link($file, $qstring, $SSL, false, false));
   }
}
?>

 

Testing on an HTC Raph (XDA) using both mobile opera and Mobile IE, cheers for the help

Link to comment
Share on other sites

  • 2 weeks later...

Using PayPal to complete transaction.

 

Not sure if this is posted already or not. When you click "Confirm Order" the current set up takes you to the PayPal log in/homepage and users can not complete transaction. But if you copy the code from your "full size" checkout_confirmation.php

 

<?php

if (isset($$payment->form_action_url)) {

$form_action_url = $$payment->form_action_url;

} else {

$form_action_url = tep_href_link(FILENAME_CHECKOUT_PROCESS, '', 'SSL');

}

 

echo tep_draw_form('checkout_confirmation', $form_action_url, 'post');

 

if (is_array($payment_modules->modules)) {

echo $payment_modules->process_button();

}

 

echo tep_image_submit('button_confirm_order.gif', IMAGE_BUTTON_CONFIRM_ORDER) . '</form>' . "\n";

?>

 

 

& paste it your mobile_checkout_confirmation.php around line 307 & around 472 (you'll need to remove the current buttons

 

<input type="submit" value="<?php echo IMAGE_BUTTON_CONFIRM_ORDER; ?>">

 

 

 

 

your users will be taken to the full size PayPal checkout page (just like on a computer).

 

It works fine because after all this is an iPhone we're dealing with (I have no idea if it works with other mobiles) good luck!

Link to comment
Share on other sites

I'm really excited by this addon and I've had some success by going back from v2c to 1.4. But I could never get v2 to work. Maybe its a php thing..

 

As I've seen in other posts, the redirect isn't working, but the pages work fine with /mobile, I also note that the http://detectmobilebrowsers.mobi/ code works fine, but then I cant use the PC version because if your mobile, your always redirected so its not an apache or .htaccess config.

 

I'm using an iPhone and also using the Apple Safari browser with the developer menu turned on in advanced perfs. THis lets you select the user agent.

 

Does anyone have any ideas?

 

the main site is here http://www.fimocreations.co.uk/

and the mobile site is here http://www.fimocreations.co.uk/mobile/

 

I put

define(DIR_MOBILE_CLASSES , 'mobile/includes/classes/');

require(DIR_MOBILE_CLASSES . 'mobile_redirect.php');

$mobileRedirect = new mobileRedirect;

 

just before the ?> in application_top.php

 

what else could be wrong?

Link to comment
Share on other sites

how do you stop google or any other search engines indexing the mobile files? I saw some solution earlier in this support thread but were does the text go in spiders.txt?

 

would this work if I added it to every mobile file?

 

<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">

Link to comment
Share on other sites

Okay, I'm trying to use this contribution, but I seem to be having many of the same problems that others have had, and the answers do not seem to be working for me.

 

Problem 1) Redirect does not work. It simply goes straight to my full PC site

Problem 2) Sorry, the page you requested was not found. - I get this for:

http://www.nalsworkshop.com/catalog/mobile/mobile_index.php

http://www.nalsworkshop.com/catalog/mobile/about.php

 

Problem 3) http://www.nalsworkshop.com/catalog/mobile/index.php redirects to http://www.nalsworkshop.com/catalog/mobile/mobile_index.php - which does not exist.

 

Problem 4) When I load up http://www.nalsworkshop.com/catalog/mobile_index.php it takes me to the mobile page, but no products load. I get my categories to load though.

 

Please, any help would be great!

 

Naloomi

Link to comment
Share on other sites

how do you stop google or any other search engines indexing the mobile files? I saw some solution earlier in this support thread but were does the text go in spiders.txt?

 

would this work if I added it to every mobile file?

 

<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">

I think both are usefull, the entries in robots.txt and the header, some bots don't read the robots.txt file, so having the meta tag could be good too.

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

Okay, I'm trying to use this contribution, but I seem to be having many of the same problems that others have had, and the answers do not seem to be working for me.

 

Problem 1) Redirect does not work. It simply goes straight to my full PC site

Problem 2) Sorry, the page you requested was not found. - I get this for:

http://www.nalsworkshop.com/catalog/mobile/mobile_index.php

http://www.nalsworkshop.com/catalog/mobile/about.php

 

Problem 3) http://www.nalsworkshop.com/catalog/mobile/index.php redirects to http://www.nalsworkshop.com/catalog/mobile/mobile_index.php - which does not exist.

 

Problem 4) When I load up http://www.nalsworkshop.com/catalog/mobile_index.php it takes me to the mobile page, but no products load. I get my categories to load though.

 

Please, any help would be great!

 

Naloomi

I think 2) and 3) are because you have your site in a subdirectory (catalog), I had similar issues when I put it first in my test directory which is located in a subdir of the main site, when I moved the code in my production live site like site.com/mobile/ it all worked much better.

 

4) I had similar different/inconsistent results between my PC site and mobile site, when I had subcategories and products at the same category level, maybe you have similar mix in your site ?

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

About the redirect issue, sorry guys, I'm still waiting on Santa to bring me test phone(s) :D

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

Someone mentioned recently that mobile pages cause his Google Search to reindex his website. I'm not really sure what that means, but probably it's a good idea to disallow search boots on your mobile website and keep them on the main site.

So if you have robots.txt file in your home directory, add those lines there

 

User-Agent: *
Disallow: /mobile
Allow: /

User-Agent: Googlebot-Mobile
Allow: /mobile
Allow: /

 

bruyndoncx, bumbarash wrote that he didnt know what google reindexing a site means and wrote to add the User-Agent: * etc code to spider.txt.

 

Reindexing a site is a disaster. It can cause your site dissapear from google for a long time while it is reindexed Then you have mobile_ files indexed in google which is not a good idea. The User Agent code is not right becuase it dissalows /mobile and allows everything else. In the latest release of iOSC, most mobile_ files are not in the mobile folder!!

 

I would not recommend posting any links or redirects to these mobile files on your web site until a definate solution is posted that will stop any indexing of the mobile file.

 

The Meta tag code is permanent a solution, I need to check where the code should be added in some files.

Link to comment
Share on other sites

bruyndoncx, bumbarash wrote that he didnt know what google reindexing a site means and wrote to add the User-Agent: * etc code to spider.txt.

 

Reindexing a site is a disaster. It can cause your site dissapear from google for a long time while it is reindexed Then you have mobile_ files indexed in google which is not a good idea. The User Agent code is not right becuase it dissalows /mobile and allows everything else. In the latest release of iOSC, most mobile_ files are not in the mobile folder!!

 

I would not recommend posting any links or redirects to these mobile files on your web site until a definate solution is posted that will stop any indexing of the mobile file.

 

The Meta tag code is permanent a solution, I need to check where the code should be added in some files.

Is it just a google bot or all robots?

May be we should include this meta to mobile files:

<meta name="googlebot" content="noindex, nofollow">

Link to comment
Share on other sites

Just downloaded version 2.2 installed as per the instructions. Ive also read through this entire length of this thread and tried all the different suggestions but...

 

when i browse via iPhone i just get a blank page

 

if i browse by PC directly to shop.multibiz.biz/mobile i get 'The Page Cannot Be Found'

 

not sure what else to try. ?? :blink:

 

thanks

zac

Edited by zac123
Link to comment
Share on other sites

ok so i think i made a little bit of progress. I think there was a '/' missing from mobile/index.php

 

so..

 

 

now if i go directly to shop.multibiz.biz/mobile i end up at shop.multibiz.biz/mobile_index.php however the page just looks like the pic attached:iOSC.jpg

 

but still no redirect from the iphone. also i dont think that its working correctly because i thinkg there should be more on the mobile_index.php page right?

 

zac

Link to comment
Share on other sites

ok, so things are getting better. i re-coppied over all the original files and now when i go to shop.multibiz.biz/mobile_index.php i can see the proper screen with categories etc.

 

my questions are now these:

 

1, when i click to view a category it takes me back to the 'PC' site, should it not remain within the iOSC ?

 

2, Still cant get the auto redirect to work from my iphone even after adding the suggested code to the application_top.php

 

3, also my title seems to appear like this: <?=title?>, is this correct or do i need to change something.

 

thanks,

 

zac

Link to comment
Share on other sites

Hi Dont know if this has been posted before

 

but in mobile/includes/iheader.php and header.php

shouldn't

<title><?=TITLE?></title>

 

be

<title><?php echo TITLE; ?></title>

 

As above wont work on all php versions and <? is used for xml not php anymore

 

Steve

Edited by steve_s
Link to comment
Share on other sites

To get it to goto mobile shopping cart

 

catalog/mobile_product_info.php

find

echo tep_draw_form('cart_quantity', tep_mobile_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=add_product')); ?>

change it to

echo tep_draw_form('cart_quantity', tep_mobile_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=mobile_add_product')); ?>

 

catalog/includes/apllication_top.php

find

      case 'add_product' :    if (isset($HTTP_POST_VARS['products_id']) && is_numeric($HTTP_POST_VARS['products_id'])) {
                               $cart->add_cart($HTTP_POST_VARS['products_id'], $cart->get_quantity(tep_get_uprid($HTTP_POST_VARS['products_id'], $HTTP_POST_VARS['id']))+1, $HTTP_POST_VARS['id']);
                             }
                             tep_redirect(tep_href_link($goto, tep_get_all_get_params($parameters)));
                             break;

add under it

      case 'mobile_add_product' :    if (isset($HTTP_POST_VARS['products_id']) && is_numeric($HTTP_POST_VARS['products_id'])) {
                               $cart->add_cart($HTTP_POST_VARS['products_id'], $cart->get_quantity(tep_get_uprid($HTTP_POST_VARS['products_id'], $HTTP_POST_VARS['id']))+1, $HTTP_POST_VARS['id']);
                             }
                             tep_redirect(tep_mobile_link($goto, tep_get_all_get_params($parameters)));
                             break;

You will also need to follow this post

http://www.oscommerce.com/forums/topic/327785-contribution-iosc-mobile-version-of-osc-on-your-iphone/page__view__findpost__p__1456042

 

for ease replace all code in mobile/includes/functions/general.php with code below

<?php
 function tep_mobile_link1($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = false) {
       return tep_href_link($page, $parameters, $connection, $add_session_id,false);   
 }



function tep_mobile_link($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = false) {
   global $request_type, $session_started, $SID;
       $module = substr($page,0,-4);

//      $page = FILENAME_MOBILE;
//      $parameters = 'module=' . $module . '&' . $parameters;
   if (substr($page, 0, 6) !== 'mobile' ) {
         $page = 'mobile_' . $page;
       }

   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"><b>Error!</b></font><br><br><b>Unable to determine connection method on a link!<br><br>Known methods: NONSSL SSL</b><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);

// Add the session ID when moving from different HTTP and HTTPS servers, or when SID is defined
   if ( ($add_session_id == true) && ($session_started == true) && (SESSION_FORCE_COOKIE_USE == 'False') ) {
     if (tep_not_null($SID)) {
       $_sid = $SID;
     } elseif ( ( ($request_type == 'NONSSL') && ($connection == 'SSL') && (ENABLE_SSL == true) ) || ( ($request_type == 'SSL') && ($connection == 'NONSSL') ) ) {
       if (HTTP_COOKIE_DOMAIN != HTTPS_COOKIE_DOMAIN) {
         $_sid = tep_session_name() . '=' . tep_session_id();
       }
     }
   }

   if (isset($_sid)) {
     $link .= $separator . tep_output_string($_sid);
   }

   return $link;
 }

 function tep_mobile_button($text, $params = '') {
//	return '<div id="mobileButton"><table><tr><td width="1px"><img src="images/greybutton/left.gif"/></td><td>' . $text . '</td><td width="1px"><img src="images/greybutton/right.gif"/></td></tr></table></div>';
return '<input type="submit" value="' . $text . '" ' . $params . '/>';
//	return '<div id="mobileButton"><table><tr><td width="1px"><img src="images/greybutton/left.gif"/></td><td>' . $text . '</td><td width="1px"><img src="images/greybutton/right.gif"/></td></tr></table></div>';
 }

 function tep_mobile_path_element($path, $element, $alt=null) {
	return ($path ? '<a href="' . $path .'">' . $element . '</a>' : ($alt ? $alt : $element)) ;
 }

 function tep_mobile_selection($path, $elements) {
 	$ret = '<tr class="categories"';
 	$ret .= ($path ? ' onclick="window.location.href=\'' . $path .'\'"' : '' );
 	$ret .=  '>';
 	foreach ($elements as $element) {
 		$ret .= '<td class="categories">' . tep_mobile_path_element($path,$element) . '</td>';
 	}
 	$ret .= '<td class="categories" align="right">';
 	$ret .= ($path) ?  '<a href="' . $path .'">' . tep_image(DIR_MOBILE_IMAGES . 'arrow_select.png') . '</a>' : '<input type="image" src="' .DIR_MOBILE_IMAGES . 'arrow_select.png' . '" border="0" alt="">';
return $ret;

 }
 function tep_print($obj) {
	print ("<pre>");
	print_r ($obj);
	print ("</pre>\n");
}
 function tep_debug($obj) {
 	if(MOBILE_DEBUG) {
	tep_print($obj);
 	}
 }
?>

 

Steve

Edited by steve_s
Link to comment
Share on other sites

Found some more changes to make this worked for me

in mobile_shopping_cart.php

find

<td align="center" class="main"><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_mobile_button(IMAGE_BUTTON_CONTINUE) . '</a>'; ?></td>

replace with

<td align="center" class="main"><?php echo '<a href="' . tep_mobile_link(FILENAME_DEFAULT) . '">' . tep_mobile_button(IMAGE_BUTTON_CONTINUE) . '</a>'; ?></td>

 

i also changed in mobile/includes/configure.php

find

define('FILENAME_CHECKOUT_CONFIRMATION', 'mobile_checkout_confirmation.php');
define('FILENAME_CHECKOUT_PAYMENT', 'mobile_checkout_payment.php');
define('FILENAME_CHECKOUT_PAYMENT_ADDRESS', 'mobile_checkout_payment_address.php');
define('FILENAME_CHECKOUT_SHIPPING', 'mobile_checkout_shipping.php');
define('FILENAME_CHECKOUT_SHIPPING_ADDRESS', 'mobile_checkout_shipping_address.php');
define('FILENAME_CHECKOUT_SUCCESS', 'mobile_checkout_success.php');

 

change to

define('FILENAME_MOBILE_CHECKOUT_CONFIRMATION', 'mobile_checkout_confirmation.php');
define('FILENAME_MOBILE_CHECKOUT_PAYMENT', 'mobile_checkout_payment.php');
define('FILENAME_MOBILE_CHECKOUT_PAYMENT_ADDRESS', 'mobile_checkout_payment_address.php');
define('FILENAME_MOBILE_CHECKOUT_SHIPPING', 'mobile_checkout_shipping.php');
define('FILENAME_MOBILE_CHECKOUT_SHIPPING_ADDRESS', 'mobile_checkout_shipping_address.php');
define('FILENAME_MOBILE_CHECKOUT_SUCCESS', 'mobile_checkout_success.php');

 

mobile_checkout_shipping.php

find

 tep_redirect(tep_mobile_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));

change it to

tep_redirect(tep_mobile_link(FILENAME_MOBILE_CHECKOUT_PAYMENT, '', 'SSL'));

 

im still working through this so might be more things to change

 

Steve

Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...