Jump to content

Script para mostrar a data e hora da ultima alteração de um ficheiro


Recommended Posts

Posted

ora bem eu nao domino muito o javascript, mas acho que podes fazer qualquer coisa do genero

<SCRIPT LANGUAGE="JavaScript">
   document.write(document.lastModified[3]);
           document.write(document.lastModified[4]);
           document.write(document.lastModified[2]);
           document.write(document.lastModified[0]);
           document.write(document.lastModified[1]);
           document.write(document.lastModified[5]);
           document.write(document.lastModified[6]);
           document.write(document.lastModified[7]);
</SCRIPT>
Posted

um "upgrade" do Pedantilva

<SCRIPT LANGUAGE="JavaScript">
var data_i = new Date (document.lastModified);
var data_f = "Última Actualização a: ";
data_f += data_i.getDate();
data_f += "-"; 
data_f += data_i.getMonth() + 1;
data_f += "-"; 
data_f += data_i.getFullYear();
document.write(data_f);
<SCRIPT>
Posted

ora bem eu nao domino muito o javascript, mas acho que podes fazer qualquer coisa do genero

<SCRIPT LANGUAGE="JavaScript">
   document.write(document.lastModified[3]);
           document.write(document.lastModified[4]);
           document.write(document.lastModified[2]);
           document.write(document.lastModified[0]);
           document.write(document.lastModified[1]);
           document.write(document.lastModified[5]);
           document.write(document.lastModified[6]);
           document.write(document.lastModified[7]);
</SCRIPT>

nao sei pq mas tentei usar o teu e nao deu resultado nenhum...  👍

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.