[wp-hackers] Importing HTML files as pages -- been done?
Dan Gayle
dangayle at gmail.com
Fri Feb 6 18:29:15 GMT 2009
Why use PHP? DOM manipulation in jQuery is easy. The jQuery to do it
is light:
$(document).ready(function() {
$('.nav a').click(function() { //when you click on a link within
the .nav container
var url = $(this).attr('href'); //creates a variable of the
link's href attribute
$('#content').load(url + ' #contentInside'); //loads the
entire #contentInside content into #content, if #contentInside exists,
it replaces it
return false; //don't follow the link
}
);
);
On Feb 6, 2009, at 10:18 AM, Mike Schinkel wrote:
> I think you'll be better off using preg_match(). That's what most
> screen-scrapers use...
>
> -Mike Schinkel
> http://mikeschinkel.com/
>
> ----- Original Message -----
> From: "Stephanie Leary" <steph at sillybean.net>
> To: wp-hackers at lists.automattic.com
> Sent: Friday, February 6, 2009 12:52:29 PM GMT -05:00 US/Canada
> Eastern
> Subject: Re: [wp-hackers] Importing HTML files as pages -- been done?
>
> On Fri, 6 Feb 2009 09:50:17 -0800, Dan Gayle <dangayle at gmail.com>
> wrote:
>> Isn't that something that you could use AJAX for? That's a simple
>> jQuery thing to do using innerHtml
>
> I was thinking more along the lines of parsing the files as XML, but
> I'm
> open to suggestions.
>
>
> Stephanie
>
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
More information about the wp-hackers
mailing list