Cruisers Forum
 


Join CruisersForum Today

Reply
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 06-11-2016, 07:41   #1
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

We badly need a few good men (or women)!

Goal: Migrate the 4 Wiki Books from Drupal to Dokuwiki:
OpenCPN User Manual
Supplementary Hardware
Supplementary Software
Developers Manual
This is dirty, dangerous, tedious, repetitive, precise work, editing & comparing but there is no other way to speed this up. It is unpaid work quickly forgotten once the job is done, but if you really want to help, we can make this like a barn raising and get it done this week!

Please PM me.

The images and screenshots have all been moved, so you will just be migrating text between two editors. Changing the image links, and verifying all the images show.

Later we will have to correct all the internal document links and check the external links which will probably be fine.

Thank you
Rick Gleason
__________________

rgleason is online now   Reply With Quote
Old 06-11-2016, 11:17   #2
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

"Getting Started" and all pages below have been migrated
Image links have been edited and should be working.
Code:
eg: {{:opencpn:opencpn_user_manual:___
Internal document links have not been reviewed.
Code:
eg: [[:opencpn:opencpn_user_manual:getting_started:opencpn_installation]]
External document links have not been reviewed.
We need more people doing this.

DO NOT EDIT THE DRUPAL WEBSITE ANY MORE, THOSE CHANGES WILL BE LOST!!!!
__________________

rgleason is online now   Reply With Quote
Old 06-11-2016, 11:45   #3
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

The next section down that needs to be migrated is

TOOLBAR Buttons
Zooming
Scaling Charts
Create Route have been migrated.
Auto Follow
Options Setting
...and the rest need to be migrated next!

I am not going to be able to do this entire wiki myself. Also I will only have intermittent internet after Thursday, so lets get this done now! Otherwise this is just going to sit for the next month probably.
rgleason is online now   Reply With Quote
Old 06-11-2016, 14:20   #4
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

Here are the instructions for Migrating to Dokuwiki.

https://forum.dokuwiki.org/post/54404
1. Find & Replace - CKG Edit does have this feature, however all features are greyed out and do not work when "Source" HTML button is selected, so this cannot be used to find image and file pathnames which need to be corrected during a migration!
We need a Find & Replace tool that will be able to work with the server files on line & will work with authentication.
Is Bash a possibility?

2. Use of CKG Editor and DW Editor for Migration.

A. Open Druple 6 website, navigate to the page to be migrated and select edit.
B. Copy all to Clipboard (Ctrl+A, then Ctrl+C).
C. Open the DokuWiki website, navigate to the page to receive content (previously created).
D. Get into CKG Edit mode. Select Edit. If CKG Edit is available at the bottom menu, select it.
F. When Edit mode closes, select Edit again.
G. Now you are in CKG Edit mode and "DW Edit" selection should be in the bottom menu.
H. Put the cursor in the edit window below the title, and Paste the clipboard contents Ctl+V
I. Pick "Save". Then when saved, pick "Edit".
J. Now switch to DW Edit mode by picking "DW Edit" from the bottom menu.
K. When Edit closes, select "Edit" again.
L. "CKG Edit" should now be in the bottom menu. You are in DW Edit Mode.
M. Now use your Browser "Edit" > "Find" to search for all image paths.
N. Enter into Find
Code:
{{:opencpn:opencpn_user_manual
and hit search.
O. Now inspect the pathname for the image and change it (shorten it generally) so that image links will work.
P. Save and view the migrated document.
Q. Compare with the original document in Druple.
R. All Internal File links and External File links will have to be checked later.

This has to be done for every page!

3. Media/Screenshots/Photos - The Dokuwiki path to the media for this namespace is
Code:
{{:opencpn;opencpn_user_manual:[filename]}}
It soon became apparent that Dokuwike does not accept filenames with uppercase characters and the migration process changes all filenames to lowercase. Therefore the 750 media files I had uploaded had to be changed. I made a bat file called renamefiles2lowercase.bat and put in it
Code:
for /F %%a in ('dir /L /B') do rename %%a %%a
To be clear, all 750 (approx) image files have been fixed to be lowercase and uploaded again. Editors assisting need be sure the DW Editor pathname is correct IE
Code:
{{:opencpn:opencpn_user_manual:[filename]}}
NOTE: Often the filename will have several hypens in it like this "user_rickgleason_realfilename.jpg[otherinformation]". I this case you should delete the first part of the filename so it reads "realfilename.jpg[otherinformation]" and the full DW Editor pathname would be

Code:
{{:opencpn:opencpn_user_manual:realfilename.jpg[otherinformation]}}
This is why I need some help, because there is no reason I should to do all this by myself! So step up to the plate, because I am not continuing with this until others are actively involved.
rgleason is online now   Reply With Quote
Old 07-11-2016, 10:39   #5
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

Gilletarom Please see this comparison with Mediawiki.
WikiMatrix - Compare them all
Dokuwiki has all the same features, but has a flat file system which gives us much more flexibility long term (ease upgrading etc because everything is not stuck in a database!)

Also look at this! If User Editors can use Firefox browser + Its All Text Extension + NotePad++ RegEx search and replace can be done on any of our Opencpn Dokuwiki pages! See this message and the two following: https://forum.dokuwiki.org/post/54428
Also this forum link: https://forum.dokuwiki.org/post/53666

Notepad++ https://notepad-plus-plus.org/
Firefox Extension Its All Text https://addons.mozilla.org/en-US/fir...l-text/?src=ss

This will make it much easier to change image and file pathnames during the migration! and available to any Editor.

Also see this search & replace for media files.
https://forum.dokuwiki.org/post/54414
rgleason is online now   Reply With Quote
Old 07-11-2016, 20:16   #6
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
USER VOLUNTEERS - It is our job to maintain the Documentation!

We need skilled EDITORS to step up to the plate here, but only if you are a USER! It is a USER job to maintain the USER DOCUMENTATION!
[You do not want to distract the programmers with this job, do you?]
So please help us migrate the Wiki documentation now!

1. First register at the new OpenCPN Dokuwiki
Register for OpenCPN Dokuwiki

2. Register for the old Drupal Website (if you have not done so) so you can go into Edit mode.
Register for OpenCPN.org

3. Then send me a PM so that I can change your permissions to Manager.

4. You will then need to review some of the previous posts for process.

We are focused on Migration of the OpenCPN User Manual. I just completed migration of Opencpn_User_Manual: AIS which has been completely reformatted and all image links have been changed to the new path. I believe this is a good example for others to follow and learn. Please inspect it, but don't change it. The next empty page is "Marks & Routes".

Later after all documents have been migrated, we will need to modify all Internal Page links towards these new pages when we have fully migrated all pages in the Namespace - Book known as "OpenCPN User Manual".

Thank you.
rgleason is online now   Reply With Quote
Old 09-11-2016, 09:38   #7
Registered User

Join Date: Jun 2010
Location: St. Petersburg, Florida
Boat: Gemini 3200
Posts: 743
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

I am at a loss. See if I've interpreted the needed changes correctly. Help me out with how I get the Docuwiki page to look like something other than HTML source.

A. Open Druple 6 website, navigate to the page to be migrated and select edit.
The manual page changes to HTML source.
B. Copy all to Clipboard (Ctrl+A, then Ctrl+C).
This works as expected.
C. Open the DokuWiki website, navigate to the page to receive content (previously created).
D. Get into CKG Edit mode. Select Edit. If CKG Edit is available at the bottom menu, select it.

A little confusing. If there's a CKG Edit button at the bottom it means you are not in CKG Edit mode, so F and G are necessary. If DW Edit is at the bottom you are already in CKG Edit mode and should skip F and G
F. When Edit mode closes, select Edit again.
G. Now you are in CKG Edit mode and "DW Edit" selection should be in the bottom menu.
H. Put the cursor in the edit window below the title, and Paste the clipboard contents Ctl+V

The HTML source from B is pasted. How do I get out of source display?
I. Pick "Save". Then when saved, pick "Edit".
J. Now switch to DW Edit mode by picking "DW Edit" from the bottom menu.
K. When Edit closes, select "Edit" again.
L. "CKG Edit" should now be in the bottom menu. You are in DW Edit Mode.
M. Now use your Browser "Edit" > "Find" to search for all image paths.
N. Enter into Find
Code:
{{:opencpn:opencpn_user_manual
and hit search.

The images in the HTML source I copied are all in the form

Code:
<img alt="" height="32" src="/sites/default/files/users/taifun/ais.png" width="32" />&nbsp; <img alt="" height="32" src="/ocpn/sites/default/files/users/taifun/ais_alive_active.png" width="32" />
The search string in the previous code snippet simply doesn't exist in the source document.

O. Now inspect the pathname for the image and change it (shorten it generally) so that image links will work.
The example above was changed to

Code:
{{:opencpn:opencpn_user_manual:ais.png?nolink&32x32}}.
Only the file name was retained. The path was replaced with opencpnpencpn_user_manual. I'm guessing the ?nolinkJ&32x32 came from the height and width in the HTML specification.

P. Save and view the migrated document.
This is where I see HTML source instead of a formatted document.
Q. Compare with the original document in Druple.
R. All Internal File links and External File links will have to be checked later.


The page I worked on is "Ship Track". It was the first empty page I came across, so I figured it was next up for editing. Something I did moved it ahead of the "Zooming" page when it should be after "Route and Mark Manager."

Fabbian
fgd3 is offline   Reply With Quote
Old 09-11-2016, 12:00   #8
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

Quote:
D. Get into CKG Edit mode. Select Edit. If CKG Edit is available at the bottom menu, select it.
A little confusing. If there's a CKG Edit button at the bottom it means you are not in CKG Edit mode, so F and G are necessary. If DW Edit is at the bottom you are already in CKG Edit mode and should skip F and G
F. When Edit mode closes, select Edit again.
G. Now you are in CKG Edit mode and "DW Edit" selection should be in the bottom menu.


Fabbian you got this right:

1. If DW Edit button appears at the bottom you are in CKG Edit mode (html) ready to accept a PASTE from the Opencpn.org page.

2. If CKG Edit appears at the bottom you are in DW Edit (DokuWiki syntax) and are ready to edit the Image Links.

I have copied Ship Track from opencpn.org again and pasted into the respective Ship Track when in CKG edit mode (with DW Edit showing at the bottom).

Then I "Saved" the page. Then picked "DWEdit" from the side menu which puts me straight into DW Edit mode (with CKG Edit showing at the bottom). Now in DWEdit mode I can edit the Image Links and correct the formatting to look like the opencpn.org page.

I have left some comments at the top of Ship TrackShip Track [Opencpn]

To help you and others with formatting image links. You can leave them for awhile and go on and do the other Image links.

What I had found was that there was HTML showing when in the DW Edit window, which should not be the case. It should have all been translated to Dokuwiki format when you switched from the CKG Editor to the DW Editor, automatically.

Incidently you will need to learn the Dokuwiki syntax which is on this page.
https://www.dokuwiki.org/wiki:syntax

Thanks for volunteering, you're most of the way there.
BTW we are just fixing the Image links and syntax first.
Image links are enclosed with {{ }} and can include width and height.

The Internal text links which may have html path are in these brackets [[ ]]
and we will be fixing those when we have moved all the pages over to this wiki, so we know the page and internal references exist.
rgleason is online now   Reply With Quote
Old 09-11-2016, 14:40   #9
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

Fabbian if this is not clearer, just ask. Thanks!
rgleason is online now   Reply With Quote
Old 09-11-2016, 16:38   #10
Registered User

Join Date: Jun 2010
Location: St. Petersburg, Florida
Boat: Gemini 3200
Posts: 743
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

It's still not working. I tried the toolbar button "Help" page. No problem copying the source document, but when I paste it into the dokuwiki page the {{indexmenu_n>10}} line gets wiped out and I can't replace it. And I'm still left with a bunch of HTML source that doesn't get formatted.

Fabbian
fgd3 is offline   Reply With Quote
Old 09-11-2016, 17:52   #11
Registered User

Join Date: Jun 2010
Location: St. Petersburg, Florida
Boat: Gemini 3200
Posts: 743
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

I managed to make a little progress with the toolbar button "Help" page. Here's how I did it.

1. I went to the original manual wiki. I did not select "Edit". I just highlighted the pertinent section and copied it to the clipboard. (If I select "Edit" the screen turns to raw HTML. There used to be a way to do WYSIWYG editing but it's not available to me any more.)

2. I went to the dokuwiki page (which I had to recreate because I kept trying to get the indexmenu line to work) and chose CKG Edit. I pasted the contents of the clipboard there.

3. I switched to DW Edit. I managed to change the image specification so it would display the Help button properly by simply editing the text.

4. I tried to change the link to the Getting Started page. When I previewed the page the text--including the square brackets--appeared instead of a link. After considerable experimentation--adding a colon, removing a colon, trying curly braces, going back to square brackets--I removed the heading markers (====) and got the link to display properly. But the original document had the link in the enlarged, bold line of text.

I sure don't understand the advantage of migrating a document written in HTML to a platform that requires learning a new markup language, particularly one that lacks features used in the original manual. One of the reasons HTML has been so successful is you can create and modify it with any text editor. It is so frustrating having to switch back and forth between CKG Edit and DW Edit because different tasks work in one but not the other. It's even more frustrating because even DW Edit (which looks like a straight text editor) doesn't let me add an indexmenu line.

Aren't you going to have to generate the manual in HTML anyway for the built in version? Dokuwiki allows you to use HTML code if you wrap it in <html></html> tags. Have you tried just adding those tags to the existing manual pages?

By the way, somehow the indexmenu line didn't get removed from the page I created, but it didn't work properly, either. It just appears at the top of the page as red text.

Fabbian
fgd3 is offline   Reply With Quote
Old 09-11-2016, 18:48   #12
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

I managed to make a little progress with the toolbar button "Help" page. Here's how I did it.
-- great!

1. I went to the original manual wiki. I did not select "Edit". I just highlighted the pertinent section and copied it to the clipboard. (If I select "Edit" the screen turns to raw HTML. There used to be a way to do WYSIWYG editing but it's not available to me any more.)

---Is the "SOURCE" button in the upper left turned on?
-- When you Copy you do not want to see the HTML. Source should be OFF.

2. I went to the dokuwiki page (which I had to recreate because I kept trying to get the indexmenu line to work) and chose CKG Edit. I pasted the contents of the clipboard there.

-- That's good.

3. I switched to DW Edit. I managed to change the image specification so it would display the Help button properly by simply editing the text.

--- very good. The path is generally {{pencpnpencpn_user_manal: [imagefile] }}


4. I tried to change the link to the Getting Started page. When I previewed the page the text--including the square brackets--appeared instead of a link. After considerable experimentation--adding a colon, removing a colon, trying curly braces, going back to square brackets--I removed the heading markers (====) and got the link to display properly. But the original document had the link in the enlarged, bold line of text.

-- I'll look at this.

I sure don't understand the advantage of migrating a document written in HTML to a platform that requires learning a new markup language, particularly one that lacks features used in the original manual. One of the reasons HTML has been so successful is you can create and modify it with any text editor. It is so frustrating having to switch back and forth between CKG Edit and DW Edit because different tasks work in one but not the other. It's even more frustrating because even DW Edit (which looks like a straight text editor) doesn't let me add an indexmenu line.

--- I was frustrated at first too, and I am still learning. It promises to be easier to read than html I think. I am still learning, but the change from Dokuwiki to Html is handled quite seamlessly by changing editors. It seems confusing at first but it gets easier. I was able to add a direct DW Edit button in the left hand column that helps to reduce the number of clicks.

Aren't you going to have to generate the manual in HTML anyway for the built in version? Dokuwiki allows you to use HTML code if you wrap it in <html></html> tags. Have you tried just adding those tags to the existing manual pages?

--- Yes, bdbcat is working on this and there is a siteexport plugin that works but needs the correct index as in a book.
--- My reading about this states that this is for limited use, not all the time.

By the way, somehow the indexmenu line didn't get removed from the page I created, but it didn't work properly, either. It just appears at the top of the page as red text.

--- I' ll check. Thanks Fabbian! Will work on the email too.

Fabbian
rgleason is online now   Reply With Quote
Old 09-11-2016, 19:01   #13
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

Fabbian,
For the sort order code which goes at the very top above the title, use
{{indexmenu_n>10}}

the 2 braces are ended by 2 braces. You were using square brackets which is for Internal and External Links and you used that successfully down at the bottom.
Just one suggestion, for checking pathnames. If you go to the page you want and look at the url you will see the path which needs to be used.

The red link indicates that that page has not been created, and if you click on it you will be prompted do you want to create this page, and you will need to enter content and save, but it will save to the wrong location, because the path is not correct if it turns red.

So ship tracks path is
Code:
http://tgp-architects.com/dokuwiki/doku.php?id=opencpn:opencpn_user_manual:toolbar_buttons:ship_track
If you use
Code:
{{:opencpn:opencpn_user_manual:toolbar_buttons:ship_track|Ship Track ]]
It will work.

Watch those underlines too "ship-track" does not work. "ship_track" does. The "_" stands in for the space in the Title "===== Ship Tracks ====="

The Title ==== Ship Tracks ===== is used for the index page title automatically by our "indexmenu" plugin which does the navigation on the left.

Excellent start Fabbian! 2 pages done.
rgleason is online now   Reply With Quote
Old 09-11-2016, 19:15   #14
Registered User

Join Date: Jun 2010
Location: St. Petersburg, Florida
Boat: Gemini 3200
Posts: 743
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

I don't have a "source" button on the manual page. Look at these screenshots.

Shouldn't I be able to paste the raw HTML source into the DW Edit window and go from there? It doesn't seem to work, but I can't figure out why.

Fabbian
Attached Thumbnails
Click image for larger version

Name:	OpenCPNManual.jpg
Views:	69
Size:	290.5 KB
ID:	135686   Click image for larger version

Name:	OpenCPNManualEdit.jpg
Views:	65
Size:	278.9 KB
ID:	135687  

fgd3 is offline   Reply With Quote
Old 09-11-2016, 19:30   #15
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 12,062
Re: Opencpn Dokuwiki Migration -MOB- Help Needed!!! MOB

Fabbian,
Now I am having the same problem with the html code showing up in the DW Edit window.!!

I am going to have to ask about this on the forum myron turner.


PS: I just got around that problem by using the smaller Sectional "Edit" buttons you see on the left in a box inside the text edit area.

PSS: Finished MOB page. Need to develop the footer system, but I first have to read about it.
__________________

rgleason is online now   Reply With Quote
Reply

Tags
enc, mob, opencpn

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DokuWiki for Opencpn Manual ? rgleason OpenCPN 30 08-11-2016 17:57
Crew Available: Snowbird Migration Ardbeg Crew Archives 1 24-09-2016 14:41
For Sale: McMurdo Guardian MOB System TWO MOB watches and Receiver petedd Classifieds Archive 1 26-09-2015 17:31
opencpn plugin user help needed CaptainKevinM OpenCPN 11 13-07-2013 08:30
OpenCPN not responding - help needed mikepeter451 OpenCPN 5 21-10-2012 11:31



Copyright 2002- Social Knowledge, LLC All Rights Reserved.

All times are GMT -7. The time now is 06:01.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2019, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.