Re: The max=0 issue is NOT a bug ...

This WebDNA talk-list message is from

2000


It keeps the original formatting.
numero = 29288
interpreted = N
texte = Ken - I am having a real hard time replicating any of your results. I tried taking a page with a simple search context and adding [text]max=9[/text] before the search and Max = [max] inside the context and I always get what I expected Max = 9. I even tried adding a &Max to the [search] context itself, and it altered how many records were retrieved by the search, but the displayed text variable still came out Max = 9. I do not know what you are doing. Please include complete code rather than snippets. Were you using a search command and not a context?I cannot even find max listed as a variable inside the search context, just as a parameter. You may note that the shownext context will not even print anything at all unless numfound > max, thus removing any need for your showif at all, if you put all of your text inside the showif.There is no question that anyone using any WebCatalog context name or parameter name as a variable name should be rapped hard on the knuckles with a metal ruler. This is a basic, beginner programming mistake. I think that WebCat 4.0 should refuse to process any page with variable assignments to reserved words, and refuse to load any database with fieldnames that are reserved words, as long as the documentation contains the list of reserved words (all in one place ;~).John Peacock ____________________Reply Separator____________________ Subject: The max=0 issue is a bug ... Author: (WebCatalog Talk) Date: 3/19/00 4:08 PMIn other words, it doesn't matter what method you use to set a [max] value in your templates, because webcatalog is going to reset that value to 0 inside your search context whether you want it to or not. And since it should not be doing this, I believe this is a bug.What's amazing to me is that no one else has uncovered this bug before now. It seems like it must be a common practice to use a showif comparison inside a search context to compare [numfound] with [max] to determine whether or not to show some leading text before the shownext code ...================================ Kenneth Grome, WebDNA Consultant 808-737-6499 http://webdna.net ================================ ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Associated Messages, from the most recent to the oldest:

    
  1. Re: The max=0 issue is NOT a bug ... (jpeacock@univpress.com 2000)
Ken - I am having a real hard time replicating any of your results. I tried taking a page with a simple search context and adding [text]max=9[/text] before the search and Max = [max] inside the context and I always get what I expected Max = 9. I even tried adding a &Max to the [search] context itself, and it altered how many records were retrieved by the search, but the displayed text variable still came out Max = 9. I do not know what you are doing. Please include complete code rather than snippets. Were you using a search command and not a context?I cannot even find max listed as a variable inside the search context, just as a parameter. You may note that the shownext context will not even print anything at all unless numfound > max, thus removing any need for your showif at all, if you put all of your text inside the showif.There is no question that anyone using any WebCatalog context name or parameter name as a variable name should be rapped hard on the knuckles with a metal ruler. This is a basic, beginner programming mistake. I think that WebCat 4.0 should refuse to process any page with variable assignments to reserved words, and refuse to load any database with fieldnames that are reserved words, as long as the documentation contains the list of reserved words (all in one place ;~).John Peacock ____________________Reply Separator____________________ Subject: The max=0 issue is a bug ... Author: (WebCatalog Talk) Date: 3/19/00 4:08 PMIn other words, it doesn't matter what method you use to set a [max] value in your templates, because webcatalog is going to reset that value to 0 inside your search context whether you want it to or not. And since it should not be doing this, I believe this is a bug.What's amazing to me is that no one else has uncovered this bug before now. It seems like it must be a common practice to use a showif comparison inside a search context to compare [numfound] with [max] to determine whether or not to show some leading text before the shownext code ...================================ Kenneth Grome, WebDNA Consultant 808-737-6499 http://webdna.net ================================ ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to jpeacock@univpress.com

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:

No luck with taxes (1997) Cobalt and WebCatalog, do they work together? (2000) cannot delete last admin (1999) Re:What file? (1997) send people in a database an email (2001) Can this be done? (1997) [WebDNA] TCPDoh (2009) need some help with a loop (1999) request for string functions (1998) Username for Admin Group (1997) Caching [include] files ... (1997) Sorting by date (1997) How did *you* learn Web Catalog? (2000) Searching multiple Databases (1997) CDATA problems (2008) webcat method for waiting specific amount of time? (2000) expired beta (1997) [WebDNA] Rewrite url (2013) Erotic Sites (1997) calculating tax rates, mail order solutions and version 2 (1997)