We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29635
    • 361 Posts
    Hi all,
    I’ve searched high and low, and could use any advice you all can offer.

    I need to pull information from this page or this page into a site I’m putting together here. (The first two links are both "owned" by the third, so it’s "ethical" wink .)

    So, the standard trick would be to pull it in with PHP or some jQuery or something, but in this case I only want to pull a little bit of the data, and I want to mark it up with classes and divs and such.

    So my thoughts are:

    • 1... A bunch of regular expressions with PHP, then exploding it into an array that I can manipulate. Unfortunately, arrays and regular expressions are two of my worst areas.
    • 2... Better, I think: Using jQuery to apply classes based on the DOM.
    • 3... Probably the best: Using strip_tags() in PHP to strip all the HTML from the page, then maybe using PHP to explode the result into an array.
    Does anybody have any better ideas or advice?

    Sincere thanks for any help.
    -Brett

    EDIT: I got it working with option #3 from above for the time being, but I think Guillaume’s project will be better for most uses.
      Need MODx Ecommerce? Try FoxyCart!
      • 7923
      • 4,213 Posts
      There is a module/snippet set for this in the works.. Contact Guillaume and ask if you could be a beta tester for it (actually, I think that the code side is allready at final stage, just the documentation need some work). But it’s true that there is the "ethical" side of this to consider too.. though I have nothing to contribute on that.


        "He can have a lollipop any time he wants to. That's what it means to be a programmer."
        • 29635
        • 361 Posts
        Thanks for that suggestion Doze. I’m really interested to see how other people would tackle a problem like this.
          Need MODx Ecommerce? Try FoxyCart!
          • 33175
          • 711 Posts
          Quote from: doze at Jul 11, 2006, 01:17 AM

          There is a module/snippet set for this in the works.. Contact Guillaume and ask if you could be a beta tester for it (actually, I think that the code side is allready at final stage, just the documentation need some work). But it’s true that there is the "ethical" side of this to consider too.. though I have nothing to contribute on that.
          Excatelly, I need beta (?) tester smiley
          It is excat that the documentation need another work. I am french an my english is ... bad embarrassed
            Sorry for my english. I'm french... My dictionary is near me, but it's only a dictionary !