I need help. My server is bogging down with the =followingcode as it is run a few hundreds times on the same page. Is there anyone =outthere that can help me increase the efficiency of =this?
[text]thumb=3Dt[/text]
[listfiles =path=3Dpics&name=3D[sku]A.jpg&exact=3Dt]
[showif =[filename]!][text]thumb=3Df[/text][/showif]
[/listfiles]
= &=nbsp; &n=bsp; &nb=sp; &nbs=p;  =; = &=nbsp;
[showif [thumb]=3Dt]<imagesrc=3D"pics/ForSaleSignA.jpg" =border=3D"0">[/showif]
[showif [thumb]=3Df]<image =src=3D"pics/[sku]A.jpg"border=3D"0">[/showif]
Basically I am looking in the pics folder to see if a =photoexists and if it does then display the photo, if it does not then =display ageneric placeholder photo. Maybe an if/then would be faster? Is there =anystatistics on how quick an if/then is compared to showif and =hideif?
Thanks in advance for all =help.
Michael A. DeLorenzo
Broker - Associate
General Manager
Olde Carriage Realty, =Inc.
Office: 904-824-4500
Toll-Free: =1-800-555-6138
Fax: 904-824-6866
|
I need help. My server is bogging down with the =followingcode as it is run a few hundreds times on the same page. Is there anyone =outthere that can help me increase the efficiency of =this?
[text]thumb=3Dt[/text]
[listfiles =path=3Dpics&name=3D[sku]A.jpg&exact=3Dt]
[showif =[filename]!][text]thumb=3Df[/text][/showif]
[/listfiles]
= &=nbsp; &n=bsp; &nb=sp; &nbs=p;  =; = &=nbsp;
[showif [thumb]=3Dt]<imagesrc=3D"pics/ForSaleSignA.jpg" =border=3D"0">[/showif]
[showif [thumb]=3Df]<image =src=3D"pics/[sku]A.jpg"border=3D"0">[/showif]
Basically I am looking in the pics folder to see if a =photoexists and if it does then display the photo, if it does not then =display ageneric placeholder photo. Maybe an if/then would be faster? Is there =anystatistics on how quick an if/then is compared to showif and =hideif?
Thanks in advance for all =help.
Michael A. DeLorenzo
Broker - Associate
General Manager
Olde Carriage Realty, =Inc.
Office: 904-824-4500
Toll-Free: =1-800-555-6138
Fax: 904-824-6866
DOWNLOAD WEBDNA NOW!
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...