HTML - How To Choose This From Xml Using Xpath?
Hi
I'm having trouble figuring out how to import a specific set of data from XML using xpath. I haven't been able to get my head around the examples I have been playing with. Here's an example of my XML: <X> <S> <A>Blah</A> <T>Blah</T> </S> <S> <A>Blah</A> <T>Blah</T> </S> <1a> <S> <A>Blah</A> <T>Blah</T> </S> <S> <A>Blah</A> <T>Blah</T> </S> </1a> <S> <A>Blah</A> <T>Blah</T> </S> </X> and php to import it: $xml = simplexml_load_file('test2.xml'); $result = $xml->xpath('S/A'); print_r($result); The above prints out the blah's in all the <A></A>'s. How do I get only the blah's in all the <A></A>'s that are between the <1a></1a> nodes? Various combinations I try give empty arrays. Thanks for your help. Shaun Similar Tutorialsas i am not very good in php and oither scripting. I browse through this forum and found the easier way to sent a form result via email is to add a mailto in form action <form action="mailto:acb@def.com"> Now my question is, can i do a droplist and put a several email for user to choose. after choose. then my action will send the email out according to what the user choose... I want the visitor to my website to be able to choose 2 live webcam streams from a text list of say 20 different streams, I have the code for each stream, what I would like is the 2 chosen streams to display on the same page side by side Hello everyone! First post on the forum, and wow, I spelled my username wrong Anyway, I am working on a new project, a rather adventurous and something out of my comfort zone one at that The website I am working on can be seen currently at it's development address - http://test.tinyentertainment.biz (Please note that most links, buttons, etc. do not work or are dead as it is of course, a development in it's early stages.) Anyway, my question is, is there a script or something else that would allow me to enter in a number of divs', and every time the page is reloaded, it will choose a random, or systematic, one to display? What I want to do, is if you notice on the home page of the website linked to above, below the large text under the flash banner, there is a quote- " "You're so afraid of taking chances, how you gonna reach the top?" -Greyson M. Chance" " I would like to have a number of different quotes to be displayed there when the page is reloaded. The current code is- Code: <div class="row"> <h3 class="center">We are a <span>fan community</span> dedicated to supporting <span>Greyson Chance</span> and his career.<b /> Don't forget to visit the <span><a href="http://www.thegreysonchanceforum.com" target="_blank" title="Visit The Forum - The Greyson Chance Forum" onMouseOver="window.status='Visit The Forum - The Greyson Chance Forum'; return true" onMouseOut="window.status=' '">forum</a></span> to chat with other fans.</h3> <p class="center"><em>"You're so afraid of taking <span>chances</span>, how you gonna reach the top?" -Greyson M. Chance</em></p> Thank you! Hello all, I'm try to use a form to choose what webpage is displayed in an iframe on the same page. What I have so far is not working: <form name="list" action="" method="get" target="repIframe" style="margin:0px;padding:0px"> <select name="zone"> <option value="./testadvisory.php?warnzone=UTZ019&warncounty=UTC053">St. George</option> <option value="./testadvisory.php?warnzone=UTZ013&warncounty=UTC043">Cedar City</option> </select> </form> <iframe name="repIframe" src="blank.html"></iframe> Could someone offer a suggestion ir procedure to allow the use of a form to choose the content of the iframe? Thanks, Randy I have a webpage at http://atlas.walagata.com/w/osmose/moosecorps/. It's a PHP page that sticks different code in the body depending on the page. The main page's newsbox does not appear correctly in IE6, but I can't figure out why - every cell but the one that should be stretched has a cell width defined. Any help would be appreciated. EDIT: Ugh, the Books page isn't working either. Again, help would be nice. please help choose a nice background color theme for my site... I'm not savy with html...I'm trying to find the code so I can change this "plain jane" background color of my "template made site". Can I get some opinions on a color theme and ALSO where I would insert the color codes. Not looking for a "in your face" attack..just anything better than the blah brown/tan colors! TIA I would like to know how to create a mini form of two pull down boxes so that when the two selections have been made and submitted it returns back a designated page or picture. For example I want to build a simple method to show routes of an office building. Pulldown box 1 would be the office number you want to start from, and pulldown box two would be the office you want to get to. when you click submit it would pull up either a page or picture which contains the corrrect floor plan and route. I feel like this should not be too hard as I don't need anything very flashy. I just don't know how to start it. If anyone knows of something open source already created to do this I would be open to that too. Thanks in advance for any assistence you can give. |