Re: Creating comums
This WebDNA talk-list message is from 1998
It keeps the original formatting.
numero = 17952
interpreted = N
texte =
Here is the code from one of my ownsearch results. It's the same as Ken's but perhaps having a secondexample will help. Best of luck!
Kimberly Wyrick
<table width="100%" border="0"cellspacing="0" cellpadding="1"align="Center">
<font face="Arial, Helvetica, sans-serif"size="2">
<tr>
[foundItems]
<td align="left" width="250"><ahref="types.tpl?command=search&db=store.txt&eqLocationdatarq=[url][Location][/url]&searchTitle=[url][searchTitle][/url]&eqCategorydatarq=[url][Category][/url]&Typesumm=t&Typesort=1&Typesdir=as&max=50">
<img src="images/[lookupdb=catphoto.txt&value=[url][Category][/url]&lookinfield=Category&returnfield=Photo¬found=black.gif]"border="0">
</a>
</td>
[showif [index]\2]</tr><tr>[/showif]
[/foundItems]
</tr>
</font>
</table>
At 08:16 AM 5/29/98, greg wrote:
>I'll try this again. This time without styles.
>
>Thank you for responding. I wasn't sure if my email made it to thelist.
>I fooled around with your solution and couldn't seem to make it workwith
>my template. Any further help would be appreciated.
>Here is the code I am trying to apply it to.
>
>[showif [searchTitle]=All]
><H3>All Items in the Catalog</H3>
>[/showif]
>
>[hideif [searchTitle]=All]
><H3>Your search for '[searchTitle]' found [numFound]items</H3>
>[/hideif]<P>
>
>[foundItems]
><P ALIGN="CENTER"><CENTER><TABLE BORDERCELLSPACING=1 CELLPADDING=0 WIDTH=60%>
>
><TR><TD VALIGN="CENTER" ALIGN="CCENTER"WIDTH="60%" ROWSPAN=5 HEIGHT=300>
><P>[showif [hasPhoto]=T]<img align=left
>src="/catalogimages/[PhotoName]"[/showif]</td>
>
><TD WIDTH="40%" VALIGN="TOP"HEIGHT=260>
><P>[description]</TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P>[title]</TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P>$[format .2f][price][/format]</TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P><a
>href="ShoppingCart.tpl?username=[username]&password=[password]&command=add&d
>b=catalog.txt&sku=[url][sku][/url]&cart=[cart]">Addto Cart</a></TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P><a
>href="Detail.tpl?username=[username]&password=[password]&command=search&db=c
>atalog.txt&eqskudata=[url][sku][/url]&cart=[cart]">Detail</a></TD>
></TR>
></TABLE>
>[/foundItems]
></CENTER>
>[shownext]<a
>href="EntryResults.tpl?username=[username]&password=[password]&command=searc
>h&[searchstring]">Show Items[start]-[end]<br>[/shownext]
><a
>href="ShoppingCart.tpl?username=[username]&password=[password]&command=showc
>art&db=catalog.txt&cart=[cart]">Show ShoppingCart</a><br>
><a
>href="Search.tpl?username=[username]&password=[password]&command=search&db=c
>atalog.txt&geSKUdata=0&cart=[cart]&categorysumm=t&categorysort=1">BackTo
>Search</a>
>
>At 11:45 AM 5/27/98 -1000, you wrote:
>>>Is there a way to create search results to be displayed in 2columns? For
>>>Example, if the results return 10 items I would like 2columns of 5.
>>
>>
>>This syntax does it:
>>
>><table>
>>[search]
>><tr>
>>[founditems]
>><td>[fieldName]</td> [showif[index]\2]</tr><tr>[/showif]
>>[/founditems]
>></tr>
>>[/search]
>>
>>
>>
>>Sincerely,
>>Ken Grome
>>808-737-6499
>>WebDNA Solutions
>>
mailto:ken@webdna.net>>
> >/eudora=autourl>http://www.webdna.net
>>
> Web Services Specialist
CNETech Net
Associated Messages, from the most recent to the oldest:
Here is the code from one of my ownsearch results. It's the same as Ken's but perhaps having a secondexample will help. Best of luck!
Kimberly Wyrick
<table width="100%" border="0"cellspacing="0" cellpadding="1"align="Center">
<font face="Arial, Helvetica, sans-serif"size="2">
<tr>
[founditems]
<td align="left" width="250"><ahref="types.tpl?command=search&db=store.txt&eqLocationdatarq=[url][Location][/url]&searchTitle=[url][searchTitle][/url]&eqCategorydatarq=[url][Category][/url]&Typesumm=t&Typesort=1&Typesdir=as&max=50">
<img src="images/[lookupdb=catphoto.txt&value=[url][Category][/url]&lookinfield=Category&returnfield=Photo¬found=black.gif]"border="0">
</a>
</td>
[showif [index]\2]</tr><tr>[/showif]
[/foundItems]
</tr>
</font>
</table>
At 08:16 AM 5/29/98, greg wrote:
>I'll try this again. This time without styles.
>
>Thank you for responding. I wasn't sure if my email made it to thelist.
>I fooled around with your solution and couldn't seem to make it workwith
>my template. Any further help would be appreciated.
>Here is the code I am trying to apply it to.
>
>[showif [searchTitle]=All]
><H3>All Items in the Catalog</H3>
>[/showif]
>
>[hideif [searchTitle]=All]
><H3>Your search for '[searchTitle]' found [numFound]items</H3>
>[/hideif]<P>
>
>
[founditems]><P ALIGN="CENTER"><CENTER><TABLE BORDERCELLSPACING=1 CELLPADDING=0 WIDTH=60%>
>
><TR><TD VALIGN="CENTER" ALIGN="CCENTER"WIDTH="60%" ROWSPAN=5 HEIGHT=300>
><P>[showif [hasPhoto]=T]<img align=left
>src="/catalogimages/[PhotoName]"[/showif]</td>
>
><TD WIDTH="40%" VALIGN="TOP"HEIGHT=260>
><P>[description]</TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P>[title]</TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P>$[format .2f][price][/format]</TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P><a
>href="ShoppingCart.tpl?username=
[username]&password=
[password]&command=add&d
>b=catalog.txt&sku=
[url][sku][/url]&cart=
[cart]">Addto Cart</a></TD>
></TR>
>
><TR><TD WIDTH="40%" VALIGN="TOP"HEIGHT=10>
><P><a
>href="Detail.tpl?username=
[username]&password=
[password]&command=search&db=c
>atalog.txt&eqskudata=
[url][sku][/url]&cart=
[cart]">Detail</a></TD>
></TR>
></TABLE>
>[/foundItems]
></CENTER>
>
[shownext]<a
>href="EntryResults.tpl?username=
[username]&password=
[password]&command=searc
>h&[searchstring]">Show Items[start]-[end]<br>[/shownext]
><a
>href="ShoppingCart.tpl?username=
[username]&password=
[password]&command=showc
>art&db=catalog.txt&cart=
[cart]">Show ShoppingCart</a><br>
><a
>href="Search.tpl?username=
[username]&password=
[password]&command=search&db=c
>atalog.txt&geSKUdata=0&cart=
[cart]&categorysumm=t&categorysort=1">BackTo
>Search</a>
>
>At 11:45 AM 5/27/98 -1000, you wrote:
>>>Is there a way to create search results to be displayed in 2columns? For
>>>Example, if the results return 10 items I would like 2columns of 5.
>>
>>
>>This syntax does it:
>>
>><table>
>>
[search]>><tr>
>>
[founditems]>><td>[fieldName]</td> [showif[index]\2]</tr><tr>[/showif]
>>[/founditems]
>></tr>
>>[/search]
>>
>>
>>
>>Sincerely,
>>Ken Grome
>>808-737-6499
>>WebDNA Solutions
>>
mailto:ken@webdna.net>>
> >/eudora=autourl>http://www.webdna.net
>>
> Web Services Specialist
CNETech Net
Kimberly Wyrick
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
authorizenet/webmerchant part 2 (2000)
counting characters and/or words (1997)
WebCatalog can't find database (1997)
Verbose error reporting (1998)
problem with [include] and Web*/SSL 3.0.1 (1998)
Sort Order on a page search (1997)
Document Contains No Data! (1997)
Item order (2002)
Serial Number Question (1997)
'does not contain' operator needed ... (1997)
Strange intermittent WebDNA problems (2008)
[listfiles] (1998)
Need help with emailer- 2 issues (1997)
Web Logs (1998)
$flushcache causes crash (2000)
Tax Collection for Different Items (2003)
Repost: pulldown menu (2000)
Replace Statement (1997)
[Sum] function? (1997)
Multiple Passwords (1997)