Home : Products : Gossamer Links : Development, Plugins and Globals :

Products: Gossamer Links: Development, Plugins and Globals: Re: [Westin] What's the best way to customize the detailed template to do...: Edit Log

Here is the list of edits for this post
Re: [Westin] What's the best way to customize the detailed template to do...
Ok it may not be elegant, but I just quickly thought of a way to do this and did it.

In my include_form.html template I added a hidden text tag that tells the database that it is to assign the field named templateID the value of 75
I added an extra column to the links properties database named templateID

Then on any page where I need to have text localized for templateID 75, I can use the following code:


Code:
<%if templateID == 75%>
New CAT 75 CONTENT HERE
<%else%>
ALL OTHER
<%endif%>


Doing it this way, I can assign any templateID number that I want dependant on which form the person is submitting by simply adding the hidden text html form field code:
Code:
<input type="hidden" id="templateID" name="templateID" value="75" class="text">


So If I add a third form to run on the include_form.html template, then I might change the value above from 75 to maybe 185 or some other meaningful number to me. That way when it's time to customize the detailed pages I can do so working off of the templateID field in the database and the numbers that it might contain.

Last edited by:

Westin: Apr 28, 2009, 3:48 AM

Edit Log: