15000 tutorials per photoshop

Ottima raccolta di tutorials su good-tutorials.com divisi per categorie.
Sito web: http://www.good-tutorials.com/

Ottima raccolta di tutorials su good-tutorials.com divisi per categorie.
Sito web: http://www.good-tutorials.com/

Ottimo sito dove poter trovare interessanti tutorial avanazati su programmazione web.
Sito web: http://nettuts.com/
<%
function RTESafe(strText)
'returns safe code for preloading in the RTE
dim tmpString
tmpString = trim(strText)
'convert all types of single quotes
tmpString = replace(tmpString, chr(145), chr(39))
tmpString = replace(tmpString, chr(146), chr(39))
tmpString = replace(tmpString, "'", "'")
'convert all types of double quotes
tmpString = replace(tmpString, chr(147), chr(34))
tmpString = replace(tmpString, chr(148), chr(34))
tmpString = replace(tmpString, """", "\""")
'replace carriage returns & line feeds
tmpString = replace(tmpString, chr(10), " ")
tmpString = replace(tmpString, chr(13), " ")
RTESafe = tmpString
end function
%>
| 'videoform.asp
<form method="POST" action="getrealurl.asp"> <p> </p> |
| <% 'getrealurl.asp Updated as of June 29, 2007. <% '---check referring form page Dim strDuh 'declaring the variable, a good habit Dim sMyArray(4)'what we name our array and how many items in it For Each i In sMyArray 'i can be any designation for the items in the array like z or bugguts or whatever 'now we need to set up a Case with with to compare our querystring to the items in the array Case YES if i = strDuh then end if Next If Cal = "YES" then response.write"" If NOT Cal = "YES" then 'replace following urls with your form page url '---end check referring form page if request.form("v") = "" then <% dim vidID Server.ScriptTimeout = 240 Set HttpObj = Server.CreateObject("AspHTTP.Conn") HttpObj.Url = "http://www.youtube.com/v/" & vidID HttpObj.FollowRedirects = true HttpObj.RequestMethod = "GET" HttpObj.UserAgent = "Mozilla/2.0 (compatible; MSIE 3.0B; Windows NT)" strResult = HttpObj.GetURL %> InitialString = curURL Set RegularExpressionObject = New RegExp With RegularExpressionObject ReplacedString = RegularExpressionObject.Replace(InitialString, "http://www.youtube.com/get_video") Set RegularExpressionObject = nothing Set HttpObj = Server.CreateObject("AspHTTP.Conn") HttpObj.Url = ReplacedString HttpObj.FollowRedirects = true HttpObj.RequestMethod = "GET" HttpObj.UserAgent = "Mozilla/2.0 (compatible; MSIE 3.0B; Windows NT)" strResult = HttpObj.GetURL nextURL = HttpObj.Url %> Set HttpObj = Server.CreateObject("AspHTTP.Conn") HttpObj.Url = nextURL HttpObj.FollowRedirects = true HttpObj.RequestMethod = "GET" HttpObj.UserAgent = "Mozilla/2.0 (compatible; MSIE 3.0B; Windows NT)" strResult = HttpObj.GetURL fnlURL = HttpObj.Url %> <% Set RegularExpressionObject = New RegExp With RegularExpressionObject MyRep = "get_video_" & vidID & ".flv" ReplacedString = RegularExpressionObject.Replace(InitialString, MyRep) Set RegularExpressionObject = nothing %> <html> <head> </head> <body style="font-family: Verdana"> <a href="savetosite.asp?vid=<%=vid%>&file=<% response.write ReplacedString %>">Click to save to server.</a><br> |
| savetosite.asp - OPTIONAL, allows the files to be saved directly to your website
<%@ Language=VBScript %> 'change folders and urls to your own ' Create Work Object ' Get the file objBinaryStream.Open Set objXMLHTTP = Nothing Response.write(vbNewLine) %> |
Questo tutorial spiega come aggiungere contenuti dinamici da un feed 2.0. RSS è un formato XML per mostrare nuovi contenuti, update di siti web eblogs.
Il formato RSS 2.0
RSS 2.0 è semplicemente un file xml.In un fedd RSS,<item> viene ripetuto per ciascuna news. Il seguente è un esempio di feed rss. vedi Resources per le specifiche complete.
<rss version="2.0">
<channel>
<title>channel title</title>
<link>link to channel</link>
<description>description</description>
<language>en-us</language>
<item>
<title>item title</title>
<link>link url</link>
<guid>unique id</guid>
<description>item description</description>
</item>
</channel>
</rss>
Leggi l'articolo completo: http://www.codebeach.com/tutorials/displaying-rss-feeds-using-asp.asp
In questo articolo vedremo come mostrare i nostri feed rss leggendo i dati dal db. Un feed rss è un file xml che ha dei tag particolari. Un feed rss è un qualcosa del tipo:
Un nuovo file rss deve iniziare con
<rss version=”0.92″>
che specifica la versione del file rss in uso. Tutte le informazioni che metteremo nel nostro file rss devono essere
racchiuse tra i tag :
<channel>
…
</channel>
Poi dobbiamo mettere un blocco di tag che identificano la provenienza delle informazioni
- <title></title> indica il titolo del documento rss
- <description></description> indica la descrizione
- <link></link> indica il sito di provenienza
- <language></language> indica la lingua
- <copyright></copyright> indica il copyright
- <managingEditor></managingEditor> indica il responsabile delle informazioni
e poi mettere le singole informazioni/notizie tra i tag. Infatti ogni nuova notizia deve iniziare tra i tag
<item>
…
</item>
Per maggiori info, potete leggere http://www.sastgroup.com/tutorials/cosa-e-un-feed-rss.
Per leggere un feed rss è necessario istanziare un oggetto del tipo MSXML2.DOMDocument . questo oggetto ti permette di accedere a questi file XML tramite DOM (Document Object Model). Ad esempio per leggere un file RSS feed con l'oggetto XML DOM:
Set xmlDOM = Server.CreateObject("MSXML2.DOMDocument")
xmlDOM.async = False
xmlDOM.setProperty "ServerHTTPRequest", True
xmlDOM.Load("file_export.asp")
Fatto ciò realizziamo il nostro file asp
'prende tutti gli <item> tags nel feed
Set itemList = xmlDOM.getElementsByTagName("item")
strHTML = strHTML & "<ul>"
'esegui una iteraione
For Each item In itemList
'Parsa i figli
For each child in item.childNodes
Select case lcase(child.nodeName)
case "title"
title = child.text
case "link"
link = child.text
case "description"
description = child.text
End Select
Next
'costruisci l'output xml
strHTML = strHTML & "<li>"
strHTML = strHTML & "<a href='" & Server.HTMLEncode(link) & "'>"
strHTML = strHTML & Server.HTMLEncode(title) strHTML = strHTML & "</a>"
strHTML = strHTML & "<br>"
strHTML = strHTML & description
strHTML = strHTML & "<br> "
strHTML = strHTML & "</li>"
Next
strHTML = strHTML & "</ul>"
Set xmlDOM = Nothing
Set itemList = Nothing
Response.Write(strHTML)
<%
If Response.IsClientConnected=true then
Response.Write(”Utente connesso!”)
else
Response.Write(”Utente non connesso”)
end if
%>
Per creare un file excel con asp è necessario settare l'header corretto e in poche parole stampare a video una tabella
<%
Response.AddHeader "Content-Disposition", "attachment;filename=doc.xls"
Response.ContentType = "application/vnd.ms-excel"
response.write "<table width="100%" border="1" >"
response.write "<tr>"
response.write "<th width=""40%""><b>Nome</b></th>"
response.write "<th width=""30%""><b>Cognome</b></th>"
response.write "<th width=""30%""><b>Eta</b></th>"
response.write "</tr>"
response.write "<tr>"
response.write "<td width=""40%"">tizio</td>"
response.write "<td width=""30%"">caio</td>"
response.write "<td width=""30%"">23</td>"
response.write "</tr>"
response.write "</table>"
%>
<%
Response.ContentType = "application/msword"
Response.AddHeader "Content-Disposition", "attachment;filename=nomefile.doc"
response.Write("ciao a tutti che bello questo tutorial lo puoi vedere da <a href="http://www.sastgroup.com">sastgroup.com</a> " & vbnewline)
response.Write("<b>Posso usare codice html</b>")
response.Write ("<div style=""padding:6px; font:12px verdana"">e codice css</span>")
%>