Jump to content
Latest News: (loading..)
burt

Bootstrap 3 in 2.3.4 - Responsive from the Get Go

Recommended Posts

In theory that's a good idea. Practically though all javascript that has to be added to the page now needs to be wrapped in PHP so it can be added to the bottom of the template.

 

That's a pretty strict enforcement.

 

What about having a jQuery header tag module that would load the jquery file in the header but allow you to choose where to load it from (ie, locally or from a list of CDNs).


:heart:, osCommerce

Share this post


Link to post
Share on other sites

I was debating whether to just revert back to loading the jquery in the header/template_top anyway, as it solves quite a lot of potential issues with addons using inline jquery/js.  

 

I think reverting back and making it a HT module to load local or load from elsewhere, is a grand idea.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest current code (community-supported responsive 2.3.4.1BS Edge) here

 

Share this post


Link to post
Share on other sites

I am testing on desktop enviroment. The radio buttons is very small to touch in address selection. I thought that click on div or touch div containers with address as a card would be better to select radio buttons but doesnt worked.

 

error messages generated without loading jQuery in header.

ReferenceError: $ is not defined

i dont know is it jquery version error?


I fixed with radio select a click event on divs.

template top:

<script type="text/javascript" src="<?php echo tep_href_link('ext/jquery/jquery-1.8.0.min.js', Null, $request_type); ?>"></script>

inline script checkout_shipping_address.php

<script>
$(".clickselect").click(function(e){
    $(this).find(":radio").click();
});
</script>

and add class for call

      <div class="col-sm-4 clickselect">

but I dont like it... something wrong with $ in doom and not helped when put inline script after jQuery near to footer scripts.


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

@@Gergely - install the HT module "clickable row" ...  works in checkout_shipping (for the choosing of shipping methods).  

 

I'm still to update checkout_payment.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest current code (community-supported responsive 2.3.4.1BS Edge) here

 

Share this post


Link to post
Share on other sites

@@burt - are we  talking the same? The shipping method is working and I have installed clickable row. I have problem with address selection in address books.


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

@@burt - are we  talking the same? The shipping method is working and I have installed clickable row. I have problem with address selection in address books.

 

Then you need to recode those to suit your needs...maybe in the same way that the clickable row stuff works ...

 

I offer that clickable thing as an idea for you to extend.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest current code (community-supported responsive 2.3.4.1BS Edge) here

 

Share this post


Link to post
Share on other sites

Thanks just figured out in footer script.

 


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

Hello, i just installed current version from git and testing it. I question in the description it says to install boxes from admin logo, breadcrumb, footer boxes, side column boxes. I don't see anyone one of these in the box module installation screen. Any suggestions. Thanks

Share this post


Link to post
Share on other sites

@@sanam

 

take a look at the header tags. some stuff is in the boxes area and some  stuff need to be installed through the header tags area.

Share this post


Link to post
Share on other sites

@@Gergely - did you also test using touch (eg in tablet/smartphone). Does it fail if .js is set to off.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest current code (community-supported responsive 2.3.4.1BS Edge) here

 

Share this post


Link to post
Share on other sites

@@Gergely - did you also test using touch (eg in tablet/smartphone). Does it fail if .js is set to off.

ok. I will unhide radio button and extend my jQuery script.


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

@@sanam

 

take a look at the header tags. some stuff is in the boxes area and some  stuff need to be installed through the header tags area.

Thanks, i had checked but some of the files for boxes were missing. I had downloaded zip from gitup from "Download Zip" link on the left, then downloaded from the link in the forum for master which had all the files.

 

Testing for now, noticed one thing if you enable No Script Message from Header Tags the link thats displayed for enable-javascript.com website comes up like this

http://localhost/osboot/"http://www.enable-javascript.com/"

I removed tep_output_string from modules->header_tags->ht_noscript.php Line 34.

$oscTemplate->addBlock('<noscript><div class="no-script"><div class="no-script-inner">' . tep_output_string(MODULE_HEADER_TAGS_NOSCRIPT_TEXT) . '</div></div></noscript>', $this->group);

TO

$oscTemplate->addBlock('<noscript><div class="no-script"><div class="no-script-inner">' . MODULE_HEADER_TAGS_NOSCRIPT_TEXT . '</div></div></noscript>', $this->group);       

Now correct link is displayed.

 

Thanks

Share this post


Link to post
Share on other sites

Hi @@burt

 

Address Card Select pushed to my repo


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

@@burt just revised my commit..

only "col-sm-4" class name usage would be better. Discard the class name changes in checkout_shipping_address.php and checkout_payment_address.php
change "addresscardselect" to "col-sm-4" in includes/modules/header_tags/ht_address_card_click_jquery.php


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

I'm not sure about it, especially the revised commit.

 

I wonder if it would be more interesting to change the layout to a table then use the existing table click jquery ?

 

Did you have a real bad problem with selection of other addresses? If so, in what viewport? Smartphone? Tablet?

How can I replicate...


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest current code (community-supported responsive 2.3.4.1BS Edge) here

 

Share this post


Link to post
Share on other sites

I just experienced this with the website update to BS3 where Firefox was blocking the Font-Awesome fonts when the website was called as http://oscommerce.com because the public resources were being loaded from http://www.oscommerce.com.

 

This is due to cross origin resource sharing:

 

http://en.wikipedia.org/wiki/Cross-origin_resource_sharing

 

This may affect certain installations with BS3 (using its own glyphicon fonts) where the relevant headers in the web server configuration must be set.


:heart:, osCommerce

Share this post


Link to post
Share on other sites

@@burt nothing is special it works good just I dont want to do css classname dependencies in the module.
 


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

:D :P yes confirmed it is Burts lazy link

 

That happens if the URL doesn't have the www first.

 

@@mattjt83

Just ran into this and it seems to depend on how you have the

 

define('HTTP_SERVER', 'mysite');

 

set up in your configuration file. If you have it defined as "http://www.mysite.com" and you access the site that way, the glyphicons appear properly when the site is first accessed. If you fail to use the "www." then they don't. The reverse also seems to be true. If you set your HTTP_SERVER without the "www." and access your site with the "www." then they won't appear when the site is first accessed.

 

Can someone confirm that this is indeed the problem?

Share this post


Link to post
Share on other sites

@@Dan Cole that is exactly the issue.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest current code (community-supported responsive 2.3.4.1BS Edge) here

 

Share this post


Link to post
Share on other sites

I used this re-write rule which seems to have solved the problem...I don't know if Gary has any better solutions but this worked for me.

RewriteEngine OnRewriteCond %{HTTP_HOST} ^[^.]+\.[^.]+$RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [L,R=301]

Share this post


Link to post
Share on other sites

This isn't really a viable option, where some people use the www subdomain to differentiate secure and non-secure pages.

(I use this technique on a number of clients' sites to save a small fortune when utilising a particular CDN.)

Any solution shouldn't really care what subdomain it is being served from.

Edited by ejsolutions

Share this post


Link to post
Share on other sites

@@ejsolutions

@@Dan Cole

@@De Dokta

 

Could you try this snippet in the .htaccess file, remove the force to/away www entirely. I'm not 100% sure where this Snippet came from, anyone got ideas: http://forums.oscommerce.com/topic/396152-bootstrap-3-in-2334-responsive-from-the-get-go/?p=1700855

 

@@Tsimi


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest current code (community-supported responsive 2.3.4.1BS Edge) here

 

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×