|
|
Please consider registering: registration is fast, easy and free! Benefits of registration:
- Free advertising for your website: Every post in our forums goes towards a "credit" of ads, which are displayed on most pages of our forums. Each post gives you 400 ad impressions. To submit your ad, edit your profile.
- Discount at TemplateMonster: All our members enjoy a 10% discount at TemplateMonster.com!
|
- Private Messages: Exchange private messages with other members of the forums.
- Message Tracking/Subscription: phpBB enables you to subscribe to threads which interest you, and will then email you when a reply is posted. phpBB also remembers which posts registered users have read during a session, which means you can keep track of which posts you have already looked at.
|
|
| Author |
Message |
Milchbazi
Junior WebHelper


Joined: 11 Mar 2003
Posts: 15
Location: NH, USA
|
Posted:
Sat May 31, 2003 3:28 am (10 years ago) |
  |
Hello everybody!
Is it possible to get arrays out of a mysql database (without unserialize(); )? I mean I have strings in form of
| Code: | $table1 = "23.1,45.7,43.8,14.9";
$table2 = "43.6,34.7,66.6,99.1,34.8"; |
and want to cut them on each comma to put them into an array.
Like that:
| Code: | | $table1 = array(23.1,45.7,43.8,14.9); |
So I can use every number.
Thx for your help!
Milchbazi
PS: It would be the best if I could use it in a function, because I need the same process a lot! |
________________________________ TS Designs
___________________________ |
|
     |
 |
Milchbazi
Junior WebHelper


Joined: 11 Mar 2003
Posts: 15
Location: NH, USA
|
Posted:
Sat May 31, 2003 3:37 am (10 years ago) |
  |
Helped myself already!
| Code: | | $table1 = explode(",",$table1); |
But do you have an other suggestion? let me know!
See you!
Milchbazi |
________________________________ TS Designs
___________________________ |
|
     |
 |
Daniel
Team Member


Joined: 06 Jan 2002
Posts: 2192
Location: London, UK
|
Posted:
Sat May 31, 2003 7:54 am (10 years ago) |
  |
Hi Milchbazi,
That is the best way to do it that I know of, and it is the way I'm using here at 4WebHelp for tutorial authors who have multiple websites.
Daniel |
________________________________
 |
|
     |
 |
|
|
|
You cannot post new topics in this forum. You cannot reply to topics in this forum. You cannot edit your posts in this forum. You cannot delete your posts in this forum. You cannot vote in polls in this forum.
|
Page generation time: 0.026837 seconds :: 17 queries executed :: All Times are GMT
Powered by phpBB 2.0
© 2001, 2002 phpBB Group :: Based on an FI Theme
| |