rechtstexte für onlineshop
Neuigkeiten
  • Die modified eCommerce Shopsoftware ist kostenlos, aber nicht umsonst.
    Spenden
  • Damit wir die modified eCommerce Shopsoftware auch zukünftig kostenlos anbieten können:
    Spenden
  • Thema: Heise.de Socialbuttons + XTC Blog (in Box) - Frage...

    Alex851

    • Neu im Forum
    • Beiträge: 11
    Huhu,

    ich habe heut den Sonntag genutzt um meinen Shop etwas auf Vordermann zu bringen.

    Zuerst habe ich das Heise.de Plugin Installiert (Facebook, Twitter, Google +) und danach den XTC Blog (in Box).

    Alles Funktioniert auch, bis ich die Datei "general.js.php" geändert habe und den "Code" vom Blog eingetragen habe. Der Blog geht, aber das Heise.de Plugin nicht mehr. Sobald ich den "Code" vom Blog lösche geht es wieder. Kann mir jemand helfen ?

    Code: PHP  [Auswählen]
    <?php
    /* -----------------------------------------------------------------------------------------
       $Id: general.js.php 1262 2005-09-30 10:00:32Z mz $

       XT-Commerce - community made shopping
       http://www.(( Wir dulden keine kommerziellen Werbelinks - Bitte <a href="index.php?topic=3013.0">Forenregeln</a> beachten! ))

       Copyright (c) 2003 XT-Commerce
       -----------------------------------------------------------------------------------------
       Released under the GNU General Public License
       ---------------------------------------------------------------------------------------*/



       // this javascriptfile get includes at the BOTTOM of every template page in shop
       // you can add your template specific js scripts here
    ?>
    <script src="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/javascript/jquery.js" type="text/javascript"></script>
    <script src="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/javascript/thickbox.js" type="text/javascript"></script>

    <link rel="stylesheet" href="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/slider/custom-nivo-slider.css" type="text/css" media="screen" />
    <script src="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/slider/jquery.nivo.slider.pack.js" type="text/javascript"></script>
    <script src="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/slider/slider_load.js" type="text/javascript"></script>


    <?php// BOF - web28 - 2010-07-09 - TABS/ACCORDION in product_info ?>
    <?php
    if (strstr($PHP_SELF, FILENAME_PRODUCT_INFO )) {
    ?>
    <script src="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/javascript/jquery-ui.js" type="text/javascript"></script>
    <script type="text/javascript">
            $(function() {
                    $("#tabbed_product_info").tabs();
                    $("#accordion_product_info").accordion({ autoHeight: false });
            });    
    </script>
    <noscript>
            <link rel="stylesheet" href="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/css/no_javascript.css" type="text/css" media="screen" />
    </noscript>
    <?php
    }
    ?>
    <?php// EOF - web28 - 2010-07-09 - TABS/ACCORDION in product_info ?>
    <script type="text/Javascript">
    <!--
    function createXMLHttpRequest() {

    var ua;

    if(window.XMLHttpRequest) {
        try {
          ua = new XMLHttpRequest();
        } catch(e) {
          ua = false;
        }
      } else if(window.ActiveXObject) {
        try {
          ua = new ActiveXObject("Microsoft.XMLHTTP");
        } catch(e) {
          ua = false;
        }
      }
      return ua;
    }

    var req = createXMLHttpRequest();

    function sendRequest(get,action,id,target,img) {
            if(target == null)
                    targetid= 'blog_inhalt';
            else
                    targetid= target;

            if(action == 'new') {
                    document.getElementById('comment').className = 'blog';
                    req.open('get', 'blog_request.php?open='+ get + '&action=' + action + '&blog_id=' + id);
            }
            else if(action == 'insert') {
                    req.open('get', 'blog_request.php?open='+get+'&action='+action+'&blog_id='+id+'&img_id='+img);
             }
            else
                    req.open('get', 'blog_request.php?open='+ get);
           
            req.onreadystatechange = handleResponse;
            req.send(null);
    }

    function get(obj) {
            <?php if(BLOG_CAPTCHA == 'ja') { ?>
                    var poststr = <?php if($_SESSION['customer_first_name'] == '') echo '"name=" + encodeURI( document.getElementById("name").value ) + '; ?> "&text=" + encodeURI( document.getElementById("text").value ) +
                    "&blog_id=" + encodeURI( document.getElementById("blog_id").value) +
                    "&captcha=" + encodeURI( document.getElementById("captcha").value);
        <?php } else { ?>
       
            var poststr = <?php if($_SESSION['customer_first_name'] == '') echo '"name=" + encodeURI( document.getElementById("name").value ) + '; ?>
                    "&text=" + encodeURI( document.getElementById("text").value ) +
                    "&blog_id=" + encodeURI( document.getElementById("blog_id").value);
        <?php } ?>
            makePOSTRequest('<?php echo $http.DIR_WS_CATALOG; ?>blog_request.php?open=comment', poststr, 'blog_inhalt');
    }

       
    function makePOSTRequest(url, parameters, target) {
            if (window.XMLHttpRequest) {
                    req = new XMLHttpRequest();
                    if (req.overrideMimeType) {
                            req.overrideMimeType('text/html');
                    }
            }
            else if (window.ActiveXObject) { // IE
                    try {
                            req = new ActiveXObject("Msxml2.XMLHTTP");
                    }
                    catch (e) {
                            try {
                                    req = new ActiveXObject("Microsoft.XMLHTTP");
                            }
                            catch (e) {}
                    }
            }
            if (!req) {
                    alert('Konnte die Anfrage nicht verarbeiten!');
                    return false;
            }
           
            req.onreadystatechange = handleResponse;
            req.open('POST', url, true);
            req.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
            req.setRequestHeader("Content-length", parameters.length);
            req.setRequestHeader("Connection", "close");
            req.send(parameters);
    }

    function fehlermeldung() {
            if (req.readyState == 4) {
                    if (req.status == 200) {
                            result = req.responseText;
                            document.getElementById('error_meldung').innerHTML = result;            
                    }
                    else {
                            alert('Es ist ein Fehler aufgetreten.');
                    }
            }
    }

    function handleResponse() {
            if(req.readyState == 4)
                    document.getElementById(targetid).innerHTML = req.responseText;
            else
                    document.getElementById(targetid).innerHTML = '<img src="<?php echo DIR_WS_CATALOG.'templates/'.CURRENT_TEMPLATE; ?>/img/icons/wait.gif" alt="Laden..." /><br /><br /> Inhalt wird geladen...';
    }
    //-->
    </script>
    <script src="<?php echo DIR_WS_CATALOG.'templates/'.CURRENT_TEMPLATE; ?>/javascript/jquery-1.2.6.js" type="text/javascript"></script>
    <?php if(BLOG_NAV_AJAX == 'ja') { ?>
    <script src="<?php echo DIR_WS_CATALOG.'templates/'.CURRENT_TEMPLATE; ?>/javascript/accordion.js" type="text/javascript"></script>
    <script type="text/javascript">
            <!--
                    ddaccordion.init({
                            headerclass: "blog_titel", //Shared CSS class name of headers group that are expandable
                            contentclass: "blog_items", //Shared CSS class name of contents group
                            revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click" or "mouseover
                            mouseoverdelay: 200, //if revealtype="mouseover", set delay in milliseconds before header expands onMouseover
                            collapseprev: true, //Collapse previous content (so only one open at any time)? true/false
                            defaultexpanded: [], //index of content(s) open by default [index1, index2, etc]. [] denotes no content
                            onemustopen: false, //Specify whether at least one header should be open always (so never all headers closed)
                            animatedefault: false, //Should contents open by default be animated into view?
                            persiststate: true, //persist state of opened contents within browser session?
                            toggleclass: ["", "blog_active"], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
                            togglehtml: ["prefix", "", ""], //Additional HTML added to the header when it's collapsed and expanded, respectively  ["position", "html1", "html2"] (see docs)
                            animatespeed: "slow", //speed of animation: integer in milliseconds (ie: 200), or keywords "fast", "normal", or "slow"
                            oninit:function(headers, expandedindices){ //custom code to run when headers have initalized
                            },
                            onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
                                    //do nothing
                            }
                    });
            //-->
    </script>
    <!-- begin jQuery Plug-In socialshareprivacy von http://www.heise.de/extras/socialshareprivacy -->
    <script src="<?php echo 'templates/'.CURRENT_TEMPLATE; ?>/socialshareprivacy/jquery.socialshareprivacy.min.js" type="text/javascript"></script>
    <script type="text/javascript"><!-- //<![CDATA[
    // Hier wird das Ganze an ein CSS-Objekt mit der id="socialshareprivacy" angehaengt.
    // Es koennen mehrere Instanzen verwendet werden, die ueber unterschiedliche id-Attribute identifiziert werden.
    jQuery(document).ready(function($){
          if($('#socialshareprivacy').length > 0){
            $('#socialshareprivacy').socialSharePrivacy(

        // Einstellungen hier vornehmen, Details bitte der Dokumentation von heise.de entnehmen:
            {
                'services' : {
                    'facebook' : {
                        'status'            : 'on',
                        'dummy_img'         : "<?php echo 'templates/'.CURRENT_TEMPLATE; ?>"+'/socialshareprivacy/socialshareprivacy/images/dummy_facebook.png',
                        'txt_info'          : '2 Klicks f&uuml;r mehr Datenschutz: Erst wenn Sie hier klicken, wird der Button aktiv und Sie k&ouml;nnen Ihre Empfehlung an Facebook senden. Schon beim Aktivieren werden Daten an Dritte &uuml;bertragen &ndash; siehe <em>i</em>.',
                        'txt_fb_off'        : 'nicht mit Facebook verbunden',
                        'txt_fb_on'         : 'mit Facebook verbunden',
                        'perma_option'      : 'on',
                        'display_name'      : 'Facebook',
                        'referrer_track'    : '',
                        'language'          : 'de_DE',
                        'action'            : 'recommend'
                    },
                    'twitter' : {
                        'status'            : 'on',
                        'dummy_img'         : "<?php echo 'templates/'.CURRENT_TEMPLATE; ?>"+'/socialshareprivacy/socialshareprivacy/images/dummy_twitter.png',
                        'txt_info'          : '2 Klicks f&uuml;r mehr Datenschutz: Erst wenn Sie hier klicken, wird der Button aktiv und Sie k&ouml;nnen Ihre Empfehlung an Twitter senden. Schon beim Aktivieren werden Daten an Dritte &uuml;bertragen &ndash; siehe <em>i</em>.',
                        'txt_twitter_off'   : 'nicht mit Twitter verbunden',
                        'txt_twitter_on'    : 'mit Twitter verbunden',
                        'perma_option'      : 'on',
                        'display_name'      : 'Twitter',
                        'referrer_track'    : '',
    // Hier kann eigener Text genutzt werden, oder eine vorher definierte JavaScript-Funktion.
    // Standard ist der Seitentitel
    //                    'tweet_text'        : getTweetText,
                        'language'          : 'en'
                    },
                    'gplus' : {
                        'status'            : 'on',
                        'dummy_img'         : "<?php echo 'templates/'.CURRENT_TEMPLATE; ?>"+'/socialshareprivacy/socialshareprivacy/images/dummy_gplus.png',
                        'txt_info'          : '2 Klicks f&uuml;r mehr Datenschutz: Erst wenn Sie hier klicken, wird der Button aktiv und Sie k&ouml;nnen Ihre Empfehlung an Google+ senden. Schon beim Aktivieren werden Daten an Dritte &uuml;bertragen &ndash; siehe <em>i</em>.',
                        'txt_gplus_off'     : 'nicht mit Google+ verbunden',
                        'txt_gplus_on'      : 'mit Google+ verbunden',
                        'perma_option'      : 'on',
                        'display_name'      : 'Google+',
                        'referrer_track'    : '',
                        'language'          : 'de'
                    }
                },
    // ENTWEDER neutraler Text ueber das Datenschutzproblem:
    //            'info_link'         : 'http://www.heise.de/ct/artikel/2-Klicks-fuer-mehr-Datenschutz-1333879.html',
    // ODER Datenschutzseite des Shops in der aktuellen Sprache:
    //            'info_link'         : ':_:2.html',
                  'info_link'         : 'shop_content.php?coID=2',
                  'txt_help'          : 'Wenn Sie diese Felder durch einen Klick aktivieren, werden Informationen an Facebook, Twitter oder Google in die USA &uuml;bertragen und unter Umst&auml;nden auch dort gespeichert. N&auml;heres erfahren Sie durch einen Klick auf das <em>i</em>.',
                  'settings_perma'    : 'Dauerhaft aktivieren und Daten&uuml;ber&shy;tragung zustimmen:',
                  'cookie_path'       : '/',
                  'cookie_domain'     : document.location.host,
                  'cookie_expires'    : '365',
                  'css_path'          : "<?php echo 'templates/'.CURRENT_TEMPLATE; ?>"+'/socialshareprivacy/socialshareprivacy/socialshareprivacy.css',
    // Hier kann eine eigene URI genutzt werden, oder eine vorher definierte JavaScript-Funktion.
    // Standard ist die als canonical angegebene URI, falls nicht vorhanden die Seiten-URI.
    //            'uri'               : getURI
            });
          }
        });
    //]]> --></script>

    <!-- end jQuery Plug-In socialshareprivacy von http://www.heise.de/extras/socialshareprivacy -->
    <?php } ?>


    Linkback: https://www.modified-shop.org/forum/index.php?topic=19500.0

    Schacko

    • Frisch an Board
    • Beiträge: 57
    • Geschlecht:
    Re: Heise.de Socialbuttons + XTC Blog (in Box) - Frage...
    Antwort #1 am: 15. April 2012, 22:45:09
    Hallo Alex851,

    versuche das Modul von noriddle zu installieren "* socialshareprivacy_multi_language.zip" die Datei findest Du in diesem Beitrag: MODUL: Facebook, Twitter & Google+ datenschutzkonform einbauen
    Der Vorteil => das javascript wird in der /includes/header.php implementiert.

    Grüße Jörg

    [EDIT Tomcraft 15.04.2012: Pfad korrigiert.]

    Schacko

    • Frisch an Board
    • Beiträge: 57
    • Geschlecht:
    Re: Heise.de Socialbuttons + XTC Blog (in Box) - Frage...
    Antwort #2 am: 15. April 2012, 22:48:28
    Hallo Alex851,

    sorry es muß natürlich /includes/header.php heißen.

    Grüße Jörg

    Alex851

    • Neu im Forum
    • Beiträge: 11
    Re: Heise.de Socialbuttons + XTC Blog (in Box) - Frage...
    Antwort #3 am: 16. April 2012, 00:15:47
    Leider liegt es nicht daran. Habe ich gemacht, Sobald ich den Code vom Blog einfüge ist das Plugin wieder weg... :/

    Schacko

    • Frisch an Board
    • Beiträge: 57
    • Geschlecht:
    Re: Heise.de Socialbuttons + XTC Blog (in Box) - Frage...
    Antwort #4 am: 16. April 2012, 00:42:55
    Hallo Alex851,

    welche javascript Fehlermeldung bekommst angezeigt?

    Grüße Jörg

    Alex851

    • Neu im Forum
    • Beiträge: 11
    Re: Heise.de Socialbuttons + XTC Blog (in Box) - Frage...
    Antwort #5 am: 18. April 2012, 13:19:05
    Hallo, ich bekomme gar keine Fehlermeldung angezeigt. Es ist einfach nicht mehr da...
    Habe es jetzt etwas anders gelöst. Man kann jetzt nur noch im Adminbereich in den Blog schreiben.
    Scheint alles zu Funktionieren soweit.

    Jetzt habe ich aber das Problem das bei einem Artikel auf einmal die Heise.de Buttons ganz unten am Ende des Artikels stehen. Alle anderen Artikel sind normal. Hab ich da irgendwo im Code nen Fehler gemacht ? Kann evtl. mal jemand schauen ? Ich würde die Arbeit natürlich auch bezahlen... Suche auch noch jemanden der mir mein Template etwas "farbiger" macht ;-)

    http://obdshop24.de/Diagnosetechnik/Universal-Tacho-Pro-2008-Programmierer-Dash-Unlock-Programmer::18.html
    Shop Hosting
    0 Antworten
    2145 Aufrufe
    01. September 2015, 11:21:02 von longchuan
    24 Antworten
    12727 Aufrufe
    27. Oktober 2011, 17:41:38 von Tomcraft
    6 Antworten
    3636 Aufrufe
    18. Juni 2015, 20:36:44 von Toby