Wordpress export: add vs replace (Artiseer 4 RC2) |
|
psimard
|
After exporting a theme for Wordpress which includes content, I get a message:
Do you want to import Content? Add Content - Replace imported Content - Close
What is the difference between "add" and "replace" and what would prevent "replace" from working?
|
|
Nick
|
As the wording suggests, "add" will add the imported content to your existing pages, and "replace" will replace them. If you choose replace your "old" pages will not get deleted. Artisteer will import the content and use custom menus. In the custom menus the "old" pages won't be included. You can add them if you want.
If you experiment 5-10 minutes with it, you will know what I'm talking about.
Now, content importing has a bug. It will import the images, but the paths to them in the pages will be wrong. You have to delete the "./images" part from the paths of the images to make them work.
|
|
Mike Allen
|
"Now, content importing has a bug. It will import the images, but the paths to them in the pages will be wrong. You have to delete the "./images" part from the paths of the images to make them work. "
You would have thought that would be an easy thing to fix - but as I have just found - it hasnt been fixed with the latest version - as of 8th Nov 2012
|
|
richard
|
Yep. caused by poor coding and lack of testing in
Line 266: .your-theme-dir/content/content-importer.php
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
return $start . $quote . $this->upload_dir['url'] . '/' . $filename . $quote . $end; } }
The calling function appears to try some regex replace but either fails to remove or adds in the hooky directory to the path. I can't be bothered to debug it. To fix you can amend the function by adding one line:
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
$filename = str_replace( "./images", "", $filename );
return $start . $quote . $this->upload_dir['url'] . $filename . $quote . $end;
}
}
This can be added to the exported theme but a much better, permanent solution (until next release when I would hope they would have fixed this) is to do it in the Artisteer program dir:
Mine is C:\Program Files (x86)\Artisteer 4\Library\Data\Templates\WordPress\template\content
You need to make sure full write access is granted on the dir or else Windows creates a personal copy and none of the edits will be seen by Artisteer. You also need to restart Artisteer as all files are cached and change only picked up when the program starts.
As I've said before I find the whole content editing in Artisteer when using Wordpress notion totally naff, however there seem to be plenty of folk who like it so they should at least be able to use it without having to edit a load of fiddly, incorrect urls to get the images to show. Shame on the developers for leaving this for so long without a patch. It took me all of 45 minutes to find the code, experiment and create a fix.
Job done...
|
|
dreamwc
|
@richard - Thanks for that! That bug is driving me crazy!
QUESTION FOLKS:
Anyone else have this problem...I create a slideshow and if I edit that page in Wordpress the slideshow disappears. Any idea what is going on there? Anyone have a fix?
|
|
Tracy
|
Ah Richard, you are now my hero!!! I have really been battling the content issue. I do work on the content within the program and is one of the reasons I like the new Artisteer 4 but the images not uploading and showing up was driving me crazy.
Thank you again,
Tracy
Quote richard:
Yep. caused by poor coding and lack of testing in
Line 266: .your-theme-dir/content/content-importer.php
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
return $start . $quote . $this->upload_dir['url'] . '/' . $filename . $quote . $end; } }
The calling function appears to try some regex replace but either fails to remove or adds in the hooky directory to the path. I can't be bothered to debug it. To fix you can amend the function by adding one line:
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
$filename = str_replace( "./images", "", $filename );
return $start . $quote . $this->upload_dir['url'] . $filename . $quote . $end;
}
}
This can be added to the exported theme but a much better, permanent solution (until next release when I would hope they would have fixed this) is to do it in the Artisteer program dir:
Mine is C:\Program Files (x86)\Artisteer 4\Library\Data\Templates\WordPress\template\content
You need to make sure full write access is granted on the dir or else Windows creates a personal copy and none of the edits will be seen by Artisteer. You also need to restart Artisteer as all files are cached and change only picked up when the program starts.
As I've said before I find the whole content editing in Artisteer when using Wordpress notion totally naff, however there seem to be plenty of folk who like it so they should at least be able to use it without having to edit a load of fiddly, incorrect urls to get the images to show. Shame on the developers for leaving this for so long without a patch. It took me all of 45 minutes to find the code, experiment and create a fix.
Job done...
|
|
richard
|
Quote Marco:
How i can stop this bad message?
I press Replace Imported Content but next time on every page i see again!
you could Start by reading my post and implementing the fix....
|
|
Athar
|
I have tried all the solutions above but still the images cannot appear right. Is there any other solution.
Artisteer 4
|
|
richard
|
No. The above works so I would suggest an error in your implemenation...
|
|
hostgator
|
Quote Tracy:
Ah Richard, you are now my hero!!! I have really been battling the content issue. I do work on the content within the program and is one of the reasons I like the new Artisteer 4 but the images not uploading and showing up was driving me crazy.
Thank you again,
Tracy
Quote richard:
Yep. caused by poor coding and lack of testing in
Line 266: .your-theme-dir/content/content-importer.php
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
return $start . $quote . $this->upload_dir['url'] . '/' . $filename . $quote . $end; } }
The calling function appears to try some regex replace but either fails to remove or adds in the hooky directory to the path. I can't be bothered to debug it. To fix you can amend the function by adding one line:
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
$filename = str_replace( "./images", "", $filename );
return $start . $quote . $this->upload_dir['url'] . $filename . $quote . $end;
}
}
This can be added to the exported theme but a much better, permanent solution (until next release when I would hope they would have fixed this) is to do it in the Artisteer program dir:
Mine is C:\Program Files (x86)\Artisteer 4\Library\Data\Templates\WordPress\template\content
You need to make sure full write access is granted on the dir or else Windows creates a personal copy and none of the edits will be seen by Artisteer. You also need to restart Artisteer as all files are cached and change only picked up when the program starts.
As I've said before I find the whole content editing in Artisteer when using Wordpress notion totally naff, however there seem to be plenty of folk who like it so they should at least be able to use it without having to edit a load of fiddly, incorrect urls to get the images to show. Shame on the developers for leaving this for so long without a patch. It took me all of 45 minutes to find the code, experiment and create a fix.
Job done...
I make changes everything linke you say with changing here: Artisteer 4\Library\Data\Templates\WordPress\template\content and line 266 is changed, but problem is still here
I have my pictures on my server but I don't have it on my site.
I don't know why I have on my folder /wp-content/upload 6 diferent size of same pictures ??
Example DSC5888, DSC5888large 150X150, DSC5888large 1024X685 ......
Do I working something wrong or Artisteer doing something wrong.
|
|
david
|
not to be funny, but why are we implementing a fix when its dont to the developers to release an update of the software
|
|
Dave
|
Because, my like-named brother, it (obviously) takes the gentle team at Artisteer time to implement changes in batches (which I am sure they do) whether RC or permanent. Developers and coders more insightful than I pick up the bugs and glitches, report them, and then the next release, we must hope, will be superior.
For all its behind-biting deficits, Artisteer remains one of the (if not the) best theme creator I've ever seen. Certainly on a local basis no one can come close to anything I can create with Artisteer independently of its.
But then again, the caffeine is wearing off, so what do I know?
|
|
richard
|
professional software development doesn't involve half arse coding, no unit testing, no SIT and introduction of regression errors with every release....
|
|
Patrick
|
Thanks, bugged me that it never worked.
Quote richard:
Yep. caused by poor coding and lack of testing in
Line 266: .your-theme-dir/content/content-importer.php
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
return $start . $quote . $this->upload_dir['url'] . '/' . $filename . $quote . $end; } }
The calling function appears to try some regex replace but either fails to remove or adds in the hooky directory to the path. I can't be bothered to debug it. To fix you can amend the function by adding one line:
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
$filename = str_replace( "./images", "", $filename );
return $start . $quote . $this->upload_dir['url'] . $filename . $quote . $end;
}
}
This can be added to the exported theme but a much better, permanent solution (until next release when I would hope they would have fixed this) is to do it in the Artisteer program dir:
Mine is C:\Program Files (x86)\Artisteer 4\Library\Data\Templates\WordPress\template\content
You need to make sure full write access is granted on the dir or else Windows creates a personal copy and none of the edits will be seen by Artisteer. You also need to restart Artisteer as all files are cached and change only picked up when the program starts.
As I've said before I find the whole content editing in Artisteer when using Wordpress notion totally naff, however there seem to be plenty of folk who like it so they should at least be able to use it without having to edit a load of fiddly, incorrect urls to get the images to show. Shame on the developers for leaving this for so long without a patch. It took me all of 45 minutes to find the code, experiment and create a fix.
Job done...
|
|
Benedict
|
Instructions incomplete for noobs.
You add this line (like what is stated above):
$filename = str_replace( "./images", "", $filename );
to your content-importer.php
Save.
Deactivate theme. Reactivate your Artisteer theme. Add content? Yes.
Done.
|
|
richard
|
Quote Benedict:
Instructions incomplete for noobs.
You add this line (like what is stated above):
$filename = str_replace( "./images", "", $filename );
to your content-importer.php
Save.
Deactivate theme. Reactivate your Artisteer theme. Add content? Yes.
Done.
Not incomplete. My instructions describe how to remedy the code in Artisteer so that exported themes work going forward. Editing the exported theme as you suggest needs to be done every time. ..
|
|
Yazzy
|
Thank you Richard, so very, very much - I had spent a couple of days trying to resolve this issue myself, but it never happened. Found this post and it has now sorted it out. changed it within Artisteer itself, as advised. Brilliant and thank you for sharing
Quote richard:
Yep. caused by poor coding and lack of testing in
Line 266: .your-theme-dir/content/content-importer.php
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
return $start . $quote . $this->upload_dir['url'] . '/' . $filename . $quote . $end; } }
The calling function appears to try some regex replace but either fails to remove or adds in the hooky directory to the path. I can't be bothered to debug it. To fix you can amend the function by adding one line:
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
$filename = str_replace( "./images", "", $filename );
return $start . $quote . $this->upload_dir['url'] . $filename . $quote . $end;
}
}
This can be added to the exported theme but a much better, permanent solution (until next release when I would hope they would have fixed this) is to do it in the Artisteer program dir:
Mine is C:\Program Files (x86)\Artisteer 4\Library\Data\Templates\WordPress\template\content
You need to make sure full write access is granted on the dir or else Windows creates a personal copy and none of the edits will be seen by Artisteer. You also need to restart Artisteer as all files are cached and change only picked up when the program starts.
As I've said before I find the whole content editing in Artisteer when using Wordpress notion totally naff, however there seem to be plenty of folk who like it so they should at least be able to use it without having to edit a load of fiddly, incorrect urls to get the images to show. Shame on the developers for leaving this for so long without a patch. It took me all of 45 minutes to find the code, experiment and create a fix.
Job done...
|
|
ranggadipta
|
Alternative solution: change your wp-config.php and add this line
1. define( 'UPLOADS', 'wp-content/uploads/'.'images' );
2. go to wp-admin > settings > media > deactive "Organize my uploads into month- and year-based folders"
3. reexport your artisteer theme.
|
|
Dave
|
ranggadipta...to use what you suggest....as someone who has not tried this yet, would I first export a theme, then do steps 1-3? Just to be sure?
|
|
Teijo
|
Sadly reading the same bug I just found also in my case.
I am running standard 4.0 and WP 3.51 and found the bug in the path.
Do I understand that 4.1 would not include the fix to this bug ??!!
Could do the proposal by ranggadipta for my testing installation, but
seriously - I do expect the fix to appear in 4.1 - soon!!
|
|
Mohammed
|
I have the same problem, and I tried to post all steps which provided from Richard or others, but the problem is sill not being worked,
what we can happen, is this problem from Artisteer IT,
please, any other solution?
|
|
Keith Whalen
|
Post 2 from Nick should be the answer I am looking for but it’s not doing what I expect..
Basically I have created a couple of pages in an ArtISteer template which I want to include in my WP Theme. When I upload the theme I select “Add Content” so as I expect my Artisteer pages and widgets, including some FB and Twitter Icons I set up are there and work which is what I want but the existing pages already created in WP before the theme upload do not appear in the Menu. I can still see them in the Dashboard and searches for them within the site work and they display with the new theme format but they are not on the Menu bar. Also if I add new pages within the dashboard they also fail to appear on the Menu.
Basically I want to import a theme with content from ArtISteer, including a couple of pages with images + widgets and know that as I add pages via the dashboard they will appear in the menu and be accessible
Any help greatly appreciated..
|
|
Mohammed
|
I have the same problem, and I tried to post all steps which provided from Richard or others, but the problem is sill not being worked,
Quote Mike Allen:
"Now, content importing has a bug. It will import the images, but the paths to them in the pages will be wrong. You have to delete the "./images" part from the paths of the images to make them work. "
You would have thought that would be an easy thing to fix - but as I have just found - it hasnt been fixed with the latest version - as of 8th Nov 2012
If it is not being solved, I'll really exchange my viewpoint about Atristeer,
I think, it is not difficult from office IT to solve it by provide our with plugin which organize slideshow
|
|
Robert
|
I have the problem myself.. Can someone give me a fix that works??? I have tried the above and doesnt work. Please ....
|
|
Joanne
|
I have the same problem and am pretty frustrated. Does anybody know how to fix this, really appreciate comments
|
|
Cees
|
I do not have any of these problems wih Artisteer 4.1.0
No problem with images, no problem with adding or replacing content!
|
|
Durenda
|
I found using a search and replace has worked fast and easy to fix the ./ problem.
|
|
InternetSolutions24x7
|
Had this problem some time ago ... i think was version 3 something. Now in 4 have same problem(might be caused by a png image from above header). Previously(vers 3) this final fix worked but now I cant find that folder in Wordpress my path goes only to C:\Program Files (x86)\Artisteer 4\Library\Data\Templates\WordPress\ without template and/or content in it.
I reinstalled with no extra folders...... and also I have changed the png image from header(not as background but as above of it, one you can resize, move etc.) and now everything works fine.
Maybe this helps someone.
Quote richard:
Yep. caused by poor coding and lack of testing in
Line 266: .your-theme-dir/content/content-importer.php
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
return $start . $quote . $this->upload_dir['url'] . '/' . $filename . $quote . $end; } }
The calling function appears to try some regex replace but either fails to remove or adds in the hooky directory to the path. I can't be bothered to debug it. To fix you can amend the function by adding one line:
private function real_sources($match) {
list($str, $start, $quote, $filename, $end) = $match;
if (isset($this->inserted_name[$filename])) {
return $start . $quote . $this->inserted_name[$filename] . $quote . $end;
}
else
{
$filename = str_replace( "./images", "", $filename );
return $start . $quote . $this->upload_dir['url'] . $filename . $quote . $end;
}
}
This can be added to the exported theme but a much better, permanent solution (until next release when I would hope they would have fixed this) is to do it in the Artisteer program dir:
Mine is C:\Program Files (x86)\Artisteer 4\Library\Data\Templates\WordPress\template\content
You need to make sure full write access is granted on the dir or else Windows creates a personal copy and none of the edits will be seen by Artisteer. You also need to restart Artisteer as all files are cached and change only picked up when the program starts.
As I've said before I find the whole content editing in Artisteer when using Wordpress notion totally naff, however there seem to be plenty of folk who like it so they should at least be able to use it without having to edit a load of fiddly, incorrect urls to get the images to show. Shame on the developers for leaving this for so long without a patch. It took me all of 45 minutes to find the code, experiment and create a fix.
Job done...
|
|
Adrian
|
So I'm having a similar problem and have not found a solution after weeks of crawling the web....
I have created a website in Artisteer which contains multiple pages with content.
When I install the theme, the theme works. When I click "add content" from the theme, my images are imported into my WordPress Media file.
However... not a single page will import or show up. Not even trying to manually type in the pages will bring them up.
Does anyone have a clue as to how to fix this? It used to work just fine when I uploaded my original site in 2013. But now WordPress will not import the pages.
Very frustrated! Eventually I will find the time to get a new computer, better software, and leave artisteer behind but for now I would appreciate help in fixing this bug.
|
|
|
|