Re: MobiZenCart with seo url
That is not going to work. MobiZenCart is built with jQuery Mobile which kinda' rewrites the URL.
Re: MobiZenCart with seo url
Thanks because Mobizen Cart and Seo url not working together?
Re: MobiZenCart with seo url
Love the theme, really great:)
If you want to show the theme on mobiles only, no tablets. Replace this code in \includes\templates\template_default\mobile_redirect.php on line 7:
if ($detect->isMobile() && !$detect->isTablet()) {
Re: MobiZenCart with seo url
I'm glad to hear that you like it. Thanks!
As for the code modification. A safer place to ensure that the code only works on small devices such as iPhones would be to change line 41 in includes > init_includes > overrides > init_templates.php from:
PHP Code:
if ($detect->isMobile()) {
to
PHP Code:
if ( ($detect->isMobile()) && (!$detect->isTablet()) ) {
Lines 38 to 50 in that file are the ones that change the template for mobile devices.
Re: MobiZenCart with seo url
i am running zencart 1.5.4 and installed mobizencart. i got problem with Paypal express checkout.
when i click paypal express checkout in mobile mode, it shows " PROBLEM: we're sorry Paypal has unexpectedly returned a blank address. in order to complete your purchase, please provide your address by clicking the "sign up"button........"
Paypal button is fine on desktop mode.
How to fix this problem?
thanks in advance!
Re: MobiZenCart with seo url
That button is actually an image with a link.
Code:
<!-- ** BEGIN PAYPAL EXPRESS CHECKOUT ** -->
<div id="PPECbutton" class="buttonRow">
<a href="http://yourdomain.com/ipn_main_handler.php?type=ec" class="ui-link">
<img src="https://www.paypalobjects.com/en_US/i/btn/btn_xpressCheckout.gif" alt="Click here to pay via PayPal Express Checkout"></a>
</div>
<!-- ** END PAYPAL EXPRESS CHECKOUT ** -->
Look at the jQuery Mobile documentation for Linking without Ajax here. I states the following:
Links that point to other domains or that have rel="external", data-ajax="false" or target attributes will not be loaded with Ajax. Instead, these links will cause a full page refresh with no animated transition. Both attributes (rel="external" and data-ajax="false") have the same effect, but a different semantic meaning: rel="external" should be used when linking to another site or domain, while data-ajax="false" is useful for simply opting a page within your domain from being loaded via Ajax. Because of security restrictions, the framework always opts links to external domains out of the Ajax behavior.
All you need to do is find the file that create the code shown above. If it is a template file that can use the template override system, make a copy, added to the mobizencart template and modify it there. Otherwise you may want to make changes with an if condition. All you need is a data=ajax="false" in the href. Something like:
PHP Code:
if ($detect->isMobile()) {
href="http://yourdomain.com/ipn_main_handler.php?type=ec" class="ui-link" data-ajax="false"
} else {
href="http://yourdomain.com/ipn_main_handler.php?type=ec" class="ui-link"
}
The above is an example and would not work but should give you a good idea.
Re: MobiZenCart with seo url
Quote:
Originally Posted by
ultimate_zc
That button is actually an image with a link.
Code:
<!-- ** BEGIN PAYPAL EXPRESS CHECKOUT ** -->
<div id="PPECbutton" class="buttonRow">
<a href="http://yourdomain.com/ipn_main_handler.php?type=ec" class="ui-link">
<img src="https://www.paypalobjects.com/en_US/i/btn/btn_xpressCheckout.gif" alt="Click here to pay via PayPal Express Checkout"></a>
</div>
<!-- ** END PAYPAL EXPRESS CHECKOUT ** -->
Look at the jQuery Mobile documentation for Linking without Ajax
here. I states the following:
Links that point to other domains or that have rel="external", data-ajax="false" or target attributes will not be loaded with Ajax. Instead, these links will cause a full page refresh with no animated transition. Both attributes (rel="external" and data-ajax="false") have the same effect, but a different semantic meaning: rel="external" should be used when linking to another site or domain, while data-ajax="false" is useful for simply opting a page within your domain from being loaded via Ajax. Because of security restrictions, the framework always opts links to external domains out of the Ajax behavior.
All you need to do is find the file that create the code shown above. If it is a template file that can use the template override system, make a copy, added to the mobizencart template and modify it there. Otherwise you may want to make changes with an if condition. All you need is a data=ajax="false" in the href. Something like:
PHP Code:
if ($detect->isMobile()) {
href="http://yourdomain.com/ipn_main_handler.php?type=ec" class="ui-link" data-ajax="false"
} else {
href="http://yourdomain.com/ipn_main_handler.php?type=ec" class="ui-link"
}
The above is an example and would not work but should give you a good idea.
Thanks for your quick reply!
it did fix the problem!
I only add class="ui-link" data-ajax="false" to the code and without an if condition. it works on desktop and mobile.
so I wonder it would cause any problem missing the if condition?
Re: MobiZenCart with seo url
It shouldn't be a problem as long as you don't use the same HTML data-* attribute for something else in your design, particularly on the same page where you have the checkout button. Chances are you don't. I just wanted to give you a reason why it is ok to just add data-ajax. See HTML data-* Attributes.
Re: MobiZenCart with seo url
Is that can working at 1.5.0 version and allbusiness template?