• Anonymous
  • Login
  • Register
BlogSphere - Feature Request: Translation for Category label + Written By regression fix


While debugging Written By translation, noticed that Category : was not translated.

Added field Conf_Trans_Category to form BlogConfigTrans. Used this field in computed text on subform SubFormDisplayStory as follows:
8<---- code starts
REM {Setup HTML For First Line of Title Block};
REM {C. Brandlehner, 16 Oct 2004: modified GoogleIT, MailIT and PrintIT to replace quotes};
REM {L Berntrop, 2 Aug 2006 readded Written By translation};
dspStoryTitle := @ReplaceSubstring(StoryTitle;"\"";"&quot;");

PreLine1 := "<div class=\"StoryTitle\"><span style=\"float:left;\">";
ShowIT := "<script language=\"JavaScript\" type=\"text/javascript\">It('"+dspStoryTitle+"','"+ FullURL + "');</script> ";
TitleHTML := "<a href=\"d6plinks/"+permalink+"\" title=\"PermaLink : "+permalink+"\" target=\"_top\"><img alt=\"PermaLink\" src=\""+plink_Image+"\" border=\"0\"></a> "+StoryTitle+"</span><span style=\"float:right;\">"+ @Text(StoryDate; "D0T1") +"</span>";
PostLine1 := "</div>";

REM {Setup HTML For Second Line Of Title Block};

PreLine2 := @If(ShowAuthor="Yes" | ShowCategory="Yes";"<div class=\"StoryTitle\">";"");
AuthorHTML := "<span style=\"float:left;\">" + @GetProfileField("BlogConfigTrans";"Conf_Trans_WrittenBy") + " " + StoryAuthor + "</span>";

CategoryHTML := "<span style=\"float:right;\">" + @GetProfileField("BlogConfigTrans";"Conf_Trans_Category") + " " +StoryCategory + "</span>";
AuthorHTMLRSS := "<span style=\"float:left;\">Written By : <a href=\"" + ShortURL + "/RSS_StoriesByAuthor?Open&amp;id="+ @Replace(StoryAuthor ;" ";"+")+"\"><script language=\"JavaScript\" type=\"text/javascript\">xmllink();</script>" + "</a> " + StoryAuthor + "</span>";
CategoryHTMLRSS := "<span style=\"float:right;\">Category : <a href=\"" + ShortURL + "/RSS_StoriesByCat?Open&amp;id="+ @URLEncode("Domino"; StoryCategory) +"\"><script language=\"JavaScript\" type=\"text/javascript\">xmllink();</script></a> " +StoryCategory + "</span>";

ShowAuth := @If(ShowAuthor="Yes";@If(ShowAuthorRSS="Yes";AuthorHTMLRSS;AuthorHTML);"");
ShowCat := @If(ShowCategory="Yes";@If(ShowCategoryRSS="Yes";CategoryHTMLRSS;CategoryHTML);"");
PostLine2 := @If(ShowAuthor="Yes" | ShowCategory="Yes";"</div>";"");


REM {Set HTML For Third Line Of Title Block};

PreLine3 := @If(ShowLocation="Yes";"<div class=\"StoryTitle\">";"");
LocationHTML := "<span style=\"float:left;\">Location : " + StoryLocation + "</span>";
ShowLoc := @If(ShowLocation="No"; ""; LocationHTML);
PostLine3 := @If(ShowLocation="Yes";"</div>";"");

REM {Show Admins a Notes Link to open a doc in the Notes Client from the browser };

_NotesLink_Image := "/"+ @WebDbName + "/images/notes_blue.gif";
_NotesLink := "<a href=\"Notes:///"+@ReplaceSubstring(@ReplicaID;":";"") +"/Stories/"+@Text(@DocumentUniqueID)+"\" title=\"Notes-Link: "+Subject +"\"><img src=\""+ _NotesLink_Image +"\" border=\"0\" alt=\"Notes-Link\" height=\"16\" width=\"16\"></a> ";
_NL := @If(@IsMember("[BlogAdmin]";@UserRoles);_NotesLink;"");

HTML := PreLine1 + _NL + ShowIT + TitleHTML + PostLine1 +
PreLine2 + ShowAuth + ShowCat + PostLine2 +
PreLine3 + ShowLoc + PostLine3;


HTML
8<---- code ends
note that this code will also fix the regression previously fixed in 2 beta 6, although in this subform only



Taken Actions by Owners



Documents
In this field you can enter the actual request.

You can use the rich text editor for rich text formating. You can also enter HTML to embed objects, e.g. to embed a YouTube video or a screenshot of the project. In this case use '[' and ']' to mark the passthrough HTML as such.

Please note that the first time you use the new UI your description is converted from rich text to MIME. You might want to copy and paste the raw plain text from the old UI in the new UI so that you don't loose information.
In this field owners can describe what they have done or want to do.

You can use the rich text editor for rich text formating. You can also enter HTML to embed objects, e.g. to embed a YouTube video or a screenshot of the project. In this case use '[' and ']' to mark the passthrough HTML as such.

Please note that the first time you use the new UI your description is converted from rich text to MIME. You might want to copy and paste the raw plain text from the old UI in the new UI so that you don't loose information.