By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,963 Members | 941 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,963 IT Pros & Developers. It's quick & easy.

I need advice on how to create thousands of articles with PHP or else

P: n/a
SM
Hello,
I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.

So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:
http://www.myweb/library/?doc=194uf7s39

So far, no problem. Everything works like it should.

Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.

Each articles contains mostly text, photos, links to other articles.
Most articles are from paper and thought needs to be digitalize in
some way.
Keep in mind that most articles contains special characters (,
...)

I need advice on this issue. I want to use the right method before
starting importing all those articles. I want to get it right the
first time.

Any advice?

Thanks in advance
Marco
Oct 2 '08 #1
Share this Question
Share on Google+
7 Replies


P: n/a
I'm not an expert but I would think that if you need portability XML
would be a good method. Are the articles currently formatted
consistently (so you could make a parser to convert them)? Or are you
going to have to go through each one and convert it by hand?

On Oct 1, 10:39*pm, SM <servandomont...@gmail.comwrote:
Hello,
I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.

So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:http://www.myweb/library/?doc=194uf7s39

So far, no problem. Everything works like it should.

Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.

Each articles contains mostly text, photos, links to other articles.
Most articles are from paper and thought needs to be digitalize in
some way.
Keep in mind that most articles contains special characters (,
...)

I need advice on this issue. I want to use the right method before
starting importing all those articles. I want to get it right the
first time.

Any advice?

Thanks in advance
Marco
Oct 2 '08 #2

P: n/a
..oO(SM)
>I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.

So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:
http://www.myweb/library/?doc=194uf7s39

So far, no problem. Everything works like it should.

Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.
Where's the problem? A database would be the right tool. You as the
developer decide if your SQL will be portable or not.

Micha
Oct 2 '08 #3

P: n/a
SM wrote:
Hello,
I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.

So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:
http://www.myweb/library/?doc=194uf7s39

So far, no problem. Everything works like it should.

Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.

Each articles contains mostly text, photos, links to other articles.
Most articles are from paper and thought needs to be digitalize in
some way.
Keep in mind that most articles contains special characters (,
...)

I need advice on this issue. I want to use the right method before
starting importing all those articles. I want to get it right the
first time.

Any advice?

Thanks in advance
Marco
As Micha said - a database is the right tool for this.

This won't affect the article at all - it will still be 100% portable.
Also, if you follow the SQL standards, your SQL code will be portable;
you don't have to use mysql_xxx calls; you can use PDO instead so that
everything except your connect string (which can be in a configuration
file) is portable.

So, properly designed, the only change you would have to make is one
line in one configuration file.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Oct 2 '08 #4

P: n/a
SM
On Oct 2, 8:03*am, Jerry Stuckle <jstuck...@attglobal.netwrote:
SM wrote:
Hello,
I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.
So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:
http://www.myweb/library/?doc=194uf7s39
So far, no problem. Everything works like it should.
Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.
Each articles contains mostly text, photos, links to other articles.
Most articles are from paper and thought needs to be digitalize in
some way.
Keep in mind that most articles contains special characters (,
...)
I need advice on this issue. I want to use the right method before
starting importing all those articles. I want to get it right the
first time.
Any advice?
Thanks in advance
Marco

As Micha said - a database is the right tool for this.

This won't affect the article at all - it will still be 100% portable.
Also, if you follow the SQL standards, your SQL code will be portable;
you don't have to use mysql_xxx calls; you can use PDO instead so that
everything except your connect string (which can be in a configuration
file) is portable.

So, properly designed, the only change you would have to make is one
line in one configuration file.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================
Thanks for all the advice.
The reason why MySQL is not an option is because some servers were the
articles will reside don't support MySQL. A part from my MYSQL, any
ideas? I've tried using PHP, txt, XML and they all seem to work ok,
except for the special characters. But, i can probably find a
workaround for that one.

Thanks again
Marco

Oct 2 '08 #5

P: n/a
On Oct 2, 12:32*pm, SM <servandomont...@gmail.comwrote:
On Oct 2, 8:03*am, Jerry Stuckle <jstuck...@attglobal.netwrote:
SM wrote:
Hello,
I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.
So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:
>http://www.myweb/library/?doc=194uf7s39
So far, no problem. Everything works like it should.
Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.
Each articles contains mostly text, photos, links to other articles.
Most articles are from paper and thought needs to be digitalize in
some way.
Keep in mind that most articles contains special characters (,
...)
I need advice on this issue. I want to use the right method before
starting importing all those articles. I want to get it right the
first time.
Any advice?
Thanks in advance
Marco
As Micha said - a database is the right tool for this.
This won't affect the article at all - it will still be 100% portable.
Also, if you follow the SQL standards, your SQL code will be portable;
you don't have to use mysql_xxx calls; you can use PDO instead so that
everything except your connect string (which can be in a configuration
file) is portable.
So, properly designed, the only change you would have to make is one
line in one configuration file.
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================

