@@ 328,8 328,11 @@ func (s *Service) Homepage(c echo.Context) error {
pd.Data["forgot_password"] = lt.Translate("Forgot Password?")
pd.Data["login"] = lt.Translate("Login")
pd.Data["no_accounts"] = lt.Translate("No accounts? Click here to create one")
- gMap := gobwebs.Map{"pd": pd}
- return links.Render(c, http.StatusOK, "index.html", gMap)
+
+ gmap := gobwebs.Map{
+ "pd": pd,
+ }
+ return links.Render(c, http.StatusOK, "index.html", gmap)
}
@@ 408,8 411,18 @@ func (s *Service) PricingList(c echo.Context) error {
pd.Data["feature_self_hosting_2"] = lt.Translate("Host your own version of Link Taco")
pd.Data["feature_self_hosting_3"] = lt.Translate("Documentation")
+ url := links.GetLinksDomainURL(c)
+ url.Path = c.Echo().Reverse("core:pricing_list")
+ seoData := links.GetSEOData(c)
+ seoData.Title = pd.Title
+ seoData.Description = lt.Translate("Pricing and feature details for LinkTaco.com")
+ seoData.Keywords = lt.Translate("pricing, links, linktaco, feature, plans, pricing plans")
+ seoData.URL = url.String()
+ seoData.TwitterURL = url.String()
+
gmap := gobwebs.Map{
- "pd": pd,
+ "pd": pd,
+ "seoData": seoData,
}
return links.Render(c, http.StatusOK, "pricing_list.html", gmap)
}
@@ 479,8 492,19 @@ func (s *Service) FeatureTour(c echo.Context) error {
pd.Data["import_pinboard"] = lt.Translate("Import from Pinboard, Chrome, Firefox, Safari")
pd.Data["export_json"] = lt.Translate("Export in JSON or HTML format")
+
+ url := links.GetLinksDomainURL(c)
+ url.Path = c.Echo().Reverse("core:feature_tour")
+ seoData := links.GetSEOData(c)
+ seoData.Title = pd.Title
+ seoData.Description = lt.Translate("All feature details for LinkTaco.com")
+ seoData.Keywords = lt.Translate("features, pricing, links, linktaco, feature, plans, pricing plans")
+ seoData.URL = url.String()
+ seoData.TwitterURL = url.String()
+
gmap := gobwebs.Map{
- "pd": pd,
+ "pd": pd,
+ "seoData": seoData,
}
return links.Render(c, http.StatusOK, "feature_tour.html", gmap)
}
@@ 1731,6 1755,17 @@ func (s *Service) PopularLinkList(c echo.Context) error {
pLinks := result.PopularLinks
rssURL := c.Echo().Reverse(s.RouteName("popular_link_list_rss"))
+
+ url := links.GetLinksDomainURL(c)
+ url.Path = c.Echo().Reverse(s.RouteName("popular_link_list"))
+ seoData := links.GetSEOData(c)
+ seoData.Title = pd.Title
+ seoData.Description = lt.Translate("Most popular links on LinkTaco.com")
+ seoData.Keywords = lt.Translate("popular, links, linktaco, feature, plans, pricing plans")
+ seoData.URL = url.String()
+ seoData.TwitterURL = url.String()
+ seoData.RssURL = url.String() + "/rss"
+
gmap := gobwebs.Map{
"pd": pd,
"links": pLinks,
@@ 1738,6 1773,7 @@ func (s *Service) PopularLinkList(c echo.Context) error {
"navFlag": "popular",
"tagFilter": "",
"rssURL": rssURL,
+ "seoData": seoData,
}
if links.IsRSS(c.Path()) {
items := []links.Item{}
@@ 2033,14 2069,14 @@ func (s *Service) OrgLinksList(c echo.Context) error {
var (
isOrgLink, isHome, advancedSearch, isRSSAuth bool
- currURL, navFlag, rssURL, followAction string
+ currURL, navFlag, rssURL, followAction, slug string
)
org := &models.Organization{}
if c.Path() != c.Echo().Reverse(s.RouteName("recent_link_list")) &&
c.Path() != c.Echo().Reverse(s.RouteName("recent_link_list_rss")) {
// This means that we want to see a specific org (private or businnes)
// and not all the recent links
- slug := links.PullOrgSlug(c)
+ slug = links.PullOrgSlug(c)
op.Var("slug", slug)
opts := &database.FilterOptions{
Filter: sq.And{
@@ 2275,8 2311,25 @@ func (s *Service) OrgLinksList(c echo.Context) error {
}
return links.ServerRSSFeed(c.Response(), rss)
}
+
+ seoData := links.GetSEOData(c)
+ url := links.GetLinksDomainURL(c)
+ if isOrgLink {
+ url.Path = c.Echo().Reverse(s.RouteName("org_link_list"), slug)
+ seoData.Description = lt.Translate("Recent public links added to %s on LinkTaco.com", org.Name)
+ } else {
+ url.Path = c.Echo().Reverse(s.RouteName("recent_link_list"))
+ seoData.Description = lt.Translate("Recent public links added to LinkTaco.com")
+ }
+ seoData.Title = pd.Title
+ seoData.Keywords = lt.Translate("recent, public, links, linktaco")
+ seoData.URL = url.String()
+ seoData.TwitterURL = url.String()
+ seoData.RssURL = url.String() + "/rss"
+
gmap := gobwebs.Map{
"pd": pd,
+ "seoData": seoData,
"links": orgLinks,
"org": org,
"isOrgLink": isOrgLink,
@@ 2388,11 2441,22 @@ func (s *Service) OrgLinkDetail(c echo.Context) error {
pd.Data["tags"] = lt.Translate("Tags")
pd.Data["back"] = lt.Translate("Back")
link := result.Link
+
+ url := links.GetLinksDomainURL(c)
+ url.Path = c.Echo().Reverse(s.RouteName("link_detail"), hash)
+ seoData := links.GetSEOData(c)
+ seoData.Title = pd.Title
+ seoData.Description = lt.Translate("Bookmark '%s' on LinkTaco.com", link.Title)
+ seoData.Keywords = lt.Translate("bookmark, note, detail, popular, links, linktaco")
+ seoData.URL = url.String()
+ seoData.TwitterURL = url.String()
+
gmap := gobwebs.Map{
"pd": pd,
"link": link,
"IsPrivate": link.IsPrivate(),
"navFlag": "bookmarks",
+ "seoData": seoData,
}
return links.Render(c, http.StatusOK, "link_detail.html", gmap)
}
@@ 3489,12 3553,23 @@ func (s *Service) NoteDetail(c echo.Context) error {
pd.Data["tags"] = lt.Translate("Tags")
pd.Data["back"] = lt.Translate("Back")
link := result.Link
+
+ url := links.GetLinksDomainURL(c)
+ url.Path = c.Echo().Reverse(s.RouteName("note_detail"), hash)
+ seoData := links.GetSEOData(c)
+ seoData.Title = pd.Title
+ seoData.Description = lt.Translate("Note '%s' on LinkTaco.com", link.Title)
+ seoData.Keywords = lt.Translate("note, detail, popular, links, linktaco")
+ seoData.URL = url.String()
+ seoData.TwitterURL = url.String()
+
gmap := gobwebs.Map{
"pd": pd,
"link": link,
"IsPrivate": link.IsPrivate(),
"IsAuth": gctx.User.IsAuthenticated(),
"navFlag": "notes",
+ "seoData": seoData,
}
return links.Render(c, http.StatusOK, "link_detail.html", gmap)
}
@@ 996,3 996,35 @@ func GetAddLinkURL(c echo.Context, gURL addLinker) string {
nextURL.RawQuery = qs.Encode()
return nextURL.String()
}
+
+type SEOData struct {
+ Title string
+ Description string
+ Keywords string
+ URL string
+ ImageURL string
+ TwitterURL string
+ TwitterImageURL string
+ RssURL string
+}
+
+func GetSEOData(c echo.Context) *SEOData {
+ lt := localizer.GetSessionLocalizer(c)
+ url := GetLinksDomainURL(c)
+ url.Path = c.Echo().Reverse("core:index")
+ seoData := &SEOData{
+ Title: lt.Translate("Social bookmarking plus link sharing, shortening and listings all in one app."),
+ Description: lt.Translate(
+ "Welcome to LinkTaco. Where you can mix all your link saving and sharing needs in one " +
+ "tight little bundle. Much like a taco. A link taco if you will.",
+ ),
+ Keywords: lt.Translate("social bookmarks, bookmarking, links, link sharing, link shortening, link listings, bookmarks, link saving, qr codes, analytics"),
+ URL: url.String(),
+ ImageURL: "https://s3.amazonaws.com/linktaco/social-media-image.jpg",
+ TwitterURL: url.String(),
+ TwitterImageURL: "https://s3.amazonaws.com/linktaco/social-media-image.jpg",
+ }
+ url.Path = c.Echo().Reverse("core:recent_link_list_rss")
+ seoData.RssURL = url.String()
+ return seoData
+}