One question when i insert into the template i get this:
{ "title": "Title of the site", "description": "Description of the site- Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore Lorem ipsum dolor sit." }
Any hint, or easy way to use it in the template.
I suppose i should use AngularJs https://angularjs.org/, is this the way it was intended to be used
Do you mind sharing the code you're using for getting the values currently?
You don't need angular to fetch the values - property editors and the backoffice UI is based on Angular but you need to fetch the values in your templates using XSLT or Razor.
you can also write a Property Editor Value Converter which return an object with properties for title and description, so you can use strongly typed object.
I just coded this thing in 20 minutes to do a presentation at a Swedish Umbraco meetup. A Property Editor Value Contevert would be the "right" way to do this. But what I did was to convert the json-string into an object that looked something like this:
public class SeoFields { public string title {get;set;} public string description {get;set;} }
I did that convertion in the view which is not best practice. If you would like to update the package with a property editor value convert just make a poll request to the github-repo - otherwise I may do that when I find some time for it =D
Yes, I would make it easier to use with strongly typed object.. I think Tims example here http://www.nibble.be/?p=337 is almost what is needed to know.. just with your class instead with the properties Title and Description.
Seo Visualizer - Insert title & Meta description
Hi
Nice little pacakage http://our.umbraco.org/projects/collaboration/seo-visualizer
One question when i insert into the template i get this:
{ "title": "Title of the site", "description": "Description of the site- Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore Lorem ipsum dolor sit." }
Any hint, or easy way to use it in the template.
I suppose i should use AngularJs https://angularjs.org/, is this the way it was intended to be used
Hi René
Do you mind sharing the code you're using for getting the values currently?
You don't need angular to fetch the values - property editors and the backoffice UI is based on Angular but you need to fetch the values in your templates using XSLT or Razor.
/Jan
Do not at all..
Another problem, i cant log in to Umbraco, i lft the computer when i was logged in, and session timed out.
I vill try to solve this first
Hi René
What version of Umbraco 7 are you currently using?
/Jan
Hi
I use version 7.1.2
I can see there are a new version, i vill try this.
Rene
Hi René
Did you solve your issue?
Seo Visualizer returns json and to get the title or description values in your MVC razor views, you can write e.g. this with the dynamic object:
you can also write a Property Editor Value Converter which return an object with properties for title and description, so you can use strongly typed object.
/Bjarne
Hi!
I just coded this thing in 20 minutes to do a presentation at a Swedish Umbraco meetup. A Property Editor Value Contevert would be the "right" way to do this. But what I did was to convert the json-string into an object that looked something like this:
public class SeoFields
{
public string title {get;set;}
public string description {get;set;}
}
I did that convertion in the view which is not best practice. If you would like to update the package with a property editor value convert just make a poll request to the github-repo - otherwise I may do that when I find some time for it =D
Cheers!
Hi Markus
Yes, I would make it easier to use with strongly typed object.. I think Tims example here http://www.nibble.be/?p=337 is almost what is needed to know.. just with your class instead with the properties Title and Description.
/Bjarne
My code fingers could not keep away from this =D So I've added a property value converter now =D
http://our.umbraco.org/projects/collaboration/seo-visualizer
Read more about usage here: https://github.com/enkelmedia/Umbraco7-SeoVisualizer
Cheers!
Awesome! .. great work Markus :) #h5yr
Great work Marcus! Just left you a little suggestion on your value converter commit in GitHub.
is working on a reply...