00:00
00:00
Newgrounds Background Image Theme

orangebag4448 just joined the crew!

We need you on the team, too.

Support Newgrounds and get tons of perks for just $2.99!

Create a Free Account and then..

Become a Supporter!

Php: Rss Feed Creaton

2,210 Views | 6 Replies
New Topic Respond to this Topic

Php: Rss Feed Creaton 2005-12-18 10:30:39


PHP: Main

Since I couldn't post it in here, I made the tutorial on a web page:
PHP: RSS Feed tutorial

Have fun with it!


"My software never has bugs. It just develops random features. " - Unknown

[ FluxBB developer | Quickmarks 0.5.1 | Strings & Ints - my blog ]

BBS Signature

Response to Php: Rss Feed Creaton 2005-12-18 16:35:24


At 12/18/05 04:27 PM, PillowBiter wrote: And I'm a fucking retard:

And yet again.

$query = "CREATE TABLE `rss` (
`id` INT( 11 ) NOT NULL ,
`title` VARCHAR( 255 ) NOT NULL ,
`link` VARCHAR( 255 ) NOT NULL ,
`description` LONGTEXT NOT NULL ,
`pubDate` VARCHAR( 255 ) NOT NULL
) TYPE = MYISAM";
if(!$query) {
die(mysql_error());

what is this? checking to see if the $query variable has a value to see if the query went through. I think you should have done this, don't you agree?:

if ( !($sql = mysql_query( $query)) ) {
die(mysql_error());

Honest mistake. I have done it loads of times before myself. Kinda wonder why though, isn't this error so obvious when reading it in someone elses code?

Newgrounds should employ code tags.

Agreed.

I didn't overly like that tutorial. For one the HTML was hard on my eyes. I didn't like looking at it how it was layed out. and I just didn't like the writting for some reason. No offence.

Response to Php: Rss Feed Creaton 2005-12-18 16:43:41


At 12/18/05 04:37 PM, PillowBiter wrote: Craige, you're way wrong too =P
I just didn't do it right for some odd reason. No variables should be used, it should be
mysql_query "query" or die(mysql_error());
Or operator is more secure than assining a variable.

well the variable isn't needed for this query. I just have a habit of doing that cause of always using the select query, and having to use the variable later. But the mysql_query( query ) or die( mysql_error() ); method is more secure.

Response to Php: Rss Feed Creaton 2005-12-18 16:52:57


Yes, I know the layout didn't work out quite right...

And what's wrong with the text?


"My software never has bugs. It just develops random features. " - Unknown

[ FluxBB developer | Quickmarks 0.5.1 | Strings & Ints - my blog ]

BBS Signature

Response to Php: Rss Feed Creaton 2005-12-18 17:27:50


At 12/18/05 04:52 PM, elbekko wrote: Yes, I know the layout didn't work out quite right...

And what's wrong with the text?

It is hard to put a finger on single things, but for example:

I'm using mysql_result here, because, for some odd reason, mysql_fetch_array wouldn't work.

That dosn't sound so good when you are saposed to be teaching someone somthing. Generally though, it is just a conbonation of the text to me. It may have a somthing to do with the fact I have a headache, and the way the text is broken on the page, but for some reasion I just didn't like it too much. Sorry. If others like it though, good for them, and I am glad for you.

Response to Php: Rss Feed Creaton 2005-12-19 06:34:34


I'm just spreading my knowledge :)

I'll rewrite it soon now I have some time on my hands again :)


"My software never has bugs. It just develops random features. " - Unknown

[ FluxBB developer | Quickmarks 0.5.1 | Strings & Ints - my blog ]

BBS Signature

Response to Php: Rss Feed Creaton 2005-12-19 06:50:14


I made a tutorial on this very same subject, not so long ago, except my tutorial was on FlashTroops

http://www.flashtroo..forum/viewthread/106