Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About sifar786

  • Rank
  1. my focus is across a whole 3 years (156 weeks) of data, beginning January 1st 2011 (or nearest date) and ending December 31st 2013 (or nearest date) – so while we are looking at 3 years total, we will only end up with 52 weeks in our clean version of the data, labelled Week 1 to Week 52 (and not dates).there will be items in this list that launched before 1st Jan 2011, for which part of the launch year will show up in the period we’re focused on. In order that data percentiles (will be calculated at later stage) are not clouded by this, we also need to move any part year data from launches pre
  2. Thanks!!! Thats plain logic stated by you. Glad that you are adding to my learning curve :)Cheers!
  3. Ok.But why does the > and > works on both IE & FF, and not the < and < Seems to me that if '>' should work on both, then so should '<' ..... some bug i guess!!!
  4. No, i am just learning XML, XSLT thru the websites W3SCHOOLS & TIZAG.so i am just changing it on this online translator or copying it to a file and testing it on my localhost having XAMPP.Firefox 3.5.7 error: Error in XSLTXML Parsing Error: not well-formed Location: http://www.w3schools.com/xsl/tryxslt_result.asp Line Number 15, Column 25: Internet Explorer 8 error: Error in XSLTLine 15: The character '<' cannot be used in an attribute value. Now, the funny part is that this works both in IE & FF, <xsl:if test="price > 10"> But this doesn't! <xsl:if test="price &
  5. Thnx a bunch dude. You Rock! :)It works now! BTW, did you find out about the < not working in the IE, FF in my previous post?
  6. Hi all,I have the following flavor.xml file: <?xml version="1.0"?><?xml-stylesheet type="text/xsl" href="flavor.xsl"?><recipe> <ingredients> <item>Boneless chicken breasts</item> <item>Chopped onions</item> <item>Ginger</item> </ingredients> <process> <step>Cut chicken into cubes, wash and apply lime juice and salt</step> <step>Add ginger, garlic, chili, coriander and lime juice in a separate bowl</step> <step>Mix well, and add chicken to marinate for 3-4 hours</step> <step>Pla
  7. yeah. Instead of <xsl:if test="price > 10"> i m using <xsl:if test="price < 10"> The browser versions are: Firefox version: 3.5.7Internet Explorer: 8
  8. Here's the link:IF exampleThe XML file:-------------- <?xml version="1.0" encoding="ISO-8859-1"?><!-- Edited by XMLSpy® --><catalog> <cd> <title>Empire Burlesque</title> <artist>Bob Dylan</artist> <country>USA</country> <company>Columbia</company> <price>10.90</price> <year>1985</year> </cd> <cd> <title>Hide your heart</title> <artist>Bonnie Tyler</artist> <country>UK</country> <company>CBS Records</company> <price>9.90<
  9. Yes in XSLT....its again a tutorial example on XSLT. Let me post it here or do you want me to start a new thread....?
  10. Thanks....i missed removing that part... :)BTW, just a question: why is it that > OR > works both in IE & FF and < OR < does not in IE & FF???
  11. Well, done it myself after some trial and error with XPATH problem :)And here's the tested code for people out there! <?php$xmlDoc=new DOMDocument();$xslDoc=new DOMDocument();$xmlDoc->preserveWhiteSpace = false;$xslDoc->preserveWhiteSpace = false;$xmlDoc->formatOutput = true;$xslDoc->formatOutput = true;function loadFile($xmlfile,$xslfile){extract($GLOBALS);//Load XML file // $xmlDoc is of type "Microsoft.XMLDOM" $xmlDoc->load($xmlfile);//Load XSL file // $xslDoc is of type "Microsoft.XMLDOM" $xslDoc->load($xslfile); //Transform file $xslt=new XSLTProcessor(); $xsl
  12. Nope. I tried that and it does not work! <?php$xmlDoc=new DOMDocument();$xslDoc=new DOMDocument();function loadFile($xmlfile,$xslfile){extract($GLOBALS);//Load XML file // $xmlDoc is of type "Microsoft.XMLDOM" $xmlDoc->load($xmlfile);//Load XSL file // $xslDoc is of type "Microsoft.XMLDOM" $xslDoc->load($xslfile); //Transform file $xslt=new XSLTProcessor(); $xslt->importStylesheet($xslDoc); print $xslt->transformToXML($xmlDoc);// return $function_ret;}function updateFile($xmlfile){extract($GLOBALS);//Load XML file // $xmlDoc is of type "Microsoft.XMLDOM" $xmlDoc->
  13. Hi,I was going through your tutorial onhttp://www.w3schools.com/xsl/xsl_editxml.aspwhich has tool.xml <?xml version="1.0" encoding="ISO-8859-1"?><tool> <field id="prodName"> <value>HAMMER HG2606</value> </field> <field id="prodNo"> <value>32456240</value> </field> <field id="price"> <value>$30.00</value> </field></tool> tool.xsl <?xml version="1.0" encoding="ISO-8859-1"?><xsl:stylesheet version="1.0"xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:template match="/"> <h
  14. Hi,problem with the Ajax PHP ResponseXML tutorial....nothing getting displayed...Actually, the reason why nothing is displayed is because you have not instructed PHP to output the data as text/xml, rather it is still outputting it as text/html.So inclusion of a header like this just before the while loop executes solves the problem... header("Content-type:text/xml");echo "<?xml version='1.0' encoding='ISO-8859-1'?>";
  • Create New...