<?php
/**
* Sozial Bookmarks 1.0
*
* Copyright (C) 2007 Özgür Karatag <hide@address.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* @class sozialBookmarks
* @version V1.0 09 Mai 2007
* @author Özgür Karatag <hide@address.com>
* @copyright 2007 Özgür Karatag
*/
class sozialBookmarks {
/**
* @var string imagesFolder
* @access private
*/
var $imagesFolder = 'simages';
/**
* @var string imageWidth
* @access private
*/
var $imageWidth = 91;
/**
* @var string imageHeight
* @access private
*/
var $imageHeight = 17;
/**
* @var string url
* @access private
*/
var $url;
/**
* @var string target
* @access private
*/
var $target = '_blank';
/**
* @var string siteTitle
* @access private
*/
var $siteTitle;
/**
* @var string siteKeywords
* @access private
*/
var $siteKeywords;
/**
* @constructor
* @param string url
* @param string siteTitle
* @param string siteKeywords
* @author Özgür Karatag
* @description Constructor
*/
function sozialBookmarks($url = '', $siteTitle = '', $siteKeywords = '') {
$this->url = $url;
$this->siteTitle = $siteTitle;
$this->siteKeywords = $siteKeywords;
}
/**
* @function setcode
* @author Özgür Karatag
* @description Sets the value
*/
function setcode() {
$SBCode = '';
$SBCode .= ' <a href="http://www.google.com/reader/preview/*/feed/'.$this->url.'" target="'.$this->target.'" title=" @ to Google Reader "><img src="./'.$this->imagesFolder.'/bookmark_google_reader.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to Google Reader" title=" @ to Google Reader " /></a>';
$SBCode .= ' <a href="http://www.google.com/bookmarks/mark?op=add&hl=de&bkmk='.$this->url.'&annotation=&labels='.$this->siteKeywords.'&title='.$this->siteTitle.'" target="'.$this->target.'" title=" @ to Google Bookmark "><img src="./'.$this->imagesFolder.'/bookmark_google_bookmark.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to Google Bookmark" title=" @ to Google Bookmark " /></a>';
$SBCode .= ' <a href="http://www.bloglines.com/sub/'.$this->url.'" target="'.$this->target.'" title=" @ to bloglines "><img src="./'.$this->imagesFolder.'/bookmark_bloglines.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to bloglines" title=" @ to bloglines " /></a>';
$SBCode .= ' <a href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url='.$this->url.'" target="'.$this->target.'" title=" @ to newsgator "><img src="./'.$this->imagesFolder.'/bookmark_newsgator.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to newsgator" title=" @ to newsgator " /></a>';
$SBCode .= ' <a href="http://www.furl.net/storeIt.jsp?u='.$this->url.'&keywords='.$this->siteKeywords.'&t='.$this->siteTitle.'" target="'.$this->target.'" title=" @ to FURL "><img src="./'.$this->imagesFolder.'/bookmark_furl.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to FURL" title=" @ to FURL " /></a>';
$SBCode .= ' <a href="http://digg.com/submit?phase=2&url='.$this->url.'" target="'.$this->target.'" title=" @ to digg "><img src="./'.$this->imagesFolder.'/bookmark_digg.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to digg" title=" @ to digg " /></a>';
$SBCode .= ' <a href="http://www.webnews.de/einstellen?url='.$this->url.'&title='.$this->siteTitle.'" target="'.$this->target.'" title=" @ to webnews "><img src="./'.$this->imagesFolder.'/bookmark_webnews.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to webnews" title=" @ to webnews " /></a>';
$SBCode .= ' <a href="http://www.netscape.com/submit/?U='.$this->url.'&T='.$this->siteTitle.'" target="'.$this->target.'" title=" @ to Netscape "><img src="./'.$this->imagesFolder.'/bookmark_netscape.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to Netscape" title=" @ to Netscape " /></a>';
$SBCode .= ' <a href="http://myweb2.search.yahoo.com/myresults/bookmarklet?t='.$this->siteTitle.'&d=&tag=&u='.$this->url.'" target="'.$this->target.'" title=" @ to Yahoo MyWeb "><img src="./'.$this->imagesFolder.'/bookmark_yahoo.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to Yahoo MyWeb" title=" @ to Yahoo MyWeb " /></a>';
$SBCode .= ' <a href="http://www.spurl.net/spurl.php?v=3&tags=&title='.$this->siteTitle.'&url='.$this->url.'" target="'.$this->target.'" title=" @ to spurl.net "><img src="./'.$this->imagesFolder.'/bookmark_spurl.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to spurl.net" title=" @ to spurl.net " /></a>';
$SBCode .= ' <a href="http://www.diigo.com/post?url='.$this->url.'&title='.$this->siteTitle.'&tag=&comments=" target="'.$this->target.'" title=" @ to diigo "><img src="./'.$this->imagesFolder.'/bookmark_diigo.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to diigo" title=" @ to diigo " /></a>';
$SBCode .= ' <a href="http://www.newsvine.com/_wine/save?popoff=1&u='.$this->url.'&tags=&blurb='.$this->siteTitle.'" target="'.$this->target.'" title=" Bookmark @ newsvine "><img src="./'.$this->imagesFolder.'/bookmark_newsvine.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark newsvine" title=" Bookmark @ newsvine " /></a>';
$SBCode .= ' <a href="http://del.icio.us/post?url='.$this->url.'" target="'.$this->target.'" title=" Bookmark @ del.icio.us "><img src="./'.$this->imagesFolder.'/bookmark_del_icio_us.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark del.icio.us" title=" Bookmark @ del.icio.us " /></a>';
$SBCode .= ' <a href="http://www.simpy.com/simpy/LinkAdd.do?href='.$this->url.'" target="'.$this->target.'" title=" Bookmark @ SIMPIFY "><img src="./'.$this->imagesFolder.'/bookmark_simpify.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark @ SIMPIFY" title=" Bookmark SIMPIFY " /></a>';
$SBCode .= ' <a href="http://www.mister-wong.de/add_url/" target="'.$this->target.'" title=" Bookmark @ Mister Wong "><img src="./'.$this->imagesFolder.'/bookmark_mister_wong.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark MISTER WONG" title=" Bookmark @ MISTER WONG " /></a>';
$SBCode .= ' <a href="http://linkarena.com/bookmarks/addlink/?url='.$this->url.'" target="'.$this->target.'" title=" Bookmark @ Linkarena "><img src="./'.$this->imagesFolder.'/bookmark_linkarena.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark Linkarena" title=" Bookmark @ Linkarena " /></a>';
$SBCode .= ' <a href="http://www.icio.de/add.php?url='.$this->url.'" target="'.$this->target.'" title=" Bookmark @ isio.de "><img src="./'.$this->imagesFolder.'/bookmark_icio.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark icio.de" title=" Bookmark @ icio.de " /></a>';
$SBCode .= ' <a href="http://beta.oneview.de:80/quickadd/neu/addBookmark.jsf?URL='.$this->url.'&title='.$this->siteTitle.'" target="'.$this->target.'" title=" Bookmark @ oneview "><img src="./'.$this->imagesFolder.'/bookmark_oneview.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark oneview" title=" Bookmark @ oneview " /></a>';
$SBCode .= ' <a href="http://www.folkd.com/submit/'.$this->url.'" target="'.$this->target.'" title=" Bookmark @ folkd.com "><img src="./'.$this->imagesFolder.'/bookmark_folkd.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark folkd.com" title=" Bookmark @ folkd.com " /></a>';
$SBCode .= ' <a href="http://yigg.de/neu?exturl='.$this->url.'" target="'.$this->target.'" title=" Bookmark @ yigg.de "><img src="./'.$this->imagesFolder.'/bookmark_yigg.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark yigg.de" title=" Bookmark @ yigg.de " /></a>';
$SBCode .= ' <a href="http://reddit.com/submit?url='.$this->url.'&title='.$this->siteTitle.'" target="'.$this->target.'" title=" Bookmark @ reddit "><img src="./'.$this->imagesFolder.'/bookmark_reddit.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark reddit" title=" Bookmark @ reddit " /></a>';
$SBCode .= ' <a href="http://www.stumbleupon.com/submit?url='.$this->url.'&title='.$this->siteTitle.'" target="'.$this->target.'" title=" Bookmark @ StumbleUpon "><img src="./'.$this->imagesFolder.'/bookmark_stumbleupon.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark StumbleUpon" title=" Bookmark @ StumbleUpon " /></a>';
$SBCode .= ' <a href="http://slashdot.org/bookmark.pl?url='.$this->url.'&title='.$this->siteTitle.'" target="'.$this->target.'" title=" Bookmark @ Slashdot "><img src="./'.$this->imagesFolder.'/bookmark_slashdot.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark Slashdot" title=" Bookmark @ Slashdot " /></a>';
$SBCode .= ' <a href="http://www.blinklist.com/index.php?Action=Blink/addblink.php&Description=&Tag=&Url='.$this->url.'&Title='.$this->siteTitle.'" target="'.$this->target.'" title=" Bookmark @ blinklist "><img src="./'.$this->imagesFolder.'/bookmark_blinklist.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark blinklist" title=" Bookmark @ blinklist " /></a>';
$SBCode .= ' <a href="http://technorati.com/faves?add='.$this->url.'&tag=" target="'.$this->target.'" title=" Bookmark @ technorati "><img src="./'.$this->imagesFolder.'/bookmark_technorati.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="Bookmark technorati" title=" Bookmark @ technorati " /></a>';
$SBCode .= ' <a href="http://blogmarks.net/my/new.php?mini=1&simple=1&url='.$this->url.'&content=&public-tags=&title='.$this->siteTitle.'" target="'.$this->target.'" title=" @ to blogmarks "><img src="./'.$this->imagesFolder.'/bookmark_blogmarks.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to blogmarks" title=" @ to blogmarks " /></a>';
$SBCode .= ' <a href="http://www.blinkbits.com/bookmarklets/save.php?v=1&title='.$this->siteTitle.'&source_url='.$this->url.'&source_image_url=&rss_feed_url=&rss_feed_url=&rss2member=&body=" target="'.$this->target.'" title=" @ to blinkbits "><img src="./'.$this->imagesFolder.'/bookmark_blinkbits.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to blinkbits" title=" @ to blinkbits " /></a>';
$SBCode .= ' <a href="http://ma.gnolia.com/bookmarklet/add?url='.$this->url.'&title='.$this->siteTitle.'&description=&tags=" target="'.$this->target.'" title=" @ to ma.gnolia "><img src="./'.$this->imagesFolder.'/bookmark_magnolia.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to ma.gnolia" title=" @ to ma.gnolia " /></a>';
$SBCode .= ' <a href="http://smarking.com/editbookmark/?url='.$this->url.'&description='.$this->siteTitle.'&tags=" target="'.$this->target.'" title=" @ to smarking.com "><img src="./'.$this->imagesFolder.'/bookmark_smarking.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to smarking.com" title=" @ to smarking.com " /></a>';
$SBCode .= ' <a href="http://www.netvouz.com/action/submitBookmark?url='.$this->url.'&description=&tags=&title='.$this->siteTitle.'&popup=yes" target="'.$this->target.'" title=" @ to netvouz "><img src="./'.$this->imagesFolder.'/bookmark_netvouz.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to netvouz" title=" @ to netvouz " /></a>';
$SBCode .= ' <a href="http://co.mments.com/track?url='.$this->url.'" target="'.$this->target.'" title=" @ to co.mments "><img src="./'.$this->imagesFolder.'/bookmark_co.mments.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to co.mments" title=" @ to co.mments " /></a>';
$SBCode .= ' <a href="http://www.connotea.org/addpopup?continue=confirm&uri='.$this->url.'" target="'.$this->target.'" title=" @ to Connotea "><img src="./'.$this->imagesFolder.'/bookmark_connotea.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to Connotea" title=" @ to connotea " /></a>';
$SBCode .= ' <a href="http://de.lirio.us/rubric/post?uri='.$this->url.'" target="'.$this->target.'" title=" @ to de.lirio.us "><img src="./'.$this->imagesFolder.'/bookmark_de.lirio.us.png" width="'.$this->imageWidth.'" height="'.$this->imageHeight.'" alt="add to de.lirio.us" title=" @ to de.lirio.us " /></a>';
return $SBCode;
}
/**
* @function GetCode
* @author Özgür Karatag
* @description Gets the HTML code with the links to the Sozial Bookmark websites
*/
function GetCode() {
return $this->setcode();
}
/*
* @function setVar
* @returns mixed
* @param $name
* @param $value
* @author Özgür Karatag
* @description Sets the value of $name
*/
function setVar($name, $value)
{
$this->{$name} = $value;
}
}
?>