<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-2187020455970780738</id><updated>2024-08-29T04:29:41.467+08:00</updated><category term="HTML"/><category term="CSS"/><category term="js"/><category term="php"/><category term="AS3"/><category term="Joomla"/><category term="jQuery"/><category term="AS2"/><category term="Facebook"/><category term="Joomla Extensions"/><category term="createjs"/><category term="facebook sharer"/><category term="graph"/><category term="2345"/><category term="IE"/><category term="IE7"/><category term="K2"/><category term="ajax"/><category term="apache"/><category term="cheat engine"/><category term="cjk"/><category term="cordova"/><category term="custom"/><category term="directory"/><category term="flash"/><category term="google map v3"/><category term="hao123"/><category term="hijack"/><category term="infobox"/><category term="json"/><category term="must-have"/><category term="og:descripion"/><category term="og:image"/><category term="og:title"/><category term="pdf"/><category term="phonegap"/><category term="php email"/><category term="placeholder"/><category term="safari"/><category term="scrollbar"/><category term="windows phone"/><category term="一般"/><category term="移除"/><category term="首頁綁架"/><title type='text'>about my life of multimedia</title><subtitle type='html'>全世界的人都在吃飯, 然而只有少數的人種田&#xa;明白種田者那份喜悅的人. . . . . .又有多少個呢?</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>31</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-5153275678565546502</id><published>2017-04-13T13:42:00.001+08:00</published><updated>2017-04-13T13:42:46.256+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="cjk"/><category scheme="http://www.blogger.com/atom/ns#" term="createjs"/><title type='text'>createjs TextField CJK text wrapping support</title><content type='html'>The TextField of official createjs supports only very basic text wrapping. It sucks when the content is CJK characters like Chinese, Korean &amp;amp; Japanese.&lt;br /&gt;
&lt;br /&gt;
Here you are the workaround:&lt;br /&gt;
&lt;br /&gt;
find the private method p._drawText in createjs (or easeljs for non combinded) and replace with the following code&lt;br /&gt;
this code has been well tested with one of my projects for half year&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;/**
  * Draws multiline text.
  * @method _drawText
  * @param {CanvasRenderingContext2D} ctx
  * @param {Object} o
  * @param {Array} lines
  * @return {Object}
  * @protected
  **/
 p._drawText = function(ctx, o, lines) {
  var paint = !!ctx;
  if (!paint) {
   ctx = Text._workingContext;
   ctx.save();
   this._prepContext(ctx);
  }
  var lineHeight = this.lineHeight || this.getMeasuredLineHeight();

  var maxW = 0,
   count = 0;
  var hardLines = String(this.text).split(/(?:\r\n|\r|\n)/);
  for (var i = 0, l = hardLines.length; i &amp;lt; l; i++) {
   var str = hardLines[i];
   var w = null;

   if (this.lineWidth != null &amp;amp;&amp;amp; (w = ctx.measureText(str).width) &amp;gt; this.lineWidth) {
    // text wrapping:
    // hanyeah CJK wrapping
    var words0;
    var words;
    if ((/[\u4e00-\u9fa5]+/).test(str)) { //contains CJK characters
     words0 = str.split(/(\s)/);
     words = [];
     for (var hi = 0; hi &amp;lt; words0.length; hi++) {
      var hs = &quot;&quot;;
      for (var hj = 0; hj &amp;lt; words0[hi].length; hj++) {
       var hjs = words0[hi][hj];
       if (hjs.charCodeAt(0) &amp;gt; 255) {
        if (hs != &quot;&quot;) {
         words.push(hs);
        }
        words.push(hjs);
        hs = &quot;&quot;;
       } else {
        hs += hjs;
       }
      }
      if (hs != &quot;&quot;) {
       words.push(hs);
      }
     }
    } else {
     words = str.split(/(\s)/);
    }
    str = words[0];
    w = ctx.measureText(str).width;

    for (var j = 1, jl = words.length; j &amp;lt; jl; j += 1) {
     // Line needs to wrap:
     var wordW = ctx.measureText(words[j]).width;
     if (w + wordW &amp;gt; this.lineWidth) {
      if (paint) {
       this._drawTextLine(ctx, str, count * lineHeight);
      }
      if (lines) {
       lines.push(str);
      }
      if (w &amp;gt; maxW) {
       maxW = w;
      }
      str = words[j];
      w = ctx.measureText(str).width;
      count++;
     } else {
      str += words[j];
      w += wordW;
     }
    }
   }
   //end hanyeah CJK wrapping
   if (paint) {
    this._drawTextLine(ctx, str, count * lineHeight);
   }
   if (lines) {
    lines.push(str);
   }
   if (o &amp;amp;&amp;amp; w == null) {
    w = ctx.measureText(str).width;
   }
   if (w &amp;gt; maxW) {
    maxW = w;
   }
   count++;
  }

  if (o) {
   o.width = maxW;
   o.height = count * lineHeight;
  }
  if (!paint) {
   ctx.restore();
  }
  return o;
 };
&lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/5153275678565546502/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2017/04/createjs-textfield-cjk-text-wrapping.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/5153275678565546502'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/5153275678565546502'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2017/04/createjs-textfield-cjk-text-wrapping.html' title='createjs TextField CJK text wrapping support'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-9163622622220460784</id><published>2017-02-03T14:35:00.001+08:00</published><updated>2017-04-13T17:46:48.911+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="apache"/><category scheme="http://www.blogger.com/atom/ns#" term="custom"/><category scheme="http://www.blogger.com/atom/ns#" term="directory"/><category scheme="http://www.blogger.com/atom/ns#" term="php"/><title type='text'>XAMPP Apache Custom Directory list</title><content type='html'>&lt;div&gt;
To modify the default ugly directory list, normaly we need to modify mod_autoindex and recompile blar blar.&lt;br /&gt;
&lt;br /&gt;
For me, i have no any knowledge of C, such actions will drive me nuts.&lt;br /&gt;
&lt;br /&gt;
We are going to re write the directory using PHP, CSS &amp;amp; HTML. no C knowledge required&lt;br /&gt;
&lt;br /&gt;
Here are the summary of what we&#39;ll doing:&lt;br /&gt;
&lt;br /&gt;
1. Config .htaccess file&lt;br /&gt;
&lt;br /&gt;
2. Prepare html assets&lt;br /&gt;
&lt;br /&gt;
3. Hide original Directory output&lt;br /&gt;
&lt;br /&gt;
4. Inject our php code&lt;br /&gt;
&lt;br /&gt;
For easier to explain, i will create everything in root folder (rootFolder)&lt;br /&gt;
&lt;br /&gt;
the default root folder of xampp should be c:/xampp/htdocs/ &lt;br /&gt;
create a folder (custom_dir) in rootFolder which contains your custom html code&lt;br /&gt;
create a .htaccess file in rootFolder and copy the following code&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:xml&quot;&gt;&amp;lt;!-- .htaccess --&amp;gt;

# DIRECTORY CUSTOMIZATION 
&amp;lt;IfModule mod_autoindex.c&amp;gt; 
 # SET INDEX OPTIONS - this enable using FancyIndexing and tell apache we will use our own html to generate the directory list
 IndexOptions IgnoreCase FancyIndexing FoldersFirst NameWidth=* DescriptionWidth=* SuppressHTMLPreamble

 # SPECIFY HEADER FILE - tell Apache where our header file stores
 HeaderName /custom_dir/header.php 

 # SPECIFY FOOTER FILE - tell Apache where our footer file stores (yes, we use ReadmeName as our footer, since ReadmeName will keep generated at the bottom)
 ReadmeName /custom_dir/footer.html 

 # IGNORE THESE FILES - hide our html asset file in directory list
 IndexIgnore /custom_dir 
&amp;lt;/IfModule&amp;gt;
    &lt;/pre&gt;
&lt;br /&gt;
create a header.php into custom_dir, we will write our own code to generate the list&lt;br /&gt;
&lt;pre class=&quot;brush:php&quot;&gt;&amp;lt;!-- header.php --&amp;gt;   

