473,748 Members | 5,232 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Anyway to put xml tags into an aspx page?

I'm trying to format some data out as an RSS feed. I already have a
perfectly good ASPX page that does the same thing with an <asp:repeater > so
I figured I'd take the page change the html tags to RSS tags and it would
all work fine.

Problem is that it appears that there's no way to tell VS or the compiler
that I really do want to push out XML and it complains that the XML tags are
not valid in 'the active schema'

<%@ Page Language="C#" ContentType="te xt/xml" %>
<?xml version="1.0" encoding="utf-8" ?>
<rss version="2.0">
<channel>
<title>My Title</title>
<link>http://www.mylink.com</link>
<asp:Repeater ID="Body" Runat="server">
<ItemTemplate >
<item>

....you get the idea.

I get a red squiggly under <rss that says 'the active schema does not
support the element rss', and of course the <asp: is equally unrecognised. I
have an RSS xsd file but there doesn't appear to be a way of making the ASPX
honor it (and even if I could would it still barf on the <asp: tags).

[Note: I know I can do it all in the code behind with an XMLWriter and yes
I've wasted more time on this than it would have taken me to write the code
but its the principle of it !!! :-) ]

Zman


Nov 18 '05 #1
2 1268
I don't think there is a way to insert them directly in teh aspx file you'll
have to put literal controls in the apsx file and out put the xml tags
codewize

cheers,
mortb
"ZMan" <news-replies@thezbuf fer> wrote in message
news:OB******** *****@TK2MSFTNG P12.phx.gbl...
I'm trying to format some data out as an RSS feed. I already have a
perfectly good ASPX page that does the same thing with an <asp:repeater >
so I figured I'd take the page change the html tags to RSS tags and it
would all work fine.

Problem is that it appears that there's no way to tell VS or the compiler
that I really do want to push out XML and it complains that the XML tags
are not valid in 'the active schema'

<%@ Page Language="C#" ContentType="te xt/xml" %>
<?xml version="1.0" encoding="utf-8" ?>
<rss version="2.0">
<channel>
<title>My Title</title>
<link>http://www.mylink.com</link>
<asp:Repeater ID="Body" Runat="server">
<ItemTemplate >
<item>

...you get the idea.

I get a red squiggly under <rss that says 'the active schema does not
support the element rss', and of course the <asp: is equally unrecognised.
I have an RSS xsd file but there doesn't appear to be a way of making the
ASPX honor it (and even if I could would it still barf on the <asp: tags).

[Note: I know I can do it all in the code behind with an XMLWriter and yes
I've wasted more time on this than it would have taken me to write the
code but its the principle of it !!! :-) ]

Zman

Nov 18 '05 #2
Even asp:literals won't work becuase they have to be inside <html><body> or
<html><head> to be valid and that will obviously make it invalid RSS. You
are more than likely still correct though.

Thanks
ZMan
"mortb" <mortb1<noospam <@hotmail.com > wrote in message
news:OW******** ******@TK2MSFTN GP09.phx.gbl...
I don't think there is a way to insert them directly in teh aspx file
you'll have to put literal controls in the apsx file and out put the xml
tags codewize

cheers,
mortb
"ZMan" <news-replies@thezbuf fer> wrote in message
news:OB******** *****@TK2MSFTNG P12.phx.gbl...
I'm trying to format some data out as an RSS feed. I already have a
perfectly good ASPX page that does the same thing with an <asp:repeater >
so I figured I'd take the page change the html tags to RSS tags and it
would all work fine.

Problem is that it appears that there's no way to tell VS or the compiler
that I really do want to push out XML and it complains that the XML tags
are not valid in 'the active schema'

<%@ Page Language="C#" ContentType="te xt/xml" %>
<?xml version="1.0" encoding="utf-8" ?>
<rss version="2.0">
<channel>
<title>My Title</title>
<link>http://www.mylink.com</link>
<asp:Repeater ID="Body" Runat="server">
<ItemTemplate >
<item>

...you get the idea.

I get a red squiggly under <rss that says 'the active schema does not
support the element rss', and of course the <asp: is equally
unrecognised. I have an RSS xsd file but there doesn't appear to be a way
of making the ASPX honor it (and even if I could would it still barf on
the <asp: tags).

[Note: I know I can do it all in the code behind with an XMLWriter and
yes I've wasted more time on this than it would have taken me to write
the code but its the principle of it !!! :-) ]

Zman


Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
6021
by: Kathleen Dollard | last post by:
Hi, Oleg's answer about attribute value templates led me to look back at a different problem, and wonder if someone else had solved it. I want to output an ASP.NET page. Thus I need to output ASP.NET tags and HTML tags. <%@ Page Language= etc...
7
2748
by: Rocky Moore | last post by:
I have a web site called HintsAndTips.com. On this site people post tips using a very simply webform with a multi line TextBox for inputing the tip text. This text is encode to HTML so that no tags will remain making the page safe (I have to convert the linefeeds to <BR>s because the Server.EncodeHTML does not do that it seems). The problem is that users can use a special tag when editing the top to specify an area of the tip that will...
2
1553
by: Jeffrey T. | last post by:
I had some JavaScript functions defined in the <SCRIPT> section at the top of an aspx page (tested fine there). I then moved the JavaScript functions to their own separate file and then referenced that file in the <HEAD> section of the aspx page. I then removed the <SCRIPT> section from the aspx page, and the JavaScript stopped working (it was getting called, but some functionality wasn't working). I verified the path and file name to...
7
2221
by: Jack | last post by:
Hello, What is the difference between SRC and CODEBEHIND Tags? Example <%@ Page Language="vb" ValidateRequest="false" AutoEventWireup="false" Codebehind="WebForm1.aspx.vb" %> or
0
992
by: Richard Steele (Basemap) | last post by:
VisualStudio 2005 Release having developed a webform with embedded tags such as <a href="javascript:OpenPopupPage('Calendar.aspx','<%= WeekEnding2.ClientID %>','<%= Page.IsPostBack %>');"> This page is saved, but when repoened for edit, i am missing the server tags i.e. <a href="javascript:OpenPopupPage('Calendar.aspx','','');">
10
3110
by: Barry L. Camp | last post by:
Hi all... hope someone can help out. Not a unique situation, but my search for a solution has not yielded what I need yet. I'm trying to come up with a regular expression for a RegularExpressionValidator that will allow certain HTML tags: <a>, <b>, <blockquote>, <br>, <i>, <img>, <li>, <ol>, <p>, <quote>, <ul>
2
1404
by: =?Utf-8?B?Sm9zaCBOaWtsZQ==?= | last post by:
I hope someone can help with this, because it’s driving me crazy. It’s also a little tough to describe what’s happening, but I’ll do my best. I have a class that takes a ProductID and then uses it to generate some html. I then insert that HTML into my page via server tags. I’m using a datalist for the content, making a 3 x 3 grid. For each instance of my ItemTemplate, I’m changing a pic, some text, a link button, and my...
3
2117
by: MikeB | last post by:
Hello, I have a content page that is from a Master page which has 2 content panes. How do I add my forms to the content page? Each pane needs a form but you can not have multiple form tags nor can the form tages be outside of the content tags? Does this make since? Below is my source to the pages. Basically I need both content tags to have form tags.
4
1863
by: King Coffee | last post by:
Hi, If I use master pages with META tags in the head section... can I still use META tag on the child pages (child pages reference the master page). I ask this question because I heard the more pages with META tags containing search engine key words, the higher the search engine ranking. Thanks, King
0
8991
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9548
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9374
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8244
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6796
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6076
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3315
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2787
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2215
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.