>HTML markup is not only escaped as it was but also displayed as simple text
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/user/news-feed@181403 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
241486383b
commit
b6efac1e66
|
@ -1,12 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" output="target/news-feed-2.8.1-SNAPSHOT/WEB-INF/classes" path="src/main/java">
|
||||
<classpathentry kind="src" output="target/news-feed-2.8.2-SNAPSHOT/WEB-INF/classes" path="src/main/java">
|
||||
<attributes>
|
||||
<attribute name="optional" value="true"/>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry excluding="**" kind="src" output="target/news-feed-2.8.1-SNAPSHOT/WEB-INF/classes" path="src/main/resources">
|
||||
<classpathentry excluding="**" kind="src" output="target/news-feed-2.8.2-SNAPSHOT/WEB-INF/classes" path="src/main/resources">
|
||||
<attributes>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
|
@ -41,5 +41,5 @@
|
|||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry kind="output" path="target/news-feed-2.8.1-SNAPSHOT/WEB-INF/classes"/>
|
||||
<classpathentry kind="output" path="target/news-feed-2.8.2-SNAPSHOT/WEB-INF/classes"/>
|
||||
</classpath>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
eclipse.preferences.version=1
|
||||
lastWarOutDir=/Users/massi/Documents/workspace/news-feed/target/news-feed-2.8.1-SNAPSHOT
|
||||
lastWarOutDir=/Users/massi/Documents/workspace/news-feed/target/news-feed-2.8.2-SNAPSHOT
|
||||
warSrcDir=src/main/webapp
|
||||
warSrcDirIsOutput=false
|
||||
|
|
|
@ -8,6 +8,9 @@
|
|||
<dependent-module archiveName="gcube-widgets-2.2.0-SNAPSHOT.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/gcube-widgets/gcube-widgets">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="social-util-library-1.6.0-SNAPSHOT.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/social-util-library/social-util-library">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="pickitem-widget-2.0.0-SNAPSHOT.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/pickitem-widget/pickitem-widget">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
|
|
|
@ -1,4 +1,8 @@
|
|||
<ReleaseNotes>
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.news-feed.2-8-2" date="2019-08-02">
|
||||
<Change>HTML markup is not only escaped as it was but also displayed as simple text</Change>
|
||||
</Changeset>
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.news-feed.2-8-1" date="2019-07-17">
|
||||
<Change>Fixed Bug #17181, post editing leads to losing both formatting and mentions</Change>
|
||||
|
|
5
pom.xml
5
pom.xml
|
@ -1,4 +1,5 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
@ -12,7 +13,7 @@
|
|||
<groupId>org.gcube.portlets.user</groupId>
|
||||
<artifactId>news-feed</artifactId>
|
||||
<packaging>war</packaging>
|
||||
<version>2.8.1-SNAPSHOT</version>
|
||||
<version>2.8.2-SNAPSHOT</version>
|
||||
|
||||
<name>gCube News Feed Portlet</name>
|
||||
<description>
|
||||
|
|
|
@ -1357,6 +1357,7 @@ public class NewsFeedPanel extends Composite {
|
|||
}
|
||||
else {
|
||||
Comment comment = (Comment) result.getComment();
|
||||
GWT.log("Returned Comment="+comment.getText());
|
||||
owner.addComment(new SingleComment(comment, owner, (comment.getUserid().equals(myUserInfo.getUsername()))));
|
||||
owner.setCommentingDisabled(false);
|
||||
owner.updateCommentsNumberCount();
|
||||
|
|
|
@ -80,7 +80,7 @@ public class SingleComment extends Composite {
|
|||
String commentToShow = toShow.getText();
|
||||
|
||||
//replace the < & and >
|
||||
commentToShow = commentToShow.replaceAll("<","<").replaceAll(">",">");
|
||||
// commentToShow = commentToShow.replaceAll("<","<").replaceAll(">",">");
|
||||
commentToShow = commentToShow.replaceAll("&","&");
|
||||
|
||||
|
||||
|
|
|
@ -308,8 +308,8 @@ public class TweetTemplate extends Composite {
|
|||
avatarImage.setUrl(post.getThumbnailURL());
|
||||
avatarImage.setPixelSize(40, 40);
|
||||
|
||||
//replace the < & and >
|
||||
postText = postText.replaceAll("<","<").replaceAll(">",">");
|
||||
// //replace the < & and >
|
||||
// postText = postText.replaceAll("<","<").replaceAll(">",">");
|
||||
postText = postText.replaceAll("&","&");
|
||||
|
||||
final String profilePageURL = GCubePortalConstants.PREFIX_GROUP_URL + NewsFeedPanel.extractOrgFriendlyURL(Location.getHref()) +GCubePortalConstants.USER_PROFILE_FRIENDLY_URL;
|
||||
|
|
|
@ -776,12 +776,6 @@ public class NewsServiceImpl extends RemoteServiceServlet implements NewsService
|
|||
if (newHashtags != null && !newHashtags.isEmpty())
|
||||
store.saveHashTagsComment(toEdit.getKey(), vreIdFeed, newHashtags);
|
||||
|
||||
// // get new hashtags
|
||||
// String escapedCommentText = Utils.escapeHtmlAndTransformUrl(toEdit.getText());
|
||||
// List<String> newHashtags = Utils.getHashTags(escapedCommentText);
|
||||
// if (newHashtags != null && !newHashtags.isEmpty())
|
||||
// escapedCommentText = Utils.convertHashtagsAnchorHTML(escapedCommentText, newHashtags);
|
||||
|
||||
edited = new Comment(toEdit.getKey(), toEdit.getUserid(),
|
||||
toEdit.getTime(), toEdit.getFeedid(), escapedCommentText, user.getFullName(), user.getAvatarId(), true, new Date());
|
||||
|
||||
|
|
Loading…
Reference in New Issue