Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Floating Menu


lc0

Recommended Posts

Posted

Hello, I would put a floating side menu on oscommerce but I can't make it working.

This is the html code:

 

<head>
<link rel="stylesheet" type="text/css" href="styles.css" />
<script type="text/javascript" src="floating-1.12.js"> 
</script>
</head>
<body>
<div id="floatdiv" style=" 
   position:absolute;
   margin:80px auto;
   width:40px;height:200px;top:10px;right:10px; 
   padding:16px;background: transparent;   
   z-index:100"> 
<ul id="navigationMenu">
   <li>
 <a class="home" href="#">
	    <span>Home</span>
    </a>
   </li>

   <li>
 <a class="about" href="#">
	    <span>Chi siamo</span>
    </a>
   </li>

   <li>
  <a class="services" href="#">
	    <span>Eventi</span>
	 </a>
   </li>

   <li>
 <a class="portfolio" href="#">
	    <span>Portfolio</span>
    </a>
   </li>

   <li>
 <a class="contact" href="#">
	    <span>Seguici</span>
    </a>
   </li>
</ul> 
</div> 

<script type="text/javascript"> 
   floatingMenu.add('floatdiv', 
    { 

	    targetLeft: 0, 
	    targetTop: 10, 

	    snap: true 
    }); 
</script> 

 

styles.css and floating-1.12.js are external files, but nothing works.

Posted

assuming you use 2.3.x you should put it in includes/template_top.php

 

if you only want it on the home page, you should check that the page is index.php and current_category_id == 0

to only then add the javascript, in the header section and the actual html content in the body

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Posted

Yes, I use 2.3.3.4. I put it in template_top but it doesn't works and I don't understand why.

Posted

Ok, now all works!

I had to put the javascript and style files in the ext folder.

So, this is the result.

Posted

Cool :thumbsup:

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...