Adobe Extending Dreamweaver CS4 Manual de usuario Pagina 349

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 387
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 348
343
EXTENDING DREAMWEAVER CS4
Data translators
}else{
imageRef = "images/kent_hardAtWorkOnWin.jpg";
}
}else{
imageRef = "images/kent_sleeping.jpg";
}
//If it's after midnight and before 10am, or anytime on Sunday
}else{
imageRef = "images/kent_sleeping.jpg";
}
return imageRef;
}
</script>
</head>
<body>
</body>
</html>
3 Save the file as kent.htm in the Configuration/Translators folder.
The data translator API functions
This section describes the functions used to define translators for Dreamweaver.
getTranslatorInfo()
Description
This function provides information about the translator and the files it can affect.
Arguments
None.
Returns
An array of strings. The elements of the array must appear in the following order:
1 The translatorClass string uniquely identifies the translator. This string must begin with a letter and can contain
only alphanumeric characters, hyphens (-), and underscores (_).
2 The title string describes the translator in no more than 40 characters.
3 The nExtensions string specifies the number of file extensions to follow. If nExtensions is zero, the translator can
run on any file. If nExtensions is zero, nRegExps is the next element in the array.
4 The extension string specifies a file extension (for example, "htm" or "SHTML") that works with this translator. This
string is not case-sensitive and should not contain a leading period. The array should contain the same number of
extension elements that are specified in nExtensions.
5 The nRegExps string specifies the number of regular expressions that follow. If nRegExps is zero, runDefault is the
next element in the array.
Vista de pagina 348
1 2 ... 344 345 346 347 348 349 350 351 352 353 354 ... 386 387

Comentarios a estos manuales

Sin comentarios