D
dSchwartz
I am creating a totally adminable news system in asp.net (C#, SQL
server). what i want to accomplish is allow multiple news templates
to be read by an admin area.
heres how it works (hopefully): an artist creates a news template
(html file), drops it into a specific directory, now a client can
choose that template and edit a certain number of fields. the artist
has to be able to specify these fields in the template somehow,
example:
....html tags...
news-NewsTitle-text-news
...html tages...
news-NewsDate-text-news
...html...
news-NewsImage1-image-news
...html tags....
now my admin area needs to read this template file and pull out of it
each of these fields to save to a db which describes the news article.
fieldname="News Title", fieldtype="text"
fieldname="News Date", fieldtype="text"
fieldname="News Image 1" fieldtype="image"
then based on that info i'll create an admin area where they can edit
the actual info saved for each of those. what i need some advise on
is how should i instruct the artists to label each of the fields in
the template, and then how should i pull that info off the template.
I'm pretty new to C# and asp.net, but have experience with classic
asp(vbscript). what i think of is useing filesystemobject, write a
function that will read the html templates line by line, looking for
"news-" and somehow extracting everything there before the "-news".
would this be a good situation to learn reg exp's to use here?
Thank You much for any time you are able to spend to give me a bit of
advise!
server). what i want to accomplish is allow multiple news templates
to be read by an admin area.
heres how it works (hopefully): an artist creates a news template
(html file), drops it into a specific directory, now a client can
choose that template and edit a certain number of fields. the artist
has to be able to specify these fields in the template somehow,
example:
....html tags...
news-NewsTitle-text-news
...html tages...
news-NewsDate-text-news
...html...
news-NewsImage1-image-news
...html tags....
now my admin area needs to read this template file and pull out of it
each of these fields to save to a db which describes the news article.
fieldname="News Title", fieldtype="text"
fieldname="News Date", fieldtype="text"
fieldname="News Image 1" fieldtype="image"
then based on that info i'll create an admin area where they can edit
the actual info saved for each of those. what i need some advise on
is how should i instruct the artists to label each of the fields in
the template, and then how should i pull that info off the template.
I'm pretty new to C# and asp.net, but have experience with classic
asp(vbscript). what i think of is useing filesystemobject, write a
function that will read the html templates line by line, looking for
"news-" and somehow extracting everything there before the "-news".
would this be a good situation to learn reg exp's to use here?
Thank You much for any time you are able to spend to give me a bit of
advise!