Buongiorno a tutti.
Sto realizzando un menù per il mio sito.
il problema è questo.
Fino a tempo fa facevo così:
ora, siccome il controlla sulla singola pagina non mi basta pensavo di leggere il contenuto della cartella e far si che se un file è uguale al strpagina mi facesse vedere ugualmente il menù.codice:<% if strPagina = "home_campi.asp" then %> <li id="nav-menu-current"> <% else %>[*] <% end if %> Dati Club
quindi ho fatto:
Il problema è che adesso mette tanti pulsanti quanti sono i file.codice:strPath = "/figsp/user/GestGare/" strExt = ".asp" Set objFso = Server.createObject("Scripting.FileSystemObject") Set objFolder = objFso.GetFolder(Server.MapPath(strPath)) Set objFiles = objFolder.Files for each strFile in objFiles if Right(strFile.name, Len(strExt)) = strExt then if strPagina = strfile.name then %> <li id="nav-menu-current"> <% else %>[*] <% end if %> Gestione gare <% end if next
come faccio a far vedere un solo pulsante?
Grazie

Rispondi quotando