Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

Lisbao

Asp.net para ASP

Recommended Posts

Eu tenho uma página em aspx e gostaria passar pra asp normal...

 

atualizar_link.aspx

<%@ Page language="c#" %><script runat="server" language="c#">	public string arquivo;	public object pasta;	public string msg;	public System.IO.FileStream arq;	public System.IO.FileStream arq1;	public string pastas;</script><%	if (PHP.TypeSupport.ToBoolean(new PHP.OrderedMap(Request.Form, false)))	{		arquivo = PHP.TypeSupport.ToString((Request.Files["arquivo"] != null)?Request.Files["arquivo"].FileName:"");		pasta = Request.Form["pasta"];		msg = "<% response.redirect(\"http://www.ibcu.org.br/audio/" + PHP.TypeSupport.ToString(pasta) + "/" + arquivo + "\") %>";		if (!(System.IO.File.Exists("msg_atual.asp") || System.IO.Directory.Exists("msg_atual.asp")))		{			//CONVERSION_WARNING: Method 'fopen' was converted to 'PHP.FileSystemSupport.FileOpen' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fopen.htm 			arq = PHP.FileSystemSupport.FileOpen("msg_atual.asp", "a+");			//CONVERSION_WARNING: Method 'fputs' was converted to 'PHPFileSystemSupport.Write' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fputs.htm 			PHP.FileSystemSupport.Write(arq, msg, msg.Length);			//CONVERSION_WARNING: Method 'fclose' was converted to 'PHP.FileSystemSupport.Close' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fclose.htm 			PHP.FileSystemSupport.Close(arq);		}		else		{			//CONVERSION_WARNING: Method 'unlink' was converted to 'System.IO.File.Delete' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/unlink.htm 			System.IO.File.Delete("msg_atual.php");			//CONVERSION_WARNING: Method 'fopen' was converted to 'PHP.FileSystemSupport.FileOpen' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fopen.htm 			arq = PHP.FileSystemSupport.FileOpen("msg_atual.php", "a+");			//CONVERSION_WARNING: Method 'fputs' was converted to 'PHPFileSystemSupport.Write' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fputs.htm 			PHP.FileSystemSupport.Write(arq, msg, msg.Length);			//CONVERSION_WARNING: Method 'fclose' was converted to 'PHP.FileSystemSupport.Close' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fclose.htm 			PHP.FileSystemSupport.Close(arq);		}		PHP.MiscSupport.End("Arquivo atualizado");	}		%><html><head><title>Atualizar Arquivo</title><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"></head><body><form enctype="multipart/form-data" method="post" action="<%Response.Write(Request.Path);%>">  <font size="2" face="Verdana, Arial, Helvetica, sans-serif">Última Mensagem   do dia:</font>   <input type = "file" name = "arquivo">  <font size="2" face="Verdana, Arial, Helvetica, sans-serif">na série:</font>   <select name="pasta">	<%	if (System.IO.File.Exists("select_pasta.txt") || System.IO.Directory.Exists("select_pasta.txt"))	{		//CONVERSION_WARNING: Method 'fopen' was converted to 'PHP.FileSystemSupport.FileOpen' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fopen.htm 		arq1 = PHP.FileSystemSupport.FileOpen("select_pasta.txt", "r+");		//CONVERSION_WARNING: Method 'feof' was converted to 'System.IO.FileStream.Position' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/feof.htm 		while (!(arq1.Position >= arq1.Length))		{			//CONVERSION_WARNING: Method 'fgets' was converted to 'PHP.FileSystemSupport.ReadLine' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fgets.htm 			pastas = PHP.FileSystemSupport.ReadLine(arq1, 1024);			Response.Write(pastas);		}		//CONVERSION_WARNING: Method 'fclose' was converted to 'PHP.FileSystemSupport.Close' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fclose.htm 		PHP.FileSystemSupport.Close(arq1);	}	%>  </select>  <input name = "Enviar" type = "submit" value = "Enviar Arquivo"></form><font size="2" face="Verdana, Arial, Helvetica, sans-serif"><a href = "select_pasta.aspx">Atualizar Séries</a></font> </body></html>

e select_pasta.aspx

<%@ Page language="c#" %><script runat="server" language="c#">	public string msg;	public System.IO.FileStream arq;</script><%Response.Write("<?xml version=\"1.0\" encoding=\"iso-8859-1\"?" + ">");%><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><%	if (PHP.TypeSupport.ToBoolean(new PHP.OrderedMap(Request.Form, false)))	{		//CONVERSION_WARNING: Method 'isset' was converted to '!=' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/isset.htm 		if (Request.Form["nova_pasta"] != null)		{			msg = "<option value = \"" + PHP.TypeSupport.ToString(Request.Form["nova_pasta"]) + "\">" + PHP.TypeSupport.ToString(Request.Form["nova_pasta"]) + "</option>";			//CONVERSION_WARNING: Method 'fopen' was converted to 'PHP.FileSystemSupport.FileOpen' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fopen.htm 			arq = PHP.FileSystemSupport.FileOpen("select_pasta.txt", "a+");			//CONVERSION_WARNING: Method 'fputs' was converted to 'PHPFileSystemSupport.Write' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fputs.htm 			PHP.FileSystemSupport.Write(arq, msg + "\r\n", msg.Length + 4);			//CONVERSION_WARNING: Method 'fclose' was converted to 'PHP.FileSystemSupport.Close' which has a different behavior. Copy this link in your browser for more info: ms-its:C:\phpconverter\PHPToAspNet.chm::/fclose.htm 			PHP.FileSystemSupport.Close(arq);		}		Response.Write("<a href =" + PHP.TypeSupport.ToString(Request.Path) + ">Atualizar Novamente</a>");		PHP.MiscSupport.End("<br>Arquivo atualizado");	}	%><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Mandar Pasta</title><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /></head><body><form action="<%Response.Write(Request.Path);%>" method="post">  <font size="2" face="Verdana, Arial, Helvetica, sans-serif">Digite o nome da nova pasta   criada: </font>   <input name = "nova_pasta" type = "text" id = "nova_pasta" />  <input name = "" type = "submit" value = "Mandar Pasta" /></form></body></html>

tem como converter essas páginas em páginas asp normal?

 

obrigado....

Compartilhar este post


Link para o post
Compartilhar em outros sites

kra isso é aspx o PHP é um objeto... e eu disse o que eu queria sim.... mas não houve respostas... sei que não é culpa de ninguém isso, eu peguei o phpconvert da microsoft e retornou esse código... tipo eu nao sei asp e mto menos asp.net....por isso peço ajuda....o que esse script faz........o atualizar_link.aspx faz...a pessoa digita o nome do arquivo e seleciona a pasta no campo selectdaí o script em asp faz uma nova página, ou seja cria uma nova página, com o comando em asp de redirecionar para a página e a pasta onde está o arquivo que foi digitado no começo....o nome da nova página é msg_atual.asp, onde contém o código <% response.redirect("http://www.ibcu.org.br/audio/(pasta que foi selecionada)/(nome do arquivo)") %>entendeu?

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.