If not overridden by the template then zencart uses the template_default copyOriginally Posted by norber
If not overridden by the template then zencart uses the template_default copyOriginally Posted by norber
Zen-Venom Get Bitten
I took the job of this site with the mobile template already installed and FEC configured by someone else.
I checked the original downloaded zip and the mobile template is named "zencart-mobile". I know that the name is pretty common and should be 1000 templates with names like this.
I checked the mobile files and seems that checks for the user agent then, if the case is mobile, it loads that template.
When im in the shopping cart in mobile mode (ie: index.php?main_page=shopping_cart&zenid=7pngq0rtqp6pjc55ifnjtim5t7) and i hit "checkout", i can see that it goes after checkout_shipping (ie: index.php?main_page=checkout_shipping&zenid=7pngq0rtqp6pjc55ifnjtim5t7), then, a split sec later, it redirects to index.php?main_page=checkout&zenid=7pngq0rtqp6pjc55ifnjtim5t7 , and, a split sec more, it lands in index.php?main_page=checkout&fecaction=null&zenid=7pngq0rtqp6pjc55ifnjtim5t7
The result is that when it ends in index.php?main_page=checkout, the content after the header doesnt show, and i think that it happens because there is no tpl_checkout_default.php in mobiles template folder (\includes\templates\default_mobile\templates)
Thanks for your help and time, i really appreciate it.
What version of ZC?
I think the key here is to determine if it's loading a separate set of files for the mobile version or if it's a plugin/overlay on the regular ZC installation.
Is the zip file named zencart-mobile.zip?
(unzip that file in a temp directory and check that all the folders and files are in your production installation. i.e. are all the files there, As Kobra stated "If not overridden by the template then zencart uses the template_default copy" and that would default to the non-mobile version.
Can you tell if FEC was downloaded from Zen Cart or from numinix? If it's a numinix product they may be able to help.
Sorry for all the questions but with a few questions either you or one of us may be able to help figure this out.
Beside that I've been looking for a simple mobile solution myself.
I have just installed FEC with tableau template. if I have the split layout turned on how can I get it to adjust if the screen is narrow for example on a mobile devise so it responds in the same way as the rest of the tableau template does?
And my second issue is that if the the one page check out is false then the second page(the confirmation page) does not have any styling or layout to it. it is as if the css file is not being read. I have gone back through the install and cannot see any css missing in my install.
Can anyone help.
Thank you.
norber
I carefully read your original post and see the ZC & FEC version info.
Assuming the mobile version is a plugin. Because the URLS have shopping_cart and checkout_shipping in them those two files must be modified or have override files.
Check you mobile zip file and see if they exist or the instructions say to modify them.
Last edited by linuxguy2; 4 Aug 2015 at 02:49 AM. Reason: Added name
LinuxGuy2, Kobra, SouthShorePizza; first of all, thanks for taking the time to read and help me, guys.
Well, what i did the last hours was to check the files looking for all the requires from the beggining.
That is, from the index.php in the root of the site. May be its an excercise on futility but im running out of options.
I put some echoes in the page to see what its loading each time:
To not confuse you, i will name the template folders as "web_template" and mobile_template". Heres what ive found:
require($code_page_directory . '/' . $value);
includes/modules/pages/index/
require($template->get_template_dir('html_header.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/html_header.php');
includes/templates/mobile_template/common/html_header.php
require($template->get_template_dir('main_template_vars.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/main_template_vars.php');
includes/templates/mobile_template/common/main_template_vars.php (*)
The funny thing, is that after the line above, if i put:
echo DIR_WS_TEMPLATE;
i got "includes/templates/web_template", INSTEAD OF "includes/templates/mobile_template"
and, after that, if i put
echo $current_page_base;
i got "index";
(*) on includes/templates/mobile_template/common/main_template_vars.php i put another echo to get where it was pulled the body code:
includes/modules/pages/index/main_template_vars.php
That folders structure doesnt come in the zip, so i think that its not overwritten by the installer
Regarding the instructions on the zip of the mobile, i got:
1) Extract the contents of the zip file you've just downloaded.
2) Put the entire folder ` zencart-mobile-install` in the root directory of your zencart installation.
3) navigate to YOURSITE.com/YOUR_ZENCART_INSTALL_DIRECTORY(usually cart or store) /zencart-mobile-install/
4) Choose a username and password for the mobile configuration tool.
5) Select your mobile logo image and your colors and let the installer do the rest.
6) Enjoy a fully functional mobile version of your website!
Seems that the installer copies and overwrites files, but the problem is to know which ones.
Inside the zip theres another zip (?) with the template files. Seems that the first "stage" of the zip is the installer itself that deflates and copies the contents of the one that is inside it.
Regarding if it is under the template or plugin category, the creators (http://www.mobilezencart.com/) define it as a "module".
Thanks again guys.
Norbert,
This new information will help a lot. I take it you're using the paid version but I/we may be able to extract enough information from the free version to help.
See if you can look at the files in the second zip file. That's probably where all the files you need to look at are.
It will be tomorrow before I have time to look at this again.
I downloaded the zencart from zencart.com.
I unzipped the zen-cart contents in a folder. Its a newer version than the one i have (1.5.4 and i have the 1.5.3) but i think that theres not so much difference.
I took the contents in the mobile module 2nd zip (a folder named "include")and pasted it in the zencart folder i decompressed earlier.
The only file to be overwritten was includes/classes/template_func. the rest were new files.
I asked the developers of mobile zencart if they knew of some conflict between the module and FEC some time ago and they told me "that they were not aware of it, but that if i wanted the money back thats ok". The last part sounded weird.
The worst scenario for me is that theres no conflict in vanilla versions of both (zencart and mobile module), and the conflict is in some modification done in some file by the previous developer. I saw dozens of test files in there (ie: main_template_vars.php_v001, main_template_vars.php_v002 and so on). Finding the problem in that condictions will be like find a needle in a haystack, because i will lost any reference to the real, documented thing.
Thx!
norber
I know you said it was the paid version but be sure it's the zencart-mobile premium install as I don't think the free install includes the mobile check out module.
Also it sound like there's an admin section to this module.
Check all the Mobile and the ZC admin sections for settings. Maybe it's just not enabled....
You said it works with the vanilla versions. Is that without FEC installed?
Or did you do a out of the box ZC test installation with FEC to see if it works?
Some trouble shooting methods I use.
1:
In the ZC folder online view details > sort on date modified and check to see which dates are different.
These are most likely the files that have been messed with.
OR
2:
With a FTP program like Winscp download entire ZC folder to your local machine so you have the working production install.
3:
In the folder you download to, view details > sort on date modified and check to see which dates are different.
These are most likely the files that have been messed with.
4:
To see what has been changed in the files, download a program that compares files like
NotePad++ you can get here. https://notepad-plus-plus.org/download/v6.8.1.html
(There are others but this one is simple to use and gets the job done)
Be sure you select the plugins option or just take the default installation settings.
5:IMPORTANT!
After you install and start the program in the menu bar go to Plugins > Plugin Manager and install the "Compare" plugin.
6:
Close and restart the program. Drag and drop the two files you want to check into it and go to Plugins > Compare > Compare.
7:
Be sure the file extensions are php or it won't give you a clear display of the differences.
Personally I don't use the nav bar on the right as it takes up space.
Hope that helps,
Meanwhile I'll try to download and install zencart-mobile.
Maybe you already saw this but one of the core files they add to is in:
/your catalog folder/include/class/template_func.php
Around lines 45 they add: (Be sure it's in there)
global $deviceType;
if($deviceType != FULL_SITE_DISPLAY_DEVICE)
$current_template = DIR_WS_TEMPLATES.DIR_MOBILE_TEMPLATE;
Bookmarks