We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 11041
    • 82 Posts
    Hello all,

    Firstly apologies, it would appear that I may have originally posted in the wrong board. My enquiry relates to this thread http://modxcms.com/forums/index.php/topic,21594.0.html"" target="_blank" rel="nofollow">See this thread.

    But to cover the finer points again...

    I was wondering if anyone here was talented in the field of coding php and xml. I am needing a snippet, and although a huge mountain for me to climb, being completely php and xml illiterate, I am sure and know that this is only a small project for someone with the right knowledge and skills.

    The project, sumarised, would required for a snippet to output a form to the front end. Something along the lines of say

    <.form.>

    phone:

    postcode:

    [.Submit.]

    <./form.>

    When filled out and submit is clicked this then is passed back to the snippet (backend) and the values from the phone and postcode field are placed within a url query for example,

    http://api.domain.com/checker.do?phone=012345678998&postcode=S819PU&outp
    ut=xml&checks=adsl,adslmax,bulldog,be,easynet,homechoice,wanadoo&options=matc
    h,prereg,adsllinecheck,adslmaxlinecheck&user=XXXX&pass=XXXX

    This url is then sent to the url itself using HTTP POST (due to the amount of characters and security because of the username and password). Once queried the same url outputs a page containing xml which needs to be then placed back in the front end in place of the form but formatted.

    There are a couple of requirements, the first being that I am able to change the url with ease, as each little extra bit either calls for more or less data, for example I wanted to remove prereg, or say if that wasnt there then add it.

    The other requirement would be (and this is because im toying with the idea of an extensive search) that I would be able to add fields which would be included in the url, with ease.

    And just for clarification...

    The user puts their details in, which is then passed to the url to be queried. Once the url is queried it will return the results on the same page (the url that was queried) but in xml format. Its this xml output that I want to display for the user after they have submitted the details of the form.

    To give you further insight, the query performs a search on the phone number and post code given against a db and reports on the details held, for example, This Phone Line can handle up to 16Mb broadband but not 24mb. Active at your exchange is: BE, Bulldog, Sky, BT.

    Does this make sense?

    So im not displaying the information the user has inputted back to them, but rather more the results that the search on the db has brought up using the details they have supplied.

    Its been said that this may be possible with AJAX, however I would prefer the moethod that would not only be most secure but would also be most compatible (ie if Javascript is disabled then AJAX may be useless).

    If anyone feels they could do this, then please could you give me a quote?

    Many thanks,

    Tom.