HTML - Media Type Inline
Hi, i've been banging my head against the wall trying to find a solution, and have eventually given in..!
I'm creating an html email that has an image in it. Easy When that email is received and the user prints, it replaces the image with another more print friendly version. Easy using media:print in a style. However, when the user then replies to the email, all of the <style> in the <head> is wiped and the large un-printer friendly image remains. The only solution would be to put all styles inline within the <body>. So the question..! Any ideas how to replicate this process only coding within the body? thanks, J Similar TutorialsIn a nutshell: --- The following <li> tags are inline-blocks. Why does removing the closing <li> tags fix the whitespace issue? Code: <li>Item one</li> <li>Item two</li> <li>Item three</li> Versus... Code: <li>Item one <li>Item two <li>Item three The context of this question: --- From: CSS display: inline-Block: Why It Rocks, And Why It Sucks The above post is about using inline-block instead of float to position <li> elements, which is useful for making navigation bars. There is one drawback to using inline-block: (You can copy and paste the first piece of code below to see what I'm talking about.) If you restrict the <ul> to a particular width, your navbar won't display correctly, which has something to do with hitting the RETURN key between your lines of code (whitespace issues?). See below: This works fine because there we didn't hit RETURN to create a line break between each list. <li>Item One</li><li>Item Two</li> Here, we hit RETURN to put each list on a separate line and now the code doesn't display properly. The first piece of code below illustrates this problem. <li>Item One</li> <li>Item Two</li> The second piece of code solves this problem by using comments to remove the whitespace. The third piece of code solves this problem by removing the closing <li> tags. My question is, how does removing closing tags change anything? Are there any issues I should be aware of if I use this solution? Are there other contexts where I can apply a similar technique? Code: <style type="text/css"> ul#display-inline-block-example, ul#display-inline-block-example li { margin: 0; padding: 0; } ul#display-inline-block-example { width: 300px; border: 1px solid #000; } ul#display-inline-block-example li { display: inline-block; width: 100px; min-height: 100px; background: #ccc; vertical-align: top; } </style> <ul id="display-inline-block-example"> <li>Item one</li> <li>Item two</li> <li>Item three</li> </ul> Code: <style type="text/css"> ul#display-inline-block-example, ul#display-inline-block-example li { margin: 0; padding: 0; } ul#display-inline-block-example { width: 300px; border: 1px solid #000; } ul#display-inline-block-example li { display: inline-block; width: 100px; min-height: 100px; background: #ccc; vertical-align: top; } </style> <ul id="display-inline-block-example"> <li>Item one<!-- --><li>Item two</li><!-- --><li>Item three</li> </ul> Code: <style type="text/css"> ul#display-inline-block-example, ul#display-inline-block-example li { margin: 0; padding: 0; } ul#display-inline-block-example { width: 300px; border: 1px solid #000; } ul#display-inline-block-example li { display: inline-block; width: 100px; min-height: 100px; background: #ccc; vertical-align: top; } </style> <ul id="display-inline-block-example"> <li>Item one <li>Item two <li>Item three </ul> Conflict between Mime Type and Document Type... Morning - I have recently been learning CSS and have been upgrading my site to Semantically correct code. The first templat I am building is the following page http://www.colletts.co.uk/colletts_n...ndexflash.html and validates here validates... sort of. Should I be worried about the mime type, what effect will this have on the page. If I follow the instructions and change the file extension to xhtml all hell breaks loose - http://www.colletts.co.uk/colletts_n...dexflash.xhtml IE Error - can't open thios document etc... What am I doing wrong??? Best, Mas i have a drop down media player on my page. it is bigger than i want it to be until i click on a song, then it goes to the size i specified. how do i make it start out at that size? http://freewebs.com/kunaproxy/home.html. that is the page, and the media player is on the left. a little assistance would be great. thanx Hi everyone, Im having trouble with a video that i have put on my website. I have converted it from dvd to divx. Does anyone know of a good converter or if i can put in on to media player and play it off my website. If you can do that will some one be able to post me the html code. I am trying to use the media="print" or @media print to modify a piece of my page when it goes to print. Below, what you see in {} is a referencing a variabled created using hsql. I want to add media="print" {display: none;} in this reference but it doesn't seem to take it. Can anyone think of another solution. HTML Code: <a onClick="popup('{&metric}');"> <img src="http://broker-sas/SAS/irsrv/images/faq.gif" style="display:{&hide_img}; border: none;" width="15px" height="15px"> </img> </a> Hi I tried embedding windows media player normally, to play videos on my site. It works on this computer (after i downloaded the rite codecs), but it doesent work on my other pc, nor mac. Is there anything you guys know that i can get (maybe some sort of php thing, or some other code) to use windows media player, or something so that when i embedd it to the site, it works with no problmes. I tried some flash things, but there all so confusing, and im not good at flash, so i get lost in it. Thanks.. I am looking for some script that allows me to insert a media player in to my page, preferably windows media player. I currently have one inserted but i want it to be able to use more than one media file and have previous and next to play other songs. The current one i have is Code: <script type="text/javascript"> AC_AX_RunContent( 'id','MediaPlayer','width','100%','height','190','classid','CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95','standby','Loading Windows Media Player components...','type','application/x-oleobject','src','03-Slinkee Minx - Summer Rain (Alex K Mix).mp3','showcontrols','true','showstatusbar','true','showdisplay','false','autostart','false','filename','03-Slinkee Minx - Summer Rain (Alex K Mix).mp3' ); //end AC code </script><OBJECT ID="MediaPlayer" WIDTH="100%" HEIGHT="190" CLASSID="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" STANDBY="Loading Windows Media Player components..." TYPE="application/x-oleobject"> <PARAM NAME="FileName" VALUE="05-johnny_cash-long_black_veil.mp3"> <PARAM name="autostart" VALUE="false"> <PARAM name="ShowControls" VALUE="true"> <param name="ShowStatusBar" value="true"> <PARAM name="ShowDisplay" VALUE="false"> <EMBED TYPE="application/x-mplayer2" SRC="05-johnny_cash-long_black_veil.mp3" WIDTH="100%" HEIGHT="190" ShowControls="1" ShowStatusBar="1" ShowDisplay="0" autostart="0"> </EMBED> </OBJECT> Like i said this will only play one song that is specified and i want it to be able to play more than one file. Anyone got any good scripts to play multiple media files? Thanks. How do I get these to show up side by side rather than on top of eachother with space in between them. for an example of what it looks like now go to www.ecxgaming.com/genericnews.html and check out the facebook like button, twitter, and google plus button. Here is the code: HTML Code: <div id="fb-root"></div> <script>(function(d, s, id) { var js, fjs = d.getElementsByTagName(s)[0]; if (d.getElementById(id)) {return;} js = d.createElement(s); js.id = id; js.src = "//connect.facebook.net/en_US/all.js#xfbml=1"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'facebook-jssdk'));</script> <div class="fb-like" data-send="false" data-width="450" data-show-faces="true"></div> <a href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-via="ecxgaming">Tweet</a><script type="text/javascript" src="//platform.twitter.com/widgets.js"></script> <g:plusone size="small" annotation="inline"></g:plusone> <!-- Place this render call where appropriate --> <script type="text/javascript"> (function() { var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true; po.src = 'https://apis.google.com/js/plusone.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s); })(); </script> <!--End google like button--> Thanks in advance Hello, I have embedded Windows Media Player on this one page I have that streams a live weather radio feed I have here in my Office. In FF it works fine but the player does not work in IE. Here is the URL http://www.mesquitechristmas.com/wea...stmas&state=tx Here is the code for the player that I have embedded. HTML Code: <script language="JavaScript" type="text/javascript"> embedFeed("","http://audiostream.wunderground.com/MesquiteChristmas/DFW.mp3.m3u"); </script> <div align="center"><object height="40" width="200"><param name="type" value="application/x-mplayer2"><param name="src" value="http://audiostream.wunderground.com/MesquiteChristmas/DFW.mp3.m3u"><param name="autostart" value="1"><param name="showcontrols" value="1"><param name="showstatusbar" value="1"><embed src="http://audiostream.wunderground.com/MesquiteChristmas/DFW.mp3.m3u" type="application/x-mplayer2" autoplay="true" autostart="1" controller="1" showstatusbar="true" bgcolor="#FFFFFF" height="69" width="280"></object></div><noscript><br>Your browser does not have javascript enabled and can not use the embedded player.<br>You will need to <a href="http://audiostream.wunderground.com/MesquiteChristmas/DFW.mp3.m3u">click here</a> to listen to this stream using your default audio player.<br></noscript> Here is the Js script for it. HTML Code: // Batmosphere Embedded Media Player, version 2006-05-31 // Written by David Battino, www.batmosphere.com // OK to use if this notice is included // This function reads an MP3 URL and title from the referring page and generates embedding code to play back the audio file. // Windows browsers (except for Internet Explorer) will play back the file with the Windows Media Player *plugin.* Internet Explorer will use Windows Media Player. // Non-Windows browsers will play back the file with their standard audio handler for the MIME type audio/mpeg. On Macs, that handler will usually be QuickTime. var audioFolder = ""; // If you have a default audio directory, e.g., http://www.your-media-hosting-site.com/sounds/, you can put it here to make links on the referring page shorter. function embedFeed(MP3title,MP3URL) { // Get Operating System var isWin = navigator.userAgent.toLowerCase().indexOf("windows") != -1; if (isWin) { // Use MIME type application/x-mplayer2 visitorOS="Windows"; } else { // Use MIME type audio/mpeg, audio/x-wav, etc. visitorOS="Other"; } var audioURL = audioFolder + MP3URL; var objTypeTag = "application/x-mplayer2"; // The MIME type to load the WMP plugin in non-IE browsers on Windows if (visitorOS != "Windows") { objTypeTag = "audio/mpeg"}; // The MIME type for Macs and Linux document.write('<div>'); document.write('<strong style="font-size:18px; position:relative; top:-28px">' + MP3title + ' </strong>'); // Adjust font style to taste document.write('<object width="280" height="69">'); // Width is the WMP minimum. Height = 45 (WMP controls) + 24 (WMP status bar) document.write('<param name="type" value="' + objTypeTag + '">'); document.write('<param name="src" value="' + audioURL + '">'); document.write('<param name="autostart" value="1">'); document.write('<param name="showcontrols" value="1">'); document.write('<param name="showstatusbar" value="1">'); document.write('<embed src ="' + audioURL + '" type="' + objTypeTag + '" autoplay="true" autostart="1" width="280" height="69" controller="1" showstatusbar="true" bgcolor="#000000"></embed>'); // Firefox and Opera Win require both autostart and autoplay document.write('</object>'); document.write('</div>'); document.close(); // Finalizes the document } Any idea what might be causing this? -Thanks I have embedded the media player on the website using this code: Code: <object type="application/x-shockwave-flash" data="test.swf" width="345" height="90"> <param name="movie" value="../flash/test.swf"> </object> and it works fine except it doesn't seem to be able to load the sound. I have the sound in the same folder as the flash file and the sound runs fine when I test the .swf but not when I embed it into the website. I would like to incorparate a media player into my website. I want it to be a separate popup window and show the list of mp3's available for people to listen to. I looked around but couldn't find anything that great and couldn't figure out how to put it in. Any suggestions? Can you suggest a video media player that supports rtmp protocol and has no branding? Maybe an open source general license? Simply to play flv files on a web page. Thanks. (not JWPlayer or Flowplayer) Is it possible to control the windows media player embed: HTML Code: <EMBED showcontrols="false" showstatusbar="false" src="song.mp3" autostart="true" loop="false"></EMBED> using Href's? Honestly, my website looks great w/o having the "showcontrols" enabled and having that rather large and un-transparent background'ed media controller on it. I would really like to be able to add my own: HTML Code: <a href="function:play(or somethin liek that...)">Play</a><br><a href="function:stop">Stop</a> I have a way to do this in flash, and it works great, but I just like the portability of windows media player. Any ideas or suggestions? Thanks in advance, Yuri I have embedded Windows media Player in an HTML Form. My question is does the .wmv has to reside on the server in order for it to run? If this is true does the server have to have IIS installed in order for windows media player thats embedded in an HTML form play wav or wmv files. Can i use javascript to control the file that playing by the real audio plug in, i mean i embeded the plug in, and i want to dynamically assign the files by using the drop down listbox. I had tried it , but although i successfully set the filename, but cant control the start value. Another question is whether window media play can play real audion file or not ?? Thanks for answering. mother of the bride dress discount wedding dress mother of the groom dress Can i use javascript to control the file that playing by the real audio plug in, i mean i embeded the plug in, and i want to dynamically assign the files by using the drop down listbox. I had tried it , but although i successfully set the filename, but cant control the start value. Another question is whether window media play can play real audion file or not ?? Thanks for answering. mother of the bride discount wedding dresses mother of the groom dresses Hi all =) I'm using the following code: Code: <embed type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" name="mediaplayer1" showstatusbar="1" EnableContextMenu="false" autostart="true" width="230" height="240" transparentstart="1" loop="0" controller="true" src="http://www.bartend.com/ecourse/videos/bartendcom-margarita.wmv"> </embed> It makes people download WMP 11 to view the file. I want to be able to let it run in WMP 9 or 10. How can I fix this? Thank you =) Light and Love and Healing to you, -Patrick Arden McNally i am using megaupload for the first time, and so far i am totally confused in how im supposed to use it. that is beside the point, however. When i embed the player, my song does not play as it is supposed to. it does nto play at all, even when i tell it to play manually (even though it is set to autoplay). here is the code i embed into my site: ~~~ <OBJECT ID="MediaPlayer" WIDTH="192" HEIGHT="190" CLASSID="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" STANDBY="Loading Windows Media Player components..." TYPE="application/x-oleobject"> <PARAM NAME="FileName" VALUE="http://www.megaupload.com/03-30_seconds_to_mars-the_kill-h8me.mp3"> <PARAM name="autostart" VALUE="true"> <PARAM name="ShowControls" VALUE="true"> <param name="ShowStatusBar" value="true"> <PARAM name="ShowDisplay" VALUE="true"> <EMBED TYPE="application/x-mplayer2" SRC="http://www.megaupload.com/03-30_seconds_to_mars-the_kill-h8me.mp3" NAME="MediaPlayer" WIDTH="192" HEIGHT="190" ShowControls="1" ShowStatusBar="1" ShowDisplay="1" autostart="1"> </EMBED> </OBJECT> ~~~ i believe the problem is the link to the file. did i write the link correctly? how do i find the direct link to the file? can megaupload be used for this? i am having problems using megaupload, and so i think my problem is more about finding the correct link for my file and not so much a problem with the html itself, as i think i did all that correctly except for the 2 places the link to my file should be. if no one knows how to use megaupload, someone please tell me a good site to use to upload music files. |