Avatar settings implemented

main
Inga 🏳‍🌈 14 years ago
parent 7202e45dde
commit 2025c058f7
  1. 2
      Builder/IISMainHandler/build.txt
  2. 1
      Common/Common.csproj
  3. 1
      Common/TableManager.cs
  4. 1
      Common/actions/ChangeSet.cs
  5. 7
      Common/dataobjects/Account.cs
  6. 10
      Common/dataobjects/AccountSettings.cs
  7. 122
      Common/dataobjects/AvatarsSettings.cs
  8. 2
      Common/dataobjects/Upload.cs
  9. 15
      Common/dataobjects/User.cs
  10. 16
      IISMainHandler/HandlersFactory.cs
  11. 4
      IISMainHandler/IISMainHandler.csproj
  12. 45
      IISMainHandler/handlers/request/avatars/AddHandler.cs
  13. 35
      IISMainHandler/handlers/request/avatars/RemoveHandler.cs
  14. 39
      IISMainHandler/handlers/request/avatars/SetAsDefaultHandler.cs
  15. 37
      IISMainHandler/handlers/response/AvatarsSettingsHandler.cs
  16. 122
      templates/Full/AvatarsSettings.xslt
  17. 2
      templates/Full/UploadNew.xslt
  18. 8
      templates/Full/elems/MyHeader.xslt
  19. 48
      templates/Full/result/AvatarAdded.xslt
  20. 48
      templates/Full/result/AvatarRemoved.xslt
  21. 48
      templates/Full/result/AvatarSetted.xslt

@ -87,6 +87,7 @@
<Compile Include="Config.cs" />
<Compile Include="dataobjects\Account.cs" />
<Compile Include="dataobjects\AccountIndicator.cs" />
<Compile Include="dataobjects\AvatarsSettings.cs" />
<Compile Include="dataobjects\Board.cs" />
<Compile Include="dataobjects\Category.cs" />
<Compile Include="dataobjects\Invite.cs" />

@ -11,6 +11,7 @@ namespace FLocal.Common {
dataobjects.Account.TableSpec.instance,
dataobjects.AccountIndicator.TableSpec.instance,
dataobjects.AccountSettings.TableSpec.instance,
dataobjects.AvatarsSettings.TableSpec.instance,
dataobjects.Board.TableSpec.instance,
dataobjects.Category.TableSpec.instance,
dataobjects.Invite.TableSpec.instance,

@ -26,6 +26,7 @@ namespace FLocal.Common.actions {
dataobjects.Account.TableSpec.TABLE,
dataobjects.User.TableSpec.TABLE,
dataobjects.AccountSettings.TableSpec.TABLE,
dataobjects.AvatarsSettings.TableSpec.TABLE,
dataobjects.AccountIndicator.TableSpec.TABLE,
dataobjects.PMConversation.TableSpec.TABLE,
dataobjects.PMMessage.TableSpec.TABLE,

@ -279,6 +279,13 @@ namespace FLocal.Common.dataobjects {
{ User.TableSpec.FIELD_SHOWPOSTSTOUSERS, new ScalarFieldValue(User.ENUM_SHOWPOSTSTOUSERS_ALL) },
},
this.user.id
),
new InsertChange(
AvatarsSettings.TableSpec.instance,
new Dictionary<string,AbstractFieldValue> {
{ AvatarsSettings.TableSpec.FIELD_ACCOUNTID, new ScalarFieldValue(this.id.ToString()) },
{ AvatarsSettings.TableSpec.FIELD_AVATARS, new ScalarFieldValue(this.user.avatarId.HasValue ? this.user.avatarId.ToString() : "") },
}
)
});
}

