WebsiteBaker Community Forum

WebsiteBaker Support (2.13.x) => General Help & Support => Topic started by: styzer1137 on December 14, 2023, 09:39:32 PM

Title: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: styzer1137 on December 14, 2023, 09:39:32 PM
Hi all,

It's been years since I've made these two websites using WB (2007). The client would like to see about upgrading to the latest version "if it doesn't create too much problems."

So I'm wondering from others who have done this jump from 2.6.x to 2.13.x - what should I expect to have to do to make it smooth? What is the best course of action to upgrade over so many versions?

And he likes this template to replace the one used presently:
https://template.WebsiteBaker.org/pages/frontend-templates/demo-chio.php?template=oiphyx

His website is in the process of getting an SSL working, but right now it's at http://www.totalchange.org/

Thanks for any help! It's been a while!

Andre

Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: sternchen8875 on December 14, 2023, 11:28:50 PM
Quote
It's been years since I've made these two websites using WB (2007). The client would like to see about upgrading to the latest version "if it doesn't create too much problems."

the upgrade is not the problem, but maybe, is it not possible, to use the One-Step-Automatic-Upgrade from the newer WB-Versions, because your version is already far too old. If you have a lot of experience with WB, you may be able to troubleshoot possible problems manually. But if not, you need help from a expert.

best solution is a test in a subfolder and with a different database (or rename the table-prefix in a copy of the database-backup-file) Also possible is a copy of this project on another server, but maybe its difficult, to run this project with a newer version of php and mysql.
I have upgraded many old projects like this, but I use a special method to do so when the automatic upgrade is not successful. Very important is a good backup from the actual database (before you start the upgrade) and from all files and folders. i put this backups in a special folder and if needed, i make a copy of this files, so that i've everytime a clean backup as "backup".

I do such difficult upgrades at home on my computer, that means offline. there i can switch the php-version and have fast access to the database.
Possible problem with a old version like yours in a upgrade:
- the database-settings table
- the old modules, if they are not part of the latest wb-package (for example: the old modules using mysql, new version use mysqli)
- older templates using the old showmenu()-function, newer templates show_menu2()

maybe, you can send us a screenshot or list from your /modules-folder of this project, so that we see, what kind of modules are installed.

P.S.: in the best case, where everything works and only default modules from the latest wb in use, the upgrade needs around 5 minutes

If you need help, build a ZIP-file with the backup-files (Folders && database) and send me a download-link
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: styzer1137 on December 15, 2023, 01:19:54 AM
Thanks! So there is hope... Great! But it could be a bumpy ride if everything has to be fixed along the way... Hmmm.

I'm going through the website right now, and noticed hundreds of spam comments. Is there a way to BULK DELETE all these comments?

I will take care of this to remove useless content first. Then I lock (disable) the commenting.

Thank you,

Andre

Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: styzer1137 on December 15, 2023, 03:12:29 PM
Where can I find information:

1- where can I modify the menu links? They all use non-SSL but I have looked for over an hour multiple time and read the PDF and search the forum unsuccessfully.

2- How can I batch delete 1423 spam comments?

Thank you in advance to anyone for any help, I feel literally lost after all these years.

Andre
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: sternchen8875 on December 15, 2023, 03:47:29 PM
crazy font styling....  :|

Quote
where can I modify the menu links?

intern links or extern links?
a intern menu-link use the WB_URL from the config.php. if this WB_URL has a https, all intern menu-links has it also - that means: you have nothing to change there, except this WB_URL in your config-file

for extern links: only step by step. its not recommended to use a batch-function like search&&replace in the sql-backup, because, you've to check every extern menu-link for this https-adress

Quote
How can I batch delete 1423 spam comments?

i do it directly in the database
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: styzer1137 on December 15, 2023, 06:09:31 PM
Thanks, sorry for the late night font formatting... I always zoom my screen 150%.

► I looked at the config file, I checked and this is what I see already:
Code: [Select]
define('WB_URL', 'https://www.totalchange.org/wb');
But when I access the site, it is only showing well using http. As soon as https is used, it is broken CSS.

So I tested the site using whynopadlock:
https://www.whynopadlock.com/results/e9dcb9f4-b680-4e9f-b6eb-cb1d978e84d9

► So there are 3 errors, and when I "View Source" all the navigation internal links show http, so that's what I'm trying to fix. But I couldn't find where to edit those links. Same issue with the contact FORM. Can't see where to edit it.

► What kind of quote could I give my client to upgrade his site to 2.13.x? It seems best to offer him that option rather than me trying to figure this out. Unless I could convert to WordPress, wonder if that could work.

Thanks again!

Andre




Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: styzer1137 on December 15, 2023, 08:25:50 PM
What an idiot I am.  :-( I was editing the wrong config.php file!!  :oops:

However, the internal site menu links don't open the pages. I notice to the /wb mention added to every link, and no page opens.

Having to dive under the hood again. Any video tutorials I could check?
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: sternchen8875 on December 16, 2023, 03:10:15 PM
not sure, what are you doing there, but it looks, that you try to fix the old WB 2.6.5 before you start the Upgrade

From a visitor-view, it looks like two WB-Installations, first in main-folder of totalchange.org, and second in totalchange.org/wb.
The pictures and some other content are linked to the /wb-subfolder, but maybe, it was linked so also in the past, before you start your work

Since WB 2.10.x WB use a placeholder in the database instead of the complete web-adress ({SYSVAR:AppUrl.MediaDir}) of a picture-link, but in former wb-versions, it use a absolute link, for example
in WB 2.6.5: http://www.totalchange.org/media/restor.jpg
since WB v2.10.x: {SYSVAR:AppUrl.MediaDir}restor.jpg

Now the little "trick" ;-)
{SYSVAR:AppUrl.MediaDir} is the placeholder  for the combination WB_URL + MEDIA_DIRECTORY. WB_URL come's from the config.php, MEDIA_DIRECTORY from the database, settings-table, means from the advanced WB_Settings
if the script found this combination in the save-process for a module like News or Wysiwyg, it replace it with the placeholder. if the old content has a valide link to a picture to a folder outside from the wb-package-folders, for example like this -> https://www.totalchange.org/wb/media/restor.jpg
the script replace only the WB_URL + MEDIA_DIR, but not the next subfolder, here the /wb
and after a upgrade, you have there a link to a picture in the database like this -> {SYSVAR:AppUrl.MediaDir}wb/media/restor.jpg
the only way to change it, is a manual correction of links like this. My solution for cases like this: i make a database backup, open this file with a good editor and search for the absolute path like www.totalchange.org/wb/ - for every search-result, i've to check the code around: is it a link to a file? and do i have this file also in my "good" wb-installation, this one in the main-folder of this domain. Maybe, it is a good soltion, if you rename the existed subfolder, called /wb, because: at the moment, all links to that folder are valide and it difficult to find problems then.

Quote
However, the internal site menu links don't open the pages. I notice to the /wb mention added to every link, and no page opens.

in older wb-versions, the backend (admin-area) use a own variabla, called ADMIN_DIRECTORY, also defined in the config.php. check the link there also.

P.S.: trouble like this is the result, when you try, to fix the old stuff at first - to many time lost to look for solutions to old stuff

Quote
What kind of quote could I give my client to upgrade his site to 2.13.x? It seems best to offer him that option rather than me trying to figure this out. Unless I could convert to WordPress, wonder if that could work.

i cannot understand, why you thinking about a new cms, if the job needs only a couple of minutes. And even if it takes two days with WB, you're still faster than with Wordpress or any other CMS.
Here another "trick", works fine, if you dont have a lot of other modules, mostly the default modules like news, form, menu-link and wysiwyg
- add via FTP a new folder in the main-directory of your webspace, where you've installed the old wb 2.6.5
- call this folder wb_new or something like that
- upload the ZIP from the WB_Package and also the unpacked/renamed unzip.php - see here-> https://addon.WebsiteBaker.org/pages/en/browse-add-ons.php?id=02C623F5 and https://addon.WebsiteBaker.org/pages/en/browse-add-ons.php?id=04D6D0F4
- call the unzip.php with the complete adress in your browser - maybe: https://www.totalchange.org/wb_new/unzip.php
- after the unzip-process, start the installer. You can use the same database (if needed), but its important, that you use a different table-prefix. otherwhise, it overwrite the datas from the old WB
- now rebuild the old page tree in the new installation. i work with multiple monitors and use one for the old stuff and one for the new stuff. Be sure, that you select everytime the correct section type
- if you copy the old content from news or wysiwyg-sections, switch the editors to Source Code, copy the whole content and add it to the new wb. check every intern link in the content and if you not sure, select the file again in the filebrowser.

this works for the most pages in your project. for the content of a guestbook, it needs some more experience, but its also possible. Remember: any of the module has no longer support, for example: bakery-shop or newsletter-module. here you need a new solution or you can fix it by yourself

So, now its my weekend. i spend a lot of time for the answers, enough for two or more upgrades  :|

Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: styzer1137 on December 16, 2023, 05:11:34 PM
Hi sternchen8875, I did mention I'm an idiot. Sorry to have wasted your time, but I truly appreciate you trying to help.

However, unfortunately, all this is beyond my understanding or ability to transpose it in real life.

My most sincere apologies, another more knowledgeable than me would probably leap on your solutions and implement them without an issue.

Wishing you a great weekend,

With gratitude,

Andre
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: sternchen8875 on December 17, 2023, 01:51:08 AM
Hi sternchen8875, I did mention I'm an idiot.
Dont call it "idiot" - You may not be a WB expert, but 99% of cms-users are not a expert for a special cms - there's no shame in that

Sorry to have wasted your time, but I truly appreciate you trying to help.
It's not my time that's wasted - it's yours  :wink:
It's a help forum here and my "job" is to answer questions and help people.

However, unfortunately, all this is beyond my understanding or ability to transpose it in real life.

Simple question:
then why not the simple solution? You get the offer that someone will do the upgrade for you. If you provide the access data for the server and database (via private message), all you have to do at the end is check. If you "only" provide the two backups, you will have to upload the corrected version later and update the database. Takes a little more time. Either way, in total less time than you have invested so far.

My most sincere apologies, another more knowledgeable than me would probably leap on your solutions and implement them without an issue.
You do not have to apologize. this is not necessary. It may also be that you would like to do this job yourself and would like to familiarize yourself with WB in order to understand it so that you can later do similar jobs for other customers and then it is definitely better if you can do things yourself tried.

Wishing you a great weekend

same for you
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: hgs on December 17, 2023, 07:46:56 AM
I would accept the offer.
sternchen8875 has already got 100s of websites up and running again.

It is important to have a functional backup of the database and the FTP area.
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: styzer1137 on December 22, 2023, 05:56:41 PM
However, unfortunately, all this is beyond my understanding or ability to transpose it in real life.

Simple question:

then why not the simple solution? You get the offer that someone will do the upgrade for you. If you provide the access data for the server and database (via private message), all you have to do at the end is check. If you "only" provide the two backups, you will have to upload the corrected version later and update the database. Takes a little more time. Either way, in total less time than you have invested so far.[/quote]

Hi, thanks for the offer, I have no plan to do this by myself, believe me! :)

I tried to contact you via PM, but just clicking on your name leads me to a dead-end. I have no permission, etc.

Can you contact me so we can look into this?
Title: Re: Upgrading from 2.6.5 - jump to 2.13.x?
Post by: hgs on December 23, 2023, 08:24:33 AM
I have sent you a PM
I have sent you a PM and will forward the data to sternchen8875