<Universal Dynamic Systems Ltd>

<Tel:020 338 42867>

<E-Mail: >

Login

 





Site News


UDSL

Adding 'Retweet' to a phpSite.

In phpSweet this is very easy, no plugins to add, no configuration to change just add a single line to the page template and update your css as follows:


Add this line to your template.
{insert name="fragment" fragmentName="retweet"}


Add some lines to you css. The tweetmeme iframe is contained in a div for easy positioning.
.retweet_frag{
   your css here
}

Job done.

How it works.

The retweet leverage's the fragment system of phpSweet. The fragment determines what page its on and generates the retweet url.

This will add the retweet to every page that uses the template, in phpSweet every page can have its own template so it easy top control on what pages you want the retweet to appear. For example if your site makes use of the blog module then setting a template for your blog pages allows you to have the retweet on all your blog pages and it will track the tweet for each blog page separately.

For those of you with a more technical inclination here is the code for the fragment:


class retweetFragmentClass extends fragmentProxy{
   private $result ;
   private $tweets;
   private $tm_link;
   private $share;
	
   public function __construct($fragmentName, $params, &$smarty, 
                                                       $fragmentId) {
      parent::__construct($fragmentName, $params, $smarty, $fragmentId) ;
      $this->getStats();
      $template = new moduleTemplateClass("fragment", "retweet");
      $template->assign("share",
               urlencode("http://".$_SERVER['SERVER_NAME']."/".
               $GLOBALS["application"]->params["%0"]););
      $this->result = $template->__toString();		
   }
}
	
   public function __toString(){
      return $this->result;
   }	
}

As you can see there is not a lot to it, you may have noticed the use of the “retweet” template, this enables you to customise how the retweet appears on the page. Not only can you style using css but you can change the html template used giving you complete control over customisation without changing phpSweet which would mean you loosing your changes during an update.

Posted: Mon 05 Jul 2010 18:56

Google joins UDSL in dropping support for IE 6

Google has announced that it is dropping support for IE 6, even the NHS are being advised to more to IE7!

With market share for IE6 now at as low as 20% this could be the death blow we have been waiting for. Not supporting IE 6 is going to save at least 10% on web development costs, may be more.

Over the years IE 6 has cost the web community frustration and expense. How many of us have been hit by the double-margin bug (actual margin is twice what you set it to)? And then there is the infamous miss interpretation of the CSS box model where IE treats padding and margin differently to every other browser and the WC3 standard!

Not to mention quirks mode - Ooops! Just did . . .

Safe to say that without IE 6 the web developers job is going to be so much easier and there blood pressure a little lower.


Posted: Mon 01 Feb 2010 16:31

Featured in Penny Powers Blog

Yesterday Ian Godman our Director was featured in Penny Power's blog on Ecademy.

Penny is the author of the best selling book on social media and its use in business Know Me, Like Me, Follow Me.

You can read Penny's blog here http://www.ecademy.com/node.php?id=143299


Posted: Tue 26 Jan 2010 09:36

We Live!

The new and improved UDSL site is live.

You know that, your looking at it. You cant say we are anything other than obvious!

We hope you find it useful if not then to tell us as feed back is the best way of improving.

Posted: Sun 24 Jan 2010 23:23