Thanks for all the advice.
The reason why MySQL is not an option is because some servers were the
articles will reside don't support MySQL. A part from my MYSQL, any
ideas? I've tried using PHP, txt, XML and they all seem to work ok,
except for the special characters. But, i can probably find a
workaround for that one.

Thanks again
Marco
Why not try looking into SQLite?

SQLite is a software library that implements a self-contained,
serverless, zero-configuration, transactional SQL database engine.

http://sqlite.org/
Oct 2 '08 #6

P: n/a
SM wrote:
On Oct 2, 8:03 am, Jerry Stuckle <jstuck...@attglobal.netwrote:
>SM wrote:
>>Hello,
I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.
So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:
http://www.myweb/library/?doc=194uf7s39
So far, no problem. Everything works like it should.
Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.
Each articles contains mostly text, photos, links to other articles.
Most articles are from paper and thought needs to be digitalize in
some way.
Keep in mind that most articles contains special characters (,
...)
I need advice on this issue. I want to use the right method before
starting importing all those articles. I want to get it right the
first time.
Any advice?
Thanks in advance
Marco
As Micha said - a database is the right tool for this.

This won't affect the article at all - it will still be 100% portable.
Also, if you follow the SQL standards, your SQL code will be portable;
you don't have to use mysql_xxx calls; you can use PDO instead so that
everything except your connect string (which can be in a configuration
file) is portable.

So, properly designed, the only change you would have to make is one
line in one configuration file.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================

Thanks for all the advice.
The reason why MySQL is not an option is because some servers were the
articles will reside don't support MySQL. A part from my MYSQL, any
ideas? I've tried using PHP, txt, XML and they all seem to work ok,
except for the special characters. But, i can probably find a
workaround for that one.

Thanks again
Marco

If they don't support a database (MySQL, PostGres, SQL Server, Oracle,
DB2, whatever), then I wouldn't put a site on them anyway.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Oct 2 '08 #7

P: n/a
On Oct 2, 5:32*pm, SM <servandomont...@gmail.comwrote:
On Oct 2, 8:03*am, Jerry Stuckle <jstuck...@attglobal.netwrote:
SM wrote:
Hello,
I have a index.php template (2 columns). The right columns contains a
bunch of links (interviews, poems, etc...) The left columns contains
the actual article.
So if I click on a link on the right menu, the article shows on the
left column.
The links have an url that look like this:
>http://www.myweb/library/?doc=194uf7s39
So far, no problem. Everything works like it should.
Here's the question or needed advice. I have more then a thousand
articles (in diferent categories) and i want to know what is the best
way to create those articles. Should i create a PHP file for each one?
Should i create a text file in notepad for each article? Should create
a 'funny' html for each article?
Maybe create an XML file for each article. I can't use MYSQL in this
case for portability reasons.
Each articles contains mostly text, photos, links to other articles.
Most articles are from paper and thought needs to be digitalize in
some way.
Keep in mind that most articles contains special characters (,
...)
I need advice on this issue. I want to use the right method before
starting importing all those articles. I want to get it right the
first time.
Any advice?
Thanks in advance
Marco
As Micha said - a database is the right tool for this.
This won't affect the article at all - it will still be 100% portable.
Also, if you follow the SQL standards, your SQL code will be portable;
you don't have to use mysql_xxx calls; you can use PDO instead so that
everything except your connect string (which can be in a configuration
file) is portable.
So, properly designed, the only change you would have to make is one
line in one configuration file.
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================

Thanks for all the advice.
The reason why MySQL is not an option is because some servers were the
articles will reside don't support MySQL. A part from my MYSQL, any
ideas? I've tried using PHP, txt, XML and they all seem to work ok,
except for the special characters. But, i can probably find a
workaround for that one.

Thanks again
Marco
PHP uses SQLite as a way of providing database functionality on hosts
with no dedicated SQL server. There's a PDO driver for SQLite as well
as more traditional SQLite functions.
Oct 3 '08 #8

This discussion thread is closed

Replies have been disabled for this discussion.