Zen Cart Logo
Forums / General Questions / Manually link to categories...

Manually link to categories...

Locked

Views: 1,167

Results 1 to 6 of 6
This thread is locked. New replies are disabled.
31 May 2007, 3:49 PM
#1
alex_clarke avatar

alex_clarke

Totally Zenned

Join Date:
Mar 2006
Posts:
909
Plugin Contributions:
1

Manually link to categories...

Is it possible to manually link to a category?

At the moment I'm using the following code:

<a href="index.php?main_page=index&cPath=7">

However, if the customer clicks on this link from a secure part of the site they are given the usual message warning them about non-secure items.

I know how to link to different pages using the zen_href_link function, but not how to link to a particular category! :S

1 Jun 2007, 6:28 PM
#2
jammin320 avatar

jammin320

Zen Follower

Join Date:
Mar 2007
Location:
Seattle, WA
Posts:
158
Plugin Contributions:
0

Re: Manually link to categories...

Do they need to stay in a secure mode? You could use the same line of code, but make the link absolute (http://mycart.com/index.php?main_page=index&cPath=7). That would remove them from the SSL portion and they would no longer get the security warning.

2 Jun 2007, 2:42 AM
#3
tatiana77 avatar

tatiana77

Zen Follower

Join Date:
May 2007
Posts:
114
Plugin Contributions:
0

Re: Manually link to categories...

Thanks I learnt from this thread.

Tat

2 Jun 2007, 6:06 AM
#4
jammin320 avatar

jammin320

Zen Follower

Join Date:
Mar 2007
Location:
Seattle, WA
Posts:
158
Plugin Contributions:
0

Re: Manually link to categories...

:smile: Awesome!

That is what I love about this community, there is knowlage and help everywhere.

3 Jun 2007, 2:34 PM
#5
alex_clarke avatar

alex_clarke

Totally Zenned

Join Date:
Mar 2006
Posts:
909
Plugin Contributions:
1

Re: Manually link to categories...

jammin320:

Do they need to stay in a secure mode? You could use the same line of code, but make the link absolute (http://mycart.com/index.php?main_page=index&cPath=7). That would remove them from the SSL portion and they would no longer get the security warning.

Hi Ben,

I agree with what you're saying, but isnt there a way of using the zen_href function. Something similar to the code below, but linking to a category...

<a href="<?php echo zen_href_link(FILENAME_ACCOUNT, '', 'SSL'); ?>">My Account</a>

Any ideas?

4 Jun 2007, 6:32 PM
#6
jammin320 avatar

jammin320

Zen Follower

Join Date:
Mar 2007
Location:
Seattle, WA
Posts:
158
Plugin Contributions:
0

Re: Manually link to categories...

I am not sure that there is, though I don't know for certain. . . we would need one of the ZenMasters to chime in for a definative answer. However, I would think that it would not work that way. The ZEN_HREF_LINK function pulls up a file. Since a category isn't a file that would include the defines in the top that the function uses, I would expect that this isn't the route to go. It may be worth taking a look into the code of the category sidebox to see what it uses to generate its links to categories. I'll do some digging myself aswell.