News:

AbanteCart v1.4.2 is released.

Main Menu
support

category menu links

Started by jesus_automatic, January 17, 2014, 03:02:18 PM

Previous topic - Next topic

jesus_automatic

Thanks for the pointers. Bit of a mad week but I will investigate those files at the weekend.
The problem started when I switched from default template to html5. So maybe the .tpl files are the culprit.

jesus_automatic

I have had look through the suggested files.
category_top.tpl looked relevant, but then the problem reoccurred in the main menu rather than the category menu. It all leaves me rather confused. I suspect it is not a problem with templates, menus or blocks, but whatever in the core generates the links. When the problem occurred in the main menu I had to reset the system and store cache to clear it. Previously resetting the category cache would do it - the file cache.category.details.0.1_0.1394910582 contains the urls.

???

jesus_automatic

So I did the upgrade from 1.1.6 to 1.1.7 and the problem persists in the top menu - Login etc.

The source code taken from the home page looks like this
<ul id="main_menu_top" class="nav main_menu">
    <li  data-id="menu_login"  class="dropdown hover"><a  class="top menu_login"  href="http://37.61.233.155/index.php?rt=account/login" ><span>Login</span></a></li>
<li  data-id="menu_account"  class="dropdown hover"><a  class="top menu_account"  href="http://37.61.233.155/index.php?rt=account/account" ><span>Account</span></a></li>
<li  data-id="menu_cart"  class="dropdown hover"><a  class="top menu_cart"  href="http://37.61.233.155/index.php?rt=checkout/cart" ><span>Cart</span></a></li>
<li  data-id="menu_checkout"  class="dropdown hover"><a  class="top menu_checkout"  href="http://37.61.233.155/index.php?rt=checkout/shipping" ><span>Checkout</span></a></li>
</ul>

But all other links point to the www.etc.
Any more ideas?

junkyard

Since you (evidently) already have the Store URL set correctly to your domain name in admin system > settings > details  (and this is the only directly related setting),  the AbanteCart is supposed to pick it up for these links generation.  Just look at how HTTP SERVER and HOST are being used in
~/public_html/core/init.php     (there's also your 'localhost' mentioned in it)     to render the links for the storefront in the php and passed to the tpls. Then at some point later the cache files come into play.   You do have supported PHP version, do you?

QuoteThe problem started when I switched from default template to html5.
QuoteI know if I clear the category cache then the problem goes away for a while.

Sounds like a software bug triggered by the switch ? 
As the old default html template appears to be rarely used,  the switch could be overlooked QA scenario..
Maybe someone from Abantecart team could help figure out this one.

jesus_automatic

Yes the system setting is correct.
The error log in 1.1.7 seems to show more details

2014-03-17 10:44:30 - App Warning:  AbanteCart core v.1.1.7 Warning: Accessing store with unconfigured or unknown domain ( localhost/ ).
Check setting of your store domain URL in System Settings . Loading default store configuration for now. in /home/figtreeb/public_html/core/lib/config.php on line 169

2014-03-25 21:28:54 - App Warning:  AbanteCart core v.1.1.7 Warning: Accessing store with unconfigured or unknown domain ( FIGTREEBEAUTY.COM/ ).

And most commonly
2014-04-01 10:25:13 - App Warning:  AbanteCart core v.1.1.7 Warning: Accessing store with unconfigured or unknown domain ( 37.61.233.155/ ).

Though strangely this last one is from this morning and the site is functioning correctly.
The server supports PHP v. 5.3.26, which I believe is ok.

I will have a look at the core/init.php and see if I can understand any of it, and post back later

jesus_automatic

Well that definitely where the address is controlled from, but I am none the wiser where this intermittent problem is coming from. I checked the file I have against a clean copy of 1.1.7 just to check it hadnt been messed with. Its an exact match.

If someone with better understanding of the structure of abantecart core could apply some thought to  this problem I would be grateful.

jesus_automatic

The only other entry in the error log is

2014-04-03 0:49:04 - warning:  AbanteCart core v.1.1.7 preg_grep() [<a href='function.preg-grep'>function.preg-grep</a>]: Compilation failed: nothing to repeat at offset 0 in <b>/home/figtreeb/public_html/core/engine/language.php</b> on line <b>232</b>

but that doesnt appear to be related.

Any ideas anyone?

Forum Rules Code of conduct
AbanteCart.com 2010 -