<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    Sealyu

    --- 博客已遷移至: http://www.sealyu.com/blog

      BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理 ::
      618 隨筆 :: 87 文章 :: 225 評論 :: 0 Trackbacks
    Mon, 09/18/2006 - 3:03pm — ches

    Updated for Drupal 5.1! See the bottom of the article.

    I have a growing backlog of stories that I've been meaning to type up here, including several articles of interest for folks getting started with drupal, but I've just finished setting up the audio module, so I thought I'd share my experience while it's fresh on the mind.

    You'll notice that you can now play the "two out of three" mp3 from my last post direct from the site without the need to download, and this is thanks to the audio module. Since it utilizes drupal's node model for content types, this module is able to harness much of the power and flexibility inherent in the CMS, including the taxonomy system and automatic RSS/podcast feed generation. It can also be readily extended through modules like the playlist toolkit for sites with sophisticated audio needs.

    My intent here, though, is just to offer a quick step-by-step guide for a simpler application: a blog or some other site seeking to include audio files attached to other content types (pages and stories, for instance). Still, this should be helpful for anyone getting started with the audio module.

    Installation and Configuration

    1. Let's obtain the audio module from the project page. I'm using version 4.7.0 for this guide. Untar the file in your site's modules directory.

      > tar xzvf audio-4.7.0.tar.gz

    2. Next we need to download the getid3 PHP libraries and unzip the downloaded file into the same directory as audio.module.

      > unzip getid3-1.7.7.zip -d <yoursitepath>/modules/audio/

      Version 1.7.7 of getid3 is recommended in the audio module's documentation.

    3. Open the site in your browser and go to administer >> modules. Enable the audio, audio_attach and audio_getid3 modules. I don't need to add audio files in bulk or use cover art, so I don't use audio_import or audio_images. Configuration for those modules is not covered here.
    4. I don't want audio entries in my navigation menu, so I disabled "audio" and "browse by" at administer >> menus. You can optionally enable audio-related blocks at, you guessed it, administer >> blocks.
    5. You'll need to set user privelages according to your needs: at administer >> access control I gave my blog user "create audio" and "edit own audio" permissions in addition to the defaults.
    6. In order to attach audio nodes to other content types, we need to enable this capability for each type at administer >> settings >> content types. I first configured audio, disabling Attach Images and Attachments since I have the image_attach and upload modules enabled. I also disabled comments and promotion to front page. Then, enable Attach audio files for the content types that suit your needs. I did so for story. You might do the same for page, CCK types or others.
    7. Finally, check your settings at administer >> settings >> audio. Typical PHP configurations will default to a 2MB upload limit -- you'll probably need to adjust your php.ini as suggested if you haven't already done so. Disable Downloadable by default if you want to make it more difficult for users to save copies of your music. Check that settings on the metadata tags tab are to your liking, and check the getid3 tab to assure that your installation is detected correctly.
    8. That's it! You should now be able to create a new node -- of a type set up in step six -- with the option to attach an audio file. This will create an audio node behind the scenes, which you can browse (and edit id3 tags for) at yoursite.com/audio. If you don't want this behavior, uncheck Published when attaching the audio file to your node.

    Taking it Further

    Of course, if audio plays a more prominent role at your site, there's much more that you can do with the audio module, incorporating taxonomy, changing the look of the player, and so on. Here are some links to get you started.

    Update for Drupal 5.1

    For the most part, updating my audio module for use as outlined above was intuitive, with one exception: the audio_attach module has just been contributed to CVS for 5.x by zirafa. He's also contributed a new audio_playlist module, but I haven't tried that out yet. To get audio_attach (and get my existing nodes with attached audio back to working order), I checked out the audio module from CVS with the following commands:

    > cd <yoursitepath>/modules
    > cvs -z6 -d:pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal-contrib checkout -d audio contributions/modules/audio

    I installed the modules as normal and ran update.php. At this point I received an SQL error as the script attempted to set multiple primary keys for the audio_attach table. I manually set nid, aid and weight as primary keys using phpMyAdmin, and I was back in business. I've found that my Flash players are not visible when using the handy admin_menu module, but that probably shouldn't effect many of your users.

    I'll try to update all of these instructions soon. In the meantime, comment if you have questions!

    posted on 2010-08-19 12:01 seal 閱讀(327) 評論(0)  編輯  收藏 所屬分類: PHP
    主站蜘蛛池模板: a毛片免费全部播放完整成| sss在线观看免费高清| 伊人久久免费视频| 亚洲精品国产美女久久久| 亚洲免费在线观看| 亚洲熟伦熟女新五十路熟妇| 羞羞漫画登录页面免费| 日韩精品亚洲专区在线观看| 色婷婷精品免费视频| 免费a级毛片无码av| 国产精品成人亚洲| 亚洲国产一成久久精品国产成人综合| 免费一级毛suv好看的国产网站 | 国产精品久久免费视频| 老司机亚洲精品影院在线观看| 国产一区二区三区无码免费| 美女裸免费观看网站| 亚洲午夜久久久久妓女影院 | 亚洲一区二区三区国产精华液 | 亚洲啪啪AV无码片| 日本免费久久久久久久网站| 亚洲人成电影在在线观看网色| 蜜桃AV无码免费看永久| 亚洲一线产区二线产区区| www国产亚洲精品久久久| 日韩免费视频一区二区| 亚洲一区二区三区在线| 免费真实播放国产乱子伦| 一级有奶水毛片免费看| 亚洲国产美女福利直播秀一区二区 | 亚洲 日韩 色 图网站| 凹凸精品视频分类国产品免费| 美女无遮挡拍拍拍免费视频| 亚洲欧洲日本国产| 免费h黄肉动漫在线观看 | 免费H网站在线观看的| 无码天堂亚洲国产AV| 亚洲黄色三级视频| 国产免费午夜a无码v视频| 久久九九全国免费| 亚洲AV无码专区在线观看成人|