@ -144,19 +144,21 @@ namespace FLocal.Common.dataobjects {
}
public static void Save(Account account, int postsPerPage, int threadsPerPage, int usersPerPage, int uploadsPerPage, Skin skin) {
Dictionary<string, AbstractFieldValue> data = new Dictionary<string,AbstractFieldValue> {
{ TableSpec.FIELD_ACCOUNTID, new ScalarFieldValue(account.id.ToString()) },
Dictionary<string, AbstractFieldValue> dataToUpdate = new Dictionary<string,AbstractFieldValue> {
{ TableSpec.FIELD_POSTSPERPAGE, new ScalarFieldValue(postsPerPage.ToString()) },
{ TableSpec.FIELD_THREADSPERPAGE, new ScalarFieldValue(threadsPerPage.ToString()) },
{ TableSpec.FIELD_USERSPERPAGE, new ScalarFieldValue(usersPerPage.ToString()) },
{ TableSpec.FIELD_UPLOADSPERPAGE, new ScalarFieldValue(uploadsPerPage.ToString()) },
{ TableSpec.FIELD_SKINID, new ScalarFieldValue(skin.id.ToString()) },
};
Dictionary<string, AbstractFieldValue> dataToInsert = new Dictionary<string,AbstractFieldValue>(dataToUpdate) {
{ TableSpec.FIELD_ACCOUNTID, new ScalarFieldValue(account.id.ToString()) },
};
ChangeSetUtil.ApplyChanges(
new InsertOrUpdateChange(
TableSpec.instance,
data,
data,
dataToInsert,
dataToUpdate,
new ComparisonCondition(
TableSpec.instance.getColumnSpec(TableSpec.FIELD_ACCOUNTID),
ComparisonType.EQUAL,

@ -0,0 +1,122 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using FLocal.Core;
using FLocal.Core.DB;
using FLocal.Core.DB.conditions;
using FLocal.Common.actions;
namespace FLocal.Common.dataobjects {
public class AvatarsSettings : SqlObject<AvatarsSettings> {
public class TableSpec : ISqlObjectTableSpec {
public const string TABLE = "Accounts_AvatarsSettings";
public const string FIELD_ID = "Id";
public const string FIELD_ACCOUNTID = "AccountId";
public const string FIELD_AVATARS = "Avatars";
public static readonly TableSpec instance = new TableSpec();
public string name { get { return TABLE; } }
public string idName { get { return FIELD_ID; } }
public void refreshSqlObject(int id) { Refresh(id); }
}
protected override ISqlObjectTableSpec table { get { return TableSpec.instance; } }
private int _accountId;
public int accountId {
get {
this.LoadIfNotLoaded();
return this._accountId;
}
}
public Account account {
get {
return Account.LoadById(this._accountId);
}
}
private HashSet<int> _avatarsIds;
public HashSet<int> avatarsIds {
get {
this.LoadIfNotLoaded();
return new HashSet<int>(this._avatarsIds);
}
}
public IEnumerable<Upload> avatars {
get {
return from avatarId in this.avatarsIds select Upload.LoadById(avatarId);
}
}
protected override void doFromHash(Dictionary<string, string> data) {
this._accountId = int.Parse(data[TableSpec.FIELD_ACCOUNTID]);
this._avatarsIds = new HashSet<int>(from stringId in data[TableSpec.FIELD_AVATARS].Split(',') select int.Parse(stringId));
}
private static readonly Dictionary<int, int> accountid2id = new Dictionary<int,int>();
public static AvatarsSettings LoadByAccount(Account account) {
if(!accountid2id.ContainsKey(account.id)) {
lock(accountid2id) {
if(!accountid2id.ContainsKey(account.id)) {
accountid2id[account.id] = int.Parse(
Config.instance.mainConnection.LoadIdByField(
TableSpec.instance.getColumnSpec(TableSpec.FIELD_ACCOUNTID),
account.id.ToString()
)
);
}
}
}
return AvatarsSettings.LoadById(accountid2id[account.id]);
}
private static void Save(Account account, HashSet<int> avatars) {
Dictionary<string, AbstractFieldValue> dataToUpdate = new Dictionary<string,AbstractFieldValue> {
{ TableSpec.FIELD_AVATARS, new ScalarFieldValue(avatars.Join(",")) },
};
Dictionary<string, AbstractFieldValue> dataToInsert = new Dictionary<string,AbstractFieldValue>(dataToUpdate) {
{ TableSpec.FIELD_ACCOUNTID, new ScalarFieldValue(account.id.ToString()) },
};
ChangeSetUtil.ApplyChanges(
new InsertOrUpdateChange(
TableSpec.instance,
dataToInsert,
dataToUpdate,
new ComparisonCondition(
TableSpec.instance.getColumnSpec(TableSpec.FIELD_ACCOUNTID),
ComparisonType.EQUAL,
account.id.ToString()
)
)
);
}
private static HashSet<int> SafeGetAvatars(Account account) {
try {
return AvatarsSettings.LoadByAccount(account).avatarsIds;
} catch(NotFoundInDBException) {
return new HashSet<int>();
}
}
public static void AddAvatar(Account account, Upload avatar) {
if(avatar.size > Upload.AVATAR_MAX_FILESIZE) throw new FLocalException("Avatar is too big (max. 80KB allowed)");
HashSet<int> avatars = SafeGetAvatars(account);
avatars.Add(avatar.id);
Save(account, avatars);
}
public static void RemoveAvatar(Account account, Upload avatar) {
HashSet<int> avatars = SafeGetAvatars(account);
avatars.Remove(avatar.id);
Save(account, avatars);
}
}
}

@ -10,6 +10,8 @@ using FLocal.Core.DB.conditions;
namespace FLocal.Common.dataobjects {
public class Upload : SqlObject<Upload> {
public const int AVATAR_MAX_FILESIZE = 80*1024;
public class TableSpec : ISqlObjectTableSpec {
public const string TABLE = "Uploads";
public const string FIELD_ID = "Id";

@ -327,5 +327,20 @@ namespace FLocal.Common.dataobjects {
);
}
public void SetAvatar(Upload avatar) {
if((avatar != null) && (avatar.size > Upload.AVATAR_MAX_FILESIZE)) throw new FLocalException("Avatar is too big (max. 80KB allowed)");
ChangeSetUtil.ApplyChanges(
new UpdateChange(
TableSpec.instance,
new Dictionary<string,AbstractFieldValue> {
{ TableSpec.FIELD_AVATARID, new ScalarFieldValue((avatar != null) ? avatar.id.ToString() : null) },
},
this.id
)
);
}
}
}

@ -102,6 +102,8 @@ namespace FLocal.IISHandler {
return new handlers.response.SettingsHandler();
case "userdata":
return new handlers.response.UserDataHandler();
case "avatars":
return new handlers.response.AvatarsSettingsHandler();
case "conversations":
if(context.requestParts.Length == 2) {
return new handlers.response.ConversationsHandler();
@ -238,6 +240,20 @@ namespace FLocal.IISHandler {
return new handlers.request.CreatePollHandler();
case "vote":
return new handlers.request.VoteHandler();
case "avatars":
if(context.requestParts.Length < 3) {
return new handlers.WrongUrlHandler();
}
switch(context.requestParts[2].ToLower()) {
case "add":
return new handlers.request.avatars.AddHandler();
case "remove":
return new handlers.request.avatars.RemoveHandler();
case "setasdefault":
return new handlers.request.avatars.SetAsDefaultHandler();
default:
return new handlers.WrongUrlHandler();
}
case "maintenance":
if(context.requestParts.Length < 3) {
return new handlers.WrongUrlHandler();

@ -144,8 +144,12 @@
</ProjectReference>
</ItemGroup>
<ItemGroup>
<Compile Include="handlers\request\avatars\AddHandler.cs" />
<Compile Include="handlers\request\avatars\RemoveHandler.cs" />
<Compile Include="handlers\request\avatars\SetAsDefaultHandler.cs" />
<Compile Include="handlers\request\UserDataHandler.cs" />
<Compile Include="handlers\response\AbstractUserGetHandler.cs" />
<Compile Include="handlers\response\AvatarsSettingsHandler.cs" />
<Compile Include="handlers\response\UserDataHandler.cs" />
<Compile Include="handlers\response\UserThreadsHandler.cs" />
</ItemGroup>

@ -0,0 +1,45 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using FLocal.Common.dataobjects;
using FLocal.Importer;
using System.Text.RegularExpressions;
using FLocal.Core;
using FLocal.Common;
using FLocal.Common.actions;
using System.Web;
namespace FLocal.IISHandler.handlers.request.avatars {
class AddHandler : AbstractPostHandler {
protected override string templateName {
get {
return "result/AvatarAdded.xslt";
}
}
protected override XElement[] Do(WebContext context) {
Upload upload;
if(context.httprequest.Files["file"] != null && context.httprequest.Files["file"].ContentLength > 0) {
HttpPostedFile file = context.httprequest.Files["file"];
if(file.ContentLength != file.InputStream.Length) throw new FLocalException("file is not uploaded completely");
try {
upload = UploadManager.UploadFile(file.InputStream, System.IO.Path.GetFileName(file.FileName), DateTime.Now, context.session.account.user, null);
} catch(UploadManager.AlreadyUploadedException e) {
upload = Upload.LoadById(e.uploadId);
}
} else {
upload = Upload.LoadById(int.Parse(context.httprequest.Form["uploadId"]));
}
AvatarsSettings.AddAvatar(context.account, upload);
return new XElement[] {
new XElement("uploadedId", upload.id)
};
}
}
}

@ -0,0 +1,35 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using FLocal.Common.dataobjects;
using FLocal.Importer;
using System.Text.RegularExpressions;
using FLocal.Core;
using FLocal.Common;
using FLocal.Common.actions;
using System.Web;
namespace FLocal.IISHandler.handlers.request.avatars {
class RemoveHandler : AbstractPostHandler {
protected override string templateName {
get {
return "result/AvatarRemoved.xslt";
}
}
protected override XElement[] Do(WebContext context) {
Upload upload = Upload.LoadById(int.Parse(context.httprequest.Form["uploadId"]));
AvatarsSettings.RemoveAvatar(context.account, upload);
return new XElement[] {
new XElement("uploadedId", upload.id)
};
}
}
}

@ -0,0 +1,39 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using FLocal.Common.dataobjects;
using FLocal.Importer;
using System.Text.RegularExpressions;
using FLocal.Core;
using FLocal.Common;
using FLocal.Common.actions;
using System.Web;
namespace FLocal.IISHandler.handlers.request.avatars {
class SetAsDefaultHandler : AbstractPostHandler {
protected override string templateName {
get {
return "result/AvatarSetted.xslt";
}
}
protected override XElement[] Do(WebContext context) {
Upload upload = null;
if(!string.IsNullOrEmpty(context.httprequest.Form["uploadId"])) {
upload = Upload.LoadById(int.Parse(context.httprequest.Form["uploadId"]));
}
context.account.user.SetAvatar(upload);
return new XElement[] {
(upload != null) ? new XElement("uploadedId", upload.id) : null
};
}
}
}

@ -0,0 +1,37 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using System.Xml.Linq;
using FLocal.Core;
using FLocal.Common;
using FLocal.Common.dataobjects;
namespace FLocal.IISHandler.handlers.response {
class AvatarsSettingsHandler : AbstractGetHandler {
override protected string templateName {
get {
return "AvatarsSettings.xslt";
}
}
override protected IEnumerable<XElement> getSpecificData(WebContext context) {
AvatarsSettings settings = null;
try {
settings = AvatarsSettings.LoadByAccount(context.account);
int accountId = settings.accountId; //just to make sure it is loaded
} catch(NotFoundInDBException) {
}
return new XElement[] {
(settings != null) ? new XElement("avatars", from avatar in settings.avatars select avatar.exportToXml(context)) : null,
(context.account.user.avatarId.HasValue) ? new XElement("currentAvatar", context.account.user.avatar.exportToXml(context)) : null,
};
}
}
}

@ -0,0 +1,122 @@
<?xml version="1.0" encoding="Windows-1251"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml">
<xsl:import href="elems\Main.xslt"/>
<xsl:template name="specificTitle">Íàñòðîéêà àâàòàðîê</xsl:template>
<xsl:template name="specific">
<table width="95%" align="center" cellpadding="1" cellspacing="1" class="tablesurround">
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="tdheader">
<xsl:text>Íàñòðîéêà àâàòàðîê</xsl:text>
</td>
</tr>
<tr>
<td class="lighttable">
<p>Âàøè àâàòàðêè:</p>
<xsl:apply-templates select="avatars/upload"/>
</td>
</tr>
<tr>
<td class="lighttable">
<form method="post" action="/do/Avatars/SetAsDefault">
<input type="hidden" name="uploadId" value=""/>
<input type="submit" class="buttons" value="Îòêëþ÷èòü àâàòàðêó">
<xsl:if test="not(/root/currentAvatar)">
<xsl:attribute name="disabled">disabled</xsl:attribute>
</xsl:if>
</input>
</form>
</td>
</tr>
</table>
</td>
</tr>
</table>
<br/>
<table width="95%" align="center" cellpadding="1" cellspacing="1" class="tablesurround">
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="tdheader">
<xsl:text>Âûáåðèòå àâàòàðêó äëÿ çàãðóçêè</xsl:text>
</td>
</tr>
<tr class="darktable">
<td>
<xsl:text>Ìàêñèìàëüíûé ðàçìåð ôàéëà &#8211; 80ÊÁ, äîïóñòèìûå ðàçðåøåíèÿ: gif, jpg, png, svg, jpe, jpeg, jfif, jif</xsl:text>
</td>
</tr>
<tr>
<td class="lighttable">
<form method="post" action="/do/Avatars/Add" enctype="multipart/form-data">
<input type="file" name="file" class="formboxes" /><br/>
<input type="submit" name="buttlogin" value="Îòïðàâèòü!" class="buttons" />
</form>
</td>
</tr>
</table>
</td>
</tr>
</table>
<br/>
<table width="95%" align="center" cellpadding="1" cellspacing="1" class="tablesurround">
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr class="tdheader">
<td>
<xsl:text>Èëè óêàæèòå íîìåð ôàéëà â àïëîàäå</xsl:text>
</td>
</tr>
<tr>
<td class="lighttable">
<form method="post" action="/do/Avatars/Add">
<input type="text" name="uploadId"/><br/>
<input type="submit" name="buttlogin" value="Îòïðàâèòü!" class="buttons" />
</form>
</td>
</tr>
</table>
</td>
</tr>
</table>
</xsl:template>
<xsl:template match="upload">
<table border="0">
<tr>
<td valign="middle">
<img alt="" class="avatar">
<xsl:attribute name="src">/Upload/Item/<xsl:value-of select="id"/>/</xsl:attribute>
</img>
</td>
<td valign="middle">
<form method="post" action="/do/Avatars/SetAsDefault">
<input type="hidden" name="uploadId">
<xsl:attribute name="value"><xsl:value-of select="id"/></xsl:attribute>
</input>
<input type="submit" class="buttons" value="Ñäåëàòü ñòàíäàðòíîé">
<xsl:if test="/root/currentAvatar/upload/id = id">
<xsl:attribute name="disabled">disabled</xsl:attribute>
</xsl:if>
</input>
</form><br/>
<form method="post" action="/do/Avatars/Remove">
<input type="hidden" name="uploadId">
<xsl:attribute name="value"><xsl:value-of select="id"/></xsl:attribute>
</input>
<input type="submit" class="buttons" value="Óäàëèòü">
<xsl:if test="/root/currentAvatar/upload/id = id">
<xsl:attribute name="disabled">disabled</xsl:attribute>
</xsl:if>
</input>
</form>
</td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>

@ -16,7 +16,7 @@
<td>
<xsl:text>Âűáĺđčňĺ ôŕéë äë˙ çŕăđóçęč</xsl:text>
<br/>
<xsl:text>Максимальный размер файла &#8211; 1МБ, допустимые разрешения: gif, jpg, png</xsl:text>
<xsl:text>Максимальный размер файла &#8211; 1МБ, допустимые разрешения: gif, jpg, png, svg, jpe, jpeg, jfif, jif</xsl:text>
</td>
</tr>
<tr>

@ -53,6 +53,14 @@
</xsl:with-param>
</xsl:call-template>
<xsl:text> | </xsl:text>
<xsl:call-template name="headerLink">
<xsl:with-param name="url">/My/Avatars/</xsl:with-param>
<xsl:with-param name="text">Àâàòàðêè</xsl:with-param>
<xsl:with-param name="isDisabled">
<xsl:if test="not(session/sessionKey)">true</xsl:if>
</xsl:with-param>
</xsl:call-template>
<xsl:text> | </xsl:text>
<img src="/static/images/shortcut.png" border="0"/>
<xsl:call-template name="headerLink">
<xsl:with-param name="url">/Users/User/<xsl:value-of select="session/user/id"/>/Info/</xsl:with-param>

@ -0,0 +1,48 @@
<?xml version="1.0" encoding="Windows-1251"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml">
<xsl:import href="..\elems\Main.xslt"/>
<xsl:template name="specificTitle">Äîáàâëåíèå àâàòàðêè</xsl:template>
<xsl:template name="specific">
<table width="95%" align="center" cellpadding="1" cellspacing="1" class="tablesurround">
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="tdheader">
<xsl:text>Äîáàâëåíèå àâàòàðêè</xsl:text>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="lighttable">
<p>Âàøà àâàòàðêà áûëà óñïåøíî çàãðóæåíà</p>
<p align="center">
<xsl:text>[&#8592;] </xsl:text>
<a id="actionLink_left">
<xsl:attribute name="href">/My/Avatars/</xsl:attribute>
<xsl:text>Âåðíóòüñÿ ê íàñòðîéêàì àâàòàðîê</xsl:text>
</a>
<xsl:text> | </xsl:text>
<a id="actionLink_right">
<xsl:attribute name="href">/Upload/Item/<xsl:value-of select="uploadedId"/></xsl:attribute>
<xsl:text>Ïðîñìîòðåòü àâàòàðêó</xsl:text>
</a>
<xsl:text> [&#8594;]</xsl:text>
</p>
<script type="text/javascript" language="Javascript">
<xsl:text>assignArrowsHandlers();</xsl:text>
</script>
</td>
</tr>
</table>
</td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>

@ -0,0 +1,48 @@
<?xml version="1.0" encoding="Windows-1251"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml">
<xsl:import href="..\elems\Main.xslt"/>
<xsl:template name="specificTitle">Óäàëåíèå àâàòàðêè</xsl:template>
<xsl:template name="specific">
<table width="95%" align="center" cellpadding="1" cellspacing="1" class="tablesurround">
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="tdheader">
<xsl:text>Óäàëåíèå àâàòàðêè</xsl:text>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="lighttable">
<p>Âàøà àâàòàðêà áûëà óñïåøíî óäàëåíà. Òåì íå ìåíåå, â àïëîàäå îíà îñòàëàñü - àâàòàðêè óäàëÿþòñÿ òîëüêî èç ñïèñêà àâàòàðîê.</p>
<p align="center">
<xsl:text>[&#8592;] </xsl:text>
<a id="actionLink_left">
<xsl:attribute name="href">/My/Avatars/</xsl:attribute>
<xsl:text>Âåðíóòüñÿ ê íàñòðîéêàì àâàòàðîê</xsl:text>
</a>
<xsl:text> | </xsl:text>
<a id="actionLink_right">
<xsl:attribute name="href">/Upload/Item/<xsl:value-of select="uploadedId"/></xsl:attribute>
<xsl:text>Ïðîñìîòðåòü óäàë¸ííóþ àâàòàðêó</xsl:text>
</a>
<xsl:text> [&#8594;]</xsl:text>
</p>
<script type="text/javascript" language="Javascript">
<xsl:text>assignArrowsHandlers();</xsl:text>
</script>
</td>
</tr>
</table>
</td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>

@ -0,0 +1,48 @@
<?xml version="1.0" encoding="Windows-1251"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml">
<xsl:import href="..\elems\Main.xslt"/>
<xsl:template name="specificTitle">Èçìåíåíèå àâàòàðêè</xsl:template>
<xsl:template name="specific">
<table width="95%" align="center" cellpadding="1" cellspacing="1" class="tablesurround">
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="tdheader">
<xsl:text>Èçìåíåíèå àâàòàðêè</xsl:text>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<table cellpadding="3" cellspacing="1" width="100%" class="tableborders">
<tr>
<td class="lighttable">
<p>Íîâàÿ àâàòàðêà áûëà óñïåøíî óñòàíîâëåíà</p>
<p align="center">
<xsl:text>[&#8592;] </xsl:text>
<a id="actionLink_left">
<xsl:attribute name="href">/My/Avatars/</xsl:attribute>
<xsl:text>Âåðíóòüñÿ ê íàñòðîéêàì àâàòàðîê</xsl:text>
</a>
<xsl:text> | </xsl:text>
<a id="actionLink_right">
<xsl:attribute name="href">/Upload/Item/<xsl:value-of select="uploadedId"/></xsl:attribute>
<xsl:text>Ïðîñìîòðåòü àâàòàðêó</xsl:text>
</a>
<xsl:text> [&#8594;]</xsl:text>
</p>
<script type="text/javascript" language="Javascript">
<xsl:text>assignArrowsHandlers();</xsl:text>
</script>
</td>
</tr>
</table>
</td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>
Loading…
Cancel
Save