Modified Link structure with Loop Links question

General ShopSite user discussion

Modified Link structure with Loop Links question

Postby Feydakin » Mon Jan 19, 2009 7:57 pm

I want to set up my manufacturers as subdomains rather than subdirectories.. This makes the built in menu/link system unlikely especially making the index page in each subdomain.. For example..

instead of
domain.com/manufacturer1/index.php
I want
manufacturer1/domain.com/ as the link..

I should be able to do this with a custom page field on each page called NewLink and then instead of calling the LoopLinks like this -

Code: Select all
[-- LOOP LINKS --]
  <li class="inline">[-- LINK --]</li>
[-- END_LOOP LINKS --]

I would call it like this -

Code: Select all
[-- LOOP LINKS --]
  <li class="inline"><a href="[-- PAGE.NewLink --]</a></li>
[-- END_LOOP LINKS --]



Except, why I try to publish the site I get the following error

AnimalCharms.sst [121]: Template Error: END_LOOP tag reached without processing this tag - LINKS

Is what I'm trying to do even possible?? Or am I making my typical minor mistake that is keeping me from seeing the solution??

Thoughts??
Feydakin
 
Posts: 42
Joined: Wed Jul 23, 2008 11:24 am
Location: Indiana

Postby Jim » Mon Jan 19, 2009 10:12 pm

I don't think there is a tag [-- PAGE.newlink --]

Even if there were you would probably need another quote mark after it since you have one before it.

When ShopSite generates pages they will only be places in the url that is in the store's auth file. So ShopSite will not publish to manufacturer1/domain.com/ if the authfile says domain.com/manufacturer. If you have access to the server you could probably create symlinks in the store's authorized output directory to another directory on the same server and then the file would be published but that would be the only way you could get this to work.
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Postby Feydakin » Tue Jan 20, 2009 12:50 pm

Right.. I created the NewLink field using the custom page fields..

As for publishing the pages themselves they are being published via filename at /manufacturer1/filename.php and then we are use subdomains to call them.. I'm not using, or don't want to use, the filename based menu system that is autocompiled.. Hence the new field idea to generate my own custom menus..

The " issue was just a typo when posting it here..
Feydakin
 
Posts: 42
Joined: Wed Jul 23, 2008 11:24 am
Location: Indiana

Postby Jim » Tue Jan 20, 2009 1:30 pm

You can't refer to a custom field in a template with the name you assign it, you can only refer to it by the field number such as [-- Page.field1 --],[-- Page.field2 --] etc.

Is that what you are trying to do?
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Postby Jim » Tue Jan 20, 2009 1:37 pm

Also the [-- LINK --] must be in the [-- LOOP Links --] section so that is why you are getting the error.

The Link itself comes from the [-- DEFINE LINK_TO_PAGE --] section of the page template so you might be able to put your code
Code: Select all
<li class="inline"><a href="[-- PAGE.fieldx --]"</a></li>

in that section and have it work.
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Postby Feydakin » Wed Jan 21, 2009 8:37 pm

AWESOME!!!!!

That was exactly what I needed to do and now it makes sense.. Thank you very much..

I learned a lot on my first shopsite store.. Learning more on my second shopsite store.. By the time I finished the rest of the stores I'll be a master :)

Thanks a lot Jim..
Feydakin
 
Posts: 42
Joined: Wed Jul 23, 2008 11:24 am
Location: Indiana

Postby Feydakin » Wed Jan 21, 2009 9:36 pm

Aw bugger - so close :)

ok - here is what I am doing -

http://animalcharms.net/index.php

The link at the bottom left (wild animal jewelry) takes you to http://wildanimaljewelry.animalcharms.net/ like it is supposed to.. Now I need to find out where to modify the template so that the products themselves do the same thing..

http://www.animalcharms.net/wildanimalj ... endant.php

should go to

http://wildanimaljewelry.animalcharms.n ... endant.php in a perfect world..

I'm assuming that it's all located in the

Code: Select all
   
[-- LOOP PRODUCTS PAGE.Columns --]
      <td valign="top" align="[-- VAR.align --]">[-- PRODUCT --]</td>
[-- END_LOOP PRODUCTS --]


part of the page template.. But I'm still looking for where PRODUCT is defined.. But it may all be impossible since there is no extra page field on the products page unless I can do the same thing with the extra product field which makes sense t- me..

I'm also working on putting the entire link loop left nav on the individual product pages because I really hate "back" links on web pages.. But I'm just starting on trying to figure that out..
Feydakin
 
Posts: 42
Joined: Wed Jul 23, 2008 11:24 am
Location: Indiana

Postby Jim » Wed Jan 21, 2009 10:12 pm

The [-- PRODUCT --] comes from the product template that is assigned to the product. It would be the part in the [-- define product --] section. The product template also contains a section that defines what the product looks like as a subproduct to other products and what the product's more information page look like.

I still don't know what you are trying to do. But products are assigned to the pages that they will appear on. You can use the extra product fields to contain information that you could use for doing selective placement of products but you can't specify that a product will be on a page by using the extra product fields.
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Postby Feydakin » Wed Jan 21, 2009 10:20 pm

I'm trying to break the site up in to subdomains rather than subdirectories..

Yes, it's an awful lot of extra work for the minor benefits that it gives, but I'm also using this as an excuse to get a much better understanding of the software in general..

Off to see what else I can break yet tonight..
Feydakin
 
Posts: 42
Joined: Wed Jul 23, 2008 11:24 am
Location: Indiana


Return to User Forum

Who is online

Users browsing this forum: No registered users and 108 guests