Migration help
Permalink
I started a conversation in the install forum but really am not sure if my question is for install or really part of this forum. So please excuse the cross post.
I'm trying to export from V5.6.3.3. I've installed the migration tool, but when I try to use it, I end up with HTML along these lines:
_POST['batchPageID'] as $cID) { $r->pages[] = $cID; $batch->removePageID($cID); } } else { $r->error = true; $r->messages = $this->error->getList(); } print Loader::helper('json')->encode($r); exit; } public function view_batch($id = null) { if ($id) { $batch = MigrationBatch::getByID($id); } if (is_object($batch)) { $this->set('batch', $batch); $this->set('pages', $batch->getPages()); } } public function batch_deleted() { $this->set('message', t('Batch deleted.')); $this->view(); } public function view() { $batches = MigrationBatch::getList(); $this->set('batches', $batches); } public function submit() { if ($this->token->validate("submit")) { $batch = MigrationBatch::create($_POST['description']); $this->redirect('/dashboard/migration/batches', 'view_batch', $batch->getID()); } else { $this->error->add($this->token->getErrorMessage()); } } }
concrete5
Return to Website
Dashboard
Intelligent Search
Sign Out
getDashboardPaneHeaderWrapper(t('Migration Tool'))?> controller->getTask() == 'view_batch' && $batch) { ?>
output("update_batch")?>
getCollectionName()?> getCollectionDescription()?>
getID()?> getTimestamp()?> getDescription()?>
output("submit")?>
textarea('description', array('style' => 'height: 120px'))?>
getDashboardPaneFooterWrapper();?>
Because of the odd output, I"m not sure what I need to be doing to try to export.
I did try clearing the cache but that did not help.
Anyone have ideas on what I'm missing?
I'm trying to export from V5.6.3.3. I've installed the migration tool, but when I try to use it, I end up with HTML along these lines:
_POST['batchPageID'] as $cID) { $r->pages[] = $cID; $batch->removePageID($cID); } } else { $r->error = true; $r->messages = $this->error->getList(); } print Loader::helper('json')->encode($r); exit; } public function view_batch($id = null) { if ($id) { $batch = MigrationBatch::getByID($id); } if (is_object($batch)) { $this->set('batch', $batch); $this->set('pages', $batch->getPages()); } } public function batch_deleted() { $this->set('message', t('Batch deleted.')); $this->view(); } public function view() { $batches = MigrationBatch::getList(); $this->set('batches', $batches); } public function submit() { if ($this->token->validate("submit")) { $batch = MigrationBatch::create($_POST['description']); $this->redirect('/dashboard/migration/batches', 'view_batch', $batch->getID()); } else { $this->error->add($this->token->getErrorMessage()); } } }
concrete5
Return to Website
Dashboard
Intelligent Search
Sign Out
getDashboardPaneHeaderWrapper(t('Migration Tool'))?> controller->getTask() == 'view_batch' && $batch) { ?>
output("update_batch")?>
getCollectionName()?> getCollectionDescription()?>
getID()?> getTimestamp()?> getDescription()?>
output("submit")?>
textarea('description', array('style' => 'height: 120px'))?>
getDashboardPaneFooterWrapper();?>
Because of the odd output, I"m not sure what I need to be doing to try to export.
I did try clearing the cache but that did not help.
Anyone have ideas on what I'm missing?
Can you post a screenshot or a copy of the full output that you are getting? It almost looks like a PHP error or a 404 page, but it's hard to tell from this.
It is a bit hard to read because of the background image but a screen shot is attached.
If there is a way to remove the image so that the information is more visible, I'm willing to try that.
If there is a way to remove the image so that the information is more visible, I'm willing to try that.
My server should be using php 5.3. Here is a package list:
php-5.3.3-46.el6_6.x86_64
php-intl-5.3.3-46.el6_6.x86_64
php-cli-5.3.3-46.el6_6.x86_64
php-xml-5.3.3-46.el6_6.x86_64
php-common-5.3.3-46.el6_6.x86_64
php-mysql-5.3.3-46.el6_6.x86_64
php-devel-5.3.3-46.el6_6.x86_64
php-pdo-5.3.3-46.el6_6.x86_64
php-gd-5.3.3-46.el6_6.x86_64
php-mbstring-5.3.3-46.el6_6.x86_64
php-ldap-5.3.3-46.el6_6.x86_64
php-mcrypt-5.3.3-4.el6.x86_64
php-5.3.3-46.el6_6.x86_64
php-intl-5.3.3-46.el6_6.x86_64
php-cli-5.3.3-46.el6_6.x86_64
php-xml-5.3.3-46.el6_6.x86_64
php-common-5.3.3-46.el6_6.x86_64
php-mysql-5.3.3-46.el6_6.x86_64
php-devel-5.3.3-46.el6_6.x86_64
php-pdo-5.3.3-46.el6_6.x86_64
php-gd-5.3.3-46.el6_6.x86_64
php-mbstring-5.3.3-46.el6_6.x86_64
php-ldap-5.3.3-46.el6_6.x86_64
php-mcrypt-5.3.3-4.el6.x86_64
If you put this into your /config/site.php it should get rid of the background image, otherwise you can just copy/paste what it says into a text file or code block here.
Also, what version of C5 do you have installed?
define('WHITE_LABEL_DASHBOARD_BACKGROUND_SRC', 'none');
Also, what version of C5 do you have installed?
I'm trying to export from V5.6.3.3.
Here is all of the text:
error->add(t('Invalid Batch')); } if (!$this->token->validate("update_batch")) { $this->error->add($this->token->getErrorMessage()); } if (!$this->error->has()) { switch($_POST['action']) { case 'delete': $batch->delete(); $this->redirect('/dashboard/migration/batches', 'batch_deleted'); break; } } $this->view_batch($_POST['id']); } public function remove_from_batch() { $id = $_POST['id']; if ($id) { $batch = MigrationBatch::getByID($id); } if (!is_object($batch)) { $this->error->add(t('Invalid Batch')); } if (!$this->token->validate("remove_from_batch")) { $this->error->add($this->token->getErrorMessage()); } $r = new stdClass; if (!$this->error->has()) { $r->error = false; $r->pages = array(); foreach((array) $_POST['batchPageID'] as $cID) { $r->pages[] = $cID; $batch->removePageID($cID); } } else { $r->error = true; $r->messages = $this->error->getList(); } print Loader::helper('json')->encode($r); exit; } public function view_batch($id = null) { if ($id) { $batch = MigrationBatch::getByID($id); } if (is_object($batch)) { $this->set('batch', $batch); $this->set('pages', $batch->getPages()); } } public function batch_deleted() { $this->set('message', t('Batch deleted.')); $this->view(); } public function view() { $batches = MigrationBatch::getList(); $this->set('batches', $batches); } public function submit() { if ($this->token->validate("submit")) { $batch = MigrationBatch::create($_POST['description']); $this->redirect('/dashboard/migration/batches', 'view_batch', $batch->getID()); } else { $this->error->add($this->token->getErrorMessage()); } } }
concrete5
Return to Website
Dashboard
Intelligent Search
Sign Out
getDashboardPaneHeaderWrapper(t('Migration Tool'))?> controller->getTask() == 'view_batch' && $batch) { ?>
output("update_batch")?>
getCollectionName()?> getCollectionDescription()?>
getID()?> getTimestamp()?> getDescription()?>
output("submit")?>
textarea('description', array('style' => 'height: 120px'))?>
getDashboardPaneFooterWrapper();?>
Here is all of the text:
error->add(t('Invalid Batch')); } if (!$this->token->validate("update_batch")) { $this->error->add($this->token->getErrorMessage()); } if (!$this->error->has()) { switch($_POST['action']) { case 'delete': $batch->delete(); $this->redirect('/dashboard/migration/batches', 'batch_deleted'); break; } } $this->view_batch($_POST['id']); } public function remove_from_batch() { $id = $_POST['id']; if ($id) { $batch = MigrationBatch::getByID($id); } if (!is_object($batch)) { $this->error->add(t('Invalid Batch')); } if (!$this->token->validate("remove_from_batch")) { $this->error->add($this->token->getErrorMessage()); } $r = new stdClass; if (!$this->error->has()) { $r->error = false; $r->pages = array(); foreach((array) $_POST['batchPageID'] as $cID) { $r->pages[] = $cID; $batch->removePageID($cID); } } else { $r->error = true; $r->messages = $this->error->getList(); } print Loader::helper('json')->encode($r); exit; } public function view_batch($id = null) { if ($id) { $batch = MigrationBatch::getByID($id); } if (is_object($batch)) { $this->set('batch', $batch); $this->set('pages', $batch->getPages()); } } public function batch_deleted() { $this->set('message', t('Batch deleted.')); $this->view(); } public function view() { $batches = MigrationBatch::getList(); $this->set('batches', $batches); } public function submit() { if ($this->token->validate("submit")) { $batch = MigrationBatch::create($_POST['description']); $this->redirect('/dashboard/migration/batches', 'view_batch', $batch->getID()); } else { $this->error->add($this->token->getErrorMessage()); } } }
concrete5
Return to Website
Dashboard
Intelligent Search
Sign Out
getDashboardPaneHeaderWrapper(t('Migration Tool'))?> controller->getTask() == 'view_batch' && $batch) { ?>
output("update_batch")?>
getCollectionName()?> getCollectionDescription()?>
getID()?> getTimestamp()?> getDescription()?>
output("submit")?>
textarea('description', array('style' => 'height: 120px'))?>
getDashboardPaneFooterWrapper();?>
This is really strange, I created a new install of 5.6.3.3 with default content and I don't get what you get, but it also doesn't work. I actually get a blank page with just the background where I can't do anything. No errors in my PHP log.
What version have you seen the migration tools work with? Is it possible for me to upgrade or downgrade to that version easily?
I have to be a bit careful because my instance is a production one so I don't want to do anything with Concrete5 which will affect the current look and feel of the website.
I have to be a bit careful because my instance is a production one so I don't want to do anything with Concrete5 which will affect the current look and feel of the website.
I managed to get a test site up and running to do some additional testing of this.
A couple of things tried this morning with no good results:
- Upgraded to 5.6.3.4 - Similar HTML errors.
- Tried to replace the screen with a white screen as suggested. That parameter as pasted did not take. When logging in after that, I got text at the top of the page and no Dashboard/Edit line at the top of the login page. See the attached screen shot.
Can you give me a screen shot of what the screen should look like? Also, what are the upgrade options if I don't use the migration tools? Shouldn't there be a way to export without them? I only have one big combined site so if there is a full site export which could be used instead of the batch migration, perhaps that would be a possibility?
A couple of things tried this morning with no good results:
- Upgraded to 5.6.3.4 - Similar HTML errors.
- Tried to replace the screen with a white screen as suggested. That parameter as pasted did not take. When logging in after that, I got text at the top of the page and no Dashboard/Edit line at the top of the login page. See the attached screen shot.
Can you give me a screen shot of what the screen should look like? Also, what are the upgrade options if I don't use the migration tools? Shouldn't there be a way to export without them? I only have one big combined site so if there is a full site export which could be used instead of the batch migration, perhaps that would be a possibility?
Remove the around that line and it will work.
OK, so that got rid of the background pic and makes the error more visible (see attached screenshot).
Now, how do I go about getting around the problem?
And *are* there other export/import options?
Now, how do I go about getting around the problem?
And *are* there other export/import options?
Unfortunately I am not able to replicate your errors and I do not know of any other export options.
I got the migration_tool package to work once, but I haven't been able to find the code for it from that time yet.
I got the migration_tool package to work once, but I haven't been able to find the code for it from that time yet.
Ok, I was able to track down the change that made my export work previously and tested it in a "full" clean install and it works.
Here is the issue (which has not yet been fixed) with the solution in ithttps://github.com/concrete5/addon_migration_tool_legacy/issues/2... so what I had to do was to open up concrete/core/models/page.php, find the export method and comment out these lines:
I'm not sure what else this affects so after you run the export I would add those lines back in just in case, but that seemed to fix the issues I was seeing.
Here is the issue (which has not yet been fixed) with the solution in ithttps://github.com/concrete5/addon_migration_tool_legacy/issues/2... so what I had to do was to open up concrete/core/models/page.php, find the export method and comment out these lines:
$v = View::getInstance(); $v->disableEditing(); $v->disableLinks(); $v->enablePreview(); ob_start(); $v->render($this); ob_end_clean();
I'm not sure what else this affects so after you run the export I would add those lines back in just in case, but that seemed to fix the issues I was seeing.
A couple of things:
First, another, more knowledgeable php guy, suggested turning on the short_open_tag parameter. That cleared up the excess strange coding on the batch exports page and made it more clear.
But, as you pointed out, it still does not seem to do anything. I looked at the version of page.php and I don't have the lines you suggest, or at least I don't find them in a row. Am I supposed to be finding them scattered throughout the file?
If there is a fix on the horizon, then perhaps it would be best to wait until that fix is in place. Are you thinking that we might see such a fixed version coming down the line?
First, another, more knowledgeable php guy, suggested turning on the short_open_tag parameter. That cleared up the excess strange coding on the batch exports page and made it more clear.
But, as you pointed out, it still does not seem to do anything. I looked at the version of page.php and I don't have the lines you suggest, or at least I don't find them in a row. Am I supposed to be finding them scattered throughout the file?
If there is a fix on the horizon, then perhaps it would be best to wait until that fix is in place. Are you thinking that we might see such a fixed version coming down the line?
Well, that issue report was from December and hasn't yet been implemented, so I have no idea when it might be. Those lines should all be together around line 730 of the file. If you have used the Dashboard to update in the past you probably need to look in updates/concrete_5.6.3.4/concrete/core/models/page.php