ID3_GET_VERSION(3) 1 ID3_GET_VERSION(3)id3_get_version - Get version of an ID3 tagSYNOPSIS
int id3_get_version (string $filename)
DESCRIPTION id3_get_version(3) retrieves the version(s) of the ID3 tag(s) in the MP3 file.
If a file contains an ID3 v1.1 tag, it always contains a 1.0 tag, as version 1.1 is just an extension of 1.0.
PARAMETERS
o $filename
- The path to the MP3 file Instead of a filename you may also pass a valid stream resource
RETURN VALUES
Returns the version number of the ID3 tag of the file. As a tag can contain ID3 v1.x and v2.x tags, the return value of this function
should be bitwise compared with the predefined constants ID3_V1_0, ID3_V1_1 and ID3_V2.
EXAMPLES
Example #1
id3_get_version(3) example
<?php
$version = id3_get_version( "path/to/example.mp3" );
if ($version & ID3_V1_0) {
echo "Contains a 1.x tag
";
}
if ($version & ID3_V1_1) {
echo "Contains a 1.1 tag
";
}
if ($version & ID3_V2) {
echo "Contains a 2.x tag
";
}
?>
The above example will output something similar to:
Contains a 1.x tag
Contains a 1.1 tag
SEE ALSO id3_set_tag(3), id3_get_tag(3), id3_remove_tag(3).
PHP Documentation Group ID3_GET_VERSION(3)
Check Out this Related Man Page
ID3_REMOVE_TAG(3) 1 ID3_REMOVE_TAG(3)id3_remove_tag - Remove an existing ID3 tagSYNOPSIS
bool id3_remove_tag (string $filename, [int $version = ID3_V1_0])
DESCRIPTION id3_remove_tag(3) is used to remove the information stored of an ID3 tag.
PARAMETERS
o $filename
- The path to the MP3 file Instead of a filename you may also pass a valid stream resource
o $version
- Allows you to specify the version of the tag as MP3 files may contain both, version 1.x and version 2.x tags.
RETURN VALUES
Returns TRUE on success or FALSE on failure.
EXAMPLES
Example #1
id3_remove_tag(3) example
<?php
$result = id3_remove_tag( "path/to/example.mp3", ID3_V1_0 );
if ($result === true) {
echo "Tag successfully removed
";
}
?>
If the file is writable and contained a 1.0 tag, this will output:
Tag successfully removed
NOTES
Note
Currently id3_remove_tag(3) only supports version 1.0 and 1.1. If you choose to remove a 1.0 tag and the file contains a 1.1 tag,
this tag will be removed, as v1.1 is only an extension of 1.0.
SEE ALSO id3_set_tag(3), id3_get_tag(3), id3_get_version(3).
PHP Documentation Group ID3_REMOVE_TAG(3)
I'm trying to get a little script working with DropScript 0.5 that edits the ID3 tags of an MP3. Here's what I've got:
#!/bin/sh
# Strip directory part but leave extension.
in_base=`basename "$@"`
# Strip extension.
in_noext=`echo "$in_base" | sed 's/\.*$//'`
/opt/local/bin/id3v2... (4 Replies)
Hi,
I have some files (650) each file has some information like subs number, hardware ID1, Hardware ID2, Hardware ID3 and 4. how can I get this informations from all files using a script ? I want to write those info to a file. like column1 (subs number) column2 (HwID1)......column4(HwID4)
how... (5 Replies)
Hello,
Can you tell me why the last command(echo) in this script does not execute?
In the command line I have to hit control -d to terminate this tag but I dont know how to do it in a shell script.
sqlplus -s <<EOF
connect / as sysdba
select sysdate from dual;
quit;
EOF
echo... (13 Replies)
Hi anbody know where i'm wrong in?
#!/bin/ksh
ID1=1234
ID2=2345
ID3=3456
count=1
while
do
if ;then
echo yeah
else
echo wrong
fi
count=$((count + 1))
done (8 Replies)
I need scan through some files, then open the file one by one and scan inside the file using perl to see if it contain a start tag and end tag which the end tag is the mirror image of the start tag, the start tag and end tag only have 5 char. And inside the file there is "http://". It is just a... (5 Replies)
I have a file where in some records are having the <Start> and <End> tag. There is data before the start tag , between the tages and after the End tag. I want to replace everything between the start & end tag with equivalent spaces.
Input File
afsdfaksddfs<start>12678<end>sgdfgdfsf... (6 Replies)
The given file consists of two tags i.e., <free-energy> and <position> tag. I want the output like this. The tag <length> is not required to consider.
(General format of output)
free-energy no.
first position no – second position no
third position no – fourth position no
------
... (8 Replies)
All,
I stuck up for the logic, how to implement the below thing in script.
-Search for <a class="string-array"> line and in next line of search string append with <string>java</string> in a xml file
The problem here is, <a class="string-array"> occurs multiple places in the xml. I just... (13 Replies)
is it possible to pass webpages to remove all tag style information, but leave the tag...
say I have
<h1 style='font-size: xxx; color: xxxxxx'>headline 1</h1>
i want to get
<h1>headline 1</h1>
BTW, i got an oneliner here to remove all tags:
sed -n '/^$/!{s/<*>//g;p;
Thanks a... (4 Replies)
Does anybody know how i can remove string from <a> tag?
There are several hundred posts in a few forums that need to be cleaned up.
The precise situation is
----------
<a href="http://mydomain.com/cgi-bin/anyboard.cgi?fvp=/family/sexuality_and_spirituality/&cmd=rA&cG=43">
-------------
my... (6 Replies)
I want to basically do the below thing. Suppose there is a tag called object1. I want to display an output for all similar tag values under heading of Object 1 and the count of the xmls. Please help
File:
<xml><object1>house</object1><object2>child</object2>... (9 Replies)
Hi all
I was wondering if you may help me in resolving an issue.
In particular I have a file like this:
the ... represent different string and what I wrote Cur or Ent are the constant.
Well, what I would like to obtain is a file in which are reported only the ID in which the second column... (6 Replies)
Hi All,
I am having a file like below. The file will having information about the records.If you see the file the file is header and data. For example it have 1 men tag and the tag id will be come after headers. The change is I want to convert All pets tag from P to X. I did a sed like below... (5 Replies)
Hi wisecracker,
Thank you for posting this.
Reference: Q: Is SQRT(n) possible in a POSIX...
I think I will create a new tag for these kind of "tutorials" or "fun projects" similar to the "solved" tag which changes the color to blue; but the "member_project" tag would turn the color to... (14 Replies)
I'm new with scripting and I can't seem to figure out what I should do to get the output that I want.
My file content would be below.
ID2|ID3 |ID4|ID5 |
I'm trying to replace the field of ID3 which has a fixed length of 10 characters, for each entry I have placed on a .txt file... (5 Replies)