FeedForAll Forum Index  
 Home  •  FAQ  •   Search   •  Register   •  Profile   •  Log in
 Boy do I need help! View next topic
View previous topic
Post new topicReply to topic
Author Message
Riviera



Joined: 01 Nov 2006
Posts: 6

PostPosted: Wed Nov 01, 2006 4:28 pm Reply with quoteBack to top

Hi

I downloaded it and followed the instructions... only problem is I have no idea how to produce the feed... :(

We have 200+ properties in a mysql database and I want to get them into a feed - how do I do it?

The instructions are not very informative :(

The result of "8) Test sql2rss by entering its URL into your browser, and including your new config file as a parameter.
Example: http://www.feedforall.com/sql2rss.php?CONFIGFILE=mynewconfig.php" produce simply this:

Quote:
<?xml version="1.0" encoding="UTF-8" ?>
- <rss version="2.0">
- <channel>
<title>sql2rss.php Sample Template</title>
<description>A sample RSS feed template for sql2rss.php, http://www.FeedForAll.com/, by NotePage, Inc.</description>
<link>http://www.FeedForAll.com/</link>
<docs>http://blogs.law.harvard.edu/tech/rss</docs>
<language>en-us</language>
<generator>FeedForAll-scripts (sql2rss.php), http://www.FeedForAll.com/, Copyright 2006, NotePage, Inc.</generator>
<lastBuildDate>Wed, 01 Nov 2006 21:24:42 +0000</lastBuildDate>
<pubDate>Wed, 01 Nov 2006 21:24:42 +0000</pubDate>
</channel>
</rss>


How do I get it to show the random results I did in my sql?

Quote:
$SQLQuery = "SELECT * FROM listings ORDER BY rand() LIMIT 10";
View user's profile
MacSupport



Joined: 24 Feb 2005
Posts: 2805

PostPosted: Wed Nov 01, 2006 4:37 pm Reply with quoteBack to top

Riviera wrote:
Hi

I downloaded it and followed the instructions... only problem is I have no idea how to produce the feed... :(

We have 200+ properties in a mysql database and I want to get them into a feed - how do I do it?

The instructions are not very informative :(

The result of "8) Test sql2rss by entering its URL into your browser, and including your new config file as a parameter.
Example: http://www.feedforall.com/sql2rss.php?CONFIGFILE=mynewconfig.php" produce simply this:

Quote:
<?xml version="1.0" encoding="UTF-8" ?>
- <rss version="2.0">
- <channel>
<title>sql2rss.php Sample Template</title>
<description>A sample RSS feed template for sql2rss.php, http://www.FeedForAll.com/, by NotePage, Inc.</description>
<link>http://www.FeedForAll.com/</link>
<docs>http://blogs.law.harvard.edu/tech/rss</docs>
<language>en-us</language>
<generator>FeedForAll-scripts (sql2rss.php), http://www.FeedForAll.com/, Copyright 2006, NotePage, Inc.</generator>
<lastBuildDate>Wed, 01 Nov 2006 21:24:42 +0000</lastBuildDate>
<pubDate>Wed, 01 Nov 2006 21:24:42 +0000</pubDate>
</channel>
</rss>


How do I get it to show the random results I did in my sql?

Quote:
$SQLQuery = "SELECT * FROM listings ORDER BY rand() LIMIT 10";


The select looks good. Did you create the "Item Template" file corectly?

Jim

_________________
Be sure to check out the FeedForAll Mac tutorials at: http://www.FeedForAll.com/tutorials/

FeedForAll Mac and rss2html.php
support@FeedForAll.com
View user's profileVisit poster's website
Riviera



Joined: 01 Nov 2006
Posts: 6

PostPosted: Wed Nov 01, 2006 4:44 pm Reply with quoteBack to top

Hi Jim

I think so I did this:

Quote:
<item>
<title>~~~title~~~</title>
<link>http://www.mysite.com/press_release.php?id=~~~listing_id~~~</link>
<description>~~~description~~~</description>
<pubDate>~~~RSSDATE(r_date)~~~</pubDate>
</item>


Richard
View user's profile
MacSupport



Joined: 24 Feb 2005
Posts: 2805

PostPosted: Wed Nov 01, 2006 4:48 pm Reply with quoteBack to top

Riviera wrote:
Hi Jim

I think so I did this:

Quote:
<item>
<title>~~~title~~~</title>
<link>http://www.mysite.com/press_release.php?id=~~~listing_id~~~</link>
<description>~~~description~~~</description>
<pubDate>~~~RSSDATE(r_date)~~~</pubDate>
</item>


Richard


That is my sample template. I hightly doubt that the field names match up with your database.

Jim

_________________
Be sure to check out the FeedForAll Mac tutorials at: http://www.FeedForAll.com/tutorials/

FeedForAll Mac and rss2html.php
support@FeedForAll.com
View user's profileVisit poster's website
Riviera



Joined: 01 Nov 2006
Posts: 6

PostPosted: Wed Nov 01, 2006 5:01 pm Reply with quoteBack to top

Hi

I have the following fields:

title
listing_id
description

The domain shouldn't matter for now should it?

R
View user's profile
MacSupport



Joined: 24 Feb 2005
Posts: 2805

PostPosted: Wed Nov 01, 2006 5:12 pm Reply with quoteBack to top

Riviera wrote:
Hi

I have the following fields:

title
listing_id
description

The domain shouldn't matter for now should it?

R


It will matter in the future, but not at this point. I am emailing you something

Jim

_________________
Be sure to check out the FeedForAll Mac tutorials at: http://www.FeedForAll.com/tutorials/

FeedForAll Mac and rss2html.php
support@FeedForAll.com
View user's profileVisit poster's website
Riviera



Joined: 01 Nov 2006
Posts: 6

PostPosted: Wed Nov 01, 2006 5:40 pm Reply with quoteBack to top

Hi

I get this

Quote:
Connect error: Access denied for user: 'nobody@localhost' (Using password: NO)
A sample RSS feed template for sql2rss.php, http://www.FeedForAll.com/, by NotePage, Inc. http://www.FeedForAll.com/ http://blogs.law.harvard.edu/tech/rss en-us FeedForAll-scripts (sql2rss.php), http://www.FeedForAll.com/, Copyright 2006, NotePage, Inc. Wed, 01 Nov 2006 22:37:50 +0000 Wed, 01 Nov 2006 22:37:50 +0000


I have double checked and triple checked the db connect data though and it is exactly the same as in my web applications...

???

R
View user's profile
MacSupport



Joined: 24 Feb 2005
Posts: 2805

PostPosted: Wed Nov 01, 2006 5:51 pm Reply with quoteBack to top

Riviera wrote:
Hi

I get this

Quote:
Connect error: Access denied for user: 'nobody@localhost' (Using password: NO)
A sample RSS feed template for sql2rss.php, http://www.FeedForAll.com/, by NotePage, Inc. http://www.FeedForAll.com/ http://blogs.law.harvard.edu/tech/rss en-us FeedForAll-scripts (sql2rss.php), http://www.FeedForAll.com/, Copyright 2006, NotePage, Inc. Wed, 01 Nov 2006 22:37:50 +0000 Wed, 01 Nov 2006 22:37:50 +0000


I have double checked and triple checked the db connect data though and it is exactly the same as in my web applications...

???

R


That helps a lot.

1) Look in you config file for the line
Code:
$DBconfigFile = "sql2rss_DBconfig.inc.php";


2) Make sure the file name specified in there is a local file, like above. Make sure the file really exists. And contains the information you think it should.

Since it is saying user is "nobody" I am guessing there is a filename problem.

Jim

_________________
Be sure to check out the FeedForAll Mac tutorials at: http://www.FeedForAll.com/tutorials/

FeedForAll Mac and rss2html.php
support@FeedForAll.com
View user's profileVisit poster's website
Riviera



Joined: 01 Nov 2006
Posts: 6

PostPosted: Wed Nov 01, 2006 6:22 pm Reply with quoteBack to top

I renamed it to "rss_DB.inc.php" to be sure and changed the name in the test.php file...

Same error :(

Then I checked the config file and the name was wrong there so I changed it and it worked :)

Thanks a lot!

Is there a way to add images?

Richard
View user's profile
MacSupport



Joined: 24 Feb 2005
Posts: 2805

PostPosted: Wed Nov 01, 2006 6:30 pm Reply with quoteBack to top

Riviera wrote:
I renamed it to "rss_DB.inc.php" to be sure and changed the name in the test.php file...

Same error :(

Then I checked the config file and the name was wrong there so I changed it and it worked :)

Thanks a lot!

Is there a way to add images?

Richard


Since you have complete control of the output yes. One way is to change
Code:
<description>~~~description~~~</description>

to
Code:
<description>&lt;img src="~~~image~~~"&gt; ~~~description~~~</description>


But you "image" column must be a URL to the image. If you don't have image URLs you can't.

The above will change the description to include the image in the description as HTML.

Jim

_________________
Be sure to check out the FeedForAll Mac tutorials at: http://www.FeedForAll.com/tutorials/

FeedForAll Mac and rss2html.php
support@FeedForAll.com
View user's profileVisit poster's website
Riviera



Joined: 01 Nov 2006
Posts: 6

PostPosted: Wed Nov 01, 2006 6:38 pm Reply with quoteBack to top

Great thanks :)

I'll try that tomorrow - need some sleep now!

Appreciate the help...

Richard
View user's profile
MacSupport



Joined: 24 Feb 2005
Posts: 2805

PostPosted: Wed Nov 01, 2006 6:41 pm Reply with quoteBack to top

Riviera wrote:
Great thanks :)

I'll try that tomorrow - need some sleep now!

Appreciate the help...

Richard


Okay.

Jim

_________________
Be sure to check out the FeedForAll Mac tutorials at: http://www.FeedForAll.com/tutorials/

FeedForAll Mac and rss2html.php
support@FeedForAll.com
View user's profileVisit poster's website
Display posts from previous:      
Post new topicReply to topic


 Jump to:   



View next topic
View previous topic


Powered by phpBB © 2001, 2002 phpBB Group :: FI Theme