Jump to content
kymation

[Addon} Theme Switcher

Recommended Posts

Yes, Version: 1.4.2

 

PHP: PHP Version 5.5.0

osCommerce Online Merchant v2.3.3

 

 

no changes to the code at all

Share this post


Link to post
Share on other sites

osCommerce 2.3.3 does not support PHP versions 5.4 and above. I doubt that most of the addons will either. I don't currently have any way to test/debug under PHP 5.5, so I'm not going to be much help.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

thanks kymation for this addon, after 20 pages of reading i could make it work but just in 1.8.23 themes eventually i will try again in future upgrades.

 

osCommerce Online Merchant v2.3.3

Theme Switcher 1.4.2

 

i get this error:

 

Warning: Illegal string offset 'id' in /users/andy2050/www/catalog/includes/modules/header_tags/ht_theme_switcher.php on line 159

 

and reading previous post the fix was:

 

$colarr[$col]['_' . $k] = @$strtolower($row[$col]);

 

and the other error

 

Warning: Illegal string offset 'id' in /users/andy2050/www/catalog/includes/modules/header_tags/ht_theme_switcher.php on line 186

 

i beleive this fix is

 

$ret[$k][$col] = @$array[$k][$col];

Edited by Tripa-X

Share this post


Link to post
Share on other sites

Those changes just hide the error message. That's fine, but it doesn't fix the underlying problem. I need to take another look at that some day, when I have the time.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Hi Jim,

 

 

I found out that using the JQUERIE 1.10.2 caused a problem ! After clicking on a productpicture it don't shows up in a PopUp but in a new page!!

Thanks of your great addon I play with it and found when I use the JQUERIE 1.8.22 the problem is solved !!

Any idea? sugestion?

 

Thanks

Regards

Kozak

Share this post


Link to post
Share on other sites

This happens because jQuery has removed some of the functionality that Fancybox uses to generate the modal screen. You can fix this by adding jQuery Migrate to your site.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

I must have an issue with my JS because I cannot see any of the theme, it's all missing/transparent. Just words. I've been trying various things suggested through the thread, but nothing ever shows up.

 

http://i32.photobucket.com/albums/d5/audiogodz1/ScreenShot2013-07-22at12755PM.png

 

http://i32.photobucket.com/albums/d5/audiogodz1/ScreenShot2013-07-22at12349PM.png

 

http://i32.photobucket.com/albums/d5/audiogodz1/ScreenShot2013-07-22at12356PM.png

Edited by lextech

RC2.2a

Share this post


Link to post
Share on other sites

It looks like something is wrong with your theme. There are extra folders in the theme folder, and some of the normal theme files are missing. Also, your latest theme CSS file is a lot smaller than it should be. Try following the instructions to extract the theme again, and check all of your steps.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Dear Jim,

 

 

I figured it out that my problem with Product Tabs Version 1.1 is due to JQUERY.

Thanks to your great addon Theme Switcher it's easy to change and testing.

When I use Jquery Version 1.8.0 with Jquery UI Version 1.8.6 everything works fine.

When I go a level higher of one of both the layout is not the right one and when using Jquery UI Version 1.10.3 I get the index page as a second layer over the product info page.

I download Jquery Migrate 1.2.1, add these to the jquery folder and ad the next script :

 

<script src="http://code.jquery.com/jquery-1.9.0.js"></script>

<script src="http://code.jquery.com/jquery-migrate-1.2.1.js"></script>

to template_top but that does'n change the issue.

As you know I am not a coder so probably i do something wrong.

 

thanks for advise

 

regards

Kozak

Share this post


Link to post
Share on other sites

Remove this line:

<script src="http://code.jquery.com/jquery-1.9.0.js"></script>

 

Theme Switcher adds the links to jQuery, jQuery UI, and the theme, so you don't need to put that in a second time. Are all of the check marks in Theme Switcher green? Is the jQuery version number 1.9.0?

 

Regards

Jim

 

Edit: Stupid editor munged the code.

Edited by kymation

See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Hi,

 

what happens if you use

jQuery v1.10.2

or

<script type="ext/jquery/jquery-1.10.1.min.js"></script>

 

??

 

Regards

Joli

 

Edit: Sorry forgot theme switcher changes the template_top.php

Edited by joli1811

To improve is to change; to be perfect is to change often.

 

Share this post


Link to post
Share on other sites

Jim, Thank you. I want to verify it is not my settings causing my issues since I have unsuccessfully tried many themes. Can you point out one free download theme that will make enough dramatic changes that I can see a good amount of change and verify it is working properly? I don't know which one's actually work so I don't know if the issue is my setup or the theme on my 2.3.3 site.

Edited by lextech

RC2.2a

Share this post


Link to post
Share on other sites

Any of the themes on the jQuery UI site should work, provided that you have the latest versions of jQuery and jQueryUI. If you want one that's different, choose LeFrog. It's really green.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Hi Jim,

 

I removed the <script src="http://code.jquery.com/jquery-1.9.0.js"></script> but no change.

I have jQuery version number 1.9.1 and also try the 1.10.2 version.

Because the last years I played a lot with Oscommerce I have a bunch of JQuery files and played with them.

At the moment I go higher then version 1.8.0 it's GAME OVER :(

and the UI version not higher then 1.8.6 or it's GAME OVER :(

 

really stupid that when something works the engineers like to change the system, if possible into something that older versions don't work anymore :devil:

 

I think the only solution is to adapt the old version that it looks like my new version

 

What I also wondering about is that the Product Tabs dont contains JQuery codes? so why JQuery f*ck up the systems after that addon?

 

thanks for your kind support

regards

Kozak

Share this post


Link to post
Share on other sites

I have yet to have a jQuery problem that jQuery Migrate (or the simpler jquery.mb.browser.min.js) won't fix. I can't guess what's wrong with your site. I'll take a look if you give me a URL. Use PM if you don't want to post it here.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Any of the themes on the jQuery UI site should work, provided that you have the latest versions of jQuery and jQueryUI. If you want one that's different, choose LeFrog. It's really green.

 

Regards

Jim

 

Thank you, I did go get a theme from there and it says the Jquery is wrong, but the theme works and as you can see it has the right number.

 

http://i32.photobucket.com/albums/d5/audiogodz1/ScreenShot2013-07-25at90000PM.png

 

It does work though :) I just had to remove the word custom from the css.

Edited by lextech

RC2.2a

Share this post


Link to post
Share on other sites

Your screenshot says that your ext/jquery/jquery-1.10.3.min.js is missing. If everything is working without it, you have an error in your includes/template_top.php. Look for an extra call to a jQuery UI Javascript file.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

That's not actually an error. Eclipse does the same thing, but there's nothing wrong with the code. The false error message is caused by the comment in the Javascript block. Of course you can remove that entire block if you upgrade your jQuery to a newer version.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

@

You have this line before the <head> tag:

<script src="[url="view-source:http://code.jquery.com/jquery-migrate-1.2.1.min.js"]http://code.jquery.com/jquery-migrate-1.2.1.min.js[/url]"></script>

 

That is invalid. That line needs to be after the jQuery files are included, but before they are used. Just before the bxGallery script should work.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

hi Jim,

 

thanks to take a look, I understand what you mean but your modified template_top dont mention the jquery script anymore as we select it in the adminsite now.

 

This is the script :

 

<head>

<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>" />

<title><?php echo tep_output_string_protected($oscTemplate->getTitle()); ?></title>

<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>" />

<link rel="stylesheet" type="text/css" href="ext/960gs/<?php echo ((stripos(HTML_PARAMS, 'dir="rtl"') !== false) ? 'rtl_' : ''); ?>960_24_col.css" />

<link rel="stylesheet" type="text/css" href="stylesheet.css" />

<?php echo $oscTemplate->getBlocks('header_tags'); ?>

<?php

if (tep_not_null(JQUERY_DATEPICKER_I18N_CODE)) {

?>

<script type="text/javascript" src="ext/jquery/ui/i18n/jquery.ui.datepicker-<?php echo JQUERY_DATEPICKER_I18N_CODE; ?>.js"></script>

<script type="text/javascript">

$.datepicker.setDefaults($.datepicker.regional['<?php echo JQUERY_DATEPICKER_I18N_CODE; ?>']);

</script>

<?php

}

?>

<script src="http://code.jquery.com/jquery-migrate-1.2.1.min.js"></script>

<script type="text/javascript" src="ext/jquery/bxGallery/jquery.bxGallery.1.1.min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/jquery/fancybox/jquery.fancybox-1.3.4.css" />

<script type="text/javascript" src="ext/jquery/fancybox/jquery.fancybox-1.3.4.pack.js"></script>

</head>

 

regards

Kozak

Share this post


Link to post
Share on other sites

Yes, the Theme Switcher module acts as a Header Tags module. That's because the jQuery theme is called by a header tag. So the jQuery, jQuery UI, and theme code is now generated at this line in template_top.php:

 

<?php  echo $oscTemplate->getBlocks('header_tags');  ?>

 

Anything that depends on jQuery needs to come after that line.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

that does'n change anything Jim

 

<head>

<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>" />

<title><?php echo tep_output_string_protected($oscTemplate->getTitle()); ?></title>

<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>" />

<link rel="stylesheet" type="text/css" href="ext/960gs/<?php echo ((stripos(HTML_PARAMS, 'dir="rtl"') !== false) ? 'rtl_' : ''); ?>960_24_col.css" />

<link rel="stylesheet" type="text/css" href="stylesheet.css" />

<?php echo $oscTemplate->getBlocks('header_tags'); ?>

<script src="http://code.jquery.com/jquery-migrate-1.2.1.min.js"></script>

<script type="text/javascript" src="ext/jquery/bxGallery/jquery.bxGallery.1.1.min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/jquery/fancybox/jquery.fancybox-1.3.4.css" />

<script type="text/javascript" src="ext/jquery/fancybox/jquery.fancybox-1.3.4.pack.js"></script>

<?php

if (tep_not_null(JQUERY_DATEPICKER_I18N_CODE)) {

?>

 

$.datepicker.setDefaults($.datepicker.regional['<?php echo JQUERY_DATEPICKER_I18N_CODE; ?>']);

</script>

<?php

}

?>

</head>

 

wright me how it must be please, I tried different way's but still te same results.

 

Thanks a lot

 

regards

Jim

Share this post


Link to post
Share on other sites

You still haven\t fixed the error I mentioned in this post. I can't do anything more until that's fixed.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Ohh yes I amworking offline not on the server, sorry. I changed it now

 

regards

Kozak

 

It's done, but did'n solved the issue

Edited by kozak

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×