&amp;lt;?php
$serverRoot = $_SERVER[&#39;DOCUMENT_ROOT&#39;];
$cssPath = $serverRoot.&#39;/custom_dir/css.php&#39;;

$currentPath = $_SERVER[&#39;DOCUMENT_ROOT&#39;].$_SERVER[&#39;REQUEST_URI&#39;]; //always get the &#39;current&#39; folder
$dirList = new DirectoryIterator(str_replace(&#39;/&#39;, &#39;\\&#39;, $currentPath)); //just replace front-slash in case there&#39;re
?&amp;gt;
 
&amp;lt;html&amp;gt; 
 &amp;lt;head&amp;gt; 
  &amp;lt;title&amp;gt;Directory Title&amp;lt;/title&amp;gt;
  
  &amp;lt;!-- make our directory responsive --&amp;gt;
  &amp;lt;meta charset=&quot;UTF-8&quot;&amp;gt;
  &amp;lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1&quot;&amp;gt;
  
  &amp;lt;style&amp;gt;
   &amp;lt;?php include_once($cssPath); //hide our system path?&amp;gt; 
  &amp;lt;/style&amp;gt;
 &amp;lt;/head&amp;gt;

 &amp;lt;body&amp;gt;
  &amp;lt;header&amp;gt;
   &amp;lt;h1&amp;gt;Directory Title&amp;lt;/h1&amp;gt;
  &amp;lt;/header&amp;gt;

  &amp;lt;div&amp;gt;
   &amp;lt;table class=&#39;dirTable&#39;&amp;gt; 
    &amp;lt;tr&amp;gt;
     &amp;lt;th&amp;gt;Name&amp;lt;/th&amp;gt;
     &amp;lt;th&amp;gt;Last modified&amp;lt;/th&amp;gt;
    &amp;lt;/tr&amp;gt; 

    &amp;lt;?php foreach($dirList as $fileInfo): ?&amp;gt;
    &amp;lt;tr class=&#39;dirItem&#39;&amp;gt;
     &amp;lt;td&amp;gt; &amp;lt;a href=&#39;&amp;lt;?=$fileInfo-&amp;gt;getFilename() ?&amp;gt;&#39;&amp;gt;&amp;lt;?=$fileInfo-&amp;gt;getFilename() ?&amp;gt;&amp;lt;/a&amp;gt; &amp;lt;/td&amp;gt;
     &amp;lt;td&amp;gt; &amp;lt;?=date( &quot;Y-m-d H:i&quot;, $fileInfo-&amp;gt;getMTime()) ?&amp;gt; &amp;lt;/td&amp;gt;
    &amp;lt;/tr&amp;gt;
    &amp;lt;?php endforeach; ?&amp;gt;
   &amp;lt;/table&amp;gt;
  &amp;lt;/div&amp;gt;
    &lt;/pre&gt;
&lt;/div&gt;
&lt;br /&gt;
then create the footer.php and do whatever you like&lt;br /&gt;
&lt;pre class=&quot;brush:xml&quot;&gt;&amp;lt;!-- footer.php --&amp;gt;
   &amp;lt;footer class=&#39;yourFooterClass&#39;&amp;gt;
    YOUR OWN FOOTER HTML CODE
   &amp;lt;/footer&amp;gt;
 &amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;
  &lt;/pre&gt;
next, create css.php, by doing this instead of &amp;lt;link&amp;gt; is to hide the source path&lt;br /&gt;
&lt;pre class=&quot;brush:css&quot;&gt;/*the default list is generated by pre, we simply hide this by applying this css rule*/
pre { display:none; !important};

/*then do whatever you like*/ 
  &lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/9163622622220460784/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2017/02/xampp-apache-custom-directory-list.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9163622622220460784'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9163622622220460784'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2017/02/xampp-apache-custom-directory-list.html' title='XAMPP Apache Custom Directory list'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-9008871137159491669</id><published>2016-09-01T14:29:00.000+08:00</published><updated>2016-09-01T14:44:45.704+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="createjs"/><title type='text'>solve createjs DOMElement responsive</title><content type='html'>replace the function p._handleDrawEnd in Easeljs with the code below&lt;br /&gt;
&lt;br /&gt;
credits to Ferry Kranenburg&lt;br /&gt;
http://stackoverflow.com/questions/27593088/using-domelement-input-text-and-resizing-canvas&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;p._handleDrawEnd = function(evt) {
  var o = this.htmlElement;
  if (!o) { return; }
  var style = o.style;

  var props = this.getConcatenatedDisplayProps(this._props), mtx = props.matrix;

  var visibility = props.visible ? &quot;visible&quot; : &quot;hidden&quot;;
  if (visibility != style.visibility) { style.visibility = visibility; }
  if (!props.visible) { return; }

  // Change position of domElement
  var stage = this.getStage();        
  var ratio = $(canvas).width() / 1000; //replace the number to your canvas width
  mtx.scale(ratio,ratio);
  mtx.tx = mtx.tx*ratio;
  mtx.ty = mtx.ty*ratio;
  // End change position of domElement

  var oldProps = this._oldProps, oldMtx = oldProps&amp;&amp;oldProps.matrix;
  var n = 10000; // precision

  if (!oldMtx || !oldMtx.equals(mtx)) {
   var str = &quot;matrix(&quot; + (mtx.a*n|0)/n +&quot;,&quot;+ (mtx.b*n|0)/n +&quot;,&quot;+ (mtx.c*n|0)/n +&quot;,&quot;+ (mtx.d*n|0)/n +&quot;,&quot;+ (mtx.tx+0.5|0);
   style.transform = style.WebkitTransform = style.OTransform = style.msTransform = str +&quot;,&quot;+ (mtx.ty+0.5|0) +&quot;)&quot;;
   style.MozTransform = str +&quot;px,&quot;+ (mtx.ty+0.5|0) +&quot;px)&quot;;
   if (!oldProps) { oldProps = this._oldProps = new createjs.DisplayProps(true, NaN); }
   oldProps.matrix.copy(mtx);
  }

  if (oldProps.alpha != props.alpha) {
   style.opacity = &quot;&quot;+(props.alpha*n|0)/n;
   oldProps.alpha = props.alpha;
  }

 };
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/9008871137159491669/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2016/09/solve-createjs-domelement-responsive.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9008871137159491669'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9008871137159491669'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2016/09/solve-createjs-domelement-responsive.html' title='solve createjs DOMElement responsive'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-1871744448098106079</id><published>2016-08-22T17:47:00.001+08:00</published><updated>2016-08-22T17:47:15.050+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AS3"/><category scheme="http://www.blogger.com/atom/ns#" term="flash"/><title type='text'>Solve Error: Version required to extract this entry not supported (788) on SWC</title><content type='html'>to solve this issue&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;ol&gt;
&lt;li&gt;rename your xxxx.swc to xxxx.zip&lt;/li&gt;
&lt;li&gt;unzip it&lt;/li&gt;
&lt;li&gt;rezip it&lt;/li&gt;
&lt;li&gt;rename .zip back to .swc&lt;/li&gt;
&lt;/ol&gt;
&lt;br /&gt;
&lt;br /&gt;
done~ : D</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/1871744448098106079/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2016/08/solve-error-version-required-to-extract.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1871744448098106079'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1871744448098106079'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2016/08/solve-error-version-required-to-extract.html' title='Solve Error: Version required to extract this entry not supported (788) on SWC'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-3040208609837786931</id><published>2016-01-07T19:14:00.001+08:00</published><updated>2016-01-08T10:26:38.557+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="php"/><title type='text'>remove &amp;#65279 BOM</title><content type='html'>http://stackoverflow.com/questions/10290849/how-to-remove-multiple-utf-8-bom-sequences-before-doctype&lt;br /&gt;
&lt;br /&gt;
credits to &lt;a href=&quot;http://stackoverflow.com/users/516859/jasonhao&quot;&gt;Jasonhao&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
//Remove UTF8 Bom&lt;br /&gt;
&lt;br /&gt;
function remove_utf8_bom($text)&lt;br /&gt;
{&lt;br /&gt;
$bom = pack(&#39;H*&#39;,&#39;EFBBBF&#39;);&lt;br /&gt;
$text = preg_replace(&quot;/^$bom/&quot;, &#39;&#39;, $text);&lt;br /&gt;
return $text;&lt;br /&gt;
}</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/3040208609837786931/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2016/01/remove.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/3040208609837786931'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/3040208609837786931'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2016/01/remove.html' title='remove &amp;#65279 BOM'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-1648661921642217936</id><published>2015-06-26T03:56:00.000+08:00</published><updated>2015-10-12T00:34:42.917+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="php"/><title type='text'>php pass data to include_once() require_once()</title><content type='html'>The following code shows how to pass params to included files in php&lt;br /&gt;
it works also in the following functions:&lt;br /&gt;
include()&lt;br /&gt;
include_once()&lt;br /&gt;
require()&lt;br /&gt;
require_once()&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;font-family: &#39;&#39;;&quot;&gt;&lt;u&gt;application.php&lt;/u&gt;&lt;/div&gt;&lt;div style=&quot;font-family: &#39;&#39;;&quot;&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;Using an Associative array to carry variables would be an ideal option.&lt;/span&gt;&lt;/div&gt;&lt;pre class=&quot;brush:js&quot;&gt;&amp;lt;?php
$m = new Main();

$items = array(
 &#39;name&#39;=&amp;gt; &#39;John Doe&#39;,
 &#39;items&#39;=&amp;gt;array(&#39;stone&#39;, &#39;knife&#39;, &#39;card&#39;, &#39;etc...&#39;)
);

$m-&amp;gt;loadViewWithParams(&#39;item_list_view.php&#39;, $items);
?&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
&lt;u&gt;Main.php&lt;/u&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;For variables which visibles to the line above the include(), they also visibles to the included file.&lt;/span&gt;&lt;br /&gt;
We simply create variables just above the include() just the way that many people do so.&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;Since we&#39;ve passed an associative array to loadViewWithParams(), we will break the array into variables in runtime.&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;&amp;lt;?php
class Main {
/**
*
*@param $path string the file path to load.
*@param $params array an associative array which carry data to the loaded file.
*/
  public function loadViewWithParams($path, $params = array()){
    //we use a foreach to parse the array to variables
    foreach ($params as $key =&amp;gt; $value ) {
      $$key = $value;
    }

    include_once($path);
  }
}
?&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
&lt;u&gt;item_list_view.php&lt;/u&gt;&lt;br /&gt;
consider the application.php above&lt;br /&gt;
the loadViewWithParams() method converted the array into variables&lt;br /&gt;
now both $name and $item were passed to the included file&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;&amp;lt;div&amp;gt;
 &amp;lt;h1&amp;gt;Welcome, &amp;lt;?php echo $name; ?&amp;gt; &amp;lt;/h1&amp;gt;
 here are your items
 &amp;lt;ul&amp;gt;
  &amp;lt;?php foreach($myItemList as $item): ?&amp;gt;
  &amp;lt;li&amp;gt;&amp;lt;?php echo $item; ?&amp;gt;&amp;lt;/li&amp;gt;
  &amp;lt;?php endforeach; ?&amp;gt;
 &amp;lt;ul&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/1648661921642217936/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2015/06/php-pass-data-include-require.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1648661921642217936'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1648661921642217936'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2015/06/php-pass-data-include-require.html' title='php pass data to include_once() require_once()'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-6976785973637774476</id><published>2015-03-30T02:20:00.000+08:00</published><updated>2015-07-20T10:46:27.491+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Joomla"/><category scheme="http://www.blogger.com/atom/ns#" term="Joomla Extensions"/><category scheme="http://www.blogger.com/atom/ns#" term="must-have"/><title type='text'>Joomla must-have installation list</title><content type='html'>This is the list that i find that it is a MUST-HAVE extensions for starting a Joomla project:&lt;br /&gt;(last review: 20th July, 2015)&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;http://getk2.org/index.php&quot; target=&quot;_blank&quot;&gt;K2&lt;/a&gt;&amp;nbsp;(Component, Plugin, Module)&lt;br /&gt;
This is a replacement of original Joomla article system which provide you a more flexible way to create content. &lt;br /&gt;&lt;br /&gt;
K2 comes with some modules such as k2_content to let you display your k2 items in various way you like.&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;&lt;a href=&quot;http://extensions.joomla.org/extension/multiple-images-for-k2&quot; target=&quot;_blank&quot;&gt;Multiple-images-for-k2&lt;/a&gt;&amp;nbsp;(Plugin)&lt;br /&gt;
Default, each k2 items can only insert 1 image, it enables K2 to insert more than 1 image per item.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://extensions.joomla.org/extensions/extension/core-enhancements/coding-a-scripts-integration/flexi-custom-code&quot; style=&quot;font-family: &#39;&#39;;&quot; target=&quot;_blank&quot;&gt;Flexi Custom Code&lt;/a&gt;&amp;nbsp;(Module)&lt;br /&gt;
It is a complete replacement of the built-in sucky Custom-HTML module. Say&amp;nbsp;goodbye&amp;nbsp;the Custom-HTML module~~. Now you can use php, css and js in your custom module WITHIN THE JOOMLA FRAMEWORK. &lt;br /&gt;&lt;br /&gt;As i introduced in my &lt;a href=&quot;http://littleshell-multimedia.blogspot.hk/2015/03/flexi-custom-code-joomla-module.html&quot; style=&quot;font-family: &#39;&#39;;&quot; target=&quot;_blank&quot;&gt;previous article&lt;/a&gt;, it saves your life in case of your Joomla project is full of custom&amp;nbsp;requirements&amp;nbsp;which cannot be done in normal way.&lt;br /&gt;&lt;br /&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://extensions.joomla.org/extension/fabrik&quot; target=&quot;_blank&quot;&gt;Fabrik&lt;/a&gt; (Component, Plugin, Module)&lt;br /&gt;
Fabrik gives you the power to create forms and tables that run inside Joomla without requiring knowledge of mySQL and PHP.&lt;br /&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://joomlacode.org/gf/project/blankcomponent/frs/&quot; target=&quot;_blank&quot;&gt;Blank Component&lt;/a&gt;&amp;nbsp;(Component)&lt;br /&gt;Simply let you create a blank module only section without creating a zero article category&lt;br /&gt;&lt;br /&gt;
&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;&lt;a href=&quot;https://www.nonumber.nl/extensions/modulesanywhere&quot; target=&quot;_blank&quot;&gt;Modules Anywhere&lt;/a&gt; (Plugin, Editor button plugin)&lt;br /&gt;
With this plugin, you can force display any module to anywhere you like. for example sometimes you would like to force display a module in another location... such as.. k2 Item...&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;&lt;a href=&quot;http://extensions.joomla.org/extension/acl-manager&quot; target=&quot;_blank&quot;&gt;ACL Manager&lt;/a&gt; (paid) (Component)&lt;br /&gt;
The complete replacement of built-in ACL manager. It makes the ACL interface much easier to use. The built-in ACL system is very confuse and hard to use. Although it is not free, it&#39;s worth to pay.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;&lt;a href=&quot;https://www.nonumber.nl/extensions/advancedmodulemanager&quot; style=&quot;font-family: &#39;&#39;;&quot; target=&quot;_blank&quot;&gt;Advanced Module Manager&lt;/a&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;&amp;nbsp;(Component, Plugin)&lt;/span&gt;&lt;br style=&quot;font-family: &#39;&#39;;&quot; /&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;A replacement of original module manager. It provide a more detail way to manage your modules. The free version is good enough.&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
i will keep updating this list once i discovered any new useful extensions. Hope those extensions helps you to develop Joomla site</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/6976785973637774476/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2015/03/joomla-must-have-installation-list.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6976785973637774476'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6976785973637774476'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2015/03/joomla-must-have-installation-list.html' title='Joomla must-have installation list'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-3872225520657090791</id><published>2015-03-18T04:05:00.000+08:00</published><updated>2015-06-18T10:59:16.283+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Joomla"/><category scheme="http://www.blogger.com/atom/ns#" term="Joomla Extensions"/><category scheme="http://www.blogger.com/atom/ns#" term="K2"/><title type='text'>Flexi Custom Code Joomla module</title><content type='html'>Joomla is good for quick cms project but once the client needs special&amp;nbsp;requirement, welcome to the hell~~. (Yeh&amp;nbsp;actually&amp;nbsp;I&#39;m wandering at the hell now . . . . .)&lt;br /&gt;
&lt;br /&gt;
Im working on a project, for some reason, most of data were not retrieve from K2 items table nor Joomla article table but few another custom tables.&lt;br /&gt;
&lt;br /&gt;
in this case, obviously, non of modules in the world fit our needs.&lt;br /&gt;
&lt;br /&gt;
ok~ in short, the problem is:&lt;br /&gt;
1. Our content were not from Joomla Article nor K2 Items (for some reason, dont ask me why)&lt;br /&gt;
2. We need to migrate the whole Joomla site&#39;s module/plugins to support our content table&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;The built-in Custom HTML module is a joke.&lt;/b&gt; it Just simply STATIC HTML and thats it.&lt;br /&gt;
&lt;br /&gt;
Plugin can extend your joomla site in many ways but you have no way to decide where your plugin should display.&lt;br /&gt;
&lt;br /&gt;
here you&#39;re few&amp;nbsp;solutions:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;ol&gt;
&lt;li&gt;&lt;br /&gt;
&lt;h3&gt;
Modify existing extensions&lt;/h3&gt;
Since the data source is not related to K2 items nor Joomla article now, we are free to modify the existing module to migrate our custom table, or simply download any modules with cool effect and ignores if it supports K2 or not.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This solution will fits 1 requirement. what if another one? I mean use the same layout with completely different source. Would u like to add N settings in the module xml file or duplicate the module?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Also modifying an module will makes the module setting useless since we&#39;re no need to/unable to care about them. it makes your module chaos --- What if i need this module to display normal k2 items in future?&lt;br /&gt;
&lt;/li&gt;
&lt;li&gt;&lt;br /&gt;
&lt;h3&gt;
Sub-templating the mod_k2_content&lt;/h3&gt;
K2 comes with a cool module &lt;i&gt;k2 content.&amp;nbsp;&lt;/i&gt;&amp;nbsp;This module have a complete settings to let you filter your k2 items in whatever you want. and the coolest setting of k2 content is sub-templating.&lt;br /&gt;
&lt;br /&gt;
it lets you create custom layout of K2 items in any way you like&lt;br /&gt;
&lt;br /&gt;
Sounds cool eh? yes it is IF OUR DATA SOURCE ARE FROM K2 ITEMS.&lt;br /&gt;
&lt;br /&gt;
with this solution, you will need to create tons of subtemplates and you will also need to create helpers for each template. And the same cons -- it will ignores all setting of the module because you dont need to use them.&lt;br /&gt;
&lt;/li&gt;
&lt;li&gt;&lt;h3&gt;
write your own&lt;/h3&gt;
it&amp;nbsp;should&amp;nbsp;be an ideal&amp;nbsp;solution&amp;nbsp;if time is not an issue.&lt;br /&gt;
&lt;/li&gt;
&lt;/ol&gt;
so what im going to show you today is:  &lt;br /&gt;
&lt;a href=&quot;http://extensions.joomla.org/extensions/extension/core-enhancements/coding-a-scripts-integration/flexi-custom-code&quot; target=&quot;_blank&quot;&gt;Flexi Custom Code&lt;/a&gt; I can say this is a&amp;nbsp;robust version of built-in Custom HTML&lt;br /&gt;
This is a module to let you write your own html, php, js, css&lt;br /&gt;
It can use all Joomla classes such as JURI:base(), JFactory::getDBO()&lt;br /&gt;
You can even use exit() in this module&lt;br /&gt;
(the php include() function seems not work so well in this module)&lt;br /&gt;
the only setting of Flexi Custom Code is your source code. Feel free to write your own layout and feel free to call any fancy query and call from any other DB tables&lt;br /&gt;
Just think it as you write with plain php page~</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/3872225520657090791/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2015/03/flexi-custom-code-joomla-module.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/3872225520657090791'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/3872225520657090791'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2015/03/flexi-custom-code-joomla-module.html' title='Flexi Custom Code Joomla module'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-8341253065914864154</id><published>2014-12-10T18:44:00.001+08:00</published><updated>2014-12-10T18:47:41.729+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Joomla"/><title type='text'>Joomla installation hangs solusion</title><content type='html'>For those who hangs during the joomla installation, here is the solution:&lt;br /&gt;
&lt;br /&gt;
at the &amp;lt;your-site-root&amp;gt;/libraries/joomla/filter/input.php&lt;br /&gt;
around line 660&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: as3&quot;&gt;// Convert decimal
//$source = preg_replace(&#39;/&amp;amp;#(\d+);/me&#39;, &quot;utf8_encode(chr(\\1))&quot;, $source); // decimal notation
$source = preg_replace_callback(&#39;/&amp;amp;#(\d+);/m&#39;, function($m){return utf8_encode(chr($m[1]));}, $source); // decimal notation
&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;
// Convert hex
//$source = preg_replace(&#39;/&amp;amp;#x([a-f0-9]+);/mei&#39;, &quot;utf8_encode(chr(0x\\1))&quot;, $source); // hex notation
$source = preg_replace_callback(&#39;/&amp;amp;#x([a-f0-9]+);/mi&#39;, function($m){return utf8_encode(chr(&#39;0x&#39;.$m[1]));}, $source); // hex notation
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/8341253065914864154/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/12/joomla-installation-hangs-solusion.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/8341253065914864154'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/8341253065914864154'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/12/joomla-installation-hangs-solusion.html' title='Joomla installation hangs solusion'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-9053716903657340390</id><published>2014-12-10T18:43:00.000+08:00</published><updated>2014-12-10T18:43:07.663+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="CSS"/><title type='text'>font-weight: bold not works in safari</title><content type='html'>given CSS&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: css&quot;&gt;@font-face {

&amp;nbsp;font-family: Frutiger;

&amp;nbsp;src: url(&#39;../fonts/frutiger_ce_45_light.otf&#39;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.ttf&#39;) format(&#39;truetype&#39;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.woff&#39;) format(&quot;woff&quot;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.eot&#39;) format(&#39;embedded-opentype&#39;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.eot?#iefix&#39;) format(&#39;embedded-opentype&#39;);

}



.someBoldFont {

&amp;nbsp;font-family: Frutiger;

}
&lt;/pre&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: xml&quot;&gt;&amp;lt;span class=&quot;someBoldFont&quot;&amp;gt;hello world&amp;lt;/span&amp;gt;
&lt;/pre&gt;
you&#39;ll notice that the word wont bold in Safari&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
here are the solution&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: css&quot;&gt;@font-face {

&amp;nbsp;font-family: Frutiger;



&amp;nbsp;/* add this 2 style rule */

&amp;nbsp;font-weight: normal;

&amp;nbsp;font-style: normal;

&amp;nbsp;/* end add */



&amp;nbsp;src: url(&#39;../fonts/frutiger_ce_45_light.otf&#39;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.ttf&#39;) format(&#39;truetype&#39;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.woff&#39;) format(&quot;woff&quot;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.eot&#39;) format(&#39;embedded-opentype&#39;),

&amp;nbsp; &amp;nbsp;url(&#39;../fonts/frutiger_ce_45_light.eot?#iefix&#39;) format(&#39;embedded-opentype&#39;);

}

&lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/9053716903657340390/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/12/font-weight-bold-not-works-in-safari.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9053716903657340390'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9053716903657340390'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/12/font-weight-bold-not-works-in-safari.html' title='font-weight: bold not works in safari'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-8472233337829083822</id><published>2014-11-24T14:31:00.000+08:00</published><updated>2014-11-24T14:31:29.531+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="CSS"/><category scheme="http://www.blogger.com/atom/ns#" term="HTML"/><category scheme="http://www.blogger.com/atom/ns#" term="safari"/><title type='text'>solve safari weird display when resize problem</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjP_ZPYkOUbIEwPxG4NgzyvX9zyudsvmoD5PnkrjvjvtuwzBdpbvFuoAWaG7uir9Pu9MInyjUjF603nPATC4QVCyVsIW43XM2g94_2YkVlYrBqqv0_fHfNJNrTjsukxwLOv0EBsh4MkINM/s1600/screen_shot.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjP_ZPYkOUbIEwPxG4NgzyvX9zyudsvmoD5PnkrjvjvtuwzBdpbvFuoAWaG7uir9Pu9MInyjUjF603nPATC4QVCyVsIW43XM2g94_2YkVlYrBqqv0_fHfNJNrTjsukxwLOv0EBsh4MkINM/s1600/screen_shot.jpg&quot; height=&quot;236&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
the image shows the weired layout display at safari when resizing the html page&lt;br /&gt;
&lt;br /&gt;
it looks totally fuxked up, but the HTML are just fine&amp;nbsp;actually&amp;nbsp;when you select any items on the page, because safari just render the graphic wrongly.&lt;br /&gt;
&lt;br /&gt;
the problem causes is that i used negative z-index in my CSS&lt;br /&gt;
&lt;br /&gt;
to solve it, simply change all&amp;nbsp;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;negative z-index to &amp;gt;=0&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/8472233337829083822/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/11/solve-safari-weird-display-when-resize.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/8472233337829083822'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/8472233337829083822'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/11/solve-safari-weird-display-when-resize.html' title='solve safari weird display when resize problem'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjP_ZPYkOUbIEwPxG4NgzyvX9zyudsvmoD5PnkrjvjvtuwzBdpbvFuoAWaG7uir9Pu9MInyjUjF603nPATC4QVCyVsIW43XM2g94_2YkVlYrBqqv0_fHfNJNrTjsukxwLOv0EBsh4MkINM/s72-c/screen_shot.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-6846458122556199583</id><published>2014-10-03T18:10:00.000+08:00</published><updated>2015-06-26T10:05:24.504+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="php"/><category scheme="http://www.blogger.com/atom/ns#" term="php email"/><title type='text'>php email 標題 主旨 寄件者 亂碼問題</title><content type='html'>&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;&amp;lt;?php&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;function emailEncode($str) {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;&amp;nbsp; return&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;&quot;=?UTF-8?B?&quot;.base64_encode(&lt;/span&gt;&lt;span style=&quot;background-color: white; color: blue; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px; margin: 0px auto;&quot;&gt;$str&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;).&quot;?=&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;$subject =&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;emailEncode(&quot;hello world&quot;);&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;$sender =&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;emailEncode(&quot;littleshell&quot;);&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #666666; font-family: &#39;Open Sans&#39;, Arial, Helvetica, sans-serif; font-size: 15px; letter-spacing: 1.0499999523162842px; line-height: 26.25px;&quot;&gt;?&amp;gt;&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/6846458122556199583/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/10/php-email.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6846458122556199583'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6846458122556199583'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/10/php-email.html' title='php email 標題 主旨 寄件者 亂碼問題'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-9086747938499799276</id><published>2014-06-11T03:00:00.000+08:00</published><updated>2017-07-05T09:59:22.978+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="2345"/><category scheme="http://www.blogger.com/atom/ns#" term="hao123"/><category scheme="http://www.blogger.com/atom/ns#" term="hijack"/><category scheme="http://www.blogger.com/atom/ns#" term="移除"/><category scheme="http://www.blogger.com/atom/ns#" term="首頁綁架"/><title type='text'>2345 hao123 hijack solusion</title><content type='html'>小弟早排被萬惡的2345.com 綁架了&lt;br /&gt;
&lt;span style=&quot;font-family: &amp;quot;&amp;quot;;&quot;&gt;2345.com&lt;/span&gt;是大陸網站, 還是用中文寫吧&lt;br /&gt;
&lt;br /&gt;
這個一般殺毒是掃不到的&lt;br /&gt;
&lt;br /&gt;
上網看了不下100個所謂解決方法, 沒有一個有用&lt;br /&gt;
&lt;br /&gt;
例如用甚麼軟件掃描&lt;br /&gt;
用甚麼anti malware 掃描&lt;br /&gt;
重改首頁 (這個可笑, 當然沒效, 那麼強力的hijacker 會那麼輕易讓你更改首頁嗎)&lt;br /&gt;
改regedit&lt;br /&gt;
裝甚麼修復器&lt;br /&gt;
更可笑是重新把瀏覽器捷徑重設, 這個就算成功也只是治標不治本 (聽說2345 是會把你的瀏覽器捷徑換成假的)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
以上所有方法通通無用&lt;br /&gt;
終於讓我找到一個暴力解決方法 -- 360安全衛士&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
&lt;span style=&quot;color: red;&quot;&gt;&lt;b&gt;裝好後, 其他甚麼也不要理, 直接找系統急救箱, 開強力模式&lt;/b&gt;&lt;/span&gt;&lt;/h2&gt;
別怕~~反正閣下的電腦本身都好毒, 確定就是~~&lt;br /&gt;
掃描好後, restart 電腦, 恭喜~~你所有瀏覽器都康復了~~&lt;br /&gt;
&lt;br /&gt;
然後當然最後就是把360移除~~都康復了, 還留來幹?? 又多廣告又慢&lt;br /&gt;
&lt;br /&gt;
成功的話請給小弟一個留言~~</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/9086747938499799276/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/06/2345-hao123-hijack-solusion.html#comment-form' title='2 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9086747938499799276'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/9086747938499799276'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/06/2345-hao123-hijack-solusion.html' title='2345 hao123 hijack solusion'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-854129645017761976</id><published>2014-03-31T18:17:00.001+08:00</published><updated>2014-11-24T14:36:10.109+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="HTML"/><category scheme="http://www.blogger.com/atom/ns#" term="IE"/><category scheme="http://www.blogger.com/atom/ns#" term="jQuery"/><category scheme="http://www.blogger.com/atom/ns#" term="js"/><category scheme="http://www.blogger.com/atom/ns#" term="placeholder"/><title type='text'>input password placeholder workaround IE</title><content type='html'>the workaround&amp;nbsp;solution for using placeholder on IE&amp;lt;10&lt;br /&gt;
&lt;b&gt;&lt;span style=&quot;color: #e06666;&quot;&gt;it works for IE7~10&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
(credits to&amp;nbsp;&lt;a href=&quot;http://jsfiddle.net/q8ajJ/&quot;&gt;http://jsfiddle.net/q8ajJ/&lt;/a&gt;)&lt;br /&gt;
&lt;br /&gt;
HTML&lt;br /&gt;
&lt;pre class=&quot;brush:xml&quot;&gt;&amp;lt;!-- Style = display none for people who dont have javascript --&amp;gt;
&amp;lt;input id=&quot;fake_pass&quot; name=&quot;fake_pass&quot; style=&quot;display: none;&quot; type=&quot;text&quot; value=&quot;Enter Password:&quot; /&amp;gt;
&amp;lt;input id=&quot;real_pass&quot; name=&quot;real_pass&quot; type=&quot;password&quot; /&amp;gt;

&lt;/pre&gt;&lt;br /&gt;
JS&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;// On DOM ready, hide the real password
$(&#39;#real_pass&#39;).hide();

// Show the fake pass (because JS is enabled)
$(&#39;#fake_pass&#39;).show();

// On focus of the fake password field
$(&#39;#fake_pass&#39;).focus(function(){
    $(this).hide(); //  hide the fake password input text
    $(&#39;#real_pass&#39;).show().focus(); // and show the real password input password
});

// On blur of the real pass
$(&#39;#real_pass&#39;).blur(function(){
    if($(this).val() == &quot;&quot;){ // if the value is empty, 
        $(this).hide(); // hide the real password field
        $(&#39;#fake_pass&#39;).show(); // show the fake password
    }
    // otherwise, a password has been entered,
    // so do nothing (leave the real password showing)
});

&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/854129645017761976/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/03/input-password-placeholder-workaround-ie.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/854129645017761976'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/854129645017761976'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/03/input-password-placeholder-workaround-ie.html' title='input password placeholder workaround IE'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-6620219478911386607</id><published>2014-02-07T17:40:00.000+08:00</published><updated>2014-02-07T17:40:37.692+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="CSS"/><category scheme="http://www.blogger.com/atom/ns#" term="HTML"/><title type='text'>vertical center css</title><content type='html'>content from&amp;nbsp;&lt;a href=&quot;http://blog.themeforest.net/tutorials/vertical-centering-with-css/&quot;&gt;http://blog.themeforest.net/tutorials/vertical-centering-with-css/&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h3 style=&quot;background-color: #f4f4f4; border: 0px; color: #191919; font-family: &#39;MgOpen Modata&#39;, Arial, Tahoma; font-size: 21px; font-weight: inherit; line-height: 1em; margin: 0px; outline: 0px; padding: 10px 0px 20px; vertical-align: baseline;&quot;&gt;
&lt;span style=&quot;color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px;&quot;&gt;In this method, we will insert a div above the content element. This will be set to&lt;/span&gt;&lt;span style=&quot;color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;code style=&quot;border: 0px; color: #434343; font-family: inherit; font-size: 13px; font-style: inherit; line-height: 19px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;height:50%;&lt;/code&gt;&lt;span style=&quot;color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px;&quot;&gt;and&lt;/span&gt;&lt;span style=&quot;color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;code style=&quot;border: 0px; color: #434343; font-family: inherit; font-size: 13px; font-style: inherit; line-height: 19px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;margin-bottom:-contentheight;&lt;/code&gt;&lt;span style=&quot;color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px;&quot;&gt;. The content will then clear the float and end up in the middle.&lt;/span&gt;&lt;/h3&gt;
&lt;div class=&quot;wp_syntax&quot; style=&quot;background-color: #f9f9f9; border: 1px solid silver; color: #110000; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px; margin: 0px 0px 1.5em; outline: 0px; overflow-x: auto; overflow-y: hidden; padding: 0px; vertical-align: baseline; width: 617px;&quot;&gt;
&lt;div class=&quot;code&quot; style=&quot;border: 0px; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 2px 4px; vertical-align: top;&quot;&gt;
&lt;pre class=&quot;html4strict&quot; style=&quot;border: 0px; clear: none; float: none; font-size: 12px; font-style: inherit; line-height: 1.333; outline: 0px; overflow: visible; padding: 0px; vertical-align: baseline; width: auto;&quot;&gt;&lt;span style=&quot;border: 0px; color: #009900; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&amp;lt;&lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;div&lt;/span&gt; &lt;span style=&quot;border: 0px; color: #000066; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;id&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #66cc66; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;border: 0px; color: red; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&quot;floater&quot;&lt;/span&gt;&amp;gt;&lt;/span&gt;
&lt;span style=&quot;border: 0px; color: #009900; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&amp;lt;&lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;div&lt;/span&gt; &lt;span style=&quot;border: 0px; color: #000066; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;id&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #66cc66; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;border: 0px; color: red; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&quot;content&quot;&lt;/span&gt;&amp;gt;&lt;/span&gt;
 Content here
&lt;span style=&quot;border: 0px; color: #009900; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&amp;lt;&lt;span style=&quot;border: 0px; color: #66cc66; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;/&lt;/span&gt;&lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;div&lt;/span&gt;&amp;gt;&lt;/span&gt;
&lt;span style=&quot;border: 0px; color: #009900; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&amp;lt;&lt;span style=&quot;border: 0px; color: #66cc66; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;/&lt;/span&gt;&lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;div&lt;/span&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;wp_syntax&quot; style=&quot;background-color: #f9f9f9; border: 1px solid silver; color: #110000; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px; margin: 0px 0px 1.5em; outline: 0px; overflow-x: auto; overflow-y: hidden; padding: 0px; vertical-align: baseline; width: 617px;&quot;&gt;
&lt;div class=&quot;code&quot; style=&quot;border: 0px; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 2px 4px; vertical-align: top;&quot;&gt;
&lt;pre class=&quot;css&quot; style=&quot;border: 0px; clear: none; float: none; font-size: 12px; font-style: inherit; line-height: 1.333; outline: 0px; overflow: visible; padding: 0px; vertical-align: baseline; width: auto;&quot;&gt;&lt;span style=&quot;border: 0px; color: #cc00cc; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;#floater&lt;/span&gt; &lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;{&lt;/span&gt;&lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;float&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;:&lt;/span&gt;&lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;left&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;;&lt;/span&gt; &lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;height&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;:&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #993333; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;border: 0px; color: #cc66cc; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;50&lt;/span&gt;%&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;;&lt;/span&gt; &lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;margin-bottom&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;:&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #993333; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;-120px&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;;&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;}&lt;/span&gt;
&lt;span style=&quot;border: 0px; color: #cc00cc; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;#content&lt;/span&gt; &lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;{&lt;/span&gt;&lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;clear&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;:&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #993333; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;both&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;;&lt;/span&gt; &lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;height&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;:&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #993333; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;240px&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;;&lt;/span&gt; &lt;span style=&quot;border: 0px; color: black; font-family: inherit; font-style: inherit; font-weight: bold; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;position&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;:&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #993333; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;relative&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;;&lt;/span&gt;&lt;span style=&quot;border: 0px; color: #00aa00; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;}&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;h4 style=&quot;background-color: #f4f4f4; border: 0px; color: #191919; font-family: &#39;MgOpen Modata&#39;, Arial, Tahoma; font-size: 15px; font-weight: inherit; line-height: 1em; margin: 0px; outline: 0px; padding: 10px 0px 20px; text-transform: uppercase; vertical-align: baseline;&quot;&gt;
THE GOODS&lt;/h4&gt;
&lt;ul style=&quot;background-color: #f4f4f4; border: 0px; color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px; list-style: none; margin: 0px; outline: 0px; padding: 3px 0px 20px; vertical-align: baseline;&quot;&gt;
&lt;li style=&quot;background-image: url(http://blog.themeforest.net/wp-content/themes/marketplace/images/post-li.gif); background-position: 10px 9px; background-repeat: no-repeat no-repeat; border: 0px; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 4px 0px 2px 35px; vertical-align: baseline;&quot;&gt;Works in all browsers&lt;/li&gt;
&lt;li style=&quot;background-image: url(http://blog.themeforest.net/wp-content/themes/marketplace/images/post-li.gif); background-position: 10px 9px; background-repeat: no-repeat no-repeat; border: 0px; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 4px 0px 2px 35px; vertical-align: baseline;&quot;&gt;When there isn’t enough space (ie. the window shrinks) our content will not be cut off, and a scrollbar will appear.&lt;/li&gt;
&lt;/ul&gt;
&lt;h4 style=&quot;background-color: #f4f4f4; border: 0px; color: #191919; font-family: &#39;MgOpen Modata&#39;, Arial, Tahoma; font-size: 15px; font-weight: inherit; line-height: 1em; margin: 0px; outline: 0px; padding: 10px 0px 20px; text-transform: uppercase; vertical-align: baseline;&quot;&gt;
THE BADS&lt;/h4&gt;
&lt;ul style=&quot;background-color: #f4f4f4; border: 0px; color: #434343; font-family: tahoma, Geneva, sans-serif; font-size: 13px; line-height: 19px; list-style: none; margin: 0px; outline: 0px; padding: 3px 0px 20px; vertical-align: baseline;&quot;&gt;
&lt;li style=&quot;background-image: url(http://blog.themeforest.net/wp-content/themes/marketplace/images/post-li.gif); background-position: 10px 9px; background-repeat: no-repeat no-repeat; border: 0px; font-family: inherit; font-style: inherit; margin: 0px; outline: 0px; padding: 4px 0px 2px 35px; vertical-align: baseline;&quot;&gt;Only one I can think of is that it requires an extra empty element (which isn’t that bad, another subjective topic)&lt;/li&gt;
&lt;/ul&gt;
</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/6620219478911386607/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/02/vertical-center-css.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6620219478911386607'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6620219478911386607'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2014/02/vertical-center-css.html' title='vertical center css'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-6840559080233477572</id><published>2013-11-11T16:06:00.001+08:00</published><updated>2013-11-11T16:07:41.912+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="HTML"/><title type='text'>make a phone call on mobile using native html (no javascript needed)</title><content type='html'>simply an &amp;lt;a&amp;gt; tag:&lt;br /&gt;
using &quot;tel:&quot; protocol in the href like other protocols such as &quot;email:&quot;, &quot;javascript:&quot;&lt;br /&gt;
&lt;b&gt;&amp;lt;a href=&quot;tel:xxxxxxxx&quot; &amp;gt;phone me&amp;lt;/a&amp;gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
if country code is needed, start with &quot;+&quot; and your country code,&lt;br /&gt;
the country in Hong kong is 852 so:&lt;br /&gt;
&lt;b&gt;&amp;lt;a href=&quot;tel:+85218503&quot;&amp;gt;call HK Observatory&amp;lt;/a&amp;gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
example:&lt;br /&gt;
&lt;a href=&quot;tel:+85225908723&quot;&gt;&lt;b&gt;call 萬寧妹妹&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
the code were tested with the following devices using its default browser:&lt;br /&gt;
Galaxy S2(Android 4.0.4),&lt;br /&gt;
iphone 4S(IOS 5.0.1),&lt;br /&gt;
WinPhone 8&lt;br /&gt;
&lt;br /&gt;
hope the information above can help u all</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/6840559080233477572/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/11/make-phone-call-on-mobile-using.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6840559080233477572'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6840559080233477572'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/11/make-phone-call-on-mobile-using.html' title='make a phone call on mobile using native html (no javascript needed)'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-1584153073824682581</id><published>2013-10-29T00:27:00.000+08:00</published><updated>2013-10-29T00:27:37.601+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="CSS"/><category scheme="http://www.blogger.com/atom/ns#" term="IE7"/><category scheme="http://www.blogger.com/atom/ns#" term="scrollbar"/><title type='text'>disable weird scroll bar in IE7</title><content type='html'>just a note for&amp;nbsp;disabling&amp;nbsp;the weird scrollbar in IE7&lt;br /&gt;
&lt;br /&gt;
add the following css&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
html {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; overflow:auto;&lt;br /&gt;
}&lt;br /&gt;
</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/1584153073824682581/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/10/disable-weird-scroll-bar-in-ie7.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1584153073824682581'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1584153073824682581'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/10/disable-weird-scroll-bar-in-ie7.html' title='disable weird scroll bar in IE7'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-3575927702344643540</id><published>2013-10-26T16:38:00.000+08:00</published><updated>2015-08-27T15:43:12.276+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Facebook"/><category scheme="http://www.blogger.com/atom/ns#" term="facebook sharer"/><category scheme="http://www.blogger.com/atom/ns#" term="graph"/><category scheme="http://www.blogger.com/atom/ns#" term="HTML"/><category scheme="http://www.blogger.com/atom/ns#" term="og:descripion"/><category scheme="http://www.blogger.com/atom/ns#" term="og:image"/><category scheme="http://www.blogger.com/atom/ns#" term="og:title"/><title type='text'>facebook sharer 使用詳解 之 description, title 和 image</title><content type='html'>&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;(本文最後&lt;/span&gt;&lt;span style=&quot;background-color: white; color: rgba(0, 0, 0, 0.870588); font-family: Roboto, arial, sans-serif; font-size: 16px;&quot;&gt;檢閱日期 - 27&lt;/span&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;th August, 2015&lt;/span&gt;&lt;span style=&quot;font-family: &#39;&#39;;&quot;&gt;)&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://littleshell-multimedia.blogspot.com/2011/03/facebook-sharer.html&quot; target=&quot;_blank&quot;&gt;facebook sharer&amp;nbsp;使用詳解&lt;/a&gt;是本部落格的人氣文章&lt;br /&gt;
謝謝各位的支持&lt;br /&gt;
&lt;br /&gt;
若各下新接觸facebook sharer(後稱sharer) 的話&lt;br /&gt;
您在跟著本文實作時或會遇到一些困難,&lt;br /&gt;
這時不妨先到上述連結了解一下sharer是怎樣運作&lt;br /&gt;
&lt;br /&gt;
今天繼續說明如何設定sharer其他重要的屬性&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;
&lt;br /&gt;
&lt;h4&gt;
og:description&lt;/h4&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi5ZjVYMH-ZFzq-Icq3SrpZbJssdpZWmCSeL4yurCTF1wICXjR1WNZsAUJZUWc-OzS5ogy8dqeK49FlgSANjt49ZwV4G3vrfEOVDh1RCm1b4S5PkJ2umyqPAHIdo7Z6-EWXS8lMWfogCsE/s1600/og_description.PNG&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;106&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi5ZjVYMH-ZFzq-Icq3SrpZbJssdpZWmCSeL4yurCTF1wICXjR1WNZsAUJZUWc-OzS5ogy8dqeK49FlgSANjt49ZwV4G3vrfEOVDh1RCm1b4S5PkJ2umyqPAHIdo7Z6-EWXS8lMWfogCsE/s320/og_description.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
設定方法為 &amp;lt;meta name=&quot;og:description&quot; content=&quot;blar blar blar&quot; /&amp;gt;&lt;br /&gt;
sharer 會先看看html裡有沒有設這個meta&lt;br /&gt;
&amp;nbsp;&amp;nbsp;有:用這個meta 裡的content 屬性&lt;br /&gt;
&amp;nbsp;&amp;nbsp;沒有:在html&amp;nbsp;裡找第一個多於120字(不包括120)的 &amp;lt;p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
兩個都找不到的話,&amp;nbsp;那description就會設為空白&lt;br /&gt;
這就是為甚麼通常share&amp;nbsp;出去的description&amp;nbsp;怪怪的原因&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h4&gt;
og:image&lt;/h4&gt;
&lt;div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4Se0GS_gkPaVf2sOvnEo23TGsK9Bg1U4ItyaSWHgaiTMaXo723Mn_5j9uerdHSGDn-BzT3iPW5OsXi8sS9TrEYYQxmz-OMRNbYcx39EvQ7geA8CAKSSZLY2hlGqxrNA7t7i2SYR-XgdI/s1600/og_image.PNG&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;106&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4Se0GS_gkPaVf2sOvnEo23TGsK9Bg1U4ItyaSWHgaiTMaXo723Mn_5j9uerdHSGDn-BzT3iPW5OsXi8sS9TrEYYQxmz-OMRNbYcx39EvQ7geA8CAKSSZLY2hlGqxrNA7t7i2SYR-XgdI/s320/og_image.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
設定方法為 &amp;lt;meta name=&quot;og:image&quot; content=&quot;http://absolute.image.path&quot;/&amp;gt;&lt;/div&gt;
&lt;div&gt;
可設多張,&amp;nbsp;多copy一次就可&lt;/div&gt;
&lt;div&gt;
&lt;b&gt;圖的url一定要absolute path 而且是published url&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
聽起來好像好簡單，那你就錯了&lt;/div&gt;
&lt;div&gt;
不要相信debugger裡og:image的結果,&amp;nbsp;那是騙你的&lt;br /&gt;
用來參考倒是可以的,&amp;nbsp;一切要以真正sharer 的結果為準&lt;/div&gt;
&lt;div&gt;
長氣點說多次, 若遇上甚麼問題,&amp;nbsp;請參閱&lt;a href=&quot;http://littleshell-multimedia.blogspot.com/2011/03/facebook-sharer.html&quot; target=&quot;_blank&quot;&gt;facebook sharer&amp;nbsp;使用詳解&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
這裡sharer&amp;nbsp;會這樣做:&lt;/div&gt;
&lt;div&gt;
先看HTML裡有沒有設og:image&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; 有:圖片是否大過200x200? (不包括200)&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; 是:sharer會用這個圖&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; 否:sharer不會使用這圖片, 請繼續看下去&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; 否: 忽略此圖片, 並找找網頁裡有哪些 *有夠大 的&amp;lt;img&amp;gt;,&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; 如有:&amp;nbsp;放入thumbnail list&amp;nbsp;讓用家選擇&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; 沒有: 這個分享不會顯示任何thumbnail&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;
* : 夠大的定義目前還未測試出來, 總之是大圖片&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;strike&gt;除了og:image&amp;nbsp;已證實必定要大過200x200外&lt;/strike&gt;&amp;nbsp;(deleted on 18th June, 2015 -- its not always true)&lt;/div&gt;
&lt;div&gt;
其他由HTML extract出來的暫時都未太清楚甚麼size才會當做thumbnail,&lt;br /&gt;
簡單來說夠大的都會有機會&lt;/div&gt;
&lt;div&gt;
測試所得, sharer會比較喜歡找放在開頭的圖&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;
&lt;br /&gt;
&lt;h4&gt;
og:title&lt;/h4&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi16kI2J1RhIIMtli8ap0H7NM2Ic221s0fWbdoObO_bUVblJlD6CbkWoLIgO6RIaUCZOcQreaKKYFH-1CqHaTNGhaYRvhiGRlu81IkpcOGE-lwyOmTaheZX8edwmzd2CUcJ1OWircs7BS0/s1600/og_title.PNG&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;106&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi16kI2J1RhIIMtli8ap0H7NM2Ic221s0fWbdoObO_bUVblJlD6CbkWoLIgO6RIaUCZOcQreaKKYFH-1CqHaTNGhaYRvhiGRlu81IkpcOGE-lwyOmTaheZX8edwmzd2CUcJ1OWircs7BS0/s320/og_title.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
這個是最簡單最正常的屬性&lt;/div&gt;
&lt;div&gt;
設法為&amp;lt;meta name=&quot;og:title&quot; content=&quot;bi li ba la&quot;/&amp;gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
sharer&amp;nbsp;會先看有沒有設og:title&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; 有:用這個為title&lt;br /&gt;
&amp;nbsp;&amp;nbsp;沒有:&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp;sharer會找&amp;lt;title&amp;gt;當title&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp;若&amp;lt;title&amp;gt;都沒有的話就會直接把網址當成title&lt;br /&gt;
&lt;br /&gt;
文章如能幫到各下的話,&amp;nbsp;請留個comment讓小弟知道&lt;br /&gt;
謝謝&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/3575927702344643540/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/10/facebook-sharer-description-title-image.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/3575927702344643540'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/3575927702344643540'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/10/facebook-sharer-description-title-image.html' title='facebook sharer 使用詳解 之 description, title 和 image'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi5ZjVYMH-ZFzq-Icq3SrpZbJssdpZWmCSeL4yurCTF1wICXjR1WNZsAUJZUWc-OzS5ogy8dqeK49FlgSANjt49ZwV4G3vrfEOVDh1RCm1b4S5PkJ2umyqPAHIdo7Z6-EWXS8lMWfogCsE/s72-c/og_description.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-1592319491305974655</id><published>2013-10-11T01:23:00.001+08:00</published><updated>2014-11-11T19:05:02.258+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="CSS"/><category scheme="http://www.blogger.com/atom/ns#" term="HTML"/><title type='text'>solution of strange extra width on 100% width input on iphone</title><content type='html'>&lt;style&gt;
.syntaxhighlighter table td.gutter .line {
  text-align: right !important;
  padding: 0 5px  !important;
}
&lt;/style&gt;&lt;br /&gt;
&lt;br /&gt;
given the following html and css:&lt;br /&gt;
&lt;br /&gt;
html:&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;&amp;lt;div class=&quot;formWrapper&quot;&amp;gt;
 &amp;lt;input id=&quot;myName&quot; type=&quot;text&quot;/&amp;gt;
 blar..
 blar...
 blar....
&amp;lt;/div&amp;gt;&lt;/pre&gt;
&lt;br /&gt;
css:&lt;br /&gt;
&lt;pre class=&quot;brush:css&quot;&gt;#myName {
 width:100%;
 border: 1px solid white;
}&lt;/pre&gt;
as the css speaks, it draws a white border gracefully in many browsers such as chrome, Firefox, and android 4.0.4 browser.&lt;br /&gt;
&lt;br /&gt;
however it fails in iphone, it adds some extra width to it.&lt;br /&gt;
&lt;br /&gt;
with some research, there is a messy but a good solution below:&lt;br /&gt;
first, we need to add a wrapper to our textfield&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;&amp;lt;div class=&quot;formWrapper&quot;&amp;gt;
 &amp;lt;div class=&quot;border&quot;&amp;gt;&amp;lt;input id=&quot;myName&quot; type=&quot;text&quot;/&amp;gt;&amp;lt;/div&amp;gt;
 blar..
 blar...
 blar....
&amp;lt;/div&amp;gt;&lt;/pre&gt;
&lt;br /&gt;
next, we add border to this wrapper instead of &amp;lt;input &amp;gt;&lt;br /&gt;
&lt;pre class=&quot;brush:css&quot;&gt;#myName {
 width:100%;

 /*we remove all styles on input*/
 margin: 0px;
 padding: 0px;
 border: 0px;
}

.border {
 border: 1px solid white;
}
 &lt;/pre&gt;
and now it looks nicely in iphone and other browsers~~&lt;br /&gt;
this method works in chrome, firefox, safari and also works in IE6 IE7 &amp;amp; IE8&lt;br /&gt;
&lt;br /&gt;
leave me a comment if it helps you~&lt;br /&gt;
&lt;br /&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
    SyntaxHighlighter.config.bloggerMode = true;
    SyntaxHighlighter.all()
&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/1592319491305974655/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/10/solution-of-strange-extra-width-on-100.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1592319491305974655'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1592319491305974655'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/10/solution-of-strange-extra-width-on-100.html' title='solution of strange extra width on 100% width input on iphone'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-2920178120512512810</id><published>2013-04-19T16:09:00.000+08:00</published><updated>2013-04-19T16:39:58.166+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="cordova"/><category scheme="http://www.blogger.com/atom/ns#" term="js"/><category scheme="http://www.blogger.com/atom/ns#" term="pdf"/><category scheme="http://www.blogger.com/atom/ns#" term="phonegap"/><category scheme="http://www.blogger.com/atom/ns#" term="windows phone"/><title type='text'>phonegap opening a PDF file in Windows Phone</title><content type='html'>&lt;span style=&quot;font-size: x-large;&quot;&gt;&lt;b&gt;&lt;i&gt;F&lt;/i&gt;&lt;/b&gt;&lt;/span&gt;or those who suffering from opening PDF in your application&lt;br /&gt;
here you are the solusion&lt;br /&gt;
&lt;br /&gt;
just simply upgrade your cordova framework to at least 2.6.0&lt;br /&gt;
and use the following js to open&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;window.open(&quot;your/pdf/link&quot;, &quot;_system&quot;)&lt;/i&gt;&lt;br /&gt;
&lt;i&gt;&lt;br /&gt;&lt;/i&gt;
the package can be downloaded &lt;a href=&quot;http://cordova.apache.org/&quot; rel=&quot;nofollow&quot; target=&quot;_blank&quot;&gt;here&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
please leave me a comment if it solves your problem~</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/2920178120512512810/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/04/phonegap-windows-phone-pdf-problem.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/2920178120512512810'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/2920178120512512810'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/04/phonegap-windows-phone-pdf-problem.html' title='phonegap opening a PDF file in Windows Phone'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-7067623503050038526</id><published>2013-02-18T17:09:00.001+08:00</published><updated>2014-11-06T12:24:27.440+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="google map v3"/><category scheme="http://www.blogger.com/atom/ns#" term="infobox"/><category scheme="http://www.blogger.com/atom/ns#" term="js"/><title type='text'>google map v3 custom infobox template</title><content type='html'>&lt;style&gt;
.syntaxhighlighter table td.gutter .line {
  text-align: right !important;
  padding: 0 5px  !important;
}
&lt;/style&gt;&lt;br /&gt;
Here you are the google map custom infobox template,&lt;br /&gt;
the js library can be downloaded &lt;a href=&quot;http://google-maps-utility-library-v3.googlecode.com/svn/trunk/infobox/src/infobox_packed.js&quot;&gt;here&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
and the API document is &lt;a href=&quot;http://google-maps-utility-library-v3.googlecode.com/svn/trunk/infobox/docs/reference.html&quot; target=&quot;_blank&quot;&gt;here&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;iframe frameborder=&quot;0&quot; height=&quot;380&quot; src=&quot;http://littleshell.host.sk/for_blogger/googlemap_custom_infobox.html&quot; width=&quot;500&quot;&gt;&lt;br /&gt;
&lt;/iframe&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:js&quot;&gt;&amp;lt;html&amp;gt;
 &amp;lt;head&amp;gt;
  &amp;lt;script type=&quot;text/javascript&quot; src=&quot;http://code.jquery.com/jquery-1.8.3.min.js&quot;&amp;gt;&amp;lt;/script&amp;gt;
  &amp;lt;script src=&quot;https://maps.googleapis.com/maps/api/js?v=3.exp&amp;amp;sensor=false&quot;&amp;gt;&amp;lt;/script&amp;gt;
  &amp;lt;script type=&quot;text/javascript&quot; src=&quot;http://google-maps-utility-library-v3.googlecode.com/svn/trunk/infobox/src/infobox_packed.js&quot;&amp;gt;&amp;lt;/script&amp;gt;
  &amp;lt;script type=&quot;text/javascript&quot;&amp;gt;
   var gMap;
   var ib;
   $(window).load(window_load);

   function initMap() {
    var _mapOptions = {
     center: new google.maps.LatLng(22.302698, 114.160501),
     zoom: 12,
     mapTypeId: google.maps.MapTypeId.ROADMAP
    }
    
    gMap = new google.maps.Map(document.getElementById(&quot;mapArea&quot;), _mapOptions);
   }

   function setMarker() {
    var _mOptions = {
     position:new google.maps.LatLng(22.302698, 114.160501),
     map:gMap
    }
    
    var _marker = new google.maps.Marker(_mOptions);
    
    ib.open(gMap, _marker)
    
    google.maps.event.addListener(_marker, &#39;click&#39;, function() {
     if(ib.getVisible()){
      ib.close();
     }else{
      ib.open(gMap, _marker)
     }
    });
   }

   function setInfoBox() {
    var _infoBoxOptions = {
     content: &quot;&amp;lt;div class=&#39;divInfoContent&#39;&amp;gt;hello world~~&amp;lt;/div&amp;gt;&quot;,
     alignBottom:true,
     closeBoxURL: &quot;&quot;,
     pixelOffset : new google.maps.Size(-20, -30),
     boxStyle: {
      width: 100,
      height: 75,
      background: &quot;url(http://www.clker.com/cliparts/6/b/2/4/1197148387581632758SRD_comic_clouds_2.svg.thumb.png) no-repeat&quot;
     }
    }
    
    ib = new InfoBox(_infoBoxOptions);
   }

   function window_load(){
    initMap();
    setInfoBox();
    setMarker();
   }
  &amp;lt;/script&amp;gt;
 &amp;lt;/head&amp;gt;
 
 
 
 &amp;lt;style&amp;gt;
  #mapArea {
   width: 480px;
   height: 360px;
   margin: 0 auto;
  }
  
  .divInfoContent {
   padding: 10px 20px;
  }
 &amp;lt;/style&amp;gt;
 
 
 
 &amp;lt;body&amp;gt;
  &amp;lt;div id=&quot;mapArea&quot;&amp;gt;&amp;lt;/div&amp;gt;
 &amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;&lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/7067623503050038526/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/02/google-map-v3-custom-infobox.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/7067623503050038526'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/7067623503050038526'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/02/google-map-v3-custom-infobox.html' title='google map v3 custom infobox template'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-6584539771802939925</id><published>2013-02-06T03:18:00.000+08:00</published><updated>2013-02-06T03:18:50.016+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="jQuery"/><category scheme="http://www.blogger.com/atom/ns#" term="js"/><title type='text'>jquery .animate() overflow</title><content type='html'>just a note on &lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: #f3f3f3;&quot;&gt;$().animate()&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
this function will set &lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: #f3f3f3;&quot;&gt;overflow:hidden&lt;/span&gt;&lt;/b&gt;&lt;/i&gt; when method call and it will be back to normal when animation finished&lt;br /&gt;
&lt;br /&gt;
simply set &lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: #f3f3f3;&quot;&gt;overflow:visible&lt;/span&gt;&lt;/b&gt;&lt;/i&gt; when needed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/6584539771802939925/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/02/jquery-animate-overflow.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6584539771802939925'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/6584539771802939925'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2013/02/jquery-animate-overflow.html' title='jquery .animate() overflow'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-2418658947605527552</id><published>2012-11-29T17:31:00.001+08:00</published><updated>2012-11-29T17:31:26.353+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="jQuery"/><category scheme="http://www.blogger.com/atom/ns#" term="js"/><title type='text'>jquery .height() problem in chrome/safari</title><content type='html'>&lt;p&gt;The evilness of Chrome is not less then IE&lt;br /&gt;
&lt;/p&gt;&lt;p&gt;Thanks my workmate discovered a problem on chrome.&lt;br /&gt;
when i use $.height(), it works well on other browsers but Chrome and Safari,&lt;br /&gt;
which is webkit based browser&lt;br /&gt;
&lt;/p&gt;&lt;p&gt;after google, findings below:&lt;br /&gt;
$(document).ready() means the DOM is fully loaded, but &lt;em&gt;&lt;b&gt;does not mean the graphics were loaded&lt;/b&gt;&lt;/em&gt;.&lt;br /&gt;
$(window).load() fires after$(document).ready() and &lt;em&gt;&lt;b&gt;all graphics were fully loaded&lt;/b&gt;&lt;/em&gt;.&lt;br /&gt;
&lt;/p&gt;&lt;br /&gt;
here i made an experiment:&lt;br /&gt;
&lt;pre class=&quot;brush: js&quot;&gt;&amp;lt;html&amp;gt;
 &amp;lt;head&amp;gt;
  &amp;lt;title&amp;gt;event&amp;nbsp;test&amp;lt;/title&amp;gt;
  &amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;nbsp;src=&amp;quot;http://code.jquery.com/jquery-1.8.3.min.js&amp;quot;&amp;gt;&amp;lt;/script&amp;gt;
  &amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;nbsp;&amp;gt;
  
  //Run&amp;nbsp;a&amp;nbsp;function&amp;nbsp;when&amp;nbsp;the&amp;nbsp;page&amp;nbsp;is&amp;nbsp;fully&amp;nbsp;loaded&amp;nbsp;including&amp;nbsp;graphics.
  $(window).load(function(){
   var&amp;nbsp;_imageHeight=$(&amp;quot;img&amp;quot;).height();
   $(&amp;quot;ol&amp;quot;).append(&amp;quot;&amp;lt;li&amp;gt;window&amp;nbsp;load,&amp;nbsp;image&#39;s&amp;nbsp;height&amp;nbsp;is&amp;nbsp;&amp;quot;&amp;nbsp;+&amp;nbsp;_imageHeight&amp;nbsp;+&amp;nbsp;&amp;quot;&amp;lt;/li&amp;gt;&amp;quot;);
  });
  
  //Specify&amp;nbsp;a&amp;nbsp;function&amp;nbsp;to&amp;nbsp;execute&amp;nbsp;when&amp;nbsp;the&amp;nbsp;DOM&amp;nbsp;is&amp;nbsp;fully&amp;nbsp;loaded.
  $(document).ready(function(){
   var&amp;nbsp;_imageHeight=$(&amp;quot;img&amp;quot;).height();
   $(&amp;quot;ol&amp;quot;).append(&amp;quot;&amp;lt;li&amp;gt;document&amp;nbsp;ready,&amp;nbsp;image&#39;s&amp;nbsp;height&amp;nbsp;is&amp;nbsp;&amp;quot;&amp;nbsp;+&amp;nbsp;_imageHeight&amp;nbsp;+&amp;nbsp;&amp;quot;&amp;lt;/li&amp;gt;&amp;quot;);
  });
  &amp;lt;/script&amp;gt;
 &amp;lt;/head&amp;gt;
 &amp;lt;body&amp;gt;
  &amp;lt;ol&amp;gt;&amp;lt;/ol&amp;gt;&amp;nbsp;&amp;lt;!--&amp;nbsp;use&amp;nbsp;ordered&amp;nbsp;list&amp;nbsp;to&amp;nbsp;show&amp;nbsp;the&amp;nbsp;call&amp;nbsp;sequence&amp;nbsp;--&amp;gt;
  &amp;lt;img&amp;nbsp;src=&amp;quot;http://static.jquery.com/files/rocker/images/logo_jquery_215x53.gif&amp;quot;/&amp;gt;
 &amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;
&lt;/pre&gt;the above code tested with IE7, IE8, firefox 17, Maxthon 3, Chrome 23 &amp;amp; Safari 5.1.7&lt;br/&gt;&lt;br /&gt;
&lt;p&gt;except chrome and safari, all other results below:&lt;br /&gt;
1.document ready, image&#39;s height is 53&lt;br /&gt;
2.window load, image&#39;s height is 53&lt;br /&gt;
&lt;br /&gt;
and chrome and safari results:&lt;br /&gt;
&lt;br /&gt;
1.document ready, image&#39;s height is 0&lt;br /&gt;
2.window load, image&#39;s height is 53&lt;br /&gt;
&lt;/p&gt;&lt;p&gt;which shows $(window).load() fires after $(document).ready()&lt;br /&gt;
and webkit-based browsers (except Maxthon3)&lt;br /&gt;
cannot get the height since all graphics have not been loaded.&lt;br /&gt;
&lt;/p&gt;in summery, it is better using $(window).load() instead of $(document).ready()&lt;br/&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
     SyntaxHighlighter.all()
&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/2418658947605527552/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2012/11/jquery-height-problem-in-chromesafari.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/2418658947605527552'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/2418658947605527552'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2012/11/jquery-height-problem-in-chromesafari.html' title='jquery .height() problem in chrome/safari'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-1251030576044496973</id><published>2012-10-04T17:52:00.001+08:00</published><updated>2014-04-01T13:06:45.185+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="ajax"/><category scheme="http://www.blogger.com/atom/ns#" term="js"/><category scheme="http://www.blogger.com/atom/ns#" term="json"/><title type='text'>load json crossdomain</title><content type='html'>Simply a note for loading json cross-domain&lt;br /&gt;
&lt;br /&gt;
i use $.ajax() method for better event handling&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
client side js coding:&lt;br /&gt;
&lt;pre class=&quot;brush: js&quot;&gt;$.ajax({
 url:&quot;http://another.domain.com&quot;,
 
 dataType: &#39;jsonp&#39;, //stand for &quot;json-padding&quot;, it is jsonp, not json
 
 //its &quot;jsonpCallback&quot;, not &quot;jsonCallback&quot;. the callback method name from JSON, will explain below
 jsonpCallback: &#39;jsonCallback&#39;, 
 
 //set this to true to let the method know im loading data cross-domain
 crossDomain : true, 
 //success handler
 success: function(data) {
  console.log(&quot;dosomthing&quot;)
 },
 
 //error handler
 error: function() {
   console.log(&quot;error occured&quot;)
 }
});
&lt;/pre&gt;&lt;br /&gt;
the json response, wrap the JSON with a function with the name which declared in jsonpCallback above:&lt;br /&gt;
&lt;pre class=&quot;brush: js&quot;&gt;jsonCallback(
 {
  &quot;user&quot;:&quot;littleshell&quot;,
  &quot;gender&quot;:&quot;male&quot;
 }
);
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/1251030576044496973/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2012/10/load-json-crossdomain.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1251030576044496973'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/1251030576044496973'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2012/10/load-json-crossdomain.html' title='load json crossdomain'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2187020455970780738.post-5215390259920824252</id><published>2012-03-07T02:05:00.001+08:00</published><updated>2012-03-07T02:09:31.617+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AS3"/><title type='text'>The 1009 error on Loader.load()</title><content type='html'>Just a note about 1009 error on Loader.load()&lt;br /&gt;
the situation is that the main.swf attempts to load child.swf&lt;br /&gt;
&lt;br /&gt;
on Child class&lt;br /&gt;
&lt;pre class=&quot;brush: as3&quot;&gt;package {

 import flash.events.Event;
 import flash.display.Sprite;

 public class Child extends Sprite {

  public function Child() {
   initChild();
  }
  
  public function initChild():void {
   stage.focus = this;
  }
 }
}
&lt;/pre&gt;
on Main class&lt;br /&gt;
&lt;pre class=&quot;brush: as3&quot;&gt;package net.littleshell {
 import flash.display.Loader;
 import flash.display.Sprite;
 import flash.events.Event;
 import flash.net.URLRequest;
 
 public class Main extends Sprite {
  
  private var l:Loader
  
  public function Main() {
   init();
  }
  
  public function loadSWF($url:String):void {
   var rq:URLRequest = new URLRequest($url);
   l.load(rq);
  }
  
  private function init():void {
   initLoader();  
   loadSWF(&quot;child.swf&quot;);
  }
  
  private function initLoader():void {
   l = new Loader();
   l.contentLoaderInfo.addEventListener(Event.COMPLETE, loader_complete);
   
   addChild(l);
  }
  
  private function loader_complete(e:Event):void {
   //blar blar blar
  }
 }
}
&lt;/pre&gt;
in such case, a #1009 error will be thrown in child.swf
it is because child.swf references the stage object too soon.&lt;br /&gt;
to solve it, simply run your code when ADDED_TO_STAGE event was dispatched.&lt;br /&gt;
&lt;br /&gt;
Modified Child class&lt;br /&gt;
&lt;pre class=&quot;brush: as3&quot;&gt;package net.littleshell {

 import flash.events.Event;
 import flash.display.Sprite;

 public class Child extends Sprite {

  public function Child() {
   addEventListener(Event.ADDED_TO_STAGE, initChild);
   initChild();
  }
  
  public function initChild(e:Event == null):void {
   removeEventListener(Event.ADDED_TO_STAGE, initChild)
   
   //its now safe to do anything
   stage.focus = this;
  }
 }
}
&lt;/pre&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
     SyntaxHighlighter.all()
&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://littleshell-multimedia.blogspot.com/feeds/5215390259920824252/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://littleshell-multimedia.blogspot.com/2012/03/1009-error-on-loaderload.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/5215390259920824252'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2187020455970780738/posts/default/5215390259920824252'/><link rel='alternate' type='text/html' href='http://littleshell-multimedia.blogspot.com/2012/03/1009-error-on-loaderload.html' title='The 1009 error on Loader.load()'/><author><name>littleshell</name><uri>http://www.blogger.com/profile/05807950370222111036</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-pYg-MTTCGUD33O5Aar6M0TnzhS6j-ub0Dm7eaXUNCu-I7J1lQeU1HU1AKeLeEapol0WazxQL0YWRVbVea7hqJ0frWaXGKa3kc84SJAAwVpvDTQSmy0BWCo1U5ioqa8E/s220/me22th_Dec_2010.jpg'/></author><thr:total>0</thr:total></entry></feed>