Re: Convert SMF to ElkArte Reply #75 – December 14, 2013, 04:38:14 pm Thorsten, does the OpenImporter version of your script fix the infamous path checking problem in the Wedge importer? You know, the error message that shows up even when the path is alright, and that can only be avoided by directly clicking Next after entering the path name..? (i.e. skipping the path check altogether.)
Re: Convert SMF to ElkArte Reply #76 – December 15, 2013, 06:31:38 am Quote from: Nao – December 14, 2013, 04:38:14 pmThorsten, does the OpenImporter version of your script fix the infamous path checking problem in the Wedge importer? You know, the error message that shows up even when the path is alright, and that can only be avoided by directly clicking Next after entering the path name..? (i.e. skipping the path check altogether.)TBH, I don't remember that bug, and I also don't know if it's fixed or not..
Re: Convert SMF to ElkArte Reply #77 – March 29, 2014, 10:45:05 pm wanna bump this as I cant see a new topic anywhere about this ... any updates will current one work for beta 2?
Re: Convert SMF to ElkArte Reply #78 – April 03, 2014, 08:03:14 am Hi TrayBake, this would probably be @TE field, though I can guess that if it worked with beta 1, it will work with anything up to the final 1.0 version. Of course this is a guess about the future, but for now, since Elk 1.0 beta 1 was released, the database schema has not been changed and as such if the converter worked with beta 1, it will work with beta 2 as well!
Re: Convert SMF to ElkArte Reply #79 – April 06, 2014, 11:01:39 am Quote from: TE – December 15, 2013, 06:31:38 amQuote from: Nao – December 14, 2013, 04:38:14 pmThorsten, does the OpenImporter version of your script fix the infamous path checking problem in the Wedge importer? You know, the error message that shows up even when the path is alright, and that can only be avoided by directly clicking Next after entering the path name..? (i.e. skipping the path check altogether.)TBH, I don't remember that bug, and I also don't know if it's fixed or not.. It was half-fixed. There was a bug in the JavaScript testing the path, I fixed that one around the time I discussed this. But there's also another bug left, and I just looked into it and understood what was going on, but I haven't found a fix yet.The problem is that when the importer script is first loaded, $this->xml is empty, and thus $this->xml->general->settings returns nothing. Because of that, your script replaces it with 'null', and does its test on /foldernull instead of /folder/Settings.php...I noticed that it only happens on FIRST load, that is, if you reload the page, then it works.Because of the first load thing, I figured it might be a session problem, and indeed it seems to be.From what I could gather, you're initializing $_SESSION variables, then determining if a script was passed in the URL, in which case it initializes it. But if there isn't, it doesn't seem to initialize anything.I'm not 100% sure, I'll need to test, but it looks like if you have just ONE *_to_wedge.xml file in your root folder, then this might trigger the bug.I'll spend some more time on this.
Re: Convert SMF to ElkArte Reply #80 – April 06, 2014, 11:59:28 am Okay... Found it.NOT A FUNNY BUG.OOP is cool, but it can end up a mess, as is the case here.Now, when it comes to a situation where only one script is in the folder, here's how the importer detects them...- Importer object is created. Does the session variable hold a script? If yes, decode it, and fill $this->xml. (Currently: none)- $template->header(), where $import->xml is tested against. (Currently: empty. The 'from' header is initialized as 'null'.)- step0. Here's where we look for scripts... If more than one is found, ask for which to use. After this point, we go back to the beginning, and we have a session variable. If only one is found, the session variable is directly initialized with the script path, and... We skip to the next step. At that point, the importer script has already shown the header, which has 'null' in it, and we have a valid script with its data, etc in it.Possible ways to fix:- Skip $template->header in case $import->xml is empty, and execute it in doStep0 instead.- Redirect to the same script once the session variable is set.What do you prefer, @Thorsten..?
Re: Convert SMF to ElkArte Reply #81 – April 06, 2014, 04:53:25 pm I've decided to go with the redirect. (Header location.)It's just slightly cleaner, and more in line with the multi-script part of the code.
Re: Convert SMF to ElkArte Reply #82 – April 06, 2014, 05:55:43 pm @emanuele yep I tried and got it working:http://convert.bryandeakin.com/forum/Now just working on a new look that fits my site better
Re: Convert SMF to ElkArte Reply #83 – April 06, 2014, 06:00:43 pm Was your SMF test site in ISO or UTF-8? I'm just wondering how well the converter handles going from SMF/ISO to Elk/UTF-8.Also, has anyone tested 1.1.x/ISO to Elk/UTF-8 yet?
Re: Convert SMF to ElkArte Reply #84 – April 06, 2014, 06:02:46 pm test site is a direct clone of main site and thats in UTF-8
Re: Convert SMF to ElkArte Reply #85 – April 06, 2014, 06:03:59 pm K. Gonna have to see what disasters happen with ISO/UTF-8.
Re: Convert SMF to ElkArte Reply #87 – April 06, 2014, 06:11:40 pm Has Spuds gone and changed the censor strings again?
Re: Convert SMF to ElkArte Reply #88 – April 06, 2014, 06:12:24 pm I ran into a bug in the openimporter when I let the Elk install script create the Settings.php file from scratch. (i.e. I didn't copy the one from the install directory into the main directory.) Elk works ok but openimporter dies because a variable wasn't set in Settings.php. Sadly I don't recall what variable it was though.