Ver Mensaje Individual
  #2 (permalink)  
Antiguo 24/10/2003, 13:19
Avatar de AlZuwaga
AlZuwaga
Colaborador
 
Fecha de Ingreso: febrero-2001
Ubicación: 34.517 S, 58.500 O
Mensajes: 14.550
Antigüedad: 24 años, 2 meses
Puntos: 535
Se me ocurrió algo así. Funciona definiendo la variable URL con el ejemplo que pasaste, pero descomentando la siguiente línea debería funcionar bien en un caso real:


<%
URL = "www.graficas.amarillas.com"
'URL = request.servervariables("SERVER_NAME")

PrimerPunto = InStr(URL, ".")
SegundoPunto = InStr(PrimerPunto + 1, URL, ".")
Subdominio = Mid(URL, PrimerPunto + 1, SegundoPunto - 5)
Response.Write Subdominio
%>


Seguro es más sencillo.. pero fue lo primero que se me ocurrió ;)
__________________
...___...