bonjour,
volià mon probléme je suis nul en asp .est depuis 2 jours je cherche la solution pour ce probléme .
j utilise un annuaire du nom de aspWebLinks jusqu a là pas de probléme.
La base contient une table categorie / sous categorie
une table skin ( qui permet de modifié le style )
mon probléme est le suivant pour chaque catégorie j ai crée un style different ( dans la table skin )
mais voila je n arrive pas à lié la catégorie avec le skin
j ennvoie une partie du code qui à mon avis doit contenir la solution .
Aidez moi svp ou ma femme divorce .....
code :
SQL = "SELECT * FROM Skins WHERE SkinName='" & SkinName & "'"
Set RS=dbc.execute(SQL)
LinkTableTag = RS("LinkTableTag")
LinkHeaderBackColor = RS("LinkHeaderBackColor")
LinkHeaderFontTag = RS("LinkHeaderFontTag")
LinkHeaderButtonsFontTag = RS("LinkHeaderButtonsFontTag")
DescriptionTableTag = RS("DescriptionTableTag")
DescriptionFontTag = RS("DescriptionFontTag")
LinkFooterBackColor = RS("LinkFooterBackColor")
LinkFooterFontTag = RS("LinkFooterFontTag")
RS.Close
Set RS=Nothing
%>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function Start(page) {
OpenWin = this.open(page, "CtrlWindow", "toolbar=yes,menubar=yes,location=yes,scrollbars=yes,resizable=yes");
}
// End -->
</SCRIPT>
<%
response.write PageHeader
'****************************************************************************
'* Subroutines
'*
'* These routines are used by other parts of the script.
'****************************************************************************
'**************************************************************************
'******** Count Links
'**************************************************************************
Function CountLinks (Category)
SQLd = "Select Count(*) From Links Where CategoryID = " & Category & " AND Live=1"
Set RSd=dbc.execute(SQLd)
RSd.MoveFirst
NumberLinks = RSd(0)
SQLe = "Select * From Categories Where ParentCategoryID = " & Category
Set RSe=dbc.execute(SQLe)
If Not RSe.EOF then
RSe.MoveFirst
Do While Not RSe.EOF
NumberLinks = NumberLinks + CountLinks(RSe("CategoryID"))
RSe.MoveNext
Loop
SQLe = "Select * From description Where ParentCategoryID = " & Category
Set RSe=dbc.execute(SQLe)
End If
CountLinks = NumberLinks
RSe.Close
Set RSe=Nothing
End Function