From: Antonio Ospite Date: Tue, 3 Apr 2018 16:08:59 +0000 (+0200) Subject: rss_converter_instagram.com.xsl: fix scraping Instagram.com X-Git-Tag: v1.3.0~10 X-Git-Url: https://git.ao2.it/tweeper.git/commitdiff_plain/50ccfa618edab58b8079d331ecac3b66e7c6b153?ds=inline rss_converter_instagram.com.xsl: fix scraping Instagram.com --- diff --git a/src/rss_converter_instagram.com.xsl b/src/rss_converter_instagram.com.xsl index 238848f..4045224 100644 --- a/src/rss_converter_instagram.com.xsl +++ b/src/rss_converter_instagram.com.xsl @@ -32,7 +32,7 @@ https://instagram.com - + - + - + @@ -60,10 +60,10 @@ - - - - + + + + <xsl:variable name="title-length" select="140"/> @@ -87,7 +87,7 @@ <xsl:value-of select="$item-permalink"/> </guid> <pubDate> - <xsl:variable name="timestamp" select="./date"/> + <xsl:variable name="timestamp" select="./taken_at_timestamp"/> <xsl:value-of select="php:functionString('Tweeper\Tweeper::epochToRssDate', $timestamp)"/> </pubDate> <description> @@ -113,7 +113,7 @@ <xsl:variable name="channel-link"> <xsl:choose> <xsl:when test="$location-name != ''"> - <xsl:variable name="location-id" select="//LocationsPage/location/id"/> + <xsl:variable name="location-id" select="//LocationsPage/graphql/location/id"/> <xsl:value-of select="concat($BaseURL, '/explore/locations/', $location-id)"/> </xsl:when> <xsl:otherwise> @@ -121,7 +121,7 @@ </xsl:otherwise> </xsl:choose> </xsl:variable> - <xsl:variable name="channel-image" select="//ProfilePage/user/profile_pic_url"/> + <xsl:variable name="channel-image" select="//ProfilePage/graphql/user/profile_pic_url"/> <rss version="2.0"> <xsl:attribute name="xml:base"><xsl:value-of select="$BaseURL" /></xsl:attribute> @@ -155,7 +155,7 @@ </url> </image> </xsl:if> - <xsl:apply-templates select="//ProfilePage/user/media/nodes|//LocationsPage/location/media/nodes"/> + <xsl:apply-templates select="//ProfilePage/graphql/user/edge_owner_to_timeline_media/edges/node|//LocationsPage/graphql/location/edge_location_to_media/edges/node"/> </channel> </rss> </xsl:template>