How to add a Flash mp3 player on your blog?

First of all, you need upload your mp3 to your server or skydrive. After you done it, get the URL, e.g. http://storage.live.com/items/2397ECF3EEF1D575!688?filename=kite.mp3

Put the below codes in where you want your mp3 player is and REPLACE the mp3 URL to the correct one. It works fine wherever you host your blog, blogger, wordpress, typepad or your own server. (p.s. replace ( ) to < >)

(object id="audioplayer1" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="290" height="24"; codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0")(param name="data" value="http://judahhimango.com/FlashAudioPlayer/player.swf" /)(param name="src" value="http://judahhimango.com/FlashAudioPlayer/player.swf" /)(param name="flashvars" value="playerID=1&soundFile=http://storage.live.com/items/2397ECF3EEF1D575!688?filename=kite.mp3" /)(embed id="audioplayer1" type="application/x-shockwave-flash" width="290" height="24"; src="http://judahhimango.com/FlashAudioPlayer/player.swf" flashvars="playerID=1&soundFile=http://storage.live.com/items/2397ECF3EEF1D575!688?filename=kite.mp3" data="http://judahhimango.com/FlashAudioPlayer/player.swf")(/embed)(/object)

You can also change the player’s size by modifying width="290" height="24".  Then you will get this

It will be more convenient if you host your blog in wordpress. Add below codes in functions.php of your wordpress theme.

Upload the mp3player.swf to your theme folder. After this, every time you want to add a mp3, you just need insert (mp3)MP3 URL(/mp3). Again, replace ( ) to [ ]

For example, (mp3)http://storage.live.com/items/2397ECF3EEF1D575!688?filename=kite.mp3(/mp3) will be converted to :[mp3]http://storage.live.com/items/2397ECF3EEF1D575!688?filename=kite.mp3[/mp3]

For auto play, use (mp3 auto="1")MP3 URL(/mp3)

How to use Latex in WordPress?

* Installation

  1. Follow this Download link, unzip it, and upload all files to your server wp/wp-content/plugins/
  2. activate this plugin in the Dashboard>Plugins
  3. If you want to allow LaTeX images in your blog’s comments in addition to your blog’s posts, go to Settings -> WP LaTeX, check the Comments checkbox, and save the settings.

* How do I add LaTeX to my posts?
This plugin uses the WordPress Shortcode Syntax. Enter your LaTeX code inside of a (latex)…(/latex) shortcode.

(latex)e^{i pi} + 1 = 0(/latex)

You may alternatively use the following equivalent syntax reminiscent of LaTeX’s inline math mode syntax.

£latex e^{i pi} + 1 = 0£

That is, if you would have written £some-code£ in a LaTeX document, just write £latex some-code£ in your WordPress post.

For the curious, the shortcode syntax is slightly faster for WordPress to process, but the inline syntax is a little easier for us humans to read. Pick your poison.

* Can I change the color of the images produced?
Yes. You can set the default text color and background color of the images in the Plugins -> WP LaTeX admin page.

You can also change the colors on an image by image basis by specifying color and background attributes inside the LaTeX shortcode. For example:

(latex color=”ff0000″ background=”00ff00″)e^{i pi} + 1 = 0(/latex)

will produce an image with a bright green background and a bright red foreground color. Colors are specified in RGB with the standard 6 digit hex notation.

The equivalent “inline” syntax uses fg and bg parameters after the LaTeX code.

£latex e^{i pi} + 1 = 0&bg=00ff00&fg=ff0000£

* Can I change the size of the image?
You can specify a size attribute in the LaTeX shortcode:

(latex size=”4″)e^{i pi} + 1 = 0(/latex)

or, equivalently, an s parameter after the LaTeX inline syntax:

£latex e^{i pi} + 1 = 0&s=4£

The size can be any integer from -4 to 4 (0 is the default). These numbers correspond to the following LaTeX size commands.

size = LaTeX size
-4 tiny
-3 scriptsize
-2 footnotesize
-1 small
0 normalsize (12pt)
1 large
2 Large
3 LARGE
4 huge

* The LaTeX images work, but they don’t really fit in with my blog’s theme
You can adjust the CSS used for the LaTeX images to suit your theme better. Go to Settings -> WP LaTeX and edit the Custom CSS.

* I want to break out of math mode and do some really wild stuff. How do I do that?
You can’t with this plugin. WP LaTeX forces you to stay in math mode. Formatting and styling for your posts should be done with markup and CSS, not LaTeX.

If you really want hardcore LaTeX formatting (or any other cool LaTeX features), you should probably just use LaTeX.

* Instead of images, I get error messages. What’s up
Formula does not parse: Your LaTeX is invalid; there must be a syntax error or something in your code (WP LaTeX doesn’t provide any debugging).
Formula Invalid: Your LaTeX code attempts to use LaTeX commands that this plugin does not allow for security reasons.
You must stay in inline math mode: Fairly self explanitory, don’t you think? See above.
The forumula is too long: Break your LaTeX up into multiple images. WP LaTeX limits you to 2000 characters per image.
Could not open TEX file for writing or Could not write to TEX file: You have some file permissions problems. See Intallation instructions.

PS: TO MAKE IT WORK, REPLACE ( ) TO [ ], AND £ TO $

Examples:

(latex)m = frac{m_0}{sqrt{1-frac{v^2}{c^2}}}(/latex) →  m = frac{m_0}{sqrt{1-frac{v^2}{c^2}}}

£latex begin{array}{rcl} y & = & x \ y & = & x^2 + 1 \ y & = & x^3 + x^2 + 1 end{array}£ →  begin{array}{rcl} y & = & x \ y & = & x^2 + 1 \ y & = & x^3 + x^2 + 1 end{array}

£latex left[ begin{array}{cc} x_{11} & x_{12} \ x_{21} & x_{22} end{array} right]£ → left[ begin{array}{cc} x_{11} & x_{12} \ x_{21} & x_{22} end{array} right]

£latex f(n) = begin{cases} n/2, & mbox{if } nmbox{ is even} \ 3n+1, & mbox{if } nmbox{ is odd} end{cases}£ → f(n) = begin{cases} n/2, & mbox{if } nmbox{ is even} \ 3n+1, & mbox{if } nmbox{ is odd} end{cases}

£latex begin{array} {lcl} f(x) & = & (a+b)^2 \ & = & a^2+2ab+b^2 end{array}£ → begin{array} {lcl} f(x) & = & (a+b)^2 \ & = & a^2+2ab+b^2 end{array}

mp3外链:找出Skydrive的真实外链地址

方法很简单,但却很有效!

下面直接实例说明:

1、打开一个Skydrive上保存的MP3文件下载页 (当然,mp3文件要上传到public文件夹中)

2、将下面的一段代码粘贴到步骤1中打开网页的Firefox地址框中,替换原来的网址,然后按一下回车键

javascript:var%20n=document.title.replace(‘%20-%20Windows%20Live’,”);var%20id=((location.hash==”)?window.selfPageData.currentItemHash:location.hash).replace(‘#resId/’,”);var%20u=’http://storage.live.com/items/’+id+’?filename=’+encodeURI(n);var%20p=’http://’+document.location.host+’/redir.aspx?page=self&resId=’+id;var%20e=’<input%20onmouseover=%22this.select();%22%20onclick=%22this.select();%22%20value=%22′;var%20f=’%22%20style=%22width:580px%22%20type=%22text%22%20/><br>’;var%20d=’by%20(<a%20href=%22http://rpsh.net/%22>Rpsh</a>)’;var%20c=’u5916u94FEu5730u5740:’+d+e+u+f+’u5206u4EABu5730u5740:’+e+p+f;var%20a=document.getElementById(‘content’);var%20g=(a.getElementsByTagName(‘p’)[0]);var%20b=g?g:document.createElement(‘P’);b.innerHTML=c;a.insertBefore(b,a.firstChild);void(0)

3、打开的下载页会有如下变化(图1→图2):

变成

红框中的就是外链地址了!

现在就可以在线听歌了!

说明:

1、只适用于播放,不适用于下载

2、只有使用ie7或者firefox浏览器才能成功获取地址,用ie6可能无效

3、该外链地址不受文件在帐户中移动的影响,下面的引用地址同样如此

4、据原创作者说,该链接会在每日后半夜失效一段时间

5、建议使用SkyDrive Explorer来管理上传文件