03 giugno 2005 alle 22:55:31 ciao a ttt, ho istallato questo mod ma mi sembra che non funzioni come dovrebbe. e mi sembra di ave capito che devo inserire delle categorie con un database!? chi puo darmi una mano
04 giugno 2005 alle 11:35:02 Il mercatino è un programma completo, con tanto di DB accluso, non è un semplice MOD, l'installazione del mercatino è abbastanza semplice, comunque vi è compreso anche un file di testo che spiega dove inserire i vari files. Il MOD successivo è quello che è stato pubblicato qui, in download, e che serve a visualizzare le ultime 5 inserzioni in home page. Ciauzz DJ
--------------- A lavare la testa ai somari, ci si rimette l'acqua e il sapone!
06 giugno 2005 alle 19:36:42 ...ok ma da dove devo inserire le categorie? un'altra cosa in amministrazione nn c'è la voce mercatino e anche.....insomma mome lo faccio funzinoare?!
--------------- http://www.sampy.it
06 giugno 2005 alle 19:48:47 La voce mercatino, in amministrazione va aggiunta amano, modificando il file CONTROLPANEL.XML. Una volta creato il link, potrai aggiungere le categorie al mercatino. Ciauzz DJ
--------------- A lavare la testa ai somari, ci si rimette l'acqua e il sapone!
06 giugno 2005 alle 20:42:55 scusami ma visto che sono un ignorante (nn sbuffare) come è il codice che devo inserire?...
...poi potresti controlare questo codice è il file "admin_allinfo-inc" mi da dei problemi nella sezione amministrazione
<% ' ************************************************************************ ' * ASPNUKE: Free web portal in ASP * ' ************************************************************************ ' * ASP-Nuke 2.0 Copyright (c) 2004 by Aspnuke.it Staff * ' * (staff@aspnuke.it) http://www.aspnuke.it * ' * * ' * Re-design by Enrico Musante (c) 2004 (emu@libero.it) * ' * Re-design by Frank Zalabard (c) 2004 (fsarzana@hotmail.com) * ' * Re-Design by Emanuele Libertini (c) 2004 (infoz@searchwarezz.net) * ' * * ' * ASP-Nuke 1.0, 1.1, 1.2 Copyright (c) 2002-2003 by Gaetan Bouveret * ' * (webmaster@asp-nuke.com) http://www.asp-nuke.com * ' * * ' * This program is free software. You can redistribute it and/or modify * ' * it under the terms of the GNU General Public License as published by * ' * the Free Software Foundation; either version 2 of the License, or * ' * (at your option) any later version. * ' * * ' ************************************************************************ %> <% ' Gives information since the last visit Sub AllInfo() Dim oCn, oCn1, oRs, oRs1, rSQL, rSQL1, iLine, sTemp
If GLOBAL_NEWS_TOP > 0 Then ' Last news rSQL = "SELECT nID, nTitle, nAuthor, nDate FROM news where nValid=1 AND nDate > '" & sLastVisit & "' ORDER BY nDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If
oRs.Close Set oRs = Nothing
' Last comments rSQL = "SELECT cID, cAuthor, cRate, cType, cText FROM comments where cValid=1 AND cDate > '" & sLastVisit & "' ORDER BY cDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = 1 iLoop = 0 While Not oRs.EOF And iLoop < 10 sTemp = oRs("cText") Response.Write " <tr class=""tableline" & iLine & """>" & vbCRLF Response.Write " <td>" If oRs("cAuthor") = "" Then Response.Write GetTranslation("LANG_ANONYM") Else Response.Write Server.HTMLEncode(oRs("cAuthor")) End If Response.Write "</td>" & vbCRLF Response.Write " <td><a href=""" & GLOBAL_SITE_ADMIN_PATH & GLOBAL_SITE_COMMENTS_PAGE & "?do=view&id=" & oRs("cID") & """>" & CodeMessageEx(sTemp, 40, True, True) & "</a></td>" & vbCRLF Response.Write " <td align=""center"">" Select Case oRs("cType") Case CATEGORY_TYPE_NEWS Response.Write GetTranslation("LANG_NEWS") Case CATEGORY_TYPE_DOWNLOADS Response.Write GetTranslation("LANG_DOWNLOADS") Case CATEGORY_TYPE_DIRECTORY Response.Write GetTranslation("LANG_DIRECTORY") Case CATEGORY_TYPE_IMAGES Response.Write GetTranslation("LANG_IMAGES") Case CATEGORY_TYPE_ARTICLES Response.Write GetTranslation("LANG_ARTICLES") Case Else Response.Write "-" End Select Response.Write "</td>" & vbCRLF Response.Write " <td align=""center""><img src=""" & GLOBAL_SITE_IMAGES_PATH & "rate_" & oRs("cRate") & ".gif"" border=""0""></td>" & vbCRLF Response.Write " </tr>" & vbCRLF
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If oRs.Close Set oRs = Nothing
End If
If GLOBAL_ARTICLES_TOP > 0 Then ' Last articles rSQL = "SELECT arID, arTitle, arAuthor, arDate FROM articles where arValid=1 AND arDate > '" & sLastVisit & "' ORDER BY arDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If oRs.Close Set oRs = Nothing End If
If GLOBAL_DOWNLOADS_TOP > 0 Then ' Last downloads rSQL = "SELECT dID, dTitle, dHits, cTitle, vCode FROM downloads, categories, versions where dCategory=cID AND dVersion=vID AND dValid=1 AND dDate > '" & sLastVisit & "' ORDER BY dDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If oRs.Close Set oRs = Nothing End If
If GLOBAL_DIRECTORY_TOP > 0 Then ' Last websites in directory rSQL = "SELECT dID, dTitle, dURL, dValid, dCategory, vCode, cTitle FROM directory, versions, categories WHERE dCategory=cID AND dVersion=vID AND dValid=1 AND dDate > '" & sLastVisit & "' ORDER BY dDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If oRs.Close Set oRs = Nothing
' Invalid websites in directory rSQL = "SELECT dID, dTitle, dURL, dValid, dCategory, vCode, cTitle FROM directory, versions, categories WHERE dCategory=cID AND dVersion=vID AND dValid=0 ORDER BY dDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If oRs.Close Set oRs = Nothing End If
If GLOBAL_IMAGES_TOP > 0 Then ' Last images rSQL = "SELECT iID, iTitle, iHits, cTitle, vCode FROM images, categories, versions where iCategory=cID AND iVersion=vID AND iValid=1 AND iDate > '" & sLastVisit & "' ORDER BY iDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If oRs.Close Set oRs = Nothing End If
If GLOBAL_POLLS_TOP > 0 Then ' Last polls rSQL = "SELECT pID, pDateBegin, pDateEnd, pTitle FROM polls where pValid=1 AND pDateBegin > '" & sLastVisit & "' AND pValid=1 ORDER BY pDateBegin DESC, pDateEnd DESC" Set oRs = DBRecordSet(oCn, rSQL)
iLine = ((iLine - 1) XOr 1) + 1 oRs.MoveNext iLoop = iLoop + 1 Wend Response.Write "</table>" & vbCRLF CreateBottomTable "" End If oRs.Close Set oRs = Nothing End If
' Last accounts rSQL = "SELECT uLogin, uEMail, uURL, rTitle FROM users, roles where uRole=rID AND uDate > '" & sLastVisit & "' AND uValid=1 ORDER BY uDate DESC" Set oRs = DBRecordSet(oCn, rSQL)
if bUseForum then 'Last posts in Forum Set oCn = DBConnexion(DB_FORUM) rSql = "SELECT PostID, PostParent, PostUser, PostDate, PostTitle, PostMessage, PostSection, PostSmileys, SectionForum, SectionName, ForumName FROM posts, sections, forums WHERE PostSection=SectionID AND PostValid=1 AND SectionForum=ForumID AND NOT (ForumLevel > 1 OR SectionLevel > 1) AND PostDate > '" & sLastVisit & "' ORDER BY PostDate DESC" Set oRs = DBRecordSet(oCn, rSQL) If Not oRs.EOF Then CreateTopTable "TopPosts_valid", GetTranslation("LANG_FORUM") iLine = 1 Response.Write GLOBAL_SITE_SUBTABLE & vbCRLF While Not oRs.EOF bSmileys = oRs("PostSmileys").Value Response.Write " <tr class=""tableline" & iLine & """>" & vbCRLF Response.Write " <td align=""left"" valign=""top"" width=""20%""><a href=""" & GLOBAL_SITE_FORUM_PATH & GLOBAL_SITE_FORUM_PAGE & "?forum=" & oRs("SectionForum") & "§ion=" & oRs("PostSection") & "&post=" & oRs("PostParent") & "&page=last"">" & CodeMessageEx(oRs("PostTitle"), 0, True, bSmileys) & "</a></td>" & vbCRLF Response.Write " <td>" & vbCRLF Response.Write " <b>" & Server.HTMLEncode(oRs("ForumName")) & "</b> - <span class=""small"">" & Server.HTMLEncode(oRs("SectionName")) & "</span><br>" & vbCRLF Response.Write " <b>" & Server.HTMLEncode(oRs("PostUser")) & "</b> - <span class=""small"">" & GetDateDDMMYYHHMMSS(StringToDate(oRs("PostDate"))) & "</span><br><br>" & vbCRLF Response.Write " " & CodeMessageEx(oRs("PostMessage"), 0, True, bSmileys) & vbCRLF Response.Write " </tr>" & vbCRLF
iLine = 1 + ((iLine-1) XOR 1) oRs.MoveNext WEnd Response.Write "</table>" & vbCRLF CreateBottomTable "" End If
'Unpublished posts Set oCn = DBConnexion(DB_FORUM) rSql = "SELECT PostID, PostParent, PostUser, PostDate, PostTitle, PostMessage, PostSection, PostSmileys, SectionForum, SectionName, ForumName FROM posts, sections, forums WHERE PostSection=SectionID AND PostValid=0 AND SectionForum=ForumID AND NOT (ForumLevel > 1 OR SectionLevel > 1) ORDER BY PostDate DESC" Set oRs = DBRecordSet(oCn, rSQL) If Not oRs.EOF Then CreateTopTable "TopPosts_invalid", GetTranslation("LANG_FORUM") & " - " & GetTranslation("LANG_TO_VALIDATE") iLine = 1 Response.Write GLOBAL_SITE_SUBTABLE & vbCRLF While Not oRs.EOF bSmileys = oRs("PostSmileys").Value Response.Write " <tr class=""tableline" & iLine & """>" & vbCRLF Response.Write " <td align=""left"" valign=""top"" width=""20%""><a href=""" & GLOBAL_SITE_FORUM_PATH & GLOBAL_SITE_FORUM_PAGE & "?forum=" & oRs("SectionForum") & "§ion=" & oRs("PostSection") & "&post=" & oRs("PostParent") & "&page=last"">" & CodeMessageEx(oRs("PostTitle"), 0, True, bSmileys) & "</a></td>" & vbCRLF Response.Write " <td>" & vbCRLF Response.Write " <b>" & Server.HTMLEncode(oRs("ForumName")) & "</b> - <span class=""small"">" & Server.HTMLEncode(oRs("SectionName")) & "</span><br>" & vbCRLF Response.Write " <b>" & Server.HTMLEncode(oRs("PostUser")) & "</b> - <span class=""small"">" & GetDateDDMMYYHHMMSS(StringToDate(oRs("PostDate"))) & "</span><br><br>" & vbCRLF Response.Write " " & CodeMessageEx(oRs("PostMessage"), 0, True, bSmileys) & vbCRLF Response.Write " </tr>" & vbCRLF
iLine = 1 + ((iLine-1) XOR 1) oRs.MoveNext WEnd Response.Write "</table>" & vbCRLF CreateBottomTable "" End If
' Mercatino - Articoli da validare rSQL1 = "SELECT COUNT(id) as t FROM mercatino_annuncio WHERE valido=False" Set oRs1 = DBRecordSet (oCn1, rSQL1)
CreateTopTable "Mercatino", "Mercatino - Articoli da verificare" Response.Write " <tr class=""tableline1"">" & vbCRLF If oRs1("t").Value >=1 then Response.Write "<td align=""left""><b>"&iif(oRs1("t").Value=1,"E' presente "&oRs1("t").Value&" annuncio da verificare","Sono presenti "&oRs1("t").Value&" annunci da verificare")&" - <a href="""&GLOBAL_SITE_URL & GLOBAL_SITE_PATH&"admin/mercatino.asp"" title=""Verifica gli annunci presenti"">VERIFICALI ADESSO !</a></b></td>" & vbCRLF Else Response.Write "<td align=""left""><b>Tutti gli annunci sono già stati verificati !</b></td>" & vbCRLF End If Response.Write " </tr>" & vbCRLF CreateBottomTable ""
oCn1.Close Set oCn1 = Nothing Set oRs1 = Nothing
oRs.Close Set oRs = Nothing oCn.Close Set oCn = Nothing End If
'here we could test last guestbook and forum entries End Sub %>
06 giugno 2005 alle 20:45:23 si lo so sono un rompi balle ed il codice è un tantino lunghetto ma le mie modifiche sono alla fine --------------- http://www.sampy.it
06 giugno 2005 alle 20:52:19 Il codice per il link te lo posso tranquillamente inserire: <element> <text>Mercatino</text> <link type="instruction">GLOBAL_SITE_ADMIN_PATH & "mercatino.asp"</link> <target></target> <bullet></bullet> <role type="instruction">ROLE_ADMINISTRATOR</role> <flag></flag> </element> ma per la modifica non saprei che dirti, mi sembra che non ti sia attenuto al file originale, che prevede la visualizzazione degli annunci subito, all'apertura della pagina di amministrazione. Ciauzz DJ
--------------- A lavare la testa ai somari, ci si rimette l'acqua e il sapone!
06 giugno 2005 alle 22:37:36 ok ok ok grazie di ttt. ora visto che sto impazzendo ed il mio socio nn è contento se impazzisco non è che potresti farmelo tu il codice di admin_allinfo-inc per il mercatino ho assolutamente bisogno del tuo aiuto!!!!
--------------- http://www.sampy.it
Sampy Utente
99 Discussioni
07 giugno 2005 alle 19:12:16 dai dj nn fare cosi aiutami tu ci metti 5 sec. io nn ho capito dove va inserito lo script!!! :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( :~( --------------- http://www.sampy.it
07 giugno 2005 alle 19:44:27 A parte gli scherzi, nel file TXT accluso al mercatino.zip V2.0.4a, vi sono tutte le spiegazioni per l'implementazione del programma, compreso la modifica al file admin_allinfo-inc.asp, la modifica va inserita all'inizio del file, seguendo le istruzioni, non capisco perchè tu abbia inserito altro. Se leggi attentamente il file TXT, ti accorgerai che è veramente semplice. Ora, prendi il file admin_allinfo-inc.asp dallo zip originale e, esegui le modifiche, poi, trasferiscilo via FTP nel tuo portale. Tutti gli utenti che hanno installato il mercatino ci sono riusciti, perchè tu non dovresti? Ciauzz Dj
--------------- A lavare la testa ai somari, ci si rimette l'acqua e il sapone!