Listing 1

Register.CFM
<cfcontent type="application/xml">
<cfparam name="URL.Uname" default="">
<cfparam name="URL.Pword" default="">
<cfquery datasource="global" name="CheckUname">
Select Username
FROM CFDJ_users
Where Username = '#URL.Uname#'
</cfquery>
<cfif CheckUname.RecordCount GTE 1>
<application>
<dashboard>
<broadcast>
<cfoutput>The Username Is Already Taken, Please Choose A Different One</cfoutput>
</broadcast>
<value> The Username Is Already Taken, Please Choose A Different One </value>
<username>#URL.Uname#</username>
</dashboard>
</application>
<cfelse>
<cfquery datasource="global" name="Register">
Insert INTO CFDJ_users (Username,Password)
Values ('#URl.Uname#','#URL.Pword#')
</cfquery>
<application>
<dashboard>
<broadcast>
<cfoutput>Welcome To G-uniX Rss Manager</cfoutput>
</broadcast>
<value>Welcome To G-uniX Rss Manager </value>
<username><cfoutput>#URL.Uname#</cfoutput></username>
</dashboard>
</application>
</cfif>

Listing 2

Login.CFM
<cfcontent type="application/xml">
<cfparam name="URL.Uname" default="">
<cfparam name="URL.Pword" default="">
<cfquery datasource="global" name="Login">
Select * 
From CFDJ_users
Where Username='#URL.Uname#'
AND Password ='#URL.Pword#'
</cfquery>
<cfquery datasource="global" name="Feed">
Select *
From CFDJ_RSS
Where Username='#URL.Uname#'
</cfquery>
<cfif Login.Recordcount GTE 1>
<application>
<dashboard>
<broadcast><cfoutput>Welcome To G-uniX Rss Manager</cfoutput>
</broadcast>
<username><cfoutput>#URL.Uname#</cfoutput></username>
<feed>
<cfloop query="Feed">
<name>
<cfoutput>#Rss_Name#</cfoutput>
</name>
<rlink>
<cfoutput>#Rss_Link#</cfoutput>
</rlink>
</cfloop>
</feed>
</dashboard>
</application>
<cfelse>
<application>
<dashboard>
<broadcast>
<cfoutput>The Username and Or Password Is Wrong Please Try Again</cfoutput>
</broadcast>
</dashboard>
</application>
</cfif>

Listing 3

ViewRSS.cfm
<cfcontent type="application/xml">
<cfparam name="URL.RSS" default="">
<cfhttp url="#URL.RSS#" method="get">
</cfhttp> 
<cfset feed = xmlParse(cfhttp.filecontent) />
<cfoutput>#feed#</cfoutput>

Listing 4

WriteRSS.cfm
<cfcontent type="application/xml">
<cfparam name="URL.Uname" default="">
<cfparam name="URL.Rlink" default="">
<cfquery datasource="global" name="DeleteRSS">
Delete
FROM CFDJ_RSS
Where Username='#URL.Uname#'
AND Rss_Link='#URL.Rlink#'
</cfquery>

Listing 5

Main.mxml

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
<mx:HTTPService id="Login" url="http://localhost:8500/httpserv/Login.cfm?Uname=
{Uname.text}&Pword={Pword.text}" useProxy="false">

</mx:HTTPService>
<mx:HTTPService id="Read" url="http://localhost:8500/httpserv/ViewRSS.cfm?feed=
{dg.selectedItem.rlink}" useProxy="false">

</mx:HTTPService>
<mx:HTTPService id="Save" url="http://localhost:8500/httpserv/WriteRSS.cfm?Uname=
{Uname.text}&rname= {Fname.text}&rlink={Furl.text}" useProxy="false">

</mx:HTTPService>
	<mx:states>
		<mx:State name="feed">
			<mx:SetProperty target="{Pword}" name="x" value="88"/>
			<mx:SetProperty target="{Pword}" name="y" value="623"/>
			<mx:SetProperty target="{Uname}" name="x" value="88"/>
			<mx:SetProperty target="{Uname}" name="y" value="593"/>
			<mx:SetProperty target="{label1}" name="x" value="10"/>
			<mx:SetProperty target="{label1}" name="y" value="595"/>
			<mx:SetProperty target="{label2}" name="x" value="10"/>
			<mx:SetProperty target="{label2}" name="y" value="625"/>
			<mx:AddChild position="lastChild">
				<mx:DataGrid x="0" y="0" id="dg" dataProvider="{Login.lastResult.application.dashboard.feed}"
				 click="Read.send()" height="585">
					<mx:columns>
						<mx:DataGridColumn headerText="Feed Name" dataField="name"/>
						<mx:DataGridColumn headerText="Feed Link" dataField="rlink"/>
					</mx:columns>
				</mx:DataGrid>
			</mx:AddChild>
			<mx:AddChild position="lastChild">
				<mx:DataGrid x="210" y="0" width="406" height="314"
				 dataProvider="{Read.lastResult.rss.channel.item}" id="dg2">
					<mx:columns>
						<mx:DataGridColumn headerText="Column 1" dataField="title"/>
						<mx:DataGridColumn headerText="Column 2" dataField="link"/>
						<mx:DataGridColumn headerText="Column 3" dataField="pubDate"/>
					</mx:columns>
				</mx:DataGrid>
			</mx:AddChild>
			<mx:AddChild position="lastChild">
				<mx:TextArea x="210" y="322" width="406" height="203" text="{dg2.selectedItem.description}"/>
			</mx:AddChild>
			<mx:AddChild position="lastChild">
				<mx:ApplicationControlBar x="210" y="533" width="406">
					<mx:LinkButton label="Add Feed" click="currentState='add'"/>
				</mx:ApplicationControlBar>
			</mx:AddChild>
			<mx:SetProperty target="{button1}" name="x" value="256"/>
			<mx:SetProperty target="{button1}" name="y" value="623"/>
			<mx:SetProperty target="{button1}" name="label" value="Back"/>
			<mx:SetProperty target="{Uname}" name="editable" value="false"/>
			<mx:SetProperty target="{Pword}" name="editable" value="false"/>
			<mx:SetProperty target="{Uname}" name="enabled" value="false"/>
			<mx:SetProperty target="{Pword}" name="enabled" value="false"/>
			<mx:SetEventHandler target="{button1}" name="click" handler="currentState=''"/>
		</mx:State>
		<mx:State name="add">
			<mx:SetProperty target="{Pword}" name="x" value="78"/>
			<mx:SetProperty target="{Pword}" name="y" value="593"/>
			<mx:SetProperty target="{label2}" name="x" value="0"/>
			<mx:SetProperty target="{label2}" name="y" value="595"/>
			<mx:SetProperty target="{button1}" name="x" value="182"/>
			<mx:SetProperty target="{button1}" name="y" value="623"/>
			<mx:SetProperty target="{Uname}" name="x" value="78"/>
			<mx:SetProperty target="{Uname}" name="y" value="563"/>
			<mx:SetProperty target="{label1}" name="x" value="0"/>
			<mx:SetProperty target="{label1}" name="y" value="565"/>
			<mx:SetProperty target="{button1}" name="label" value="Back"/>
			<mx:AddChild position="lastChild">
				<mx:Panel x="142.5" y="75" width="341" height="246" layout="absolute" title="Add A Feed">
					<mx:TextInput x="115.5" y="40" id="Fname"/>
					<mx:TextInput x="115.5" y="91" id="Furl"/>
					<mx:Button x="210.5" y="132" label="save" click="Save.send();Login.send();currentState='feed'"/>
					<mx:Label x="39.5" y="42" text="Feed Name"/>
					<mx:Label x="45.5" y="93" text="Feed URL"/>
				</mx:Panel>
			</mx:AddChild>
		</mx:State>
	</mx:states>
	<mx:TextInput x="233" y="214" id="Uname"/>
	<mx:TextInput x="233" y="244" id="Pword"/>
	<mx:Label x="155" y="216" text="Username" id="label1"/>
	<mx:Label x="155" y="246" text="Password" id="label2"/>
	<mx:Button x="328" y="274" label="Login" click="Login.send();currentState='feed'" id="button1"/>

</mx:Application>