![]() |
Need Help with An Array
I have an array that looks kind of like this:
$array = array("rss", "rss, happy, total", "total, happy, yesterday"); Now what I'd like to do is remove all of the duplicates so I have one array that looks like this - just one element in each value. $array = array("rss", "happy", "total", "yesterday"); How could I do this? |
PHP Code:
|
Yeah, but how do I get that first array?
It's already set as: $array = array("rss", "rss, happy, total", "total, happy, yesterday"); That's in the database already, I can't just change it -- well, my question is, how do I change it to a way I can use array_unique. |
PHP Code:
|
Tried it and still had duplicates. Am I missing something?
:-/ Thanks for your help by the way! PHP Code:
|
Can you give me the value of "$entry['tags']"?
|
1 Attachment(s)
Maybe I'm making a mistake -- so here's the output (value of $entry['tags']) from the query I am running.
Thanks again. |
PHP Code:
|
Hmm, this only returned three results:
recommendation, avatar, ap related --------------- Added [DATE]1209324149[/DATE] at [TIME]1209324149[/TIME] --------------- However, removing "$tags = array_map('trim', $tag_entry);" seems to have done it. --------------- Added [DATE]1209325454[/DATE] at [TIME]1209325454[/TIME] --------------- Of course - sort() doesn't work on this -- but it seems to work for what I need! Thank you so much!!! I appreciate it. |
All times are GMT. The time now is 10:41 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|