Connect php & xml with Flex
Dear Friends,
i am doing a ticker in Flex, i want to connect the xml
generated by php and fetch the data and display in data grid. iam
new to Flex. Kindly help me to do this assignment..
Thanks and Regards,
Syed Abdul Rahim
In Flex Builder help take a look at HTTPService class. You
use this class to hit a URL on a server, and listen in the result
event for the data sent by the URL.
ATTA
Similar Messages
-
Dear Friends,
iam doing my first project in flex. trying to connect a xml
generated by php connected to mysql. i took an example from the
following link:
http://www.adobe.com/cfusion/communityengine/index.cfm?event=showDetails&postId=5561&produ ctId=2&loc=en_US
my xml is generated. working fine. when i run my Flex, it is
not working. it is giving the following error
Process terminated without establishing connection to
debugger.
Command:
"C:\Program Files\Adobe\Flex Builder
3\sdks\3.2.0\bin\adl.exe"
C:\Rahim\TestApplications\Flexapplication\xmltest\bin-debug\xmltest-app.xml
C:\Rahim\TestApplications\Flexapplication\xmltest\bin-debug
Output from command:
invocation forwarded to primary instance
my flex file is :
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
initialize="doSend()"
layout="absolute">
<mx:Script>
<![CDATA[
import mx.collections.ArrayCollection;
import mx.rpc.events.ResultEvent;
[Bindable]
private var datalist:ArrayCollection;
private function resultHandler(event:ResultEvent):void{
datalist = event.result.data.row;
public function doSend():void {
xmlFromDatabase.url = "
http://localhost/flex/flexdb.php";
xmlFromDatabase.send();
]]>
</mx:Script>
<mx:HTTPService url="
http://localhost/flex/flexdb.php"
id="xmlFromDatabase"
showBusyCursor="true"
result="resultHandler(event)"
method="GET" />
<mx:DataGrid x="10" y="10" dataProvider="{datalist}"
id="dg">
<mx:columns>
<mx:DataGridColumn headerText="Col1" dataField="id"/>
</mx:columns>
</mx:DataGrid>
</mx:Application>
Thanks and Regards,
Syed Abdul Rahimhi _funkyboy ,
thks for ur msg. i tried using run also.. still not
running... can u pls advice me wt to do. i got struct up.. i have
to do this.
tell me how to connect xml which was generated by php and
fetch the data and display in Flex.
thanks and regards,
Syed Abdul Rahim -
Adobe Designer 7.0 - XML parsing error when data connection to XML with UTF-16
Hi all
<br />
<br />I need to change my data connection xml file to use UTF-16 instead of ISO-8859-1. When I connect the file with the UTF-16 encoding, I receive the following error
<br />
<br />Invalid XML: Xml parsing error: encoding specified in XML declaration is incorrect (error code 19) ..
<br />
<br />The XML declaration is:
<br /><?xml version="1.0" encoding="utf-16"?>
<br />
<br />I am able to succesfully set the encoding to "UTF-8". UTF-16 should also be possible.
<br />
<br />Has anyone seen this error before ? How can I resolve this ?
<br />
<br />Thanks in advance
<br />
<br />Bilal HaniffThank you, expert, for your quick reply.
Described problem got solved: we noticed later that the extra text only appears for users using Adobe professional 7.0, 'normal' users with adobe 8.0 reader don't get the extra text, so that is ok for us. -
How to configure PHP Server with Flex
Hello everyone,
I am trying to create new flex application with PHP as server option.
but on the Configure PHP server window it gives error as
" You must enter a valid root URL."
I am usingh xampp as php server, and i have changed the port no of apache to 90.
so my web root is //localhost:90
\xampp\htdocs\phpProject-debug
Can anyone help me to configure the PHP server with Flash builder 4
I am not using Zend server...Hello Rupesh,
You need to specify full url like this "http://localhost:90/" and need to start server before validating.
This check may be missed by you.
Thanks,
Vikram -
Using XML with Flex - Best Practice Question
Hi
I am using an XML file as a dataProvider for my Flex
application.
My application is quite large and is being fed a lot of data
– therefore the XML file that I am using is also quite large.
I have read some tutorials and looked thorough some online
examples and am just after a little advice. My application is
working, but I am not sure if I have gone about setting and using
my data provider in the best possible (most efficient) way.
I am basically after some advice as to weather I am going
about using (accessing) my XML and populating my Flex application
is the best / most efficient way???
My application consists of the main application (MXML) file
and also additional AS files / components.
I am setting up my connection to my XML file within my main
application file using HTTPService :
<mx:HTTPService
id="myResults"
url="
http://localhost/myFlexDataProvider.xml"
resultFormat="e4x"
result="myResultHandler(event)" />
and handling my results with the following function:
public function myResultHandler(event:ResultEvent):void
myDataFeed = event.result as XML;
within my application I am setting my variable values by
firstly delacring them:
public var fName:String;
public var lName:String;
public var postCode:string;
public var telNum:int;
And then, giving them a value by “drilling” into
the XML, E;g:
fName = myDataFeed.employeeDetails.contactDetails.firstName;
lName = myDataFeed.employeeDetails.contactDetails.lastName;
postCode =
myDataFeed.employeeDetails.contactDetails.address.postcode;
telNum = myDataFeed.employeeDetails.contactDetails.postcode;
etc…
Therefore, for any of my external (components in a different
AS file) components, I am therefore referencing there values using
Application:
import mx.core.Application;
And setting the values / variables within the AS components
as follows:
public var fName:String;
public var lName:String;
fName =
Application.application.myDataFeed.employeeDetails.contactDetails.firstName;
lName =
Application.application.myDataFeed.employeeDetails.contactDetails.lastName;
As mentioned this method seems to work, however, is it the
best way to do it??? :
- Connect to my XML file
- Set up my application variables
- Give my variables values from the XML file ……
Bearing in mind that in this particular application there are
many variable that need to be set and there for a lot of lines of
code just setting up and assigning variables values from my XML
file.
Could someone Please advise me on this one????
Thanks a lot,
Jon.I don't see any problem with that.
Your alternatives are to skip the instance variables and
query the XML directly. If you use the values in a lot of places,
then the Variables will be easier to use and maintain.
Also, instead of instance variables, you colld put the values
in an "associative array" (object/hashtable), or in a dictionary.
Tracy -
Cannot Connect to Coldfusion with Flex 2
I am attempting to call a coldfusion component using
RemoteObject and I am
getting the error where cannot communicate with Coldfusion.
[RPC Fault faultString="[MessagingError message='Unknown
destination
'Coldfusion'.']" faultCode="InvokeFailed"
faultDetail="Couldn't establish a
connection to 'Coldfusion'"]
I know everything is running correctly and the application
and cfc is
located in the coldfusion wwwroot.
I have looked this up online and found many articles about
it, but they all
seem to be from Beta 2. The compiler solution is already done
and I have
editted the services-config.xml to include the path of my Cf
server.
CF is running just fine and I restarted both the coldfusion
server and the
flex builder 2 program after all the changes.
Any ideas on where I can find information pertaining the
released version of
Flex 2?
Here is my actual path to my application:
C:\CFusionMX7\wwwroot\flexbtb\flex
Here is my URL:
http://localhost:8501/flexbtb/flex
Here is the modified version of the services-config.xml file
inside the
coldfusion directory
<?xml version="1.0" encoding="UTF-8"?>
<services-config xmlns="
http://www.macromedia.com/2005/flex-service-config">
<services>
<service id="coldfusionsamples-service"
class="flex.messaging.services.RemotingService"
messageTypes="flex.messaging.messages.RemotingMessage">
<adapters>
<adapter-definition id="cf-object"
class="coldfusion.flash.messaging.ColdFusionAdapter"
default="true"/>
</adapters>
<destination id="ColdFusion">
<channels>
<channel ref="my-cfamf"/>
</channels>
<properties>
<source>*</source>
<!-- define the resolution rules and access level of the
cfc being
invoked -->
<access>
<!-- Use the ColdFusion mappings to find CFCs, by default
only CFC files
under your webroot can be found. -->
<use-mappings>false</use-mappings>
<!-- allow "public and remote" or just "remote" methods to
be invoked -->
<method-access-level>remote</method-access-level>
</access>
<property-case>
<!-- cfc property names -->
<force-cfc-lowercase>false</force-cfc-lowercase>
<!-- Query column names -->
<force-query-lowercase>false</force-query-lowercase>
<!-- struct keys -->
<force-struct-lowercase>false</force-struct-lowercase>
</property-case>
</properties>
</destination>
</service>
</services>
<security>
<login-command
class="flex.messaging.security.JRunLoginCommand"
server="JRun"/>
</security>
<channels>
<channel-definition id="my-cfamf"
class="mx.messaging.channels.AMFChannel">
<endpoint uri="
http://localhost:8501{context.root}/flex2gateway/"
class="flex.messaging.endpoints.AMFEndpoint"/>
<properties>
<polling-enabled>false</polling-enabled>
<serialization>
<custom-deserializer type="typed-object"
class="coldfusion.flash.messaging.io.amf.serializers.TypedObjectDeserializer"
/>
</serialization>
</properties>
</channel-definition>
</channels>
<logging>
<target class="flex.messaging.log.ConsoleTarget"
level="Debug">
<properties>
<prefix>[Flex] </prefix>
<includeDate>false</includeDate>
<includeTime>false</includeTime>
<includeLevel>false</includeLevel>
<includeCategory>false</includeCategory>
</properties>
<filters>
<pattern>Endpoint.*</pattern>
<pattern>Service.*</pattern>
<pattern>Configuration</pattern>
<pattern>Message.*</pattern>
</filters>
</target>
</logging>
<system>
<locale>
<default-locale>en</default-locale>
<supported-locale>de</supported-locale>
<supported-locale>fr</supported-locale>
<supported-locale>es</supported-locale>
</locale>
<redeploy>
<enabled>true</enabled>
<watch-interval>20</watch-interval>
<watch-file>{context.root}/WEB-INF/flex/flex-enterprise-services.xml</watch-file>
<touch-file>{context.root}/WEB-INF/web.xml</touch-file>
</redeploy>
</system>
</services-config>
Wally Kolcz
MyNextPet.org
Founder / Developer
586.871.4126I've just fixed mine go to settings general then at bottom of page click reset and follow on screen this worked for me after everything else failed
-
Ok I've gone through Ed's awesome Flex tutorial in the wiki but for some reason I simply can't nail this one.
<mx:Label y="10" text="Craig's Movie List" id="lblTitle" enabled="true" horizontalCenter="0" fontSize="19" fontFamily="Arial" fontWeight="bold" fontStyle="italic"/>
<mx:HTTPService id="httpRSS" url="http://creator.zoho.com/ccmehil/rss/30/" resultFormat="e4x" />
<mx:DataGrid id="entries" verticalCenter="11" horizontalCenter="0" width="480" dataProvider="{httpRSS.lastResult.channel.item}" height="230">
<mx:columns>
<mx:DataGridColumn headerText="Name" dataField="title" width="300"/>
<mx:DataGridColumn headerText="Rating" dataField="zc:Rating" width="50"/>
<mx:DataGridColumn headerText="Type" dataField="zc:Genre"/>
<mx:DataGridColumn headerText="Runtime" dataField="zc:Runtime"/>
</mx:columns>
</mx:DataGrid>
The RSS looks like
<item>
<title>Winnie the Pooh - A New friend for Winnie Pooh</title>
<link>http://creator.zoho.com/ccmehil/view/30/record/7987000000110023/</link>
<description><b>Title</b> : Winnie the Pooh - A New friend for Winnie Pooh<br/><b>Genre</b> : Zeichentrick<br/><b>Rating</b> : G<br/><b>Director</b> : <br/><b>Year</b> : <br/><b>Runtime</b> : 65<br/><b>Status</b> : Available</description>
<guid isPermaLink="true">http://creator.zoho.com/ccmehil/view/30/record/7987000000110023/</guid>
<zc:Title>Winnie the Pooh - A New friend for Winnie Pooh</zc:Title>
<zc:Genre>Zeichentrick</zc:Genre>
<zc:Rating>G</zc:Rating>
<zc:Director></zc:Director>
<zc:Year></zc:Year>
<zc:Runtime>65</zc:Runtime>
<zc:Status>Available</zc:Status>
</item>
So why can't I access the zc elements? What am I missing?check this documentation on how to handle namespace
http://livedocs.adobe.com/flex/201/html/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Book_Parts&file=dataservices_099_17.html -
Howdy everyone!
I've only been playing with Flex for about 6 weeks or so and
I've figured out lots and lots from the online tutorials and help
system. However the project that I'm trying to put together
requires that I can pass data back and forth to Db's. I haven't
even tried to write into a database yet because for the last 3
weeks I've been trying every combination (except the working one's)
to write my Db data into XML and use an HTTPService tag to retrieve
it for use as dataProviders. I've tried everything remotely related
on this site. Several others I've found online and modified the
resultFormat and my variable types in every combination
(resultFormat = "[' ', Object, xml, e4x, text, array]" &
myDP:[ArrayCollection, Array, XML, XMLList, XMLListCollection]) and
have received as many errors & nonworking results for my
efforts. I'm not sure if perhaps there's a PHP/MySQL setting on my
server that's not set how it should be? or if I just have failed to
notice some simple detail.
Here's the PHP version I currently believe most promising:
quote:
<?php
require_once('Connections/peaceheartconnection.php');
header("Content-type: text/xml");
mysql_select_db($database_peaceheartconnection,
$peaceheartconnection);
$query_topics = "SELECT * FROM p_insight_topics";
$topics = mysql_query($query_topics, $peaceheartconnection)
or die(mysql_error());
$row_topics = mysql_fetch_assoc($topics);
$totalRows_topics = mysql_num_rows($topics);
mysql_select_db($database_peaceheartconnection,
$peaceheartconnection);
$query_categories = "SELECT * FROM p_insight_types";
$categories = mysql_query($query_categories,
$peaceheartconnection) or die(mysql_error());
$row_categories = mysql_fetch_assoc($categories);
$totalRows_categories = mysql_num_rows($categories);
print("<?xml version=\"1.0\" encoding=\"utf-8\"?>");
$dataXML = '';
$dataXML .= "<data><categories>";
while($cat = mysql_fetch_object($categories))
$dataXML .= "<category>$cat->type</category>"
$dataXML .= "</categories>";
$dataXML .= "<topics>";
while($topic = mysql_fetch_object($topics))
$dataXML .="<topic>$topic->topic</topic>";
$dataXML .= "</topics></data>";
?>
<?php
echo $dataXML;
?>
<?php
mysql_free_result($topics);
mysql_free_result($categories);
?>
This gives me results that show up in the browser identical
to
An XML file from
"Flex 2 Training from the Source" (I event get the "no
associated style information ... document tree is shown" message
from Firefox).
Here are the relevant parts of the Flex app:
quote:
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
xmlns:ns1="Components.*" layout="absolute" autoLayout="true"
horizontalScrollPolicy="off" verticalScrollPolicy="off"
creationComplete=" getData()" >
<!-- Service Definitions -->
<mx:HTTPService id="getTypesNTopics" url="../../data.xml"
method="POST" useProxy="false"
result="showData(event)" fault="handleFault(event);" />
<mx:HTTPService id="getTypesNTopics2"
url="../../topicsNcategories5.php" method="POST" useProxy="false"
result="showData2(event)" fault="handleFault2(event);" />
<!-- End Service Definitions-->
<mx:Script>
<![CDATA[
import mx.collections.XMLListCollection;
import mx.effects.*;
import mx.effects.easing.*;
import mx.containers.*;
import mx.core.*;
import mx.rpc.events.ResultEvent;
import mx.rpc.events.FaultEvent;
import mx.events.FlexEvent;
import mx.controls.Alert;
import flash.events.*;
import mx.managers.DragManager;
import mx.events.DragEvent;
import mx.collections.ArrayCollection;
import mx.rpc.events.ResultEvent;
import mx.rpc.events.FaultEvent;
[Bindable] private var topicsAC:ArrayCollection = new
ArrayCollection();
[Bindable] private var categoryAC:ArrayCollection = new
ArrayCollection();
[Bindable] private var topics2AC:XMLListCollection = new
XMLListCollection();
public function getData():void
getTypesNTopics.send();
getTypesNTopics2.send();
private function showData2(event:ResultEvent):void
//topics2AC = event.result.data.topics.topic;
lastResultValue2.text = "Event, Categories:"
+event.result.data.categories.category
+ "Event, Topics:" + event.result.data.topics.topic;
scrollMenu.dataProvider = event.result.data.topics.topic;
lastResultValue2.text = "Result: " +
String(event.result.data.topics.topic);
private function handleFault2(event:FaultEvent):void
lastResultValue2.text = "Error: " + event.fault;
(Keep in mind that the function & service tag contents
are just the latest version as of 20 mins ago.)
Any help would be greatly appreciated. There are still dozens
of other things I want to get working on but there's no point until
I can get my app. to talk with mySQL (databases). I'm begging
PLEASE after weeks of wasting time trying to get my <topic>
& <category> nodes to populate two ComboBoxes I just
wrote a static XML file last night--just so I could feel like I had
accomplished something (that's what the first Service tag does).
Thanks 2^65536 times!
ToddAs it is posted right now (resultFormat (rF) = default object
with the result assigned directly), I don't receive an error but
lastResultValue.text & scrollMenu (a comboBox) both read
"$topic->topic."
With rF = default (object) & topics2AC:ArrayCollection
(assigned to the text & CB) I get: "Type Coercion failed:
cannot convert "$topic->topic" to
mx.collections.ArrayCollection. ..."
With rF = e4x, data type (dT) = arrayCollection I get:
"Error: [RPC Fault faultString="Error #1088: The markup in the
document following the root element must be well-formed."
faultCode="Client.CouldNotDecode" faultDetail="null"] "
(e4x is the format that I WANT to use, but anything working
will suffice for now)
rF = xml, dT = AC: "Property data not found on
flash.xml.XMLDocument and there is no default value."
With the "xml version" tag removed rF = e4x, dT =
XMLListCollection I get " Error #1034: Type Coercion failed: cannot
convert "$topic->topic" to mx.collections.XMLListCollection."
Likewise with dT=arrayCollection: "Error #1034: Type Coercion
failed: cannot convert "$topic->topic" to
mx.collections.ArrayCollection." (Same with dT=XMLList)
The underlying code(source) of the PHP page's output is:
"<data><categories><category>Poem</category>
...</categories><topics><topic>Teaching</topic>...<topic>Kids</topic></topics></data>"
There's an empty line above the source. The <?xml version="1.0"
encoding="utf-8"?> tag is/isn't there depending on whether I
leave it in or not. I don't know how/why the empty line is there.
The general result seems to be that I get either "cannot
decode" using e4x, "cannot convert $topic->topic" using anything
else. Perhaps the problem is still in the PHP, but Firefox
recognizes & treats it as valid XML giving me the "
This XML file does not appear to have any style information
associated with it. The document tree is shown below.
−
<data>
−
<categories>
<category>Poem</category>
<category>Song</category>
<category>Prayer</category>
<category>Idea</category>
<category>Whim</category>
<category>Enlightenment</category>
<category>Quote</category>
<category>Answers</category> ..." when I call the
page. So I'm at a loss as to what to even try anymore.
Thanks again anyone, everyone
Merry Christmas, Happy Hannukah, Happy Holidays, etc.
Todd -
Check What PHP function returned with Flex Mobile Project
Hello, I'm connected to PHP service and Im calling function login that is returning "yes" or "no".
My question is, how to check what was returned with Flex, this is what I have:
protected function button_clickHandler(event:MouseEvent):void
loginResult.token = employeeService.login(Name.text, pass.text);
What to do next?
Thank youThanks Keith, I'll have a look at that. In addition to opening a PDF, I want to be able to encode an anchor id in to the open command to jump a specific anchor; I'd concluded that on iOS, until Adobe add decent url-scheme support, that was a no go - so I've been staring down the barrel of converting the .pdf to HTML and tidying up the inevitable issues manually. Here's hoping Print2Flash will help avoid that!
-
Flex + amfphp vs. flex +php&xml
Here's the deal. I hear how great amfphp is, and how much
easier it is to develop flex applications with a PHP back end by
using amfphp, but I don't understand it at all. On the other hand,
I DO understand how to use POST in Flex to make PHP mysql queries,
convert the results into xml and then use the xml in flex. It seems
SO straightforward and easy to understand compared with
understanding everything going on in amfphp, but I can see that it
will be a pain to do all the coding to get what I want done doing
it that way. So is it worth it to figure out amfphp and flex
remoting, or should I just churn out the code using what I know?
I want to do things the smart way, but I looked at a couple
amfphp tutorials and I have absolutely no clue what is going on. I
feel like I have wasted the whole night, and not learned anything,
while I could have been working on the code to do it with xml. The
explanations in those tutorials seem to assume a HUGE amount of
knowledge that I don't have, and I can't really find tutorials that
explain things in newbie language. Plus, I don't even know what
other tutorials I should look at and understand before I even start
to understand the amfphp tutorials, so I'm not sure the amount of
time its going to take for me to learn everything I need.
To top it all off, I don't really even get what the benefit
is... Look at the code below from one tutorial -
http://www.sephiroth.it/tutorials/flashPHP/flex_remoteobject/page003.php.
Aside from the fact that I barely understand what is going on, just
how is this easier than outputting xml?Maybe this will help explain...
http://blogs.adobe.com/mikepotter/2006/07/php_and_flex_js.html
Scott -
Issue with parameter passing in ie7 to php xml
Hi
I wondered if anyone could offer a little advice what the issue is here.
I have a page with xml generated from php in a separte file and presented by a dataset in spry.
The xml is OK and in firefox it all works but ie seems to barf on it.
The situation is this:
I have a jump menu on a front page that provides a url with anumeric parameter passed like this
platforms.php?platform_id=1
This parameter is picked up by php on the platforms.php page using the $_GET Array and is passed into the code in my Spry dataset to the file that runs my query and returns my xml- so basically the page displays a dataset filtered on this parameter id.
It works perfectly in FF.
In IE if I link straight to the page without a parameter at all- so platforms.php the page loads OK using the default parameter I have set up in the top of this page to send the default id of 1 to the code page so the spry query says platform_sql.php?platform_id=1 and the xml generator is fine with thisiel. ie I do a
if(isset($_GET['platform_id'])){
$platform=$_GET['platform_id'];
}else{
$platform=1;
The dataset loads Ok in IE but when I pass a parameter in the url from my jump menu IE gives a blank SPRY table i- it momentarily appears with just the placeholders for my dataset elements then vanishes. The source code of the page shows the correct id was set in the spry data going to my query file.
There is an error in ie saying there is a javascript error but its not any help- in ie fashion- FF shown no such errors.
I thought this might be a data type thing again in the dataset but its not - I have set the elements returned to simple strings but it still does not work.
Is there a problem passing in a parameter like this to a spry dataset?After about half a day of mucking round I found the problem and a solution to this problem.
What appeared to have happened was that some of the older content in my database used html originally encoded using a WYSWYG editor called ktml.
Later data uses Tiny MCE. It looks like the character set of the two formats is slightly different and as a result some characters rendered incorrectly when passed through XML parsing where it specifies the character set as utf-8.
Firefox on the whole seems to ignore the issue though looking at the raw xml output of my php-xml code- where "-" characters were (dashes) there was a question mark character shown. None the less in actual use on my page the xml was produced and the dataset worked out.
In IE, it barfed at these same characters and failed to return the xml dataset.
What confused the issue more was some of my smaller datasets if they by chance never had a "-" character in rendered OK in IE- hence my default dataset (platform_id=1) worked in IE. After much experimenting I noticed other ids worked too if there was never such a character.
How I got round it was to wrap my server side data in the utf8_encode() function, and now all my xml is clean.
The javascript error being thrown was a red herring though I could not tell until I managed to run my page in ie7 with Visual Studio Express error console running- I had this on a spare machine at work so could debug with it.
All sorted now- now just need to find away to wrap all my datasets in collapsible panels that work.
K -
Help with Flex Ant build.xml error
So I've started on a new project and I'm new to Flex. A lot of learning curve here. Anyway, I'm trying to deploy a project that uses flex and is built with Ant. We've moving up from a version of Flex 2 to Flex 3. The build file works fine in the Flex 2 app but for some reason does not seem to be working with Flex 3. I'm hoping someone can give me some insight on what might be wrong or where to start.
The error is Command not found: compc
The part of the build file it has a problem with is:
<compc include-classes="${classes}"
ouput="${flex.dist.dir}/${flex.app.name}.swc"
keep-generated-actionscript="false"
headless-server="${headless.server}"
incremental="true">
<load_config filename="${FLEX_HOME}/frameworks/flex-config.xml" />
<source-path path-element="${FLEX_HOME}/frameworks" />
<source-path path-element="${flex.app.root}" />
<compiler.library-path dir="${FLEX_HOME}/frameworks" append="true">
<include name="libs" />
<include name="../bundles/{local}" />
</compiler.library-path>
<compiler.library-path dir="${flex.app.root}" appent="true">
<include name="libs" />
</compiler.library-path>
</compc>
Any help at all would be greatly appreciated, thank you.Sorry, I meant to address that. Yes, since we've moved up to the Flex 3 sdk, we are pointing at a new directory. The old directory was flex_sdk and the new directory is flex_sdk_340.
FLEX_HOME is being set in the build.properties file for local building and then overidden in the build.xml file with this code:
<target name="build">
<available property="FLEX_HOME" value="/apps/flex_sdk_340" file="/apps/flex_sdk_340" />
<echo>FLEX_HOME = ${FLEX_HOME}</echo>
<antcall target="compile" />
</target>
I did notice a warning about not using the available property, so I removed it and just changed what FLEX_HOME was set to in the build.properties file to the server directory. Would mess up local building but regardless it didn't matter because it had no effect on the error being generated. I alos looked a little into the file property of the available tag trying to figure out if that was somehow an issue but I wasn't able to come to any conclusion.
Before the program errors out, it does displayt he echo statement and the value of FLEX_HOME appears to be correct in that it does show /apps/flex_sdk_340.
Thank you so much for your continued help. This is truly frustrating because nothing but a directory name has really changed and yet it stopped working. I can't find any information anywhere on what could be wrong and this is really my last resort. -
Connection SQLite with Flex Web Based App??
Hi! I have a problem, I create a Flex Web Based App in Flash Builder 4 and I need connect that app with my SQLite database... but I can't found the method that permit me create that connection.
My question is... exist some method or some kind of code with I can do the connection?
Can someone help me, please?SQLLite is only available in AIR apps.
The preferred method for a web-app is to use some kind service architecture to expose your data. I wouldn't be able to offer any specific advise without knowing more about your deployment environment. -
Error in connecting the database with context.xml resource
Dear everyone,
i am trying to connect the application with database...
i have a table with employee id, name...
i have given context xml and established connection..
but i am getting error as
* " Element type "Resource" must be followed by either attribute specifications, ">" or "/>"."
* "The context.xml file seems to be broken. Check whether it is well-formed and valid."
anyone please give ur suggestions....the error that i received now was...
HTTP Status 500 -
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jasper.JasperException: Unable to compile class for JSP:
An error occurred at line: 34 in the jsp file: /index.jsp
Context cannot be resolved to a type
31: int i=0;
32:
33:
34: Context ctx = new InitialContext();
35: DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/employee");
36:
37: try
An error occurred at line: 34 in the jsp file: /index.jsp
InitialContext cannot be resolved to a type
31: int i=0;
32:
33:
34: Context ctx = new InitialContext();
35: DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/employee");
36:
37: try
An error occurred at line: 35 in the jsp file: /index.jsp
DataSource cannot be resolved to a type
32:
33:
34: Context ctx = new InitialContext();
35: DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/employee");
36:
37: try
38: {
An error occurred at line: 35 in the jsp file: /index.jsp
DataSource cannot be resolved to a type
32:
33:
34: Context ctx = new InitialContext();
35: DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/employee");
36:
37: try
38: {
Stacktrace:
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:435)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:298)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:277)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:265)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:564)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:299)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:315)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.23 logs. -
Flex tree displaying raw XML with tags
For some reason, after I setup a tree control and set its
dataprovider to an XML that a coldfusion component is returning,
the tree will display the raw XML in one node (including tags and
everything) instead of formatting it into folders and files. At
first I thought the coldfusion component was formatting the XML
incorrectly but after I used one of the example XML's in the adobe
docs, it will still display the RAW xml. This is the code where I
define the tree control:
<mx:Tree x="0" y="10" width="266" height="223"
id="courseTree" dataProvider="{myxml}"/>
and even using this example XML from the livedocs it still
doesnt format it and display folders and entries, it will display
the raw XML with tags:
<mx:XML id="myxml">
<Company label="Macromedia">
<Branch label="Newton">
<Department label="Flex Doc">
<Title label="Intern">
<Name label="Kapil Virdi"></Name>
</Title>
</Department>
</Branch>
</Company>
</mx:XML>I also tried the following format for the XML as the
datasource, and it still only displays the raw XML and not format
it into folders
<node>
<node label="Finance" dept="200">
<node label="John H" />
<node label="Sam K" />
</node>
<node label="Engineering" dept="300">
<node label="Erin M" />
<node label="Ann B" />
</node>
<node label="Operations" dept="400" isBranch="true" />
</node>
Maybe you are looking for
-
Error while calling IdcService: COLLECTION_ADD_LINK
Hi, I am trying to add a link to a document inside a folder using COLLECTION_ADD_LINK service but getting the following error response of service call. @Properties LocalData StatusCode=-32 StatusMessage=Error receiving response from server. (Unable t
-
I recently purchased a 13" MacBook Pro. It is the 2.53 Ghz with 4 GB of RAM. If I install Windows XP using Bootcamp, will I be able play Left 4 Dead 2 on it?
-
Is French Canadian Language (FR-CA) Supported?
We can use the portal content translation tool in EP6 to translate texts in languages other than English. Then we can change personalize portal to set the language to French Canadian (fr-ca). The problem is, that the portal content translation tool
-
RAW Thumbnails in Windows Explorer?
I had this problem when I first got my Nikon D40x in June, I couldn't see thumbnails in my Windows Explorer. Then one day during the summer, on its own it seems, I was able to see thumbs, and its been that way until recently when I had to reinstall X
-
Hello Experts, we are on SAP Release 4.70 R2 (472). Want to apply SAP Notes to get SEPA Functionality. Did anyone have idea on what & how many SAP notes we need to apply to get SEPA Credit Transfer functionality in system. Current SP level of affec