Embedding serendipity in another page

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
ebang

Embedding serendipity in another page

Post by ebang »

Is there a way that I can embed only my "news" category in an php page. Right now, I have my blog at http://blog.hungryhungryhypocrites.com and I'm wondering if I can embed only the news category entries in my http://news.hungryhungryhypocrites.com/news.php while having all of the entries on the blog.hhh.com page. Thanks
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Embedding serendipity in another page

Post by garvinhicking »

How do you embed your pages currently?

You can embed a specific category only by setting

$_GET['serendipity']['category'] = XXX;

in your PHP wrapper.

If that doesn't help you much, please describe very detailed what it is that you're needing. Serendpity offers at least 4-5 methods to embed content: Via Smarty, via PHP, via the 'embed' directive, via a plugin, via RSS, via JavaScript/Iframes and maybe more I didn't instantly think of.

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
ebang
Posts: 1
Joined: Fri Dec 30, 2005 8:28 pm
Location: Glastonbury, CT
Contact:

Post by ebang »

Now there's a good response.

Let's see. I embed using PHP right now. I use CuteNews to set up news on my site, but I think this would be better. Will the

Code: Select all

$_GET['serendipity']['category'] = XXX;
work if I host the blog on blog.hungryhungryhypocrites.com and want the news to appear on news.hungryhungryhypocrites.com?

Thanks a lot for the help.

Kevin
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hm, I think I would need more of your Code Examples on how you do the embedding to tell you more.

You'll need that line of PHP code on the site where your serendipity installation is! This variable needs to be set there, so that the index.php of serendipity has that variable set